/*! copyright 2025 Aditude, Inc - Prebid - production - Updated: 2025-07-18T20:51:32.485Z, v1.4.0, creative-timed-refresh-component 77ed12fd3034151c8974 38b6721fdf67d7d1c595 */ (self.tudeChunk=self.tudeChunk||[]).push([[20900,37890,81665,96526],{659:function(e,t,r){var i=r(51873),n=Object.prototype,s=n.hasOwnProperty,o=n.toString,a=i?i.toStringTag:void 0;e.exports=function(e){var t=s.call(e,a),r=e[a];try{e[a]=void 0;var i=!0}catch(e){}var n=o.call(e);return i&&(t?e[a]=r:delete e[a]),n}},1882:function(e,t,r){var i=r(72552),n=r(23805);e.exports=function(e){if(!n(e))return!1;var t=i(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}},2853:function(e,t,r){"use strict";r.d(t,{E3:function(){return o},VC:function(){return a}});var i=r(14900),n=r(77467),s=r(9337);r.g.TUDE_SERVE_LOADED=!1;let o=(e="latest")=>{r.g.TUDE_SERVE_LOADED||document.querySelector("script[data-tudeserve]")||(r.g.TUDE_SERVE_LOADED=!0,(0,i.loadTudeServe)(e,"production"),l())},a=e=>{d().cmd.push(e)},d=()=>(window.tudeserve=window.tudeserve||{cmd:[]},window.tudeserve),l=()=>{a(e=>{e.events().on("bid_won",({bid:e,slot:t})=>{t.bids.filter(t=>t!==e).forEach(e=>{var t,r;if("amazon"===e.source&&(null==(t=e.sourceData)?void 0:t.amzniid)){let t=e.sourceData.slotID,r=e.sourceData.amzniid;(0,n.BI)({slotID:t,amzniid:r})}"prebid"===e.source&&(null==(r=e.sourceData)?void 0:r.adId)&&(e.sourceData.isRequesting=!1)})}),(0,s.Su)()&&(e.events().on("viewable",({bid:e,slot:t})=>{(0,s.Su)()&&(0,s.bf)("impressionViewable",{adServer:"tudeserve",adUnitPath:t.adUnit,bidder:e.bidder,cpm:e.amount,slotElementId:t.elementId,source:e.source,currency:e.currency,mediaType:e.mediaType})}),e.events().on("no_bid",({slot:e})=>{(0,s.Su)()&&(0,s.bf)("unfilledImpression",{adServer:"tudeserve",adUnitPath:e.adUnit,slotElementId:e.elementId})}),e.events().on("bid_won",({bid:e,slot:t})=>{(0,s.Su)()&&(0,s.bf)("bidWon",{adServer:"tudeserve",adUnitPath:t.adUnit,bidder:e.bidder,cpm:e.amount,slotElementId:t.elementId,source:e.source,currency:e.currency,mediaType:e.mediaType})}),e.events().on("request",({slot:e})=>{(0,s.Su)()&&(0,s.bf)("slotRequested",{adServer:"tudeserve",adUnitPath:e.adUnit,slotElementId:e.elementId})}),e.events().on("impression",({bid:e,slot:t})=>{(0,s.Su)()&&(0,s.bf)("impression",{adServer:"tudeserve",adUnitPath:t.adUnit,bidder:e.bidder,cpm:e.amount,slotElementId:t.elementId,source:e.source,currency:e.currency,mediaType:e.mediaType})}))})};d()},3656:function(e,t,r){e=r.nmd(e);var i=r(9325),n=r(89935),s=t&&!t.nodeType&&t,o=s&&e&&!e.nodeType&&e,a=o&&o.exports===s?i.Buffer:void 0,d=a?a.isBuffer:void 0;e.exports=d||n},4509:function(e,t,r){var i=r(12651);e.exports=function(e){return i(this,e).has(e)}},4901:function(e,t,r){var i=r(72552),n=r(30294),s=r(40346),o={};o["[object Float32Array]"]=o["[object Float64Array]"]=o["[object Int8Array]"]=o["[object Int16Array]"]=o["[object Int32Array]"]=o["[object Uint8Array]"]=o["[object Uint8ClampedArray]"]=o["[object Uint16Array]"]=o["[object Uint32Array]"]=!0,o["[object Arguments]"]=o["[object Array]"]=o["[object ArrayBuffer]"]=o["[object Boolean]"]=o["[object DataView]"]=o["[object Date]"]=o["[object Error]"]=o["[object Function]"]=o["[object Map]"]=o["[object Number]"]=o["[object Object]"]=o["[object RegExp]"]=o["[object Set]"]=o["[object String]"]=o["[object WeakMap]"]=!1,e.exports=function(e){return s(e)&&n(e.length)&&!!o[i(e)]}},5789:function(e,t,r){"use strict";r.d(t,{I:function(){return o},U:function(){return s}});var i=r(79989),n=r(86964).Promise;async function s(e,{intervalMs:t=200,maxTries:r=20}={}){let n=0;for(;n{document.addEventListener("DOMContentLoaded",()=>e(!0))})}},6262:function(e,t,r){"use strict";r.d(t,{G:function(){return n}});var i=r(10667);function n(e,t){if(Array.isArray(e)&&e.length)for(let r=e.length-1;r>=0;r--)try{t(e[r])||e.splice(r,1)}catch(e){(0,i.A)().error("filterArrayInPlace error in filter",e)}return e}t.A=n},7723:function(e,t,r){"use strict";r.d(t,{f:function(){return f}});var i=r(74547),n=r(6262),s=r(22188),o=r(87594),a=r(18238),d=r(52093),l=r(10667);let u={};a.A.sub("wrapperConfigOnInit",e=>(u=e.AMAZON_HASH_MAP||{},e));let c=(0,s.b)(),f=e=>(d.U.push(()=>{let t=d.U.getSlotListByDivIds(e);t.length>0?(o.B.emit(i.qY.BEFORE_AD_SERVER_REQUEST,{slots:t}),t.forEach(e=>{var r,i,s,a;let d=null==e?void 0:e.getSlotElementId(),l=null==e?void 0:e.getTargetingMap(),f=function(e){try{return c.adUnits.find(t=>t.code===e)}catch(e){}return!1}(d),h=String((null==e||null==(r=e.getTargeting("hb_pb"))?void 0:r[0])||"").trim(),p=!!(h&&Number(h)),g=!!(null==e||null==(i=e.getTargeting("amziid"))?void 0:i[0]),m=null==e||null==(s=e.getTargeting("hb_bidder"))?void 0:s[0],v=null==e||null==(a=e.getTargeting("amznbid"))?void 0:a[0],b=u[v],y=null==e?void 0:e.getAdUnitPath(),A=document.getElementById(d),I=[];b&&I.push(b),isNaN(Number(h))||I.push(h);let w=Math.max(...I),E={adSlot:A,adUnitPath:y,slot:e,divId:d,prebidUnit:f,hasPrebidBid:p,hbBidder:m,hasBid:g||p,prebidBid:Number(h),amazonBidHash:v,targetingMap:l,amazonBid:b,highBid:w,remove:()=>{(0,n.A)(t,t=>t!==e)}};o.B.emit("gpt.beforeAdServerRequest",E)}),t.length&&d.U.refresh(t)):(0,l.A)().error("Cannot find slots to refresh",e)}),!0)},8555:function(e,t,r){"URLSearchParams"in window||r.e(3212).then(r.t.bind(r,48318,23))},9325:function(e,t,r){var i=r(34840),n="object"==typeof self&&self&&self.Object===Object&&self;e.exports=i||n||Function("return this")()},10392:function(e){e.exports=function(e,t){return null==e?void 0:e[t]}},11331:function(e,t,r){var i=r(72552),n=r(28879),s=r(40346),o=Object.prototype,a=Function.prototype.toString,d=o.hasOwnProperty,l=a.call(Object);e.exports=function(e){if(!s(e)||"[object Object]"!=i(e))return!1;var t=n(e);if(null===t)return!0;var r=d.call(t,"constructor")&&t.constructor;return"function"==typeof r&&r instanceof r&&a.call(r)==l}},11490:function(e,t,r){"use strict";r.r(t),r.d(t,{setPrivacySettings:function(){return s}});var i=r(18238),n=r(85222);let s=e=>{let{personalizedAds:t}=e;n.A.onReady(()=>{n.A.setState({personalizedAds:t})}),window.googletag=window.googletag||{},window.googletag.cmd=window.googletag.cmd||[],window.googletag.cmd.push(()=>{window.googletag.pubads().setPrivacySettings({nonPersonalizedAds:!t})})};i.A.sub("tudePublicFunctions",({tude:e})=>(e.setPrivacySettings=s,{tude:e}))},12651:function(e,t,r){var i=r(74218);e.exports=function(e,t){var r=e.__data__;return i(t)?r["string"==typeof t?"string":"hash"]:r.map}},12749:function(e,t,r){var i=r(81042),n=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;return i?void 0!==t[e]:n.call(t,e)}},14900:function(e,t){(function(e){"use strict";let t,r={Verbose:3,Advanced:2,None:0,Standard:1},i=r.None,n=new URL(window.location.href).searchParams.get("aditude_debug"),s=r.None;switch(n){case"3":s=r.Verbose;break;case"2":case"99":s=r.Advanced;break;case"1":case"true":s=r.Standard;break;default:s=r.None}let o=(e,t)=>{console[e](...t)},a=(e,t)=>{let r=[].slice.call(e),{label:i,prefix:n}=t;n&&r.unshift(n);let s=[],o=[];function a(e){return`display: inline-block; color: #fff; font-size: 9px; background: ${e}; padding: 1px 4px; border-radius: 0; margin-right: 1px;`}return o.push("%ctudeserve"),i.text.length>0&&o.push(`%c${i.text}`),i.text.length>0&&s.push(a(i.color)),s.push(a("green")),s.forEach(e=>{r.unshift(e)}),r.unshift(o.join("")),r},d=(e,t={})=>{let r=t.type??"log",n=t.label??{text:"",color:"#339933"},d=t.level??i;return(...e)=>{d<=s&&o(r,a(e,{prefix:"",label:n}))}},l=d("log",{label:{text:"log",color:"#61B321"},level:r.Standard}),u=d("error",{type:"error",label:{text:"error",color:"red"},level:r.Standard}),c=d("verbose",{label:{text:"verbose",color:"#61B321"},level:r.Verbose});class f{slotId;bidder;source;amount;mediaType;sourceData;currency="USD";constructor(e){this.slotId=e.slotId,this.bidder=e.bidder??e.source,this.source=e.source,this.amount=e.amount,this.mediaType=e.mediaType??"unknown",this.sourceData=e.sourceData,this.currency=e.currency??"USD",c("Bid created",this)}toJson(){return{slotId:this.slotId,source:this.source,bidder:this.bidder,amount:this.amount,currency:this.currency,mediaType:this.mediaType,sourceData:this.sourceData}}}class h{adUnit;elementId;sizes;keyValues;#e=[];constructor(e,t,r,i){this.adUnit=e,this.elementId=t,this.sizes=r,this.keyValues=i,l("Slot created",this)}getElement(){return document.getElementById(this.elementId)}get bids(){return this.#e}set bids(e){c("setting bids to slot",{slot:this,bids:e}),this.#e=e}clearBids(){this.#e=[]}}let p=(e,t)=>new CustomEvent(`tudeserve_${e}`,{detail:t}),g=(e,t)=>{e.dispatchEvent(t),c(`event:${t.type.replace("tudeserve_","")} dispatched`,t.detail)};class m{on(e,t){window.addEventListener(`tudeserve_${e}`,e=>{t(e.detail)}),c(`event:${e} listener registered`)}}let v=(e,t,r)=>{let i,n=0;new IntersectionObserver((e,s)=>{e.forEach(e=>{e.isIntersecting?i=setInterval(()=>{(n+=100)>1e3&&(g(window,p("viewable",{slot:t,bid:r})),s.unobserve(e.target),clearInterval(i))},100):clearInterval(i)})},{root:null,rootMargin:"0px 0px 0px 0px",threshold:.5}).observe(e)},b=new Uint8Array(16),y=[];for(let e=0;e<256;++e)y.push((e+256).toString(16).slice(1));var A={randomUUID:"undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};class I{timings={};addTiming(e,t){this.timings[e]=t??Date.now()}getTiming(e){return this.timings[e]}}class w{id;results=[];slots=[];tt=new I;status="init";constructor(e){this.id=function(e,r,i){if(A.randomUUID&&!e)return A.randomUUID();let n=(e=e||{}).random||(e.rng||function(){if(!t&&!(t="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)))throw Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return t(b)})();return n[6]=15&n[6]|64,n[8]=63&n[8]|128,function(e,t=0){return y[e[t+0]]+y[e[t+1]]+y[e[t+2]]+y[e[t+3]]+"-"+y[e[t+4]]+y[e[t+5]]+"-"+y[e[t+6]]+y[e[t+7]]+"-"+y[e[t+8]]+y[e[t+9]]+"-"+y[e[t+10]]+y[e[t+11]]+y[e[t+12]]+y[e[t+13]]+y[e[t+14]]+y[e[t+15]]}(n)}(),this.slots=e??[],this.logTiming("init"),c("Request created",this)}nextStep(){switch(this.status){case"init":this.status="requested",this.logTiming("requested");break;case"requested":this.status="complete",this.logTiming("complete");break;default:u("Request already ended",this)}}addResult(e){this.results.push(e)}logTiming(e){this.tt.addTiming(e)}getTimings(){let e=this.tt.getTiming("init"),t=this.tt.getTiming("requested"),r=this.tt.getTiming("complete");return{startToRequest:t&&e?t-e:null,requestToComplete:r&&t?r-t:null,startToComplete:r&&e?r-e:null}}}let E=e=>{if(e){if(!Array.isArray(e))throw u("Slot inputs must be an array of Slot objects or element ID strings",e),Error("Slot inputs must be an array of Slot objects or element ID strings");for(let t of e)if("string"!=typeof t&&("object"!=typeof t||!(t instanceof h)))throw u("Slot inputs must be an array of Slot objects or element ID strings",e),Error("At least one of the slot inputs is not a Slot object or element ID string")}return c("valid request input",e),!0},S=e=>{let t=document.createElement("iframe");return t.id=`tudeserve-frame--${e.elementId}`,t.name=t.id,t.setAttribute("width","1"),t.setAttribute("height","1"),t.setAttribute("scrolling","no"),t.setAttribute("frameBorder","0"),t.style.background="#fff",t.sandbox.add("allow-forms","allow-pointer-lock","allow-popups","allow-popups-to-escape-sandbox","allow-same-origin","allow-scripts","allow-top-navigation-by-user-activation","allow-presentation"),t.addEventListener("load",()=>{t.contentWindow?.document.body&&(t.contentWindow.document.body.style.margin="0px")}),t},_=window._tudePbjsGlobal||"pbjs";window[_]=window[_]||{que:[]},window[_].que=window[_].que||[];let O=window[_],T={createBid:e=>new f(e),createRequest:e=>new w(e)};class D{slots=[];add(e,t,r,i){return this.updateOrCreate(e,t,r,i)}updateOrCreate(e,t,r,i){let n=this.slots.find(e=>e.elementId===t);return n?(n.adUnit!==e&&(n.adUnit=e),n.sizes=r,n.keyValues=i):(n=new h(e,t,r,i),this.slots.push(n)),n}getSlots(){return this.slots}getSlotByElementId(e){return this.slots.find(t=>t.elementId===e)}getSlotByAdUnit(e){return this.slots.find(t=>t.adUnit===e)}getSlotBySize(e,t){return this.slots.find(r=>r.sizes.some(r=>r[0]===e&&r[1]===t))}}class C{slotsService;constructor(){this.slotsService=new D,c("AdsService created")}factory(){return T}get slots(){return this.slotsService}request(e){c("Request start",e),E(e);let t=new w(e);if(c("Requesting slots: ",t.slots),0===t.slots.length)return void u("No slots to request",t);let r=t.slots.filter(e=>"string"==typeof e?!!this.slotsService.getSlotByElementId(e)||(u("Slot not found: ",e),t.addResult(`#${e} > outcome:slot_not_found`),!1):e instanceof h||(u("Invalid slot object: ",e),!1)).map(e=>"string"==typeof e?this.slotsService.getSlotByElementId(e):e);t.nextStep(),r.forEach(e=>{if(g(window,p("request",{slot:e})),!e.getElement()){u("Slot element not found"),t.addResult(`#${e.elementId} > outcome:sloterror`);return}let r=function(e){if(0!==e.length)return e.filter(e=>"number"==typeof e.amount&&e.amount>0).reduce((e,t)=>t.amount>e.amount?t:e,e[0])}(e.bids);if(!r){u("No bid found for slot: ",e),g(window,p("no_bid",{slot:e})),t.addResult(`#${e.elementId} > outcome:no_bid`);return}g(window,p("bid_won",{bid:r,slot:e}));let i=`#${e.elementId} > source:${r.source}, bidder:${r.bidder}, amt:${r.amount.toFixed(5)} > outcome:`;try{let n=this.render(r,e);return n?t.addResult(`${i}:rendered`):t.addResult(`${i}:error`),n}catch(e){t.addResult(`${i}:error`),u("Failed to render ad",e)}}),t.nextStep(),t.results.forEach(e=>{l(e)}),l("request complete",t.getTimings())}render(e,t){c("Render start",{slot:t,bid:e}),g(window,p("render_start",{bid:e,slot:t}));let r=t.getElement();if(!r)return u("Slot element not found"),t.clearBids(),!1;let{source:i}=e,n=function(e,t,r){if(c("building creative",{demandSource:e,slot:t,bid:r}),!t.getElement())return u("Slot element not found"),!1;let i=document.createElement("div");i.classList.add("tudeserve-wrap"),i.style.textAlign="center",i.id=`tudeserve-slot--${t.elementId}`;try{let n;switch(e){case"amazon":c("rendering amazon ad",{slot:t,bid:r}),n=function(e,t,r){let i=encodeURIComponent(window.location.href),n={kvMap:JSON.stringify(r),url:JSON.stringify(i),bidType:"openAuction",cv:"v2.0.0"},s=S(e);return setTimeout(()=>{window.apstag?.renderImp?.(s.contentWindow?.document,r.amzniid,n)}),s}(t,0,r.sourceData);break;case"prebid":c("rendering prebid ad",{slot:t,bid:r}),n=function(e,t,r){let i=S(e);return setTimeout(()=>{O.que.push(()=>{O.renderAd(i.contentWindow?.document,r.adId)})}),i}(t,0,r.sourceData);break;default:return u("Unknown demand source to render: ",e),!1}return i.appendChild(n),i}catch(e){return u(e),!1}}(i,t,e);return n?(r.innerHTML="",r.appendChild(n),g(window,p("impression",{bid:e,slot:t})),t.clearBids(),v(r,t,e),c("Render end",{slot:t,bid:e}),t):(u("Failed to build creative"),t.clearBids(),!1)}}let R=(e,t=!1,r=!1,i=[])=>{let n=document.createElement("script");t?n.async=!0:n.async=!1,r&&(n.defer=!0),i.forEach(e=>{n.setAttribute(`data-${e.key}`,e.value)}),n.src=e,document.head.appendChild(n)};e.AdRequest=w,e.Bid=f,e.TudeServe=class{#t;#r;cmd;constructor(){this.#t=new C,this.#r=new m,this.cmd={push:e=>{e(this)}},l("TudeServe created",this)}ads(){return this.#t}events(){return this.#r}},e.loadTudeServe=(e="latest",t="production")=>{R(`${("production"===t?"https://cw-static.aditude.io/tudeserve":"http://localhost:3001/static")??"https://cw-static.aditude.io/tudeserve"}/${"production"===t?e:"index"}.js?b=0.0.72-2024-06-09T22:55:13.730Z`,!0,!1,[{key:"tudeserve",value:"1"}])}})(t)},14974:function(e){e.exports=function(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]}},16547:function(e,t,r){var i=r(43360),n=r(75288),s=Object.prototype.hasOwnProperty;e.exports=function(e,t,r){var o=e[t];s.call(e,t)&&n(o,r)&&(void 0!==r||t in e)||i(e,t,r)}},17670:function(e,t,r){var i=r(12651);e.exports=function(e){var t=i(this,e).delete(e);return this.size-=+!!t,t}},18678:function(e,t,r){var i,n;void 0===(n="function"==typeof(i=function(){"use strict";Array.isArray||(Array.isArray=function(e){return"[object Array]"===Object.prototype.toString.call(e)});var e={},t={"==":function(e,t){return e==t},"===":function(e,t){return e===t},"!=":function(e,t){return e!=t},"!==":function(e,t){return e!==t},">":function(e,t){return e>t},">=":function(e,t){return e>=t},"<":function(e,t,r){return void 0===r?e=t?[]:i}};return e.is_logic=function(e){return"object"==typeof e&&null!==e&&!Array.isArray(e)&&1===Object.keys(e).length},e.truthy=function(e){return(!Array.isArray(e)||0!==e.length)&&!!e},e.get_operator=function(e){return Object.keys(e)[0]},e.get_values=function(t){return t[e.get_operator(t)]},e.apply=function(r,i){if(Array.isArray(r))return r.map(function(t){return e.apply(t,i)});if(!e.is_logic(r))return r;var n,s,o,a,d,l=e.get_operator(r),u=r[l];if(Array.isArray(u)||(u=[u]),"if"===l||"?:"==l){for(n=0;n0){var c=String(l).split("."),f=t;for(n=0;n1?r[s-1]:void 0,a=s>2?r[2]:void 0;for(o=e.length>3&&"function"==typeof o?(s--,o):void 0,a&&n(r[0],r[1],a)&&(o=s<3?void 0:o,s=1),t=Object(t);++i{this.onChangeListeners.forEach(e=>{e()})}),this.store=e}static isEnabled(){return this.enabled}static onChange(e){this.onChangeListeners.push(e)}static enableUserId(){this.enabled=!0}static disableUserId(){this.enabled=!1}}r(i,"store",void 0),r(i,"enabled",!1),r(i,"onChangeListeners",[]),t.A=i},24739:function(e,t,r){var i=r(26025);e.exports=function(e){var t=this.__data__,r=i(t,e);return r<0?void 0:t[r][1]}},25279:function(e,t,r){"use strict";let i;r.d(t,{A:function(){return a}});var n={randomUUID:"undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};let s=new Uint8Array(16),o=[];for(let e=0;e<256;++e)o.push((e+256).toString(16).slice(1));var a=function(e,t,r){if(n.randomUUID&&!t&&!e)return n.randomUUID();let a=(e=e||{}).random??e.rng?.()??function(){if(!i){if("undefined"==typeof crypto||!crypto.getRandomValues)throw Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");i=crypto.getRandomValues.bind(crypto)}return i(s)}();if(a.length<16)throw Error("Random bytes length must be >= 16");if(a[6]=15&a[6]|64,a[8]=63&a[8]|128,t){if((r=r||0)<0||r+16>t.length)throw RangeError(`UUID byte range ${r}:${r+15} is out of buffer bounds`);for(let e=0;e<16;++e)t[r+e]=a[e];return t}return function(e,t=0){return(o[e[t+0]]+o[e[t+1]]+o[e[t+2]]+o[e[t+3]]+"-"+o[e[t+4]]+o[e[t+5]]+"-"+o[e[t+6]]+o[e[t+7]]+"-"+o[e[t+8]]+o[e[t+9]]+"-"+o[e[t+10]]+o[e[t+11]]+o[e[t+12]]+o[e[t+13]]+o[e[t+14]]+o[e[t+15]]).toLowerCase()}(a)}},26025:function(e,t,r){var i=r(75288);e.exports=function(e,t){for(var r=e.length;r--;)if(i(e[r][0],t))return r;return -1}},27301:function(e){e.exports=function(e){return function(t){return e(t)}}},27534:function(e,t,r){var i=r(72552),n=r(40346);e.exports=function(e){return n(e)&&"[object Arguments]"==i(e)}},28879:function(e,t,r){e.exports=r(74335)(Object.getPrototypeOf,Object)},29817:function(e){e.exports=function(e){return this.__data__.has(e)}},30085:function(e,t,r){"use strict";function i(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}t.A=/^(22(251|440)|4(0687|1726|2003|7389)|6(2110|6432|6779|8181|8222|9138)|7(492|6607|8143|8530|9818)|8((1|49|93)07|7938)|9(5(472|611|968)|6056)|11696|17176|32109|51932)$/.test(r.j)?null:class{onComplete(e){this.onCompleteHandler=e}addBidder(e){this.bidders[e]=!1}setBidderStatus(e,t){this.bidders[e]=t,this._syncBidderChange()}complete(){return!!this.onCompleteHandler&&!this.queued&&(this.onCompleteHandler(),this.queued=!0,this.timing.end=Date.now(),!0)}_syncBidderChange(){Object.keys(this.bidders).filter(e=>!this.bidders[e]).length<1&&this.complete()}constructor(){i(this,"queued",void 0),i(this,"bidders",void 0),i(this,"timing",void 0),i(this,"onCompleteHandler",void 0),this.queued=!1,this.bidders={},this.timing={start:Date.now()},this.onCompleteHandler=!1}}},30294:function(e){e.exports=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=0x1fffffffffffff}},30361:function(e){var t=/^(?:0|[1-9]\d*)$/;e.exports=function(e,r){var i=typeof e;return!!(r=null==r?0x1fffffffffffff:r)&&("number"==i||"symbol"!=i&&t.test(e))&&e>-1&&e%1==0&&e{let r="https://dn0qt3r0xannq.cloudfront.net";return(-1!==e.indexOf("vendor/")||-1!==t.indexOf("vendor/"))&&(r="https://dn0qt3r0xannq.cloudfront.net"),r+e+t},a=(e,t,r=!1,i=!1,n=[])=>{let s=document.createElement("script");r?s.async=!0:s.async=!1,i&&(s.defer=!0),n.forEach(e=>{s.setAttribute("data-"+e.key,e.value)}),s.src=e,document[t].appendChild(s)},d=(e,t=!1)=>{let r=document.createElement("link");t&&(r.id=t),r.rel="stylesheet",r.type="text/css",r.href=e,r.media="all",document.getElementsByTagName("head")[0].appendChild(r)},l=e=>{e.forEach(e=>{(void 0===e.trigger||!e.trigger||e.trigger())&&(void 0===e.type||"js"===e.type?a(e.url,e.appendTo,e.async||!1,e.defer||!1,e.dataAttributes||[]):d(e.url,e.id))})};t.Ay=l},34840:function(e,t,r){e.exports="object"==typeof r.g&&r.g&&r.g.Object===Object&&r.g},34858:function(e,t,r){"use strict";var i=r(44558),n=r(10667),s=r(67259);t.A=function(e,t=!1,r=!1){if("true"===(0,s.P3)("disable_refresh"))return void(0,n.A)().warn("Refresh disabled by URL param");(0,i.TT)().then(i=>{i.cmd.push(function(){r&&(0,n.A)().log(r,e),Array.isArray(e)||(e=[e]),e.forEach(e=>{var t,r;t=function(e){for(var t=1;t({name:"prebid",createConfig(e){let t;try{let r=e.find(e=>{var t,r,i;return(null==e?void 0:e.name)==="pubProvidedId"&&(null==e||null==(i=e.params)||null==(r=i.eids)||null==(t=r[0])?void 0:t.source)}),i=e.find(e=>(null==e?void 0:e.name)==="sharedId");!globalThis.__tude_iiq_enabled&&(r?t=r.params.eids[0].source:i&&(t="pubcid.org"))}catch(e){}return{ppid:t,userIds:e}}});var d=r(85914),l=r.n(d),u=r(90031),c=r.n(u),f=r(10667);let h=(0,f.A)("UserID").setLabel("UserId","pink"),p={"33acrossId":"pid",fabrickId:"apiKey",hadronId:"partnerId",id5Id:"partner",identityLink:"pid",pairId:"liveramp",unifiedId:"partner",lotamePanoramaId:"clientId",liveIntentId:"publisherId",connectId:"pixelId",uid2:"uid2Token"},g={"33acrossId":{name:"33acrossId",storage:{name:"33acrossId",type:"html5",expires:90,refreshInSeconds:28800},modifyBidderConfig(e,t,r){let i={};return Object.keys(i).forEach(t=>{r[t]&&(e.params[i[t]]=r[t])}),e}},connectId:{name:"connectId",modifyBidderConfig(e,t,r){let i={_email:"he",_ppid:"puid"};return Object.keys(i).forEach(t=>{r[t]&&(e.params[i[t]]=r[t])}),e}},criteo:{name:"criteo"},fabrickId:{name:"fabrickId",storage:{name:"pbjs_fabrickId",type:"cookie",expires:7},modifyBidderConfig(e,t,r){let i={_email:"e",_phone:"p",_ipv4:"i4",_ipv6:"i6",_idfa:"m",_ifa:"ia",_ifv:"iv"};return Object.keys(i).forEach(t=>{r[t]&&(e.params[i[t]]=r[t])}),e}},hadronId:{name:"hadronId",storage:{name:"hadronId",type:"html5"},modifyBidderConfig(e,t,r){let i={};return Object.keys(i).forEach(t=>{r[t]&&(e.params[i[t]]=r[t])}),e}},id5Id:{name:"id5Id",storage:{name:"id5id",type:"html5",expires:90,refreshInSeconds:28800},modifyBidderConfig(e,t,r){let i=["_email","_phone"],n={_email:"1",_phone:"2",_ipv4:"10",_ipv6:"11",_idfa:"6",_ifv:"14",_ua:"12"},s="";Object.keys(n).forEach(e=>{if(r[e]){let t=r[e];i.includes(e)||(t=encodeURIComponent(t)),s+=n[e]+"="+t+"&"}}),e.params.pd=s.slice(0,-1);try{e.params.pd=function(e){if(!e)return"";try{let t=c().encode(e);return l().encode(t)}catch(e){return(0,f.A)().error("Error encoding string:",e),""}}(e.params.pd)}catch(e){h.error(e)}return e}},identityLink:{name:"identityLink",storage:{name:"idl_env",type:"html5",expires:15,refreshInSeconds:1800},modifyBidderConfig(e,t,r){let i={};return Object.keys(i).forEach(t=>{r[t]&&(e.params[i[t]]=r[t])}),e}},liveIntentId:{name:"liveIntentId",storage:{name:"__tamLIResolveResult",type:"html5",expires:1},modifyBidderConfig(e,t,r,i){return"prebid"===i&&(e.params=e.params||{},r._email&&(e.params.emailHash=r._email),r._ipv4&&(e.params.ipv4=r._ipv4),r._ipv6&&(e.params.ipv6=r._ipv6),e.params.fpid={strategy:"html5",name:"li_fpid"},e.params.userAgent=navigator.userAgent,e.params.requestedAttributesOverrides={uid2:!0,medianet:!0,magnite:!0,bidswitch:!0,pubmatic:!0,openx:!0,sovrn:!0,index:!0,thetradedesk:!0,sharethrough:!0,sonobi:!0,vidazoo:!0,zetassp:!0,triplelift:!0,fpid:!0}),e}},lotamePanoramaId:{name:"lotamePanoramaId"},pairId:{name:"pairId"},pubProvidedId:{name:"pubProvidedId",props:{eids:[]},modifyBidderConfig(e,t,r,i){if("prebid"===i&&(r._ppid||r._email)){let t=[];r._email&&t.push({id:r._email,atype:3,ext:{stype:64===String(r._email).length?"hemsha256":"hemmd5"}}),r._md5email&&t.push({id:r._md5email,atype:3,ext:{stype:"hemmd5"}}),r._ppid&&t.push({id:r._ppid,atype:1,ext:{stype:"ppuid"}}),e.params.eids[0]={source:window.location.hostname,uids:t}}return e}},sharedId:{name:"sharedId",storage:{name:"_sharedid",type:"cookie",expires:365}},unifiedId:{name:"unifiedId",storage:{name:"pbjs-unifiedid",type:"cookie",expires:60}},uid2:{name:"uid2",modifyBidderConfig(e,t,r,i){let n=o.A.apply("userId.uid2.includeEmail",!0,e=>!!(null==e||e));if("prebid"===i&&(e.params=e.params||{},0===Object.keys(e.params.uid2Token||{}).length&&e.params.serverPublicKey&&e.params.subscriptionId&&n&&r._email&&"string"==typeof r._email)){let t=r._email;64===t.length&&(t=function(e=""){let t=[];for(let r=0;rString.fromCharCode(e)).join(""))}(t)),44===t.length&&(e.params.emailHash=t)}return e}},amxId:{name:"amxId",storage:{name:"amxId",type:"html5",expires:1}}};function m(e){for(var t=1;t{let t=e.module,r=e.storage||{},i=e.extraParams||{},n=e.key||null,{name:s,props:o={},modifyBidderConfig:a,storage:d={}}=g[t],l=p[t],u={name:s,configs:{prebid:{name:s,params:m({},n&&l?{[l]:n}:{},i,o),storage:m({},d,r)}},convert(e,t){let r=this.configs[t];return!!r&&("function"==typeof a&&(r=a(r,this,e,t)),r)}};return 0===Object.keys(u.configs.prebid.params).length&&delete u.configs.prebid.params,0===Object.keys(u.configs.prebid.storage).length&&delete u.configs.prebid.storage,u};var b=r(51804),y=r(44558),A=r(5789),I=r(22188),w=r(87594),E=r(52093),S=r(86964).Promise;function _(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}let O=(0,f.A)("UserID"),T={_email:!1,_phone:!1,_ipv4:!1,_ipv6:!1,_idfa:!1,_ifa:!1,_ifv:!1,_ppid:!1,_ua:null!=(i=window.navigator.userAgent)&&i,_md5email:!1};class D{restoreCachedValues(){let e=[];Object.entries(this._storageKeys).forEach(([t,r])=>{let i=this._userIdData[t];i||(this._userIdData[t]=localStorage.getItem(r)||i,this._userIdData[t]!==i&&e.push(t))}),e.length&&O.advancedLog("restored from storage:",e.join(", "))}saveCachedValues(){Object.entries(this._storageKeys).forEach(([e,t])=>{let r=this._userIdData[e];r&&"string"==typeof r&&localStorage.setItem(t,r)})}clearCachedValues(){Object.values(this._storageKeys).forEach(e=>{localStorage.removeItem(e)})}onChange(e){this.onChangeHandler=e}emitChange(e){var t;this.onChangeHandler(),w.B.emit("UserId.setIdProfile.onChange",{input:e,data:this._userIdData}),w.B.emit("UserId.setIdProfile.afterRun",e),this.amazon&&this.sendToAmazon(),"string"==typeof this._userIdData._ppid&&E.U.setPublisherProvidedId(this._userIdData._ppid);let r=(0,I.b)();null==r||null==(t=r.refreshUserIds)||t.call(r)}setBiddersWithUserId(e){this._bidders=e}setUserIdModules(e){this._userIdModules=e}enableAmazonEmail(){this.amazon=!0,O.log("Amazon Email enabled"),this.sendToAmazon()}setIdProfile(e){O.log("User Id profile set from client",e);let t=JSON.stringify(this._userIdData);this._userIdData={_email:(null==e?void 0:e.e)||this._userIdData._email,_phone:(null==e?void 0:e.p)||this._userIdData._phone,_ipv4:(null==e?void 0:e.i4)||this._userIdData._ipv4,_ipv6:(null==e?void 0:e.i6)||this._userIdData._ipv6,_idfa:(null==e?void 0:e.idfa)||this._userIdData._idfa,_ifa:(null==e?void 0:e.ifa)||this._userIdData._ifa,_ifv:(null==e?void 0:e.ifv)||this._userIdData._ifv,_ppid:(null==e?void 0:e.ppid)||this._userIdData._ppid,_ua:(null==e?void 0:e.ua)||this._userIdData._ua,_md5email:(null==e?void 0:e.e_md5)||this._userIdData._md5email},this.restoreCachedValues();let r=t!==JSON.stringify(this._userIdData);r&&this.saveCachedValues(),r&&this.emitChange(e)}resetIdProfile(){var e;O.log("User Id profile reset");let t=(0,I.b)(),r=!!(this._userIdData._ppid||this._userIdData._email),i=JSON.stringify(this._userIdData)!==JSON.stringify(T);this._userIdData=T,this.clearCachedValues(),this.amazon&&(0,A.U)("apstag",{}).then(()=>{var e,t;null==(e=(t=window.apstag).dpa)||e.call(t),O.log("amazon token deleted")}),r&&(O.log("gpt ppid reset"),E.U.setPublisherProvidedId("")),O.log("prebid user ids refreshed"),null==t||null==(e=t.refreshUserIds)||e.call(t),w.B.emit("UserId.resetIdProfile.afterRun"),i&&this.emitChange({})}getPublicFunctions(){return{setIdProfile:this.setIdProfile.bind(this),resetIdProfile:this.resetIdProfile.bind(this)}}toConfig(e){let t=this._bidders.find(t=>t.name===e);if(!t)return!1;let r=[];return this._userIdModules.forEach(e=>{let i=e.convert(this._userIdData,t.name);i&&r.push(i)}),!(r.length<1)&&t.createConfig(r)}constructor(){_(this,"_userIdData",T),_(this,"_bidders",[]),_(this,"_userIdModules",[]),_(this,"_storageKeys",{_email:"cw-cache.user-id.hem-sha256",_md5email:"cw-cache.user-id.hem-md5",_ppid:"cw-cache.user-id.ppid"}),_(this,"amazon",!1),_(this,"amazonPubId",void 0),_(this,"onChangeHandler",()=>{}),_(this,"enableAmazonBetaApi",async()=>{let e=(0,I.b)(),{AMAZON_PUB_ID:t}=await y.rI.getConfig();if(!t)return O.warn("Amazon pub id not found for beta api"),!1;e.que.push(()=>{e.getUserIdsAsync&&e.getUserIdsAsync().then(()=>{O.log("User Ids enabled for API"),({accountID:t,record:function(e,t){return new S((r,i)=>{var n,s;window._aps.get(this.accountID).queue.push(new CustomEvent(e,{detail:(n=function(e){for(var t=1;t{if(!this._userIdData._email||"string"!=typeof this._userIdData._email)return;let e={hashedRecords:[{type:"email",record:this._userIdData._email}]};O.log("Sending token to Amazon",e),(0,A.U)("apstag",{}).then(()=>{window.apstag.rpa(e,()=>{O.log("Amazon token sent",e)})})});let e=JSON.stringify(this._userIdData);this.restoreCachedValues(),e!==JSON.stringify(this._userIdData)&&this.emitChange({})}}function C(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}class R extends s.A{getLoggerColor(){return"pink"}getInitialState(){return{}}start(){let e=new D;e.setBiddersWithUserId([a()]);let{userModules:t}=this.props;return e.setUserIdModules(t.map(e=>v(e))),b.y.setStore(e),b.y.enableUserId(),!1!==this.props.enableAmazonEmail&&e.enableAmazonEmail(),this.props.enableAmazonBetaApi&&e.enableAmazonBetaApi(),this.publicFunctions=e.getPublicFunctions()||{},o.A.sub("tudePublicFunctions",({tude:e})=>(Object.entries(this.publicFunctions).forEach(t=>{let[r,i]=t;e[r]=i}),{tude:e})),this.publicFunctions}constructor(e){super(e,"UserId"),C(this,"userModules",void 0),C(this,"defaultUserModules",[{module:"sharedId"},{module:"fabrickId",key:"2254903614"},{module:"id5Id",key:1016},{module:"33acrossId",key:"0015a00002qqhgFAAQ"},{module:"pubProvidedId"},{module:"criteo"}]),C(this,"publicFunctions",void 0),this.userModules=e.userModules,this.defaultUserModules.length&&this.defaultUserModules.filter(e=>null==e?void 0:e.module).filter(e=>!this.userModules.find(t=>t.module===e.module)).filter(t=>!(e.disabledModules||[]).includes(t.module)).forEach(e=>{this.userModules.push(e)})}}C(R,"componentName","user-id"),(0,n.h)(R);var P=R},36800:function(e,t,r){var i=r(75288),n=r(64894),s=r(30361),o=r(23805);e.exports=function(e,t,r){if(!o(r))return!1;var a=typeof t;return("number"==a?!!(n(r)&&s(t,r.length)):"string"==a&&t in r)&&i(r[t],e)}},37167:function(e,t,r){var i=r(4901),n=r(27301),s=r(86009),o=s&&s.isTypedArray;e.exports=o?n(o):i},37217:function(e,t,r){var i=r(80079),n=r(51420),s=r(90938),o=r(63605),a=r(29817),d=r(80945);function l(e){var t=this.__data__=new i(e);this.size=t.size}l.prototype.clear=n,l.prototype.delete=s,l.prototype.get=o,l.prototype.has=a,l.prototype.set=d,e.exports=l},37241:function(e,t,r){var i=r(70695),n=r(72903),s=r(64894);e.exports=function(e){return s(e)?i(e,!0):n(e)}},37334:function(e){e.exports=function(e){return function(){return e}}},37828:function(e,t,r){e.exports=r(9325).Uint8Array},39344:function(e,t,r){var i=r(23805),n=Object.create;e.exports=function(){function e(){}return function(t){if(!i(t))return{};if(n)return n(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}()},40295:function(e,t,r){"use strict";r.d(t,{y:function(){return i}});let i={START:"plugin.start"}},40346:function(e){e.exports=function(e){return null!=e&&"object"==typeof e}},42824:function(e,t,r){var i=r(87805),n=r(93290),s=r(71961),o=r(23007),a=r(35529),d=r(72428),l=r(56449),u=r(83693),c=r(3656),f=r(1882),h=r(23805),p=r(11331),g=r(37167),m=r(14974),v=r(69884);e.exports=function(e,t,r,b,y,A,I){var w=m(e,r),E=m(t,r),S=I.get(E);if(S)return void i(e,r,S);var _=A?A(w,E,r+"",e,t,I):void 0,O=void 0===_;if(O){var T=l(E),D=!T&&c(E),C=!T&&!D&&g(E);_=E,T||D||C?l(w)?_=w:u(w)?_=o(w):D?(O=!1,_=n(E,!0)):C?(O=!1,_=s(E,!0)):_=[]:p(E)||d(E)?(_=w,d(w)?_=v(w):(!h(w)||f(w))&&(_=a(E))):O=!1}O&&(I.set(E,_),y(_,E,b,A,I),I.delete(E)),i(e,r,_)}},43360:function(e,t,r){var i=r(93243);e.exports=function(e,t,r){"__proto__"==t&&i?i(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}},44558:function(e,t,r){"use strict";let i,n,s,o,a;r.d(t,{rI:function(){return eJ},GJ:function(){return e0},TT:function(){return eX},Xp:function(){return e1}}),r(11490),r(8555);var d,l,u,c=r(18238),f=r(10667);c.A.sub("prebidAdUnitConfig",e=>{var t,r;let{adUnit:i}=e;return i&&(null==i||null==(r=i.mediaTypes)||null==(t=r.banner)?void 0:t.sizes)&&(i.mediaTypes.banner.sizes=i.mediaTypes.banner.sizes.filter(e=>{let t=e.includes("fluid");return t&&(0,f.A)().log(`Removing size ${e} from ${i.slot}`),!t})),e});var h=r(22188);c.A.sub("wrapperConfigOnInit",e=>{let t;try{Object.keys(e.AD_UNITS).find(r=>!!e.AD_UNITS[r].find(e=>!!((null==e?void 0:e.bids)||[]).find(e=>"adagio"===e.bidder&&(t=e,!0))))}catch(e){}return c.A.sub("prebidGlobalConfig",e=>{let r=(0,h.b)();return r.que.push(()=>{var i,n,s,o,a;if(t&&(null==t||null==(i=t.params)?void 0:i.organizationId)&&(null==t||null==(n=t.params)?void 0:n.site)&&(r.version||"").startsWith("v9")&&r.installedModules.includes("adagioBidAdapter")&&r.installedModules.includes("adagioRtdProvider")){e.realTimeData=null!=(s=e.realTimeData)?s:{auctionDelay:100,dataProviders:[]};let r=e.realTimeData;r.dataProviders=r.dataProviders||[],r.dataProviders.find(e=>"adagio"===e.name)||((0,f.A)().advancedLog("Auto-configuring adagioRtdModule for prebid v9"),r.dataProviders.push({name:"adagio",params:{organizationId:null==(o=t.params)?void 0:o.organizationId,site:null==(a=t.params)?void 0:a.site}}))}}),e}),e});var p=r(25279),g=r(74547),m=r(24510),v=r(51804),b=r(85222),y=r(87594),A=r(52093),I=r(46817);let w={COMPLETED:"completed",NOT_STARTED:"not_started",STARTED:"started"},E=()=>Date.now();var S=class{push(e){this.reqs.push(e)}getByRecent(){return this.reqs.sort((e,t)=>e.startedAt!(e.status===w.COMPLETED&&E()-e.completedAt>1e4)&&!0)}constructor(){this.reqs=[]}};class _{formatBids(e){return e.filter(e=>void 0===e.status).map(e=>({adId:e.adId,adUnitCode:e.adUnitCode,bidder:e.bidder,cpm:e.cpm,creativeId:e.creativeId,requestId:e.requestId,status:e.status,statusMessage:e.statusMessage}))}constructor({adUnit:e,adUnitCode:t,divId:r,baseDivId:i},n){this.adUnitCode=t,this.adUnit=e,this.divId=r,this.baseDivId=i,this.pbjsGlobalName=n,this.bidderMatches=[],this.index=_.num,_.num++}}"num"in _?Object.defineProperty(_,"num",{value:0,enumerable:!0,configurable:!0,writable:!0}):_.num=0;class O{addUnit({adUnit:e,adUnitCode:t,divId:r,baseDivId:i}){this.units.push(new _({adUnit:e,adUnitCode:t,divId:r,baseDivId:i},this.pbjsGlobalName))}getTimings(){return{deltas:{e2e:this.completedAt-this.createdAt,steps:{"0_createdStarted":this.startedAt-this.createdAt,"1_startedCompleted":this.completedAt-this.startedAt}}}}markAsStarted(){this.status=w.STARTED,this.startedAt=E(),y.B.emit(g.qY.AUCTION_START,{auctionId:this.auctionId,ids:this.units.map(e=>({adUnit:e.adUnit,adUnitCode:e.adUnitCode,divId:e.divId}))})}markAsCompleted(){this.status=w.COMPLETED,this.completedAt=E()}constructor(e,t){this.status=w.NOT_STARTED,this.createdAt=E(),this.startedAt=!1,this.completedAt=!1,this.units=[],this.auctionId=t,this.index=O._num,this.pbjsGlobalName=e,O._num++}}function T(e,t){if(void 0===e)throw TypeError("attempted to "+t+" private static field before its declaration")}function D(e,t,r){return P(e,t),T(r,"get"),r.get?r.get.call(e):r.value}function C(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function R(e){for(var t=1;te.find(e=>{let r=!0;return e.slot&&t.slot&&(r=Array.isArray(e.slot)?e.slot.includes(t.slot):e.slot===t.slot),r&&(e.code===t.divId||e.code===t.adUnit)});class N{static setGlobalName(e){this.globalName=e}static getGlobalInstance(){return window[this.globalName]=window[this.globalName]||{},window[this.globalName].que=window[this.globalName].que||[],window[this.globalName]}static setBidderSettings(e){let t=N.getGlobalInstance(),r=t.bidderSettings||{};t.bidderSettings=R({standard:{storageAllowed:!0}},r,e)}static registerSignalSources(){if(N.registerSignalSourcesCalled)return;N.registerSignalSourcesCalled=!0;let e=N.getGlobalInstance();e.que.push(()=>{e.getUserIdsAsync&&e.getUserIdsAsync().then(()=>{let t=Array.from(new Set(e.getUserIdsAsEids().map(e=>e.source)));if(t&&t.length){let r=r=>((null==(r=r||{})?void 0:r.encryptedSignalSources)||((r=r||{}).encryptedSignalSources={sources:[{source:t,encrypt:!1}]},e.mergeConfig({userSync:r})),r);r(e.getConfig("userSync")),e.getConfig("userSync",e=>r(null==e?void 0:e.userSync)),A.U.push(()=>e.registerSignalSources())}})})}setListenersForUserIdChanges(){m.A.onChange(()=>{this.syncUserIdConfig()}),v.A.onChange(()=>{this.syncUserIdConfig()})}syncUserIdConfig(){let e,{userSync:t}=this.config.PREBID_CONFIG,r="User Id";if(m.A.isEnabled()&&m.A.store?e=m.A:v.A.isEnabled()&&v.A.store&&(e=v.A,r="User Id V2"),!e)return;let i=e.store.toConfig("prebid");if(i){j(`Syncing ${r} config for prebid`,e.store),t=R({},t,i);let n=N.getGlobalInstance();n.que.push(()=>{let e=n.getConfig("userSync.userIds")||[];if(e.length){let r=t.userIds||[];e.forEach(e=>{r.every(t=>t.name!==e.name)&&r.push(e)}),t.userIds=r}n.setConfig({userSync:t})})}else(0,f.A)(U).warn(`${r} profile or modules were empty`,e.store)}forceTriggerPrebidUserSyncs(){let e=N.getGlobalInstance();e.que.push(()=>{j("calling prebid triggerUserSyncs"),e.setConfig({userSync:{enableOverride:!0}}),e.triggerUserSyncs(),e.setConfig({userSync:{enableOverride:!1}}),e.getUserIdsAsync().then(e=>j("user ids all complete:",e))})}isTudeServe(){return["v2","tude"].includes(this.config.AD_SERVER)}constructor(e){C(this,"config",void 0),C(this,"requestBidsWithoutSlots",e=>{let{mappings:t,adUnits:r,cb:i,auctionState:n={}}=e,{PREBID_GLOBAL:s,PREBID_TIMEOUT:o,PREBID_SIZES_OVERRIDE:a}=this.config,d=N.getGlobalInstance(),l=(0,p.A)(),u=new O(s,l);if(!b.A.canReceivePersonalizedAds()){(0,f.A)(U).warn("Prebid will not run because personalized ads are turned off"),i({adUnitCodes:[],bids:{},req:!1});return}let h=t.filter(e=>x(r,e)).map(e=>{var t;let i=Object.assign({},x(r,e));i.code=e.divId,(null==(t=i.mediaTypes)?void 0:t.banner)&&(a&&e.prebidSizes&&(i.mediaTypes.banner.sizes=e.prebidSizes),i.mediaTypes.banner.sizes=c.A.apply("prebidSizes",{code:i.code,adUnit:e.adUnit,baseDivId:e.baseDivId,sizes:i.mediaTypes.banner.sizes},({sizes:e})=>e));let n={adUnitCode:(i=c.A.apply("prebidAdUnitConfig",{adUnit:i,adUnits:r,baseDivId:e.baseDivId,divId:e.divId},({adUnit:e})=>e)).code,adUnit:e.adUnit,divId:e.divId,baseDivId:e.baseDivId};return u.addUnit(n),i}),m=c.A.apply("prebidAdUnits",{prebidAdUnits:h,adUnits:r,mappings:t},({prebidAdUnits:e})=>e);if(m.length<1)return(0,f.A)(U).error("No prebid ad unit matches for ",t),!1;m.forEach(e=>{y.B.emit(`pbjs.beforeRequest.${e.code}`,e)});let v=m.map(e=>e.code);B.push(u),B.garbageCollect(),d.que.push(()=>{var e,t;j(g.dN.PREBID_REQUEST_STARTING,v,{requestableUnits:h}),u.markAsStarted(),d.removeAdUnit(m.map(e=>e.code)),d.addAdUnits(m);let r=this.isTudeServe();d.requestBids((e=R({},{timeout:o,adUnitCodes:v,auctionId:l}),t=t={bidsBackHandler:e=>{n.timedout||r||d.setTargetingForGPTAsync(v),u.markAsCompleted(),i({adUnitCodes:v,bids:e,req:u})}},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);r.push.apply(r,i)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e))})});let{BID_MODIFIERS:t,PREBID_CACHE:r,PREBID_CACHE_DISABLE_MOVING_BIDDERS:i,PREBID_SECURE_SIGNALS:n,PREBID_SINGLETON:s,PREBID_EARLY_USERSYNC:o}=e;if(s){if(D(N,N,M))return D(N,N,M);var a=N,d=N,l=M,u=this;if(P(a,d),T(l,"set"),l.set)l.set.call(a,u);else{if(!l.writable)throw TypeError("attempted to set read only private field");l.value=u}}this.config=e,(m.A.isEnabled()&&m.A.store||v.A.isEnabled()&&v.A.store)&&(v.A.isEnabled()?j("User Id V2 sync service is enabled for Prebid"):j("User Id sync service is enabled for Prebid"),this.syncUserIdConfig(),this.setListenersForUserIdChanges(),o&&s&&this.forceTriggerPrebidUserSyncs()),r&&(0,I.A)({PREBID_CACHE_DISABLE_MOVING_BIDDERS:i,BID_MODIFIERS:t,AD_SERVER:e.AD_SERVER}),n&&N.registerSignalSources()}}C(N,"globalName","pbjs"),C(N,"registerSignalSourcesCalled",!1);var M={writable:!0,value:void 0};function k(e,t){if(void 0===e)throw TypeError("attempted to "+t+" private static field before its declaration")}function z(e,t,r){return G(e,t),k(r,"get"),r.get?r.get.call(e):r.value}function L(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function q(e){for(var t=1;t{var t;return(null==e?void 0:e.s2sConfig)&&!(null==e||null==(t=e.s2sConfig)?void 0:t.timeout)&&(null==e?void 0:e.bidderTimeout)&&(e.s2sConfig.timeout=Math.max(500,e.bidderTimeout-250)),function(e={}){if((null==e?void 0:e.eventHistoryTTL)!==void 0&&(null==e?void 0:e.minBidCacheTTL)!==void 0)return;let t=(0,h.b)();t.que.push(()=>{setTimeout(()=>{var i,n;if(Object.keys(r.g.assertive||{}).length||window._assertiveInitialized)return;let s={eventHistoryTTL:null!=(i=e.eventHistoryTTL)?i:15,minBidCacheTTL:null!=(n=e.minBidCacheTTL)?n:0};(0,f.A)().advancedLog("configuring prebid to clear events and expired bids",s),t.setConfig(s)},15e3)})}(e),e});class V extends Error{constructor(e,t){super(e),L(this,"context",void 0),this.context=t,this.name="PrebidOptimizationError"}}let $=(0,f.A)("Prebid-V2").setLabel("Pb2","#2B65EC"),H=(()=>{let e=new Map;return async(...t)=>{let r=t[0];if("string"==typeof r&&e.has(r))return e.get(r);let i=$.log(...t);return"string"==typeof r&&e.set(r,i),i}})(),W=(o=null,{getInstance:()=>(o||(o=new S),o)});(a=!1,()=>{if(!a)try{window.googletag=window.googletag||{},window.googletag.cmd=window.googletag.cmd||[],a=!0}catch(e){throw new V("Failed to initialize Google Tag Manager",{error:e})}})();let Z=(()=>{let e=new Map,t=0;return(r,i)=>{try{let n=Date.now();n-t>5e3&&(e.clear(),t=n);let s=`${r}_${i}`;if(e.has(s))return e.get(s);for(let t of W.getInstance().getByRecent().filter(e=>e.status===w.STARTED)){let n=t.units.find(e=>e.adUnitCode===r&&!e.bidderMatches.includes(i));if(n)return n.bidderMatches.push(i),e.set(s,n),n}return e.set(s,null),null}catch(e){return $.error("Error in matchAdUnitCodeToDivId:",e),null}}})(),Y=(()=>{let e=new Map,t=0;return(r,i)=>{try{let n=r.length+r.reduce((e,t)=>e+t.code.length,0);n!==t&&(e.clear(),r.forEach(t=>{e.set(t.code,t)}),t=n);let s=e.get(i.divId)||e.get(i.adUnit);return s||(s=r.find(e=>{let t=!0;return e.slot&&i.slot&&(t=Array.isArray(e.slot)?e.slot.includes(i.slot):e.slot===i.slot),t&&(e.code===i.divId||e.code===i.adUnit)})),s}catch(e){throw new V("Error matching mapping to ad unit",{mapping:i,error:e})}}})();class Q{initialize(){if(!this.isInitialized)try{let{BID_MODIFIERS:e,PREBID_CACHE:t,PREBID_CACHE_DISABLE_MOVING_BIDDERS:r,PREBID_SECURE_SIGNALS:i,PREBID_SINGLETON:n,PREBID_EARLY_USERSYNC:s}=this.config,o=[];this.isUserIdServiceEnabled()&&(v.A.isEnabled()?H("User Id V2 sync service is enabled for Prebid"):H("User Id sync service is enabled for Prebid"),o.push(this.syncUserIdConfig(),this.setListenersForUserIdChanges()),s&&n&&o.push(this.forceTriggerPrebidUserSyncs())),t&&(0,I.A)({PREBID_CACHE_DISABLE_MOVING_BIDDERS:Array.isArray(r)?r:[],BID_MODIFIERS:e,AD_SERVER:this.config.AD_SERVER}),i&&Q.registerSignalSources(),this.isInitialized=!0}catch(e){throw new V("Failed to initialize OptimizedPrebidBidder",{error:e})}}static setGlobalName(e){this.globalName=e}static getGlobalInstance(){let e=this.globalName;return window[e]?window[e].que||(window[e].que=[]):window[e]={que:[]},window[e]}static setBidderSettings(e){try{let t=Q.getGlobalInstance();t.bidderSettings=q({standard:{storageAllowed:!0}},t.bidderSettings,e)}catch(t){throw new V("Failed to set bidder settings",{settings:e,error:t})}}static registerSignalSources(){if(!Q.registerSignalSourcesCalled){Q.registerSignalSourcesCalled=!0;try{let e=Q.getGlobalInstance();e.que.push(()=>{e.getUserIdsAsync&&e.getUserIdsAsync().then(()=>{let t=e.getUserIdsAsEids()||[],r=[...new Set(t.map(e=>e.source))];if(0===r.length)return;let i=(e={})=>(null==e?void 0:e.encryptedSignalSources)?e:F(q({},e),{encryptedSignalSources:{sources:[{source:r,encrypt:!1}]}}),n=e.getConfig("userSync"),s=i(n);e.mergeConfig({userSync:s}),e.getConfig("userSync",t=>{let r=i(null==t?void 0:t.userSync);r!==(null==t?void 0:t.userSync)&&e.mergeConfig({userSync:r})}),A.U.push(()=>e.registerSignalSources())}).catch(e=>{$.error("Failed to register signal sources:",e)})})}catch(e){throw new V("Failed to register signal sources",{error:e})}}}setListenersForUserIdChanges(){let e=()=>this.syncUserIdConfig();this.userIdChangeListeners.has(e)||(m.A.onChange(e),v.A.onChange(e),this.userIdChangeListeners.add(e))}syncUserIdConfig(){try{let{userSync:e}=this.config.PREBID_CONFIG||{},t=this.getActiveUserIdService();if(!t)return;let r=t.store.toConfig("prebid");if(!r){let e=t===v.A?"User Id V2":"User Id";$.warn(`${e} profile or modules were empty`,t.store);return}H(`Syncing ${t===v.A?"User Id V2":"User Id"} config for prebid`,t.store),e=q({},e,r);let i=Q.getGlobalInstance();i.que.push(()=>{try{let t=i.getConfig("userSync.userIds")||[];if(t.length>0){let r=[...e.userIds||[]],i=new Set(r.map(e=>e.name));t.forEach(e=>{i.has(e.name)||r.push(e)}),e.userIds=r}i.setConfig({userSync:e})}catch(e){$.error("Error setting user sync config:",e)}})}catch(e){throw new V("Failed to sync user ID config",{error:e})}}getActiveUserIdService(){return m.A.isEnabled()&&m.A.store?m.A:v.A.isEnabled()&&v.A.store?v.A:null}forceTriggerPrebidUserSyncs(){let e=Q.getGlobalInstance();e.que.push(()=>{try{H("calling prebid triggerUserSyncs"),e.setConfig({userSync:{enableOverride:!0}}),e.triggerUserSyncs(),e.setConfig({userSync:{enableOverride:!1}}),e.getUserIdsAsync().then(e=>H("user ids all complete:",e)).catch(e=>$.error("Error getting user IDs:",e))}catch(e){$.error("Error triggering user syncs:",e)}})}processRequestableUnits(e,t,r,i){let n=[];for(let o of e)try{var s;let e=Y(t,o);if(!e)continue;let a=F(q({},e),{code:o.divId});if(null==(s=a.mediaTypes)?void 0:s.banner){i&&o.prebidSizes&&(a.mediaTypes.banner.sizes=o.prebidSizes);try{let e=c.A.apply("prebidSizes",{code:a.code,adUnit:o.adUnit,baseDivId:o.baseDivId,sizes:a.mediaTypes.banner.sizes},({sizes:e})=>e);a.mediaTypes.banner.sizes=Array.isArray(e)?e:a.mediaTypes.banner.sizes}catch(e){$.error("Error applying prebidSizes filter:",e)}}let d=c.A.apply("prebidAdUnitConfig",{adUnit:a,adUnits:t,baseDivId:o.baseDivId,divId:o.divId},({adUnit:e})=>e),l={adUnitCode:d.code,adUnit:o.adUnit,divId:o.divId,baseDivId:o.baseDivId};r.addUnit(l),n.push(d)}catch(e){$.error("Error processing requestable unit:",e,{mapping:o})}return n}applyPrebidFilters(e,t,r){try{return c.A.apply("prebidAdUnits",{prebidAdUnits:e,adUnits:t,mappings:r},({prebidAdUnits:e})=>e)}catch(t){return $.error("Error applying prebid filters:",t),e}}constructor(e){let t,r;if(L(this,"config",void 0),L(this,"userIdChangeListeners",new Set),L(this,"isInitialized",!1),L(this,"isUserIdServiceEnabled",(t=null,()=>(null===t&&(t=!!(m.A.isEnabled()&&m.A.store)||!!(v.A.isEnabled()&&v.A.store)),t))),L(this,"isTudeServe",(r=null,()=>(null===r&&(r=["v2","tude"].includes(this.config.AD_SERVER||"")),r))),L(this,"requestBidsWithoutSlots",e=>{let{mappings:t,adUnits:r,cb:i,auctionState:n={}}=e,{PREBID_GLOBAL:s,PREBID_TIMEOUT:o,PREBID_SIZES_OVERRIDE:a}=this.config;try{if(!(null==t?void 0:t.length))throw new V("No mappings provided",{params:e});if(!(null==r?void 0:r.length))throw new V("No ad units provided",{params:e});if(!i||"function"!=typeof i)throw new V("Invalid callback function",{params:e});let d=Q.getGlobalInstance(),l=(0,p.A)(),u=new O(s,l);if(!b.A.canReceivePersonalizedAds())return $.warn("Prebid will not run because personalized ads are turned off"),i({adUnitCodes:[],bids:{},req:!1}),!1;let c=this.processRequestableUnits(t,r,u,a);if(0===c.length)return $.error("No prebid ad unit matches for",t),!1;let f=this.applyPrebidFilters(c,r,t);f.forEach(e=>{try{y.B.emit(`pbjs.beforeRequest.${e.code}`,e)}catch(t){$.error(`Error emitting event for unit ${e.code}:`,t)}});let h=f.map(e=>e.code),m=W.getInstance();return m.push(u),m.garbageCollect(),d.que.push(()=>{try{H(g.dN.PREBID_REQUEST_STARTING,h,{requestableUnits:c}),u.markAsStarted(),d.removeAdUnit(h),d.addAdUnits(f);let e=this.isTudeServe();d.requestBids(F(q({},{timeout:o,adUnitCodes:h,auctionId:l}),{bidsBackHandler:t=>{try{n.timedout||e||d.setTargetingForGPTAsync(h),u.markAsCompleted(),i({adUnitCodes:h,bids:t,req:u})}catch(e){$.error("Error in bidsBackHandler:",e),i({adUnitCodes:[],bids:{},req:!1})}}}))}catch(e){$.error("Error in prebid request execution:",e),u.markAsCompleted(),i({adUnitCodes:[],bids:{},req:!1})}}),!0}catch(e){return $.error("Error in requestBidsWithoutSlots:",e),i({adUnitCodes:[],bids:{},req:!1}),!1}}),e.PREBID_SINGLETON){if(z(Q,Q,K))return z(Q,Q,K);var i=Q,n=Q,s=K,o=this;if(G(i,n),k(s,"set"),s.set)s.set.call(i,o);else{if(!s.writable)throw TypeError("attempted to set read only private field");s.value=o}}this.config=q({},e),this.initialize()}}L(Q,"globalName","pbjs"),L(Q,"registerSignalSourcesCalled",!1);var K={writable:!0,value:null};c.A.sub("prebidGlobalConfig",e=>{try{return(null==e?void 0:e.s2sConfig)&&!e.s2sConfig.timeout&&e.bidderTimeout&&(e.s2sConfig.timeout=Math.max(500,e.bidderTimeout-250)),function(e={}){if(void 0===e.eventHistoryTTL||void 0===e.minBidCacheTTL)try{let t=(0,h.b)();t.que.push(()=>{let i=setTimeout(()=>{try{var i,n;if(Object.keys(r.g.assertive||{}).length>0||window._assertiveInitialized)return;let s={eventHistoryTTL:null!=(i=e.eventHistoryTTL)?i:15,minBidCacheTTL:null!=(n=e.minBidCacheTTL)?n:0};(0,f.A)().advancedLog("configuring prebid to clear events and expired bids",s),t.setConfig(s)}catch(e){$.error("Error in prebid clear events configuration:",e)}},15e3);"undefined"!=typeof window&&window.addEventListener("beforeunload",()=>{clearTimeout(i)},{once:!0})})}catch(e){$.error("Error setting up prebid clear events:",e)}}(e),e}catch(t){return $.error("Error in prebidGlobalConfig filter:",t),e}});var J=r(4413),X=r(67259);let ee="true"==(0,X.P3)("pbjsv2")?100:1,et=100-ee,{PrebidBidderTest:er,matchAdUnitCodeToDivIdTest:ei}=(0,J.J)({name:`20250625-prebid-v2-test-${ee}-${et}`,tracking:"custom_116",variants:[{name:"test",value:{PrebidBidderTest:Q,matchAdUnitCodeToDivIdTest:Z},percent:ee},{name:"control",value:{PrebidBidderTest:N,matchAdUnitCodeToDivIdTest:(e,t)=>{let r=null;return B.getByRecent().filter(e=>e.status===w.STARTED).forEach(i=>{let n=i.units.filter(r=>r.adUnitCode===e&&!1!==r.bidderMatches.includes(t));if(n.length>0)return r=n[0],n[0].bidderMatches.push(t),!1}),r}},percent:et}]});var en=/^(22(251|440)|4(0687|1726|2003|7389)|6(2110|6432|6779|8181|8222|9138)|7(492|6607|8143|8530|9818)|8((1|49|93)07|7938)|9(5(472|611|968)|6056)|11696|17176|32109|51932)$/.test(r.j)?null:er,es=r(99406),eo=r(75208),ea=r(36016);let ed=(0,f.A)("ay-revenue").setLabel("Predictions"),el=.8,eu="USD",ec=[{name:"2RPS",rps:.02},{name:"6RPS",rps:.06},{name:"10RPS",rps:.1},{name:"15RPS",rps:.15},{name:"20RPS",rps:.2},{name:"25RPS",rps:.25}],ef=!1,eh="assertive_predictedRevenue";function ep(){let e;ep.hasRan||(ep.hasRan=!0,window.addEventListener(eh,()=>{e="yes",ea.A.setTargeting({tude_revpr:e})}),A.U.addEventListener("slotRenderEnded",()=>{setTimeout(()=>{e||(e="no",ea.A.setTargeting({tude_revpr:e}))},1e3)}))}var eg={addImpCPMTrackingEvents:(e=el,t=eu)=>{ed.log(g.dN.ADDING_FB_PURCHASE_TRACKING),ep(),window.addEventListener(eh,function(r){if(void 0===window.fbq)return void ed.warn("No FB pixel on the page to record Purchase events");try{let i=r.data.meta.impressionUUID,n=r.data.predictedRevenueCPM.impression*e;fbq("track","Purchase",{currency:t,value:n,transactionId:i}),ed.advancedLog("Facebook (FB) event triggered",{event:"Purchase",value:n,type:"impression"})}catch(e){ed.error(e)}},!1)},addRPSTrackingEvents:(e=ec,t=eu,r=ef,i=!1)=>{ed.log(g.dN.ADDING_FB_RPS_TRACKING),ep(),window.addEventListener(eh,function(n){if(void 0===window.fbq)return void ed.warn("No FB pixel on the page to record RPS events");try{let s=n.data.meta.impressionUUID,o=n.data.predictedRevenueCPM.session/1e3;ed.advancedLog("Session revenue updated",{sessionRev:o}),e.forEach(e=>{let n="tude-fb-rps-"+e.name,a=function(e){let t=new RegExp("".concat(e,"=([^;]+)(?:;|$)")).exec(document.cookie);return t?JSON.parse(t[1]):[]}(n);o>e.rps&&!a.includes(e.rps)&&(fbq("trackCustom",e.name,{currency:t,value:e.rps,transactionId:s}),a.push(e.rps),document.cookie="".concat(n,"=").concat(JSON.stringify(a),"; path=/; samesite=lax; max-age=").concat(1800),ed.advancedLog("Facebook (FB) event triggered",{event:e.name,value:e.rps,type:"rps"}),r&&(window.dataLayer=window.dataLayer||[],window.dataLayer.push({event:"RPS",rpsValue:i?parseInt(100*e.rps):e.rps})))})}catch(e){ed.error(e)}},!1)},useServerSideAyPredictions:()=>{eh="assertive_predictedRevenueServer"}};if(!/^(22(251|440)|4(0687|1726|2003|7389)|6(2110|6432|6779|8181|8222|9138)|7(492|6607|8143|8530|9818)|8((1|49|93)07|7938)|9(5(472|611|968)|6056)|11696|17176|32109|51932)$/.test(r.j))var em=r(69837);var ev=r(34858),eb=/^(22(251|440)|4(0687|1726|2003|7389)|6(2110|6432|6779|8181|8222|9138)|7(492|6607|8143|8530|9818)|8((1|49|93)07|7938)|9(5(472|611|968)|6056)|11696|17176|32109|51932)$/.test(r.j)?null:({divMapping:e,forceRender:t=!1,inViewOnly:r=!0,cb:i})=>{document.addEventListener("visibilitychange",()=>{!document.hidden&&((0,em.A)(document.getElementById(e.divId))||!r)&&(i&&i(),(0,ev.A)(e,t,"Triggering Activity Refresh"))})};if(!/^(22(251|440)|4(0687|1726|2003|7389)|6(2110|6432|6779|8181|8222|9138)|7(492|6607|8143|8530|9818)|8((1|49|93)07|7938)|9(5(472|611|968)|6056)|11696|17176|32109|51932)$/.test(r.j))var ey=r(71309);function eA(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}let eI="timedRefresh";async function ew(...e){(0,f.A)(eI).log(...e)}async function eE(...e){(0,f.A)(eI).advancedLog(...e)}(0,f.A)(eI).setLabel("Timed Refresh","#FFD700");var eS=/^(22(251|440)|4(0687|1726|2003|7389)|6(2110|6432|6779|8181|8222|9138)|7(492|6607|8143|8530|9818)|8((1|49|93)07|7938)|9(5(472|611|968)|6056)|11696|17176|32109|51932)$/.test(r.j)?null:class{startTimer(){this.isPaused&&(this.isPaused=!1,ew(`Started timed refresh for ${this.mapping.divId} at ${this.activeViewSeconds}/${this.targetSeconds} seconds`),this.interval=setInterval(()=>{this.activeViewSeconds+=1,eE([this.mapping.divId],`at ${this.activeViewSeconds} seconds`),this.activeViewSeconds===this.targetSeconds&&this.refresh()},1e3))}refresh(){ew("Triggering timed refresh",this.mapping),this.onTimedRefresh(this.mapping),(0,ev.A)(this.mapping),this.reset()}reset(){setTimeout(()=>this.activeViewSeconds=0,500)}pauseTimer(){this.isPaused||(this.isPaused=!0,ew(`Timed refresh paused for ${this.mapping.divId} at ${this.activeViewSeconds} seconds`),clearInterval(this.interval))}constructor(e,{onTimedRefresh:t,onActivityRefresh:r}){var i,n,s;eA(this,"activeViewSeconds",0),eA(this,"interval",void 0),eA(this,"isPaused",!0),eA(this,"mapping",void 0),eA(this,"onActivityRefresh",void 0),eA(this,"onTimedRefresh",void 0),eA(this,"targetSeconds",void 0),this.mapping=e,this.onActivityRefresh=r,this.onTimedRefresh=t,this.targetSeconds=null==(i=e.refresh)?void 0:i.seconds,ew(`Watching for timed refresh of ${this.targetSeconds} seconds for ${e.divId}`),(null==(n=e.refresh)?void 0:n.activityRefresh)&&eb({divMapping:e,forceRender:!1,inViewOnly:!0,cb:()=>{this.reset(),r(e)}}),(null==(s=e.refresh)?void 0:s.activeView)?(0,ey.A)({viewablePercent:50,divId:e.divId,inViewCb:()=>this.startTimer(),outOfViewCb:()=>this.pauseTimer()}):this.startTimer()}};let e_={onTimedRefresh:void 0,onActivityRefresh:void 0};var eO=/^(22(251|440)|4(0687|1726|2003|7389)|6(2110|6432|6779|8181|8222|9138)|7(492|6607|8143|8530|9818)|8((1|49|93)07|7938)|9(5(472|611|968)|6056)|11696|17176|32109|51932)$/.test(r.j)?null:(e,t)=>new eS(e,function(e){for(var t=1;tt.name===e)}static usePlugin(e,t){let r={props:{}},{PLUGINS:i}=t;i&&i[e.name]&&"object"==typeof i[e.name]&&(r=i[e.name]),e.setConfig(r.props),e.trigger(eD.y.START),this.plugins.push(e),e.ready=!0,e.trigger("ready"),(0,f.A)("Plugin").log("Plugin "+e.name+" has been loaded",r)}static async onReady(e,t){let r=this.getPluginByName(e);r&&(r.ready?t(r):r.on("ready",()=>t(r)))}}u=[],(l="plugins")in eC?Object.defineProperty(eC,l,{value:u,enumerable:!0,configurable:!0,writable:!0}):eC[l]=u;var eR=/^(22(251|440)|4(0687|1726|2003|7389)|6(2110|6432|6779|8181|8222|9138)|7(492|6607|8143|8530|9818)|8((1|49|93)07|7938)|9(5(472|611|968)|6056)|11696|17176|32109|51932)$/.test(r.j)?null:eC,eP=r(7723);if(!/^(22(251|440)|4(0687|1726|2003|7389)|6(2110|6432|6779|8181|8222|9138)|7(492|6607|8143|8530|9818)|8((1|49|93)07|7938)|9(5(472|611|968)|6056)|11696|17176|32109|51932)$/.test(r.j))var eU=r(30085);var ej=r(6262),eB=/^(22(251|440)|4(0687|1726|2003|7389)|6(2110|6432|6779|8181|8222|9138)|7(492|6607|8143|8530|9818)|8((1|49|93)07|7938)|9(5(472|611|968)|6056)|11696|17176|32109|51932)$/.test(r.j)?null:e=>{let t=e.getGlobalInstance();t.que.push(()=>{t.onEvent("auctionEnd",function(e){let t=(0,f.A)("Bid Response");console.group("Bids Received"),console.log("Ad Units",e.adUnitCodes),e.bidsReceived.length>0?console.table(e.bidsReceived,["bidder","cpm","size","timeToRespond"]):t.warn("No bids!"),console.groupEnd()}),t.onEvent("adRenderFailed",function(e){console.error("ad render error",e)})})},ex=r(27286);function eN(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var eM=class{add(e){if("number"!=typeof e||!Number.isFinite(e))throw Error("Value must be a finite number");this.count++,this.total+=e,this.average=this.total/this.count,this.max=1===this.count?e:Math.max(this.max,e),this.min=!1===this.min?e:Math.min(this.min,e),this.list.push(e)}constructor(){eN(this,"count",void 0),eN(this,"total",void 0),eN(this,"average",void 0),eN(this,"max",void 0),eN(this,"min",void 0),eN(this,"list",void 0),this.count=0,this.total=0,this.average=0,this.max=0,this.min=!1,this.list=[]}};(0,f.A)("speed").setLabel("Speed","#888");var ek=r(36783),ez=r(2853),eL=r(28519),eq=r(85487),eF=r(55364),eG=r.n(eF),eV=r(86964).Promise;function e$(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function eH(e){for(var t=1;ti=e),eQ=new eV(e=>n=e),eK=new eV(e=>s=e);class eJ{static init(){window[this.globalName]=window[this.globalName]||{},window[this.globalName].cmd=window[this.globalName].cmd||[],i(window[this.globalName])}static async getInstance(){return eY}static async getConfig(){return eQ}static async getAdUnits(){return eK}}async function eX(){return eJ.getInstance()}async function e0(){return eJ.getAdUnits()}e$(eJ,"globalName","tude");let e1=(e,t,i,{getCurrentDeviceAdUnits:o,getCloneOfUnits:a},d,l=!1,u=!1,p={},I=!1)=>{i=c.A.apply("wrapperConfigOnInit",i,e=>e),n(i),s(o((0,ex.ZI)())),d=c.A.apply("bidModifiersOnInit",d,e=>e);let{AMAZON_BIDDING:w,GLOBAL_NAME:E,PREBID_BIDDER_SETTINGS:S,INIT_GTAG_EARLY:_,INITIAL_USER_STATE:O,DEBUG:T,GPT_SRA:D,GPT_COLLAPSE_EMPTY_DIVS:C,GPT_LAZYLOAD_ENABLED:R,GPT_LAZYLOAD_FETCH_MARGIN:P,GPT_LAZYLOAD_RENDER_MARGIN:U,GPT_LAZYLOAD_MOBILE_SCALING:j,GPT_FORCE_SAFEFRAMES:B,GPT_SET_CENTERING:x,GPT_DISABLE_INITIAL_LOAD:N,PREBID_ALIASES:M,PREBID_CONFIG:k,PREBID_TIMEOUT:z,PREBID_EARLY_USERSYNC:L}=i;O&&b.A.setState(O),eJ.globalName=E,eJ.init(),m.A.isEnabled()||v.A.isEnabled()||(0,eL.x)(ek.default,{userModules:[]}),T&&(0,f.A)().enable(),(0,f.A)().advancedLog(g.dN.SCRIPT_STARTED,i),en.setGlobalName(i.PREBID_GLOBAL),d?en.setBidderSettings(eH({},d(),S)):en.setBidderSettings(eH({},S)),(0,f.A)().isEnabled()&&eB(en);let q=!1,F=null,G=null,V=[],$={collapseEmptyDivs:C,enableSingleRequest:D,setForceSafeFrame:B,setCentering:x,disableInitialLoad:!1!==N,enableLazyLoad:!!R&&{fetchMarginPercent:P,renderMarginPercent:U,mobileScaling:j}};function H(e,t={}){t&&"object"==typeof t&&A.U.setSlotTargeting(e,t);let r=i.GOOGLE_TARGETING_PARAMS||{};A.U.setSlotTargeting(e,r)}function W(e){A.U.push(function(){A.U.init($),e.forEach(e=>{let t=G||c.A.apply("gamAdUnitName",e.adUnit,e=>e),r=c.A.apply("gamSizes",{adUnit:t,divId:e.divId,baseDivId:e.baseDivId,targeting:e.targeting,sizes:e.sizes},({sizes:e})=>e);H(A.U.defineGptSlot({adUnit:t,sizes:r,divId:e.divId}),eW(eH({},e.targeting),{baseDivId:e.baseDivId}))})})}_&&A.U.init($),A.U.addAllEventListeners(),A.U.addEventListener("slotRenderEnded",e=>{let t=e.slot.getSlotElementId(),r=e.isEmpty?"generic.ad.unfilled":"generic.ad.filled";y.B.emit(r,{id:t})}),(0,ez.VC)(e=>{e.events().on("no_bid",e=>{let t=e.slot.elementId;y.B.emit("generic.ad.unfilled",{id:t})}),e.events().on("bid_won",e=>{let t=e.slot.elementId;y.B.emit("generic.ad.filled",{id:t})})});let Z={};(i.URL_TARGETING_PARAMS||[]).forEach(e=>{let t=(0,X.P3)(e);t&&(Z[e]=t)}),Object.keys(Z).length&&ea.A.setTargeting(Z),w&&("aps"===i.AMAZON_SDK?(es.A.setConfig(i),eo.A.getInstance({accountId:String(i.AMAZON_PUB_ID),timeout:i.PREBID_TIMEOUT,deals:i.AMAZON_DEALS,useSafeFrames:i.GPT_FORCE_SAFEFRAMES||i.AMAZON_SAFE_FRAMES||!1,wrapperConfig:i})):es.A.loadLibrary({pubID:i.AMAZON_PUB_ID,bidTimeout:i.PREBID_TIMEOUT,deals:i.AMAZON_DEALS,useSafeFrames:i.GPT_FORCE_SAFEFRAMES||i.AMAZON_SAFE_FRAMES||!1,wrapperConfig:i,params:i.AMAZON_PARAMS,signals:i.AMAZON_SIGNALS})),M.length>0&&(k.userSync=eH({},k.userSync,{aliasSyncEnabled:!0}));let Y=c.A.apply("prebidGlobalConfig",eH({bidderTimeout:z},k),e=>e),Q=en.getGlobalInstance();Q.que.push(()=>{let e=o(F);M.length>0&&M.map(e=>{Q.aliasBidder(e.bidder,e.alias,e.options)}),Q.setConfig(Y),(0,f.A)().log(g.dN.CONFIG_ESTABLISHED,{config:Y,adUnits:e})}),L&&new en(i),A.U.push(()=>{let e=en.getGlobalInstance();e.que.push(()=>{e.setTargetingForGPTAsync(),(0,f.A)().log(g.dN.SERVER_INITIALIZED)})});let K=!1;i.ASSERTIVE_YIELD.predictions&&(i.ASSERTIVE_YIELD.serverSidePredictions&&eg.useServerSideAyPredictions(),i.EVENTS_AY_FB_PURCHASE_ENABLED&&eg.addImpCPMTrackingEvents(i.EVENTS_AY_FB_PURCHASE_MODIFIER||.8),i.EVENTS_AY_FB_RPS_ENABLED&&eg.addRPSTrackingEvents(i.EVENTS_AY_FB_RPS_MAP,i.CURRENCY,i.EVENTS_AY_RPS_GTM_ENABLED,i.EVENTS_AY_RPS_GTM_WHOLE_NUMBERS));let J=e=>{let t=[];return e.filter(e=>{for(let r=0;r"v2"===i.AD_SERVER;ee()&&(0,ez.E3)();let et=e=>{K=K||{};let t=F||(0,ex.ZI)();(0,f.A)().log(g.dN.DIV_TO_PREBID_AD_UNIT_MAP_SETTING,e),e.forEach(e=>{var r;let i;if(!e.divId)return(0,f.A)().error(g.dN.NO_DIV_ID_GIVEN_TO_MAP,e),!1;e.prebidAdUnit||(0,f.A)().warn(g.dN.NO_PREBID_AD_UNIT_GIVEN_TO_MAP,e);let n=!1;if(a(o(t)).forEach(t=>{if(!(null==e?void 0:e.gamOnly)&&t.code===e.prebidAdUnit){let{amazon:e,mediaTypes:r,code:i,disableAmazonBidding:s,allowLazyDestroy:o,safeframe:a}=t;return n={amazon:e,code:i,allowLazyDestroy:o,disableAmazonBidding:s,safeframe:a,sizes:r.banner?r.banner.sizes:[[1,1]]},!0}}),e.gamSizes?i=J(e.gamSizes):((0,f.A)().warn(g.dN.NO_GAM_SIZES_GIVEN,e),n&&(i=J(n.sizes))),!i)return!1;if(e.device){if(Array.isArray(e.device)&&!e.device.includes(t)||"string"==typeof e.device&&e.device!==t)return!1}else if(!n)return!1;K[e.divId]={amazon:null==n?void 0:n.amazon,allowLazyDestroy:null==(r=null==n?void 0:n.allowLazyDestroy)||r,disableAmazonBidding:null==n?void 0:n.disableAmazonBidding,prebidAdUnit:e.prebidAdUnit,gamOnly:(null==e?void 0:e.gamOnly)||!1,gamSizes:i,prebidSizes:e.prebidSizes,safeframe:null==n?void 0:n.safeframe,slot:e.slot,targeting:e.targeting}}),!q&&(q=!0,V.length>0&&V.forEach(function(e){"function"==typeof e&&new eV(t=>{e(),t()})}))},er=e=>{if(ee()&&((0,ez.VC)(t=>{e.forEach(e=>{let{divId:r,adUnit:n,sizes:s,targeting:o,safeframe:a}=e;t.ads().slots.add(n,r,s,o,null!=a?a:i.GPT_FORCE_SAFEFRAMES)}),(0,f.A)().log("slots",t.ads().slots)}),!(null==i?void 0:i.TUDESERVE_GPT_FALLBACK)))return;e.forEach(e=>{let t=A.U.getSlotByDivId(e.divId);t&&H(t,Object.assign({},i.GOOGLE_TARGETING_PARAMS,e.targeting))});let t=A.U.getAllSlotDivIds();if(t.length<1)return W(e.map(e=>{let{divId:t,adUnit:r,sizes:i,targeting:n,baseDivId:s}=e;return{divId:t,adUnit:r,sizes:i,targeting:n,baseDivId:s}})),!0;let r=e.filter(e=>!t.includes(e.divId)).map(e=>{let{divId:t,adUnit:r,sizes:i,targeting:n,baseDivId:s}=e;return{divId:t,adUnit:r,sizes:i,targeting:n,baseDivId:s}});r.length&&W(r)};async function ed(e=[],t=!0){(0,f.A)().log(g.dN.DESTROYING_DIVS,e),t&&e.forEach(e=>{let t=document.getElementById(e);if(t){let e=t.offsetHeight,r=document.createElement("div");r.classList.add("tude-destruct-placeholder"),r.style="min-height:"+e+"px;background:#f3f3f3;border-radius:4px;",r.setAttribute("data-div-id",t.id),t.after(r),t.remove()}}),A.U.push(()=>{let t=A.U.getSlotListByDivIds(e);t.length>0?((0,f.A)().log(g.dN.DESTROYING_GPT_SLOTS,t.map(e=>e.getSlotElementId())),A.U.destroySlots(t)):(0,f.A)().warn(g.dN.DESTROYING_NO_GPT_SLOTS)})}let el=e=>e.filter(e=>!!e.baseDivId&&!!K[e.baseDivId]||((0,f.A)().error('Missing a base prebid mapping for base "'+e.baseDivId+'"'),!1)).map(e=>{let{amazon:t,allowLazyDestroy:r,disableAmazonBidding:i,gamOnly:n,gamSizes:s,prebidAdUnit:o,prebidSizes:a,safeframe:d,targeting:l,timedRefresh:u,slot:c,lazy:f}=K[e.baseDivId],h={};return l&&"object"==typeof l&&(h=eH({},l)),e.targeting&&(h=eG()(h,e.targeting)),eW(eH({},e),{adUnit:o,amazon:t,allowLazyDestroy:r,disableAmazonBidding:i,gamOnly:n,sizes:s,prebidSizes:a||s,safeframe:d,targeting:h,timedRefresh:u,slot:c,lazy:f})}),eu=(e,t)=>{if(!q)return V.push(()=>{eu(e,t)}),!1;if(!e||!K[e])return(0,f.A)().error('Missing a base prebid mapping for base "'+e+'"'),!1;A.U.init($);let{prebidAdUnit:r}=K[e],{targeting:n}=K[e],{CUSTOM_DIVS:s}=i;r=s.some(t=>t.divId===e&&!t.excludePathOverride)&&G?G:c.A.apply("gamAdUnitName",r,e=>e);let o=()=>{(0,f.A)().log("Calling interstitial slot",[e,r]);let i=!1;A.U.push(function(){let s=googletag.enums.OutOfPageFormat.INTERSTITIAL;"string"==typeof t&&(s=t),"BOTTOM_ANCHOR"===t&&(s=googletag.enums.OutOfPageFormat.BOTTOM_ANCHOR),"TOP_ANCHOR"===t&&(s=googletag.enums.OutOfPageFormat.TOP_ANCHOR);let o={baseDivId:e,prebidAdUnit:r,gamEnumOopType:s,targeting:n};if(y.B.emit("baseWrapper.beforeDefineOutOfPageSlot",o),i=A.U.defineOutOfPageSlot(o.prebidAdUnit,o.gamEnumOopType)){H(i,n),i=c.A.apply("interstitialBeforeLoad",i,e=>e);let{INTERSTITIAL_CONFIG:t}=o;if(t){var a,d;i.setConfig({interstitial:{triggers:{navBar:null!=(a=t.navbar)&&a,unhideWindow:null!=(d=t.unhideWindow)&&d}}})}(0,f.A)().log("Interstitial initalized with GPT",[e,r]),(0,f.A)().log("Rendering interstitial",[e,r]),A.U.refresh([i])}else(0,f.A)().error("Device does not support interstitials",[e,r])})},{INTERSTITIAL_DELAY:a}=i;return a?setTimeout(()=>{o()},a):o(),!0};async function ec(e,t){(0,f.A)().log("Render triggered",e,{speed:Date.now()-t.timing.start}),eZ.record("requestToRender",Date.now()-t.timing.start),(0,eP.f)(e),y.B.emit(g.qY.AFTER_REQUEST,{divIds:e})}async function ef(e,t,r){let n=e.map(e=>e.divId),s=new eU.A;if(s.onComplete(()=>{ec(n,s)}),t.length<1)return s.complete(),!0;t.forEach(e=>{s.addBidder(e)});let d=e.filter(e=>!1!==e.adUnit);if(t.includes("prebid")){let t=new en(i);(0,f.A)().log(g.dN.PREBID_BIDS_REQUESTING,e.map(e=>e.divId)),t.requestBidsWithoutSlots({mappings:d,adUnits:a(o(F)),cb:({adUnitCodes:e,bids:t,req:r})=>{null!==t&&void 0!=t&&"object"==typeof t&&((0,f.A)().log(g.dN.PREBID_BIDS_RECEIVED,e,{bids:t,timing:r?r.getTimings():null}),(0,f.A)().isAdvanced()&&Object.keys(t).forEach(e=>{t[e].bids.forEach(e=>{eZ.record("bidder."+e.bidderCode,e.timeToRespond)})})),s.setBidderStatus("prebid",!0)}})}if(t.includes("amazon")){let e;("aps"===i.AMAZON_SDK?eo.A.getInstance({accountId:String(i.AMAZON_PUB_ID)}):new es.A).requestBids({slots:d.map(e=>{let{adUnit:t,amazon:r,divId:i,sizes:n}=e;return r?eH({slotName:G||t,sizes:n,slotID:i},r):{slotID:i,slotName:G||t,sizes:n}})},!0,e=>{!1!==e&&(0,f.A)("Amazon").log(g.dN.AMAZON_BIDS_RECEIVED,n,{bids:e}),s.setBidderStatus("amazon",!0)})}let l=e.filter(e=>!1!==e.adUnit).map(e=>{let{divId:t,baseDivId:r}=e;return{divId:t,baseDivId:r}});y.B.emit(g.qY.BIDS_REQUESTED,{divIds:n,divToBaseMaps:r,filteredMappings:l});let{FAILSAFE_TIMEOUT:u}=i;setTimeout(()=>{s.complete()&&(0,f.A)().log(g.dN.REQUEST_TIMED_OUT,s,n)},u)}let eh=[],ep=(e,t=!1)=>{if((0,f.A)().log("refreshAdsViaDivMappings called",{divToBaseMaps:e,forceRender:t}),!Array.isArray(e))return(0,f.A)().error("Expected an array of div mappings. Received the following.",e),!1;let r=Array.from(new Set((e=e.map(e=>(e.metadata=e.metadata||{},e.metadata.forceRenderFromCall=t,(null==e?void 0:e.divId)&&"string"==typeof e.divId&&(e.divId=e.divId.trim()),(null==e?void 0:e.baseDivId)&&"string"==typeof e.baseDivId&&(e.baseDivId=e.baseDivId.trim()),e))).map(e=>e.divId)));if(r.length!==e.length){let t={before:e};t.after=e=r.map(t=>e.find(e=>e.divId===t)),(0,f.A)().warn("duplicate divIds passed to refreshAdsViaDivMappings(), normalized configs",t)}i.GOOGLE_PAGE_URL&&e.forEach(e=>{e.pageUrl&&A.U.setPageUrl(e.pageUrl)}),i.ADVANCED_TIMED_REFRESH.enabled&&e.forEach(e=>{e.refresh&&!eh.includes(e.divId)&&(eh.push(e.divId),eO(e,i.ADVANCED_TIMED_REFRESH.advancedTimedRefreshConfig))});let{FORCE_RENDER_OVERRIDE:n}=i;if(n&&(t=n),!q)return V.push(()=>{ep(e,t)}),!1;y.B.emit(g.qY.BEFORE_REFRESH,e),e.forEach(r=>{y.B.emit(`baseWrapper.beforeRefresh.${r.baseDivId}`,{mapping:r,remove:()=>{(0,ej.A)(e,e=>e.divId!==r.divId)},forceRender:t})});let s=el(e),d=s.map(e=>e.divId);if(s.length<1)return(0,f.A)().warn("Not refreshing because divs do not have mappings",r),!1;function u(t,r,{AMAZON_BIDDING:n,AMAZON_OUTSTREAM_SUPPORT:s,AMAZON_PUB_ID:d,AMAZON_SDK:l}){if((0,f.A)().log("Starting bid request from function",t,r),t.length<1)return;y.B.emit(g.qY.BEFORE_REQUEST,{divIds:t,mappings:r});let u=[],p=[];r.forEach(e=>{y.B.emit(`baseWrapper.beforeRequest.${e.baseDivId}`,{mapping:e,remove:()=>{u.push(e.divId),p.push(e.divId)}})}),r=r.filter(e=>!u.includes(e.divId)),t=t.filter(e=>!p.includes(e)),u.length=0,p.length=0,er(r),y.B.emit(g.qY.AFTER_CREATE_SLOTS,{divIds:t,mappings:r}),r.forEach(e=>{y.B.emit(`baseWrapper.afterCreateSlots.${e.baseDivId}`,{mapping:e,remove:()=>{u.push(e.divId),p.push(e.divId)}})}),r=r.filter(e=>!u.includes(e.divId)),t=t.filter(e=>!p.includes(e));let m=r.filter(e=>e.gamOnly);m.length>0&&((0,f.A)().log("Requesting GAM only units",m),ef(m,[],e));let v=r.filter(e=>!e.gamOnly),b=v.map(e=>e.divId);if(v.length<1)return y.B.emit(g.qY.BIDS_REQUESTED,{divIds:t,divToBaseMaps:e,filteredMappings:r.filter(e=>!1!==e.adUnit).map(e=>{let{divId:t,baseDivId:r}=e;return{divId:t,baseDivId:r}})}),!0;let A={queued:!1,prebid:!1,timedout:!1,timeoutHandle:void 0,timing:{start:Date.now()}};function I(e){return clearTimeout(A.timeoutHandle),!A.queued&&((A.queued=!0,(0,f.A)().log("Render triggered",e,{speed:Date.now()-A.timing.start}),eZ.record("requestToRender",Date.now()-A.timing.start),ee())?((0,ez.VC)(t=>{t.ads().request(e)}),e):void((0,eP.f)(e),y.B.emit(g.qY.AFTER_REQUEST,{divIds:e})))}if(n&&(A.amazon=!1),v=v.filter(e=>!1!==e.adUnit),ee()&&(0,ez.VC)(e=>{e.ads().slots.getSlots().filter(e=>b.includes(e.elementId)).forEach(e=>{e.clearBids()})}),n&&v.length>0){let e;e="aps"===l?eo.A.getInstance({accountId:String(d)}):new es.A;let t=c.A.apply("amazonAuctionMappings",v,e=>e).filter(e=>!e.disableAmazonBidding).map(e=>{let{slot:t,adUnit:r,amazon:i,divId:n,sizes:d}=e,l={slotID:n,slotName:G||r,sizes:d};if(s){var u,c,f;let{mediaTypes:e={}}=a(o(F||(0,ex.ZI)())).find(e=>{if(e.slot===t||Array.isArray(e.slot)&&e.slot.includes(t))return!0})||{};if((null==e||null==(u=e.video)?void 0:u.context)==="outstream"){let t=(null==e||null==(c=e.video)?void 0:c.playerSize)||[[640,480]];t&&Array.isArray(t)&&2==t.length&&!Array.isArray(t[0])&&(t=[t]),(null==e||null==(f=e.banner)?void 0:f.sizes)||(l=eW(eH({},l),{mediaType:"video",sizes:t}))}}return i&&(l=eH({},l,i)),l}),r=c.A.apply("amazonAuctionSlots",t,e=>e);r.length?e.requestBids({slots:r,auctionState:A},!0,e=>{!1!==e&&(e.length>0?(0,f.A)("Amazon").log(g.dN.AMAZON_BIDS_RECEIVED,b,e):(0,f.A)("Amazon").warn("No Amazon bids received for",b)),!A.timedout&&(ee()&&(0,ez.VC)(e=>{r.forEach(t=>{let r=e.ads().slots.getSlotByElementId(t.slotID),i=r&&(0,eT.c$)({slotID:t.slotID});if(r&&i){var n;let s=(0,eT.iC)(i),o=e.ads().factory().createBid({amount:(0,eT.UN)(s.amznbid)||0,slotId:r.elementId,source:"amazon",mediaType:null!=(n=null==t?void 0:t.mediaType)?n:"banner",sourceData:s,currency:"USD"});r.bids.push(o)}})}),A.amazon=!0,A.prebid&&I(b))}):A.amazon=!0}let w=new en(i);(0,f.A)("Prebid").log(g.dN.PREBID_BIDS_REQUESTING,v.map(e=>e.divId)),w.requestBidsWithoutSlots({mappings:v,adUnits:a(o(F)),auctionState:A,cb:({adUnitCodes:e,bids:t,req:r})=>{null!==t&&void 0!=t&&"object"==typeof t&&((0,f.A)("Prebid").log(g.dN.PREBID_BIDS_RECEIVED,e,{bids:t,timing:r?r.getTimings():null}),(0,f.A)().isAdvanced()&&Object.keys(t).forEach(e=>{t[e].bids.forEach(e=>{eZ.record("bidder."+e.bidderCode,e.timeToRespond)})})),ee()&&(0,ez.VC)(e=>{for(let n of r.units)try{var t,i;let r=null==(t=Q.getHighestCpmBids(n.adUnitCode))?void 0:t[0];if(r&&r.adId){let t=e.ads().slots.getSlotByElementId(n.divId);if(t){let n=e.ads().factory().createBid({amount:r.cpm,bidder:r.bidder,slotId:t.elementId,source:"prebid",mediaType:null!=(i=null==r?void 0:r.mediaType)?i:"banner",sourceData:r,currency:r.currency||"USD"});t.bids.push(n)}}}catch(e){(0,f.A)().error(e)}}),A.timedout||(A.prebid=!0,(!n||A.amazon)&&I(b))}});let E=r.filter(e=>!1!==e.adUnit).map(e=>{let{divId:t,baseDivId:r}=e;return{divId:t,baseDivId:r}});y.B.emit(g.qY.BIDS_REQUESTED,{divIds:t,divToBaseMaps:e,filteredMappings:E});let S=400;try{S=(0,h.b)().getConfig("timeoutBuffer")||S}catch(e){}A.timeoutHandle=setTimeout(()=>{if(A.timedout=!0,ee())A.prebid||(0,f.A)().log(g.dN.REQUEST_TIMED_OUT,A,b),I(b);else{if(!1===A.prebid)try{(0,h.b)().setTargetingForGPTAsync(b)}catch(e){}!1!==I(b)&&(0,f.A)().log(g.dN.REQUEST_TIMED_OUT,A,b)}},i.PREBID_TIMEOUT+S+100)}let p=l;("function"!=typeof p||t)&&(p=function(e,t,r,i){i(e,t,r)});let m=()=>{if(i.DIV_CHECK_ON_REQUEST){let e=d.filter(e=>!document.getElementById(e));e.length>0&&((0,f.A)().warn("Requested Div Ids do not exist on page",e),d=d.filter(e=>document.getElementById(e)),s=s.filter(e=>d.includes(e.divId)))}p(d,s,i,u)};return ee()?(0,ez.VC)(()=>m()):A.U.push(()=>m()),!0},em=e=>{eq.A.do("device-type-change",async()=>{let t=Object.keys(g.Xr).find(t=>g.Xr[t]===e);t&&e!==F?((0,f.A)().log(g.dN.SETTING_DEVICE_TYPE,e),F=e):t&&F===e?(0,f.A)().log(g.dN.SETTING_SAME_DEVICE_TYPE,F):(0,f.A)().error(g.dN.DEVICE_TYPE_NOT_SUPPORTED,e,g.Xr)})},ev=e=>{if(!e||"object"!=typeof e)throw Error("Object not set in first arg for setPageTargeting");(0,f.A)().log("setPageTargeting invoked",e),eq.A.do("setPageTargeting",()=>{ea.A.setTargeting(e)},e),(null==p?void 0:p.setVideoPageTargeting)&&p.setVideoPageTargeting(e)},eb=eH({},i.FLAGS),ey=e=>{if("object"!=typeof e)return!1;eb=eH({},eb,e)};function eA(e){var t,n,s;let o=(null==(s=i.PLUGINS)||null==(n=s.FixedAdInjection)||null==(t=n.props)?void 0:t.placements)||[];e.enabled&&(e.viewableShowHide&&o.forEach(t=>{e.viewableShowHide.baseDivsToHide.includes(t.baseDivId)&&(t.viewableShowHide={target:e.viewableShowHide.target})}),r.e(67823).then(r.bind(r,97016)))}let eI=e=>{eR.usePlugin(e,i)},ew=e=>{G=e.endsWith("/")?e.slice(0,-1):e,(0,f.A)().log("Setting Ad Unit Path Override",G)},eE=e=>{e()},eS=!1,e_=setInterval(()=>{if(eS||!i.WAIT_FOR_CMP||"function"==typeof __tcfapi||"function"==typeof __uspapi){i.WAIT_FOR_CMP&&(0,f.A)().log("CMP check passed. Starting wrapper.",{isDev:!1,isUsp:"function"==typeof __uspapi,isGdpr:"function"==typeof __tcfapi,isSkip:eS});let e=window[E]||{};e.cmd=e.cmd||[];let t=[];Array.isArray(e.cmd)&&(t=[...e.cmd]),(0,f.A)().log("Queue to process soon",t),Object.assign(window[E],c.A.apply("tudePublicFunctions",{tude:eW(eH({},p),{cmd:{push:eE},destroyAds:ed,interstitial:eu,matchAdUnitCodeToDivId:ei,refreshAdsViaDivMappings:ep,registerPlugin:eI,setAdInjectionConfig:eA,setAdUnitPath:ew,setBasePrebidMappings:et,setDeviceType:em,setFeatureFlags:ey,setPageTargeting:ev})},({tude:e})=>e)),y.B.emit(g.qY.GLOBAL_SET,window[E]),(0,f.A)().log("window."+E+" established"),eq.A.do("before-process-queue",async()=>{}),t.length>0&&((0,f.A)().log(g.dN.QUEUE_PROCESSING),t.forEach(function(e){"function"==typeof e&&new eV(t=>{e(),t()}).catch(e=>(0,f.A)().error(e))}),(0,f.A)().log(g.dN.QUEUE_PROCESSED)),!1!==u&&(et(u),y.B.emit(g.qY.BASE_DIV_MAPPINGS_SET,K)),I&&"function"==typeof I&&I(eb),e_&&(clearInterval(e_),e_=!1)}},50);setTimeout(function(){e_&&((0,f.A)().log(g.dN.CMP_NEVER_LOADED),eS=!0)},12e3),(0,f.A)("baseWrapper").setLabel("Wrapper has loaded","red").log({buildTime:"2025-07-18T20:40:24.976Z",buildTimeEST:new Date("2025-07-18T20:40:24.976Z").toLocaleString("en-US",{timeZone:"America/New_York",hour:"2-digit",minute:"2-digit",hour12:!1,month:"2-digit",day:"2-digit"}),device:(0,ex.ZI)(),environment:"production",name:e,version:t.toString().replaceAll('"',"")})}},45083:function(e,t,r){var i=r(1882),n=r(87296),s=r(23805),o=r(47473),a=/^\[object .+?Constructor\]$/,d=Object.prototype,l=Function.prototype.toString,u=d.hasOwnProperty,c=RegExp("^"+l.call(u).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=function(e){return!(!s(e)||n(e))&&(i(e)?c:a).test(o(e))}},46817:function(e,t,r){"use strict";let i,n;r.d(t,{A:function(){return C},w:function(){return R}});var s=r(9337),o=r(22188),a=r(87594),d=r(52093),l=r(10667);function u(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function c(e){for(var t=1;t{var t,r,n,s;let o=null==e?void 0:e[0];(null==o?void 0:o.dynamicRevShare)&&["aditude.io","aditude.com"].includes(null==o||null==(s=o.schain)||null==(n=s.config)||null==(r=n.nodes)||null==(t=r[0])?void 0:t.asi)&&(i=o.dynamicRevShare),null==g||g()}),m={buckets:[{max:5,increment:.5}]},v={buckets:[{max:20,increment:.1}]},b={buckets:[{max:20,increment:.01}]},y={buckets:[{max:3,increment:.01},{max:8,increment:.05},{max:20,increment:.5}]},A={buckets:[{max:5,increment:.05},{max:10,increment:.1},{max:20,increment:.5}]};class I{enable(){this.enabled||(this.enabled=!0,this.pbjs.que.push(()=>{this.setTargetingForGPTAsyncOriginal||(this.setTargetingForGPTAsyncOriginal=this.pbjs.setTargetingForGPTAsync),this.getHighestCpmBidsOriginal||(this.getHighestCpmBidsOriginal=this.pbjs.getHighestCpmBids),this.pbjs.getHighestCpmBids=this.getHighestCpmBids.bind(this),this.pbjs.setTargetingForGPTAsync=this.setTargetingForGPTAsync.bind(this),this.originalUseBidCache=this.pbjs.getConfig("useBidCache"),this.pbjs.setConfig({useBidCache:!0})}),this.logger.advancedLog("enabled"))}getMediaTypes(e){var t,r;let i=null!=(r=null==(t=this.pbjs.adUnits)?void 0:t.filter(t=>t.code===e))?r:[],n=!!(null==i?void 0:i.find(e=>{var t;return null==(t=e.mediaTypes)?void 0:t.banner})),s=!!(null==i?void 0:i.find(e=>{var t;return null==(t=e.mediaTypes)?void 0:t.video})),o=s&&!!(null==i?void 0:i.find(e=>{var t,r;return(null==(r=e.mediaTypes)||null==(t=r.video)?void 0:t.context)==="outstream"})),a=s&&!!(null==i?void 0:i.find(e=>{var t,r;return(null==(r=e.mediaTypes)||null==(t=r.video)?void 0:t.context)==="instream"}));return{isBanner:n,isMultiformat:n&&o,isVideo:s,isOutstream:o,isInstream:a}}dynamicRevShareBattle(e,t){var r,n,s;if(!this.isDynamicRevShareEnabled())return e;let o=(0,l.A)("dynamic-rev-share").setLabel("DynamicRevShare","crimson");if(t.originalCurrency!==t.currency||t.currency!==e.currency)throw Error("currency mismatch");if(Math.floor(100*t.originalCpm)=Math.floor(100*v)){let r=t.cpm;return t[this.dynamicRevShareOriginalBidKey]=t.cpm,t.cpm=v,this.updatePriceBucketsForBid(t),o.advancedLog("aditude demand wins",{oldCpm:r,newCpm:v,pubCpm:e.cpm},t),this.sendDynamicRevShareEvent("tude-win",t.adUnitCode,t,y),t}return o.advancedLog("pub demand wins",e),this.sendDynamicRevShareEvent("tude-lose",t.adUnitCode,t,y),e}sendDynamicRevShareEvent(e,t,r,i){var n;let o=d.U.getSlotByDivId(t),a={adServer:"v2"===this.adServer?"tudeserve":"googletag",adUnitPath:(null==o||null==(n=o.getAdUnitPath)?void 0:n.call(o))||t,slotElementId:t,slotId:t},l={source:"dynamic-rev-share:"+e,mediaType:r.mediaType,currency:r.currency||"USD",originalCurrency:r.originalCurrency||"USD",cpm:r.cpm,originalCpm:r.originalCpm,bidder:r.bidder,adapterCode:r.adapterCode||r.bidder,adId:r.adId},u=c({event:e},i);(0,s.yM)("outError",f(c({},a,l),{message:JSON.stringify(u)}))}updatePriceBucketsForBid(e){var t,r,i,n,s,o,a,d,l,u;if(!(null==e?void 0:e.cpm))return;let c=null!=(u=null==(t=(r=this.pbjs).getConfig)?void 0:t.call(r,"mediaTypePriceGranularity"))?u:{},f=(null==(i=(n=this.pbjs).getConfig)?void 0:i.call(n,"currency.granularityMultiplier"))||1,h=null==(s=(o=this.pbjs).getConfig)?void 0:s.call(o,"customPriceBucket"),p=null==(d=(l=this.pbjs).getAllBidRequests)||null==(a=d.call(l).find(t=>t.bidId===e.requestId))?void 0:a.mediaTypes,g=this.getMediaTypeGranularity(e.mediaType,p,c),I=parseFloat(null==e?void 0:e.cpm),w={low:this.getCpmStringValue(I,m,f),med:this.getCpmStringValue(I,v,f),high:this.getCpmStringValue(I,b,f),auto:this.getCpmStringValue(I,A,f),dense:this.getCpmStringValue(I,y,f),custom:this.getCpmStringValue(I,null!=g?g:h,f)};e.pbLg=w.low,e.pbMg=w.med,e.pbHg=w.high,e.pbAg=w.auto,e.pbDg=w.dense,e.pbCg=w.custom}isEmpty(e){return!e||(Array.isArray(e)||"string"==typeof e?!(e.length>0):Object.keys(e).length<=0)}isValidPriceConfig(e){if(this.isEmpty(e)||!e.buckets||!Array.isArray(e.buckets))return!1;let t=!0;return e.buckets.forEach(e=>{e.max&&e.increment||(t=!1)}),t}getCpmStringValue(e,t,r){let i="";if(Number.isNaN(e)||!this.isValidPriceConfig(t))return i;let n=t.buckets.reduce((e,t)=>e.max>t.max?e:t,{max:0}),s=0,o=t.buckets.find(t=>{if(e>n.max*r){let e=t.precision;void 0===e&&(e=2),i=(t.max*r).toFixed(e)}else{if(e<=t.max*r&&e>=s*r)return t.min=s,t;s=t.max}});return o&&(i=this.getCpmTarget(e,o,r)),i}getCpmTarget(e,t,r){let i,n,s=void 0!==t.precision?t.precision:2,o=t.increment*r,a=t.min*r,d=Math.floor,l=this.pbjs.getConfig("cpmRoundingFunction");"function"==typeof l&&(d=l);let u=Math.pow(10,s+2),c=(e*u-a*u)/(o*u);try{i=d(c)*o+a}catch(e){n=!0}return(n||"number"!=typeof i)&&(i=Math.floor(c)*o+a),(i=Number(i.toFixed(10))).toFixed(s)}getMediaTypeGranularity(e,t,r){let i="video";if(e&&r){if(e===i){var n,s;let e=null!=(s=null==t||null==(n=t[i])?void 0:n.context)?s:"instream";if(r[`${i}-${e}`])return r[`${i}-${e}`]}return r[e]}}getHighestCpmBids(e,t={}){this.logger.advancedLog("Prebid - Invoking custom pbjs.getHighestCpmBids",{adUnitCode:e,options:t});let r=this.getAdUnitCodes(e),i=[];return r.forEach(e=>{var r;let n=this.getAllUnusedBidsForCode(e,t);n.forEach(t=>{t.adUnitCodeOriginal=t.adUnitCodeOriginal||t.adUnitCode,t.adUnitCode=e}),this.maybeAdjustForDynamicRevShare(e,n);let s=null==(r=this.pbjs.getTargetingManager().getWinningBids(e,n))?void 0:r[0],o={from:void 0};s&&(this.pbjs.getAuctionManager().setStatusForBids(s.adId,p.BID_STATUS.BID_TARGETING_SET),s.isRequesting=e,i.push(s),s.adUnitCode!==s.adUnitCodeOriginal&&(o.from=s.adUnitCodeOriginal)),this.logger.advancedLog(e,f(c({highBid:s},o),{bids:n})),n.forEach(e=>{e.adUnitCodeOriginal&&e.adId!==(null==s?void 0:s.adId)&&(e.adUnitCode=e.adUnitCodeOriginal)})}),i}setTargetingForGPTAsync(e,t,r={}){if(this.logger.advancedLog("Prebid - Invoking custom pbjs.setTargetingForGPTAsync",{adUnit:e,customSlotMatching:t}),!(d.U.getGlobal().pubads&&d.U.getGlobal().pubads().getSlots)){this.logger.error("window.googletag is not defined on the page, deferring"),d.U.push(()=>{this.setTargetingForGPTAsync(e,t)});return}return this.getMajorPrebidVersion()>=9?this.setTargetingForGPTAsyncModern(e,t,r):this.setTargetingForGPTAsyncLegacy(e,t,r)}isDynamicRevShareEnabled(){return!!((null==i?void 0:i.enabled)&&(null==i?void 0:i.fees)&&this.bidModifiers)}maybeAdjustForDynamicRevShare(e,t){var r;if(!this.isDynamicRevShareEnabled())return;let i=null==(r=this.pbjs.getTargetingManager().getWinningBids(e,t))?void 0:r[0];if((null==i?void 0:i.isAditudeDemand)===!1&&(null==i?void 0:i.cpm)){let e=t.filter(e=>e.isAditudeDemand&&e.originalCpm>i.cpm).sort((e,t)=>e.originalCpm>t.originalCpm||e.originalCpm===t.originalCpm&&e.responseTimestamp!0===e.isAditudeDemand);if(null==e?void 0:e.cpm)try{this.dynamicRevShareBattle(i,e)}catch(e){}}}revertDynamicRevShareChanges(e){(null==e?void 0:e[this.dynamicRevShareOriginalBidKey])&&(this.logger.advancedLog("DynamicRevShare resetting: ",{current:e.cpm,resettingTo:e[this.dynamicRevShareOriginalBidKey],bid:e}),e.cpm=e[this.dynamicRevShareOriginalBidKey],this.updatePriceBucketsForBid(e)),delete e[this.dynamicRevShareOriginalBidKey]}setTargetingForGPTAsyncModern(e,t,r={}){let i=this.getAdUnitCodes(e),n=this.pbjs.getAuctionManager().getBidsReceived().filter(O),s="__tmp_disable__";i.forEach(e=>{let i=this.getAllUnusedBidsForCode(e,r);n.forEach(t=>{t.adUnitCodeOriginal=t.adUnitCodeOriginal||t.adUnitCode,i.includes(t)||t.adUnitCode!==e||(t.adUnitCode=s+t.adUnitCode)}),i.forEach(t=>{t.adUnitCodeOriginal=t.adUnitCodeOriginal||t.adUnitCode,t.adUnitCode=e}),this.maybeAdjustForDynamicRevShare(e,i);let o="",a=t=>{var r;return o=null==t||null==(r=t[e])?void 0:r.hb_adid};this.pbjs.onEvent("setTargeting",a),this.pbjs.getTargetingManager().setTargetingForGPT(e,t),this.pbjs.offEvent("setTargeting",a),a=void 0,o||this.logger.advancedLog(e,{hidghBid:void 0,bids:i}),i.filter(e=>e.adUnitCodeOriginal&&e.adId!==o).forEach(e=>e.adUnitCode=e.adUnitCodeOriginal),n.filter(e=>{var t,r;return e.adUnitCodeOriginal&&(null==(r=e.adUnitCode)||null==(t=r.startsWith)?void 0:t.call(r,s))}).forEach(e=>e.adUnitCode=e.adUnitCodeOriginal),n.find(t=>{if(o&&t.adId===o){t.isRequesting=e;let r=t.adUnitCode!==t.adUnitCodeOriginal?{from:t.adUnitCodeOriginal}:{};return this.logger.advancedLog(e,f(c({highBid:t},r),{bids:i})),!0}return!1})})}setTargetingForGPTAsyncLegacy(e,t,r={}){let i={};this.getAdUnitCodes(e).forEach(e=>{var t;let n=this.getAllUnusedBidsForCode(e,r);n.forEach(t=>{t.adUnitCodeOriginal=t.adUnitCodeOriginal||t.adUnitCode,t.adUnitCode=e}),this.maybeAdjustForDynamicRevShare(e,n);let s=this.pbjs.getTargetingManager().getAllTargeting(e,n),o=null==s||null==(t=s[e])?void 0:t.hb_adid;if(o){this.pbjs.getAuctionManager().setStatusForBids(o,p.BID_STATUS.BID_TARGETING_SET);let t=this.pbjs.getAuctionManager().findBidByAdId(o)||{};t.isRequesting=e;let r=t.adUnitCode!==t.adUnitCodeOriginal?{from:t.adUnitCodeOriginal}:{};this.logger.advancedLog(e,f(c({highBid:t},r),{bids:n}))}else this.logger.advancedLog(e,{hidghBid:void 0,bids:n});Object.assign(i,s),n.forEach(e=>{e.adUnitCodeOriginal&&e.adId!==o&&(e.adUnitCode=e.adUnitCodeOriginal)})}),this.pbjs.getTargetingManager().resetPresetTargeting(e,t),this.pbjs.getTargetingManager().setTargetingForGPT(i,t),this.pbjs.getEventsManager().emit(p.EVENTS.SET_TARGETING,i)}getBidFromGamSlot(e){var t;let r=(null==e?void 0:e.getTargetingMap())||{},i=null==r||null==(t=r.hb_adid)?void 0:t[0];return i?this.pbjs.getAuctionManager().findBidByAdId(i):void 0}getAllUnusedBidsForCode(e,t={}){var r;let i,n=null==(r=this.pbjs.adUnits)?void 0:r.filter(t=>t.code===e);if(!n.length)return this.logger.warn("no adUnit found for code:",e),[];let s=new Set,o=new Set;n.forEach(e=>{var t,r;Object.keys(e.mediaTypes||{}).forEach(e=>{s.add(e)}),((null==e||null==(r=e.mediaTypes)||null==(t=r.banner)?void 0:t.sizes)||[]).filter(e=>(null==e?void 0:e[0])*(null==e?void 0:e[1])>=2500).map(e=>e.join("x")).forEach(e=>o.add(e))}),s.size||s.add("banner");let a={},d={},l=this.getAllRelatedCodes(e),u=e=>{if(null==t?void 0:t.bidFilter)try{return t.bidFilter(e)}catch(e){this.logger.error(e)}return!0};return this.pbjs.getAuctionManager().getBidsReceived().filter(t=>{if(!O(t)||!u(t)||("string"==typeof t.isRequesting&&(void 0===d[t.isRequesting]&&(d[t.isRequesting]=!!document.getElementById(t.isRequesting)),!1===d[t.isRequesting]&&(t.isRequesting=!1)),this.disableBidMovingForBidders.includes(t.bidderCode)&&t.adUnitCode!==e))return!1;let r=t.mediaType||"banner";if(t.isRequesting&&t.isRequesting!==e)return!1;if(this.revertDynamicRevShareChanges(t),l.has(t.adUnitCode)&&s.has(r))return!0;try{if(s.has("banner")&&"banner"===r&&o.has(t.size)&&(a[t.bidderCode]=a[t.bidderCode]||n.filter(e=>{var t;return(null==e||null==(t=e.mediaTypes)?void 0:t.banner)&&1===Object.keys((null==e?void 0:e.mediaTypes)||{}).length}).filter(e=>{var r,i;return null==(i=e.bids)||null==(r=i.find)?void 0:r.call(i,e=>e.bidder===t.bidderCode)}).map(e=>e.bids||[]).reduce((e,t)=>e.concat(t),[]).map(e=>T(null==e?void 0:e.params)),a[t.bidderCode].length)){let e=(i=i||this.pbjs.getAllBidRequests()).find(e=>e.bidId===t.requestId);if(e){let r=T(null==e?void 0:e.params);if(a[t.bidderCode].includes(r))return!0}}}catch(e){}return!1}).sort((e,t)=>e.cpm>t.cpm||e.cpm===t.cpm&&e.responseTimestampt.add(e)):t.add(e);let i=this.pbjs.adUnits.filter(e=>t.has(e.code));return i.length?(i.forEach(e=>{this.getSlotsFromAdUnit(e).forEach(e=>r.add(e))}),this.pbjs.adUnits.forEach(e=>{this.getSlotsFromAdUnit(e).find(e=>r.has(e))&&t.add(e.code)})):this.logger.warn(`no unit found for ${JSON.stringify(e)}`),t}getAdUnitCodes(e){var t;return"string"==typeof e?[e].filter(Boolean).filter(w):Array.isArray(e)?e.filter(Boolean).filter(w):(null==(t=this.pbjs.getAuctionManager())?void 0:t.getAdUnitCodes())||[]}getMajorPrebidVersion(){if(this.majorPrebidVersion)return this.majorPrebidVersion;try{var e,t;let r=Number(null==(t=String(this.pbjs.version).split("."))||null==(e=t[0])?void 0:e.replace(/[^0-9]/g,""));if(!Number.isNaN(r)&&r>0)return this.majorPrebidVersion=r,r}catch(e){}return 0}constructor({BID_MODIFIERS:e={},PREBID_CACHE_DISABLE_MOVING_BIDDERS:t=[],AD_SERVER:r}){u(this,"enabled",!1),u(this,"logger",(0,l.A)("bid-caching").setLabel("BidCaching")),u(this,"originalUseBidCache",void 0),u(this,"setTargetingForGPTAsyncOriginal",void 0),u(this,"getHighestCpmBidsOriginal",void 0),u(this,"disableBidMovingForBidders",[]),u(this,"bidModifiers",void 0),u(this,"dynamicRevShareOriginalBidKey",Symbol.for("_drsOriginalCpm")),u(this,"majorPrebidVersion",void 0),u(this,"pbjs",void 0),u(this,"adServer",void 0),this.pbjs=(0,o.b)(),this.bidModifiers=e,this.disableBidMovingForBidders=t||[],this.adServer=r,this.pbjs.que.push(()=>{if(!["getAllBidRequests","getAllBidResponses","getAuctionManager","getEventsManager","getTargetingManager"].every(e=>this.pbjs[e]))return void this.logger.warn("prebid not built with aditude custom module, disabling feature");this.enable(),this.pbjs.getConfig("ttlBuffer",e=>{h="number"==typeof e.ttlBuffer?e.ttlBuffer:h}),this.pbjs.getEventsManager().on(p.EVENTS.BID_WON,e=>{e.isRequesting&&(e.isRequesting=!1)}),d.U.addEventListener("slotRenderEnded",e=>{if(!this.enabled)return;let t=e.slot.getSlotElementId(),r=this.getBidFromGamSlot(e.slot)||{};if(r.isRequesting===t)if(e.isEmpty)r.isRequesting=!1;else{let t=window.console.warn;window.console.warn=()=>{};let i=e.slot.getHtml();window.console.warn=t,i&&(i.match(/(ucTag\.renderAd|pbjs\.renderAd|prebid-universal-creative)/i)||(r.isRequesting=!1))}}),d.U.addEventListener("slotOnload",e=>{if(!this.enabled)return;let t=e.slot.getSlotElementId(),r=this.getBidFromGamSlot(e.slot)||{};r.isRequesting===t&&setTimeout(()=>{(null==r?void 0:r.isRequesting)&&(r.isRequesting=!1)},500)})})}}function w(e,t,r){return r.indexOf(e)===t}function E(e){var t;return e.responseTimestamp+(e.ttl-((t="ttlBuffer",Object.prototype.hasOwnProperty.call(e,t))?e.ttlBuffer:h))*1e3>new Date().getTime()}function S(e){return e&&(e.status&&![p.BID_STATUS.RENDERED].includes(e.status)||!e.status)}function _(e){return!e.getStatusCode||e.getStatusCode()===p.STATUS.GOOD}function O(e){return[_,E,S].every(t=>t(e))}function T(e){return JSON.stringify(e,D)}function D(e,t){return t instanceof Object&&!(t instanceof Array)?Object.keys(t).sort().reduce((e,r)=>(e[r]=t[r],e),{}):t}function C(e){n=n||new I(e)}function R(){return n}},47473:function(e){var t=Function.prototype.toString;e.exports=function(e){if(null!=e){try{return t.call(e)}catch(e){}try{return e+""}catch(e){}}return""}},48034:function(e,t,r){"use strict";function i(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}r.d(t,{Rd:function(){return n}});let n=new class{encode(e){if(!e)return"";let t=new TextEncoder().encode(e),r=t.length,i=new Uint8Array(r);for(let e=0;e>>4).toString(16),t[2*r+1]=(15&i).toString(16)}return t.join("")}hexToBytes(e){if(e.length%2!=0)throw Error("Invalid hex string: odd length");let t=new Uint8Array(e.length/2);for(let r=0;r-1}},49653:function(e,t,r){var i=r(37828);e.exports=function(e){var t=new e.constructor(e.byteLength);return new i(t).set(new i(e)),t}},51420:function(e,t,r){var i=r(80079);e.exports=function(){this.__data__=new i,this.size=0}},51804:function(e,t,r){"use strict";function i(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}r.d(t,{y:function(){return n}});class n{static setStore(e){e.onChange(()=>{this.onChangeListeners.forEach(e=>{e()})}),this.store=e}static isEnabled(){return this.enabled}static onChange(e){this.onChangeListeners.push(e)}static enableUserId(){this.enabled=!0}static disableUserId(){this.enabled=!1}}i(n,"enabled",!1),i(n,"onChangeListeners",[]),i(n,"store",void 0),t.A=n},51811:function(e){var t=Date.now;e.exports=function(e){var r=0,i=0;return function(){var n=t(),s=16-(n-i);if(i=n,s>0){if(++r>=800)return arguments[0]}else r=0;return e.apply(void 0,arguments)}}},51873:function(e,t,r){e.exports=r(9325).Symbol},53661:function(e,t,r){var i=r(63040),n=r(17670),s=r(90289),o=r(4509),a=r(72949);function d(e){var t=-1,r=null==e?0:e.length;for(this.clear();++twindow.location.pathname.split("/")[e+1]||"",o=Math.floor(100*Math.random())+1,a={device:(0,n.ZI)(),domain:window.location.hostname,path1:s(0),path2:s(1),path3:s(2),path4:s(3),os:(0,n.DC)(),browser:(0,n.X5)(),hour:new Date().getHours(),pageRandomNumber:o,sessionRandomNumber:function(){let e="cw-srn",t=sessionStorage.getItem(e);if(null!==t)return parseInt(t,10);let r=Math.floor(100*Math.random())+1;return sessionStorage.setItem(e,r.toString()),r}(),default:!0};function d({rules:e,context:t=function(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);r.push.apply(r,i)}return r})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}(function(e){for(var t=1;t(function(e,t){return"AND"===e.type?e.predicates.every(e=>u(e,t)):e.predicates.filter(e=>!l.some(t=>t.test(e.path))).some(e=>u(e,t))})(e,t))}(r,t)){var s,o;let e=null==(s=r.conditions.find(e=>e.predicates.find(e=>e.path.includes("tracking:"))))?void 0:s.predicates.find(e=>e.path.includes("tracking:")),t=(null==e||null==(o=e.path.split(":"))?void 0:o[1])||null,n=(null==e?void 0:e.value)||null;return t&&i.A.setTargeting({[t]:String(n)}),r.value}return r}let l=[/tracking:/];function u(e,t){var r;let{path:i,operator:n,value:s}=e,o=(r=t,i.split(".").reduce((e,t)=>e&&void 0!==e[t]?e[t]:void 0,r));switch(n){case"eq":return o===s;case"neq":return o!==s;case"gt":return"number"==typeof o&&"number"==typeof s&&o>s;case"gte":return"number"==typeof o&&"number"==typeof s&&o>=s;case"lt":return"number"==typeof o&&"number"==typeof s&&o=s[0]&&o<=s[1];return!1;default:return!1}}},59350:function(e){var t=Object.prototype.toString;e.exports=function(e){return t.call(e)}},63040:function(e,t,r){var i=r(21549),n=r(80079),s=r(68223);e.exports=function(){this.size=0,this.__data__={hash:new i,map:new(s||n),string:new i}}},63605:function(e){e.exports=function(e){return this.__data__.get(e)}},63702:function(e){e.exports=function(){this.__data__=[],this.size=0}},63862:function(e){e.exports=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=+!!t,t}},64894:function(e,t,r){var i=r(1882),n=r(30294);e.exports=function(e){return null!=e&&n(e.length)&&!i(e)}},66721:function(e,t,r){var i=r(81042),n=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;if(i){var r=t[e];return"__lodash_hash_undefined__"===r?void 0:r}return n.call(t,e)?t[e]:void 0}},68223:function(e,t,r){e.exports=r(56110)(r(9325),"Map")},69302:function(e,t,r){var i=r(83488),n=r(56757),s=r(32865);e.exports=function(e,t){return s(n(e,t,i),e+"")}},69837:function(e,t){"use strict";t.A=function(e,t=50){if(!e)return!1;let{top:r,bottom:i,left:n,right:s}=e.getBoundingClientRect(),o=window.innerHeight||document.documentElement.clientHeight,a=window.innerWidth||document.documentElement.clientWidth,d=(s-n)*(i-r);return 0===d?r0&&n0:Math.max(0,Math.min(i,o)-Math.max(r,0))*Math.max(0,Math.min(s,a)-Math.max(n,0))/d*100>=t}},69884:function(e,t,r){var i=r(21791),n=r(37241);e.exports=function(e){return i(e,n(e))}},70080:function(e,t,r){var i=r(26025),n=Array.prototype.splice;e.exports=function(e){var t=this.__data__,r=i(t,e);return!(r<0)&&(r==t.length-1?t.pop():n.call(t,r,1),--this.size,!0)}},70695:function(e,t,r){var i=r(78096),n=r(72428),s=r(56449),o=r(3656),a=r(30361),d=r(37167),l=Object.prototype.hasOwnProperty;e.exports=function(e,t){var r=s(e),u=!r&&n(e),c=!r&&!u&&o(e),f=!r&&!u&&!c&&d(e),h=r||u||c||f,p=h?i(e.length,String):[],g=p.length;for(var m in e)(t||l.call(e,m))&&!(h&&("length"==m||c&&("offset"==m||"parent"==m)||f&&("buffer"==m||"byteLength"==m||"byteOffset"==m)||a(m,g)))&&p.push(m);return p}},71309:function(e,t,r){"use strict";t.A=/^(22(251|440)|4(0687|1726|2003|7389)|6(2110|6432|6779|8181|8222|9138)|7(492|6607|8143|8530|9818)|8((1|49|93)07|7938)|9(5(472|611|968)|6056)|11696|17176|32109|51932)$/.test(r.j)?null:({viewablePercent:e=50,divId:t,inViewCb:r,outOfViewCb:i})=>{window.googletag=window.googletag||{},window.googletag.cmd=window.googletag.cmd||[],window.googletag.cmd.push(()=>{window.googletag.pubads().addEventListener("slotVisibilityChanged",n=>{n.slot.getSlotElementId()===t&&(n.inViewPercentage>=e?r&&r():i&&i())})})}},71961:function(e,t,r){var i=r(49653);e.exports=function(e,t){var r=t?i(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}},72428:function(e,t,r){var i=r(27534),n=r(40346),s=Object.prototype,o=s.hasOwnProperty,a=s.propertyIsEnumerable;e.exports=i(function(){return arguments}())?i:function(e){return n(e)&&o.call(e,"callee")&&!a.call(e,"callee")}},72552:function(e,t,r){var i=r(51873),n=r(659),s=r(59350),o=i?i.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":o&&o in Object(e)?n(e):s(e)}},72903:function(e,t,r){var i=r(23805),n=r(55527),s=r(90181),o=Object.prototype.hasOwnProperty;e.exports=function(e){if(!i(e))return s(e);var t=n(e),r=[];for(var a in e)"constructor"==a&&(t||!o.call(e,a))||r.push(a);return r}},72949:function(e,t,r){var i=r(12651);e.exports=function(e,t){var r=i(this,e),n=r.size;return r.set(e,t),this.size+=+(r.size!=n),this}},74218:function(e){e.exports=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}},74335:function(e){e.exports=function(e,t){return function(r){return e(t(r))}}},74450:function(e,t,r){"use strict";r.r(t),r.d(t,{CreativeTimedRefresh:function(){return w}});var i=r(77467),n=r(44558),s=r(74547),o=r(7723),a=r(6262),d=r(69837),l=r(59293),u=r(72179),c=r(34858),f=r(18134),h=r(54240),p=r(22188),g=r(28519),m=r(87594),v=r(18238),b=r(52093),y=r(48034),A=r(76076);function I(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}class w extends h.A{getLoggerColor(){return"#EB6424"}getInitialState(){return{}}start(){this.disableActivityRefresh||(0,g.x)(A.default,{excludeBaseDivIds:this.excludeBaseDivIds,excludeDivIds:this.excludeDivIds,includeBaseDivIds:this.includeBaseDivIds,inViewOnly:this.viewableOnly,multipleInstances:this.multipleInstances}),m.B.on(s.qY.BIDS_REQUESTED,({filteredMappings:e})=>{e.forEach(e=>{if(this.baseDivMappings[e.divId]={mapping:e,time:new Date().getTime()},this.resetTimerBeforeRequest){let t={divId:e.divId,mapping:e,type:"unknown",offset:0};this.init(t)}})}),b.U.addEventListener("slotRenderEnded",e=>{let t=this.getAdData(e.slot);this.isValidMapping(t.mapping)&&this.init(t)});let e=(0,p.b)();if(e.que.push(()=>{e.onEvent("auctionInit",e=>{let t=Date.now();[...new Set(e.adUnits.map(e=>e.code))].forEach(e=>{this.auctionTimestamps[e]=t})})}),this.auctionThrottleTime>0){let e=1e3*this.auctionThrottleTime;m.B.on(s.qY.AFTER_CREATE_SLOTS,t=>{let r=Date.now();Object.keys(this.auctionTimestamps).forEach(t=>{r-this.auctionTimestamps[t]>=e&&delete this.auctionTimestamps[t]});let n=t.mappings.filter(e=>this.isValidMapping(e)).map(e=>e.divId),d={divIds:[],mappings:[]};if(n.filter(e=>!!this.auctionTimestamps[e]).forEach(e=>{let r;(r=t.divIds.indexOf(e))>=0&&t.divIds.splice(r,1),(r=t.mappings.findIndex(t=>t.divId===e))>=0&&(d.divIds.push(e),d.mappings.push(t.mappings[r]))}),d.divIds.length){d.divIds.forEach(e=>(0,i.Ab)(e));let e=(0,p.b)();e.setTargetingForGPTAsync&&e.setTargetingForGPTAsync(d.divIds),d.mappings.forEach(e=>{this.baseDivMappings[e.divId]={mapping:e,time:new Date().getTime()}}),b.U.push(()=>{let e=b.U.getGlobal().pubads().getSlots().filter(e=>d.divIds.includes(e.getSlotElementId())),r=[],i=[],n=[];e.forEach(e=>{let s=e.getSlotElementId();if(["hb_adid","amzniid"].find(t=>{var r;return null==(r=e.getTargeting(t))?void 0:r[0]}))r.push(s),(0,a.A)(t.mappings,e=>e.divId!==s),n.push(`${s} (has bid, will refresh)`);else{var o,l;if(null==(l=document.getElementById(s))||null==(o=l.matches)?void 0:o.call(l,":empty"))n.push(`${s} (no bid, but empty div so will run auction)`);else{(0,a.A)(t.mappings,e=>e.divId!==s);let e=d.mappings.find(e=>e.divId===s);i.push({divId:e.divId,mapping:e}),n.push(`${s} (no bid, will reset timer)`)}}}),this.advancedLog("auction throttled for:",n.join("\n")),r.length&&((0,o.f)(r),m.B.emit(s.qY.AFTER_REQUEST,{divIds:r})),i.forEach(e=>this.init(e))})}})}}setupTudeserve(){n.rI.getConfig().then(e=>{"v2"===e.AD_SERVER&&(window.tudeserve=window.tudeserve||{cmd:[]},window.tudeserve.cmd=window.tudeserve.cmd||[],window.tudeserve.cmd.push(e=>{e.events().on("no_bid",e=>{var t;let r=e.slot.elementId,i=null==(t=this.baseDivMappings[r])?void 0:t.mapping;if(!this.isValidMapping(i))return;let n=(null==i?void 0:i.time)?Date.now()-(null==i?void 0:i.time):0;this.init({divId:r,mapping:i,offset:n,type:"unknown"})}),e.events().on("impression",e=>{var t,r,i,n;let s=null==e||null==(t=e.slot)?void 0:t.elementId,o=null==(r=this.baseDivMappings[s])?void 0:r.mapping;if(!this.isValidMapping(o))return;let a=(null==e||null==(i=e.bid)?void 0:i.bidder)||"",d=(null==e||null==(n=e.bid)?void 0:n.source)||"unknown";this.bypassPrebidBidders.includes(a)&&(d="unknown");let l=(null==o?void 0:o.time)?Date.now()-(null==o?void 0:o.time):0,u={divId:s,mapping:o,offset:l,type:d};this.init(u)})}))})}isValidMapping(e){return!(!e||this.includeBaseDivIds.length>0&&!this.includeBaseDivIds.includes(null==e?void 0:e.baseDivId)||this.excludeBaseDivIds.length>0&&this.excludeBaseDivIds.includes(null==e?void 0:e.baseDivId)||this.includedDivIds.length>0&&!this.includedDivIds.includes(null==e?void 0:e.divId)||this.excludeDivIds.length>0&&this.excludeDivIds.includes(null==e?void 0:e.divId))}constructor(e){var t,r,i,n,s,o,a,f,h;if(super(e,"CreativeTimedRefresh"),I(this,"refreshTimes",{}),I(this,"disableActivityRefresh",!1),I(this,"fallbackRefreshTime",26),I(this,"viewableOnly",!0),I(this,"onRefresh",void 0),I(this,"includeBaseDivIds",[]),I(this,"excludeBaseDivIds",[]),I(this,"excludeDivIds",[]),I(this,"includedDivIds",[]),I(this,"multipleInstances",!1),I(this,"divsOnRefresh",new Map),I(this,"bypassPrebidBidders",["ogury","optidigital"]),I(this,"multiformatRefreshOnEnd",!1),I(this,"multiformatRefreshMaxErrors",3),I(this,"multiformatErrorCount",0),I(this,"auctionThrottleTime",0),I(this,"auctionTimestamps",{}),I(this,"resetTimerBeforeRequest",!1),I(this,"useCommentSnippets",!1),I(this,"refreshOverrides",{}),I(this,"baseDivMappings",[]),I(this,"checkViewport",e=>!this.viewableOnly||(0,d.A)(e)),I(this,"refreshDiv",e=>{let{mapping:t}=e,{divId:r}=t;if(!document.hidden){let e=document.getElementById(r);if(e&&this.checkViewport(e)){this.log("Triggering timed refresh",t),(0,c.A)(t,!0),this.onRefresh&&this.onRefresh(t);return}}this.advancedLog(`Div not in view, restarting timer ${r}`),this.divsOnRefresh.delete(r),this.init(e,!1)}),I(this,"init",(e,t=!0)=>{let{mapping:r}=e,{divId:i}=e,n=this.refreshOverrides[r.baseDivId],s=n||this.refreshTimes[e.type]||this.fallbackRefreshTime;if(n&&this.refreshTimes[e.type]&&(s=n-(this.fallbackRefreshTime-this.refreshTimes[e.type])),this.useCommentSnippets&&e.aditudeComments&&Array.isArray(e.aditudeComments)&&e.aditudeComments.forEach(e=>{if("tude_disable_refresh"===e&&(s=0),e.includes("tude_disable_refresh:")){var t;let r=parseInt(null==(t=e.split(":"))?void 0:t[1]);r&&(s=r,this.log("timed refresh override from creative:",i,`${r}s`))}}),!this.isValidMapping(r)||0===s)return;this.divsOnRefresh.has(i)?(this.advancedLog("Already started a timed refresh for this div -- resetting",r),this.divsOnRefresh.get(i).cancel()):t&&this.advancedLog(`Starting a timed refresh for ${e.type} on ${i}`);let o=()=>{d(),this.divsOnRefresh.delete(i),this.refreshDiv(e)};r.metadata=r.metadata||{},r.metadata.refreshCode=y.Rd.encode(s.toString());let a=setTimeout(o,1e3*s-(e.offset||0)),d=()=>clearTimeout(a);this.divsOnRefresh.set(i,{refresh:o,cancel:d})}),I(this,"getAdData",e=>{var t,r,i;let n=window.console.warn;window.console.warn=()=>{};let s=(null==e?void 0:e.getResponseInformation())?e.getHtml():"";window.console.warn=n;let o=[...s.matchAll(//g)].map(e=>e[0].replace(//g,"")),a=e.getSlotElementId(),d=s.indexOf("_apstagRenderCallback")>-1,l=s.indexOf("ucTag.renderAd")>-1||s.indexOf("pbjs.renderAd")>-1||s.indexOf("prebid-universal-creative")>-1,u=!1;if(l){let t=null==(i=e.getTargeting("hb_bidder"))?void 0:i[0];this.bypassPrebidBidders.includes(t)&&(l=!1,u=!0)}let c="";switch(!0){case d:c="amazon";break;case l:c="prebid";break;case u:c="blackListedBidder";break;default:c="unknown"}return{divId:a,type:c,aditudeComments:o,mapping:null==(t=this.baseDivMappings[a])?void 0:t.mapping,offset:new Date().getTime()-(null==(r=this.baseDivMappings[a])?void 0:r.time)||0}}),this.refreshTimes=e.refreshTimes||this.refreshTimes,this.fallbackRefreshTime=e.fallbackRefreshTime||this.fallbackRefreshTime,this.viewableOnly=null!=(t=e.viewableOnly)?t:this.viewableOnly,this.includeBaseDivIds=e.includeBaseDivIds||this.includeBaseDivIds,this.excludeBaseDivIds=e.excludeBaseDivIds||this.excludeBaseDivIds,this.excludeDivIds=e.excludeDivIds||this.excludeDivIds,this.includedDivIds=e.includedDivIds||this.includedDivIds,this.multipleInstances=null!=(r=e.multipleInstances)?r:this.multipleInstances,this.disableActivityRefresh=null!=(i=e.disableActivityRefresh)?i:this.disableActivityRefresh,this.multiformatRefreshOnEnd=null!=(n=e.multiformatRefreshOnEnd)?n:this.multiformatRefreshOnEnd,this.multiformatRefreshMaxErrors=null!=(s=e.multiformatRefreshMaxErrors)?s:this.multiformatRefreshMaxErrors,this.auctionThrottleTime=null!=(o=e.auctionThrottleTime)?o:this.auctionThrottleTime,this.resetTimerBeforeRequest=null!=(a=e.resetTimerBeforeRequest)?a:this.resetTimerBeforeRequest,this.onRefresh=e.onRefresh||this.onRefresh,this.bypassPrebidBidders=null!=(f=e.bypassPrebidBidders)?f:this.bypassPrebidBidders,this.useCommentSnippets=null!=(h=e.useCommentSnippets)?h:this.useCommentSnippets,v.A.sub("wrapperConfigOnInit",e=>{try{Object.keys(e.AD_UNITS||{}).forEach(t=>{(e.AD_UNITS[t]||[]).forEach(t=>{let r=Object.keys(t.mediaTypes||{}),i=e.SLOT_PREFIX+t.slot;t.refreshRules&&(0,u.JJ)().then(e=>{let r=(0,l.U)({rules:t.refreshRules,geo:e});this.refreshOverrides[i]=r}),1!==r.length||(null==r?void 0:r[0])!=="video"||this.excludeBaseDivIds.includes(i)||this.excludeBaseDivIds.push(i)})})}catch(e){this.error("CreativeTimedRefresh error parsing ad units",e)}return e}),this.multiformatRefreshOnEnd){let e=t=>{var r;let i=null==t||null==(r=t.detail)?void 0:r.id;i&&this.divsOnRefresh.has(i)&&(this.multiformatErrorCount++,this.divsOnRefresh.get(i).refresh(),this.multiformatRefreshMaxErrors&&this.multiformatErrorCount>=this.multiformatRefreshMaxErrors&&(this.advancedLog(`multiformat video reached max error count (${this.multiformatRefreshMaxErrors}), disabling refresh on error`),document.removeEventListener("AD_ERROR",e)))};document.addEventListener("AD_ERROR",e),document.addEventListener("ENDED",e=>{var t;let r=null==e||null==(t=e.detail)?void 0:t.id;r&&this.divsOnRefresh.has(r)&&this.divsOnRefresh.get(r).refresh()})}this.setupTudeserve()}}I(w,"componentName","creative-timed-refresh"),(0,f.h)(w),t.default=w},75208:function(e,t,r){"use strict";var i=r(74547),n=r(33386),s=r(85222),o=r(10667),a=r(86964).Promise;function d(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}let l=(0,o.A)("Amazon"),u={};window._aps=window._aps||new Map;let c={};class f{get accountId(){return this._accountId}get aps(){return this._aps}static getInstance({accountId:e="",timeout:t,deals:r,videoAdServer:i,useSafeFrames:n,wrapperConfig:s}){return c[e]||(c[e]=new f({accountId:e,timeout:t,deals:r,videoAdServer:i,useSafeFrames:n,wrapperConfig:s})),c[e]}read(e){return this.aps.store.get(e)}record(e,t){return new a((r,i)=>{var n,s;this.aps.queue.push(new CustomEvent(e,{detail:(n=function(e){for(var t=1;t!e.includes("fluid");e.forEach(e=>{let{display:t,video:r}=e.multiFormatProperties||{};return[e,t,r].forEach(e=>{(null==e?void 0:e.sizes)&&(e.sizes=e.sizes.filter(n))}),e.multiFormatProperties||e.mediaType||(e.mediaType="display"),e}),l.log(i.dN.AMAZON_BIDS_REQUESTING,{slots:e});let o=this.wrapperConfig.PREBID_TIMEOUT?this.wrapperConfig.PREBID_TIMEOUT:this.timeout,a=e.map(e=>e.slotID);this.record("ad/slot/define",{slots:e}),this.record("ad/targeting/fetch",{itemIds:a,timeout:o}).then(()=>{if(t){var e;null==(e=this.read("ad/attachTargeting"))||e({itemIds:a,adServer:"googletag"})}let i=a.map(e=>{let t=Object.fromEntries(this.read("ad/targeting").get(e));return t.slotID=e,t.amznsz&&(t.size=t.amznsz),t});try{r(i)}catch(e){l.error("error with custom bidHandler",{slotIds:a,bids:i},e)}})}constructor({accountId:e="",timeout:t,deals:r,videoAdServer:s,useSafeFrames:o,wrapperConfig:a}){var c,f,h,p,g,m,v;d(this,"_aps",void 0),d(this,"_accountId",""),d(this,"timeout",3e3),d(this,"deals",!1),d(this,"videoAdServer","DFP"),d(this,"useSafeFrames",!1),d(this,"wrapperConfig",void 0),v=e,window._aps.has(v)||window._aps.set(v,{queue:[],store:new Map}),u[v]||(v?(0,n.k0)(`https://config.aps.amazon-adsystem.com/configs/${v}`,i.Lk.HEAD,!0,!0):l.error("no accont id passed, not loading account config",{accountId:v}),u[v]=!0),u.publisherJs||((0,n.k0)("https://client.aps.amazon-adsystem.com/publisher.js",i.Lk.HEAD,!0,!0),u.publisherJs=!0),this.wrapperConfig=a,this._accountId=String(null!=(p=null!=e?e:null==(c=this.wrapperConfig)?void 0:c.AMAZON_PUB_ID)?p:""),this._aps=window._aps.get(this.accountId),this.timeout=null!=(g=null!=t?t:null==(f=this.wrapperConfig)?void 0:f.PREBID_TIMEOUT)?g:this.timeout,this.deals=null!=(m=null!=r?r:null==(h=this.wrapperConfig)?void 0:h.AMAZON_DEALS)?m:this.deals,this.videoAdServer=null!=s?s:this.videoAdServer,this.useSafeFrames=null!=o?o:this.useSafeFrames,l.log(i.dN.AMAZON_LIBRARY_LOADED,{aps:!0,accountId:this._accountId,timeout:this.timeout,deals:this.deals,videoAdServer:this.videoAdServer,useSafeFrames:this.useSafeFrames})}}t.A=f},75288:function(e){e.exports=function(e,t){return e===t||e!=e&&t!=t}},76076:function(e,t,r){"use strict";r.r(t),r.d(t,{ActivityRefresh:function(){return h}});var i=r(74547),n=r(69837),s=r(34858),o=r(18134),a=r(54240),d=r(87594),l=r(18238);function u(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}let c=new Map,f=0;class h extends a.A{getLoggerColor(){return"#FF7276"}getInitialState(){return{}}start(){f+=1,d.B.on(i.qY.BEFORE_REFRESH,e=>{this.includeBaseDivIds.length>0&&(e=e.filter(e=>{var t;return this.props.includeBaseDivIds.includes(e.baseDivId)||(null==e||null==(t=e.refresh)?void 0:t.activityRefresh)})),this.excludeBaseDivIds.length>0&&(e=e.filter(e=>{var t;return!this.excludeBaseDivIds.includes(e.baseDivId)||(null==e||null==(t=e.refresh)?void 0:t.activityRefresh)})),this.excludeDivIds.length>0&&(e=e.filter(e=>{var t;return!this.excludeDivIds.includes(e.divId)||(null==e||null==(t=e.refresh)?void 0:t.activityRefresh)})),e.forEach(e=>{if(this.divsOnRefresh.includes(e.divId))return!1;this.checkFirstInstanceToRefresh(e)&&(f>1&&this.multipleInstances&&(c.set(e.divId,this.instanceId),this.advancedLog(`Instance ${this.instanceId} is the first to act on ${e.divId} `,c)),this.advancedLog("Adding to activity refresh",e),this.divsOnRefresh.push(e.divId),this.addActivityRefreshListener(e))})})}constructor(e){var t,r;super(e,"ActivityRefresh"),u(this,"includeBaseDivIds",[]),u(this,"excludeBaseDivIds",[]),u(this,"excludeDivIds",[]),u(this,"divsOnRefresh",[]),u(this,"cb",void 0),u(this,"multipleInstances",!1),u(this,"inViewOnly",!0),u(this,"instanceId",`actref-${f}`),u(this,"viewportCheck",e=>(0,n.A)(document.getElementById(e))||!this.inViewOnly),u(this,"checkFirstInstanceToRefresh",e=>{if(c.has(e.divId)){let t=c.get(e.divId);if(t!==this.instanceId)return this.log(`Instance ${this.instanceId} cannot act on ${e.divId}, already acted upon by Instance ${t}`),!1}return!0}),u(this,"addActivityRefreshListener",e=>{document.addEventListener("visibilitychange",()=>{!document.hidden&&(this.advancedLog("Visibilty change happened"),this.viewportCheck(e.divId)&&(this.log("Refreshing",e.divId),this.props.cb&&this.cb(e),(0,s.A)(e,this.props.forceRender)))})}),this.cb=this.props.cb||this.cb,this.inViewOnly=null!=(t=this.props.inViewOnly)?t:this.inViewOnly,this.includeBaseDivIds=this.props.includeBaseDivIds||this.includeBaseDivIds,this.excludeBaseDivIds=this.props.excludeBaseDivIds||this.excludeBaseDivIds,this.excludeDivIds=this.props.excludeDivIds||this.excludeDivIds,this.multipleInstances=null!=(r=this.props.multipleInstances)?r:this.multipleInstances,this.advancedLog("instanceId: ",this.instanceId),l.A.sub("wrapperConfigOnInit",e=>{try{Object.keys(e.AD_UNITS||{}).forEach(t=>{(e.AD_UNITS[t]||[]).forEach(t=>{let r=Object.keys(t.mediaTypes||{}),i=e.SLOT_PREFIX+t.slot;1!==r.length||(null==r?void 0:r[0])!=="video"||this.excludeBaseDivIds.includes(i)||this.excludeBaseDivIds.push(i)})})}catch(e){this.error("ActivityRefresh error parsing ad units",e)}return e})}}u(h,"componentName","activity-refresh"),(0,o.h)(h),t.default=h},77467:function(e,t,r){"use strict";r.d(t,{Ab:function(){return u},BI:function(){return c},D6:function(){return h},UN:function(){return a},c$:function(){return f},iC:function(){return l},u0:function(){return d}});var i=r(18238),n=r(52093),s=r(86964).Promise;let o={};function a(e="",t=o){return e.includes("testBid")?20:t[e.replace(/^(v_|o_)/,"")]}function d(){var e,t,r;return null==(r=window)||null==(t=r.apstag)||null==(e=t.debug)?void 0:e.call(t,"getState")}function l(e){var t;return(null==e||null==(t=e.newBidObject)?void 0:t.targeting)||{}}function u(e,t){let r=f({slotID:e});if(r){let i=l(r);t||(t=n.U.getSlotByDivId(e)),t?(Object.keys(i).forEach(e=>{t.setTargeting(e,i[e])}),r.bidState="SET"):r.bidState="EXPOSED"}return r}function c({slotID:e,amzniid:t}){var r,i,n,s;let o=null==(s=d())||null==(n=s.slotBids)||null==(i=n[e])||null==(r=i.find)?void 0:r.call(i,e=>e.bidObject.amzniid===t);o&&"RENDERED"!==o.bidState&&(o.bidState="EXPOSED")}function f({slotID:e}){let t,r=Date.now(),i=d()||void 0;if(!i)return;let n=(i.slotBids||{})[e]||[];if(!n.length)return;Object.keys(o).length&&n.filter(e=>{var t;return!e.cpm&&(null==e||null==(t=e.bidConfig)?void 0:t.amznbid)}).forEach(e=>{e.cpm=a(e.bidConfig.amznbid,o),e.host&&(e.host=e.host.replace("http://","https://"),String(e.host).match(/^https?:\/\//)||(e.host="https://"+e.host))});let s=n.filter(e=>["NEW","EXPOSED"].includes(e.bidState)).filter(e=>{if(!e.responseTimestamp&&Array.isArray(i.AAXReqs)){let t=i.AAXReqs.find(t=>t.bidReqID===e.bidReqID);e.responseTimestamp=(null==t?void 0:t.resTs)||(null==t?void 0:t.responseTimestamp)}return!(e.responseTimestamp&&Math.floor((r-e.responseTimestamp)/1e3)>120)});return(t=s.find(e=>a(e.bidConfig.amznbid,o)>0)?s.sort((e,t)=>(e.cpm||0)>(t.cpm||0)?-1:1).find(e=>{var t;return null==(t=e.bidConfig)?void 0:t.amzniid}):[...s].reverse().find(e=>e.bidConfig.amzniid))&&(t.bidState="SET"),t}function h(e){return globalThis._aps=globalThis._aps||new Map,globalThis._aps.has(e)||globalThis._aps.set(e,{queue:[],store:new Map}),{accountID:e,record:function(e,t){return new s((r,i)=>{var n,s;globalThis._aps.get(this.accountID).queue.push(new CustomEvent(e,{detail:(n=function(e){for(var t=1;t(o=e.AMAZON_HASH_MAP,e))},78096:function(e){e.exports=function(e,t){for(var r=-1,i=Array(e);++rsetTimeout(t,e))}},80079:function(e,t,r){var i=r(63702),n=r(70080),s=r(24739),o=r(48655),a=r(31175);function d(e){var t=-1,r=null==e?0:e.length;for(this.clear();++tn)})}class o{addBefore(e){this.before.push(e)}addAfter(e){this.after.push(e)}async triggerBefore(e){await this.trigger(s(this.before,"order"),e)}async triggerAfter(e){await this.trigger(s(this.after,"order"),e)}async trigger(e,t){for(let r of e)await r.callback(t)}constructor(){n(this,"name",void 0),n(this,"before",[]),n(this,"after",[])}}var a=new class{before(e,t,r,i=0){this.hooks[e]||(this.hooks[e]=new o,this.hooks[e].name=e),this.hooks[e].addBefore({name:t,callback:r,order:i})}after(e,t,r,i=0){this.hooks[e]||(this.hooks[e]=new o,this.hooks[e].name=e),this.hooks[e].addAfter({name:t,callback:r,order:i})}async dispatch(e,t){if(!this.hooks[e])return void(0,i.A)().advancedLog('No hooks registered for "'+e+'"',this.hooks);try{await this.hooks[e].triggerBefore(t)}catch(e){(0,i.A)().error(e)}try{await this.hooks[e].triggerAfter(t)}catch(e){(0,i.A)().error(e)}}async do(e,t,r={},n=!1){if(!this.hooks[e]){(0,i.A)().advancedLog('No hooks registered for "'+e+'"',this.hooks),(0,i.A)().advancedLog(`Hook "${e}" main action executing`);try{await t()}catch(e){(0,i.A)().error(e)}(0,i.A)().advancedLog(`Hook "${e}" main action executed`);return}try{await this.hooks[e].triggerBefore(r)}catch(e){(0,i.A)().error(e)}(0,i.A)().advancedLog(`Hook "${e}" main action executing`);try{await t()}catch(e){(0,i.A)().error(e)}(0,i.A)().advancedLog(`Hook "${e}" main action executed`);try{await this.hooks[e].triggerAfter(r)}catch(e){(0,i.A)().error(e)}n&&delete this.hooks[e]}constructor(){var e,t;t={},(e="hooks")in this?Object.defineProperty(this,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):this[e]=t}}},85914:function(e,t,r){var i,n,s,o,a,d,l;e=r.nmd(e),e&&e.exports,(n="object"==typeof r.g&&r.g).global===n||n.window,(s=function(e){this.message=e}).prototype=Error(),s.prototype.name="InvalidCharacterError",o=function(e){throw new s(e)},a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",d=/[\t\n\f\r ]/g,l={encode:function(e){e=String(e),/[^\0-\xFF]/.test(e)&&o("The string to be encoded contains characters outside of the Latin1 range.");for(var t,r,i,n=e.length%3,s="",d=-1,l=e.length-n;++d>18&63)+a.charAt(i>>12&63)+a.charAt(i>>6&63)+a.charAt(63&i);return 2==n?(i=(t=e.charCodeAt(d)<<8)+(r=e.charCodeAt(++d)),s+=a.charAt(i>>10)+a.charAt(i>>4&63)+a.charAt(i<<2&63)+"="):1==n&&(i=e.charCodeAt(d),s+=a.charAt(i>>2)+a.charAt(i<<4&63)+"=="),s},decode:function(e){var t,r,i=(e=String(e).replace(d,"")).length;i%4==0&&(i=(e=e.replace(/==?$/,"")).length),(i%4==1||/[^+a-zA-Z0-9/]/.test(e))&&o("Invalid character: the string to be decoded is not correctly encoded.");for(var n=0,s="",l=-1;++l>(-2*n&6)));return s},version:"1.0.0"},void 0===(i=(function(){return l}).call(t,r,t,e))||(e.exports=i)},86009:function(e,t,r){e=r.nmd(e);var i=r(34840),n=t&&!t.nodeType&&t,s=n&&e&&!e.nodeType&&e,o=s&&s.exports===n&&i.process,a=function(){try{var e=s&&s.require&&s.require("util").types;if(e)return e;return o&&o.binding&&o.binding("util")}catch(e){}}();e.exports=a},86649:function(e,t,r){e.exports=r(83221)()},87296:function(e,t,r){var i,n=r(55481),s=(i=/[^.]+$/.exec(n&&n.keys&&n.keys.IE_PROTO||""))?"Symbol(src)_1."+i:"";e.exports=function(e){return!!s&&s in e}},87805:function(e,t,r){var i=r(43360),n=r(75288);e.exports=function(e,t,r){(void 0===r||n(e[t],r))&&(void 0!==r||t in e)||i(e,t,r)}},89935:function(e){e.exports=function(){return!1}},90031:function(e,t){!function(e){var t,r,i,n=String.fromCharCode;function s(e){for(var t,r,i=[],n=0,s=e.length;n=55296&&t<=56319&&n=55296&&e<=57343)throw Error("Lone surrogate U+"+e.toString(16).toUpperCase()+" is not a scalar value")}function a(e,t){return n(e>>t&63|128)}function d(){if(i>=r)throw Error("Invalid byte index");var e=255&t[i];if(i++,(192&e)==128)return 63&e;throw Error("Invalid continuation byte")}e.version="3.0.0",e.encode=function(e){for(var t=s(e),r=t.length,i=-1,d="";++i>6&31|192):(0xffff0000&e)==0?(o(e),t=n(e>>12&15|224)+a(e,6)):(0xffe00000&e)==0&&(t=n(e>>18&7|240)+a(e,12)+a(e,6)),t+=n(63&e|128)}(t[i]);return d},e.decode=function(e){r=(t=s(e)).length,i=0;for(var a,l=[];!1!==(a=function(){var e,n,s,a;if(i>r)throw Error("Invalid byte index");if(i==r)return!1;if(e=255&t[i],i++,(128&e)==0)return e;if((224&e)==192){if((a=(31&e)<<6|(n=d()))>=128)return a;throw Error("Invalid continuation byte")}if((240&e)==224){if((a=(15&e)<<12|(n=d())<<6|(s=d()))>=2048)return o(a),a;throw Error("Invalid continuation byte")}if((248&e)==240&&(n=d(),(a=(7&e)<<18|n<<12|(s=d())<<6|d())>=65536&&a<=1114111))return a;throw Error("Invalid UTF-8 detected")}());)l.push(a);for(var u,c=l.length,f=-1,h="";++f65535&&(u-=65536,h+=n(u>>>10&1023|55296),u=56320|1023&u),h+=n(u);return h}}(t)},90181:function(e){e.exports=function(e){var t=[];if(null!=e)for(var r in Object(e))t.push(r);return t}},90289:function(e,t,r){var i=r(12651);e.exports=function(e){return i(this,e).get(e)}},90938:function(e){e.exports=function(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}},91033:function(e){e.exports=function(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}},93243:function(e,t,r){var i=r(56110);e.exports=function(){try{var e=i(Object,"defineProperty");return e({},"",{}),e}catch(e){}}()},93290:function(e,t,r){e=r.nmd(e);var i=r(9325),n=t&&!t.nodeType&&t,s=n&&e&&!e.nodeType&&e,o=s&&s.exports===n?i.Buffer:void 0,a=o?o.allocUnsafe:void 0;e.exports=function(e,t){if(t)return e.slice();var r=e.length,i=a?a(r):new e.constructor(r);return e.copy(i),i}},99406:function(e,t,r){"use strict";let i;r.d(t,{A:function(){return E}});var n=r(74547),s=r(33386),o=r(86964).Promise;let a=({pubID:e,bidTimeout:t,adServer:r="googletag",deals:i,useSafeFrames:n=!1,videoAdServer:s,params:o,signals:a={}})=>{!function(e,t,r,i,n,s,o){t[e]||(t[e]={init:function(){a("i",arguments)},fetchBids:function(){a("f",arguments)},setDisplayBids:function(){},targetingKeys:function(){return[]},dpa:function(){a("di",arguments)},rpa:function(){a("ri",arguments)},upa:function(){a("ui",arguments)},_Q:[]},(s=r.createElement(i)).async=!0,s.src=n,(o=r.getElementsByTagName(i)[0]).parentNode.insertBefore(s,o));function a(r,i){t[e]._Q.push([r,i])}}("apstag",window,document,"script","//c.amazon-adsystem.com/aax2/apstag.js"),window.apstag.init({pubID:e,adServer:r,deals:i,videoAdServer:s,bidTimeout:t,useSafeFrames:n,params:o,signals:a})},d=({pubID:e,bidTimeout:t,adServer:r="googletag",deals:i,useSafeFrames:a=!1,videoAdServer:d,params:l,signals:u={}})=>((0,s.k0)(`https://config.aps.amazon-adsystem.com/configs/${e}`,n.Lk.HEAD,!0),(0,s.k0)("https://client.aps.amazon-adsystem.com/publisher.js",n.Lk.HEAD,!0),window.aps=((t=e)=>{let r=window._aps=window._aps||new Map;r.has(t)||r.set(t,{queue:[],store:new Map});let i={accountID:t,record:function(e,t){return new o((i,n)=>{var s,o;r.get(this.accountID).queue.push(new CustomEvent(e,{detail:(s=function(e){for(var t=1;t!e.includes("fluid");class A{static setConfig(e){i=e}isTudeServe(){return["v2","tude"].includes(null==i?void 0:i.AD_SERVER)}static loadLibrary({pubID:e="",bidTimeout:t=3e3,deals:r=!1,videoAdServer:s="DFP",useSafeFrames:o=!1,params:l,wrapperConfig:c,signals:p={}}){i=c;let g={pubID:e,bidTimeout:t,deals:r,videoAdServer:s,useSafeFrames:o,params:l,signals:p};(null==c?void 0:c.AMAZON_BOOTSTRAP)==="hybrid"?d(g):a(g),m(this,A,w,!0),(0,f.A)(b).log(n.dN.AMAZON_LIBRARY_LOADED,g),(null==i?void 0:i.AMAZON_BID_CACHING)&&((0,f.A)(b).advancedLog("bid caching enabled"),u.B.on("gpt.slotRenderEnded",e=>{var t,r,n;let s=e.divId,o=e.targetingMap,a=e.amzniid,d=(0,h.u0)(),{AMAZON_HASH_MAP:l={}}=i||{};if(a){let t=e.isAmazonWin;((null==d||null==(n=d.slotBids)?void 0:n[s])||[]).forEach(r=>{let{bidConfig:i}=r;if(t&&i.amzniid===a){r.bidState="RENDERED";let t=(0,h.UN)(i.amznbid,l)||"?";(0,f.A)(b).advancedLog("bidWon",{slotID:s,bid:r,cpm:t});try{let t=document.getElementById(s),r=String(i.size).split("x").map(Number);if(S(r)||(r=function(e=[],t=1e3){return e.filter(e=>S(e)&&e[0]*e[1]>=t).sort((e,t)=>e[0]*e[1]-t[0]*t[1]).find(e=>e)}(e.sizes)),t&&S(r)){let[e,i]=r;t.querySelectorAll('[id*="google_ads_iframe"]').forEach(t=>{t.hasAttribute("width")&&(t.setAttribute("width",String(e)),t.setAttribute("height",String(i))),t.style.setProperty("width",`${e}px`),t.style.setProperty("height",`${i}px`)})}}catch(e){(0,f.A)(b).error("Error trying to size an amazon bid win",e)}}let n=i.amzniid===a,o="RENDERED"===r.bidState,d="SET"===r.bidState;(n&&!o||!n&&d)&&(r.bidState="EXPOSED")})}let u=[];((null==d||null==(r=d.targetingKeys)||null==(t=r[s])?void 0:t.length)?d.targetingKeys[s]:Object.keys(o).filter(e=>e.startsWith("amzn"))).forEach(t=>{o[t]&&e.slot.clearTargeting(t)})}))}getGlobal(){return window.apstag=window.apstag||{}}requestBids(e,t,r=()=>{}){let{auctionState:s={}}=e;if(delete e.auctionState,e.slots=e.slots.map(e=>{let{display:t,video:r}=e.multiFormatProperties||{};return[e,t,r].forEach(e=>{(null==e?void 0:e.sizes)&&(e.sizes=e.sizes.filter(y))}),e}),(0,f.A)(b).log(n.dN.AMAZON_BIDS_REQUESTING,e),!e.slots)return(0,f.A)(b).error(n.dN.AMAZON_MISSING_FIELD,"slots"),!1;if(!l.A.canReceivePersonalizedAds()){(0,f.A)(b).warn("Amazon will not run because personalized ads are turned off"),r(!1);return}i.PREBID_TIMEOUT&&(e.timeout=i.PREBID_TIMEOUT);let o=this.getGlobal();o.fetchBids(e,n=>{if(t&&!s.timedout&&!this.isTudeServe())if(null==i?void 0:i.AMAZON_BID_CACHING)try{!function({apsRequestConfig:e,bidResponses:t}){var r;let n=null!=(r=i.AMAZON_CACHE_TTL)?r:120,{slots:s=[]}=e,o=s.map(e=>e.slotID),a=(0,h.u0)(),d=a.slotBids||{},l=Date.now(),u=t.filter(e=>e.amzniid).map(e=>e.amzniid);o.forEach(e=>{let t=d[e]||[],r=t.find(e=>{var t;return u.includes(null==e||null==(t=e.bidConfig)?void 0:t.amzniid)});r&&(r.responseTimestamp=l),c.U.push(()=>{let r=c.U.getSlotByDivId(e);if(!r)return;let i=(0,h.Ab)(e,r);if(!i||!i.newBidObject)return void(0,f.A)(b).advancedLog("no bid",{slotID:e,bids:t,BID_TTL:n});let s=Object.keys((null==a?void 0:a.bidReqs)||{}).length;if(!s)return;let o=String(s-1),d=!1;s&&i.bidReqID!==o&&(d=!0),(0,f.A)(b).advancedLog("bid",{slotID:e,cached:d,bid:i,cpm:i.cpm||"?",currentBidReqID:o,bids:t,BID_TTL:n})})})}({apsRequestConfig:e,bidResponses:n})}catch(e){(0,f.A)(b).advancedLog("cache error, falling back to apstag.setDisplayBids()",e),c.U.push(()=>{o.setDisplayBids()})}else c.U.push(()=>{o.setDisplayBids()});r(n)})}constructor(){let{AMAZON_SINGLETON:e}=i||{};if(e&&g(A,A,I))return g(A,A,I);e&&m(A,A,I,this)}}var I={writable:!0,value:void 0},w={writable:!0,value:void 0},E=A;function S(e){return Array.isArray(e)&&2===e.length&&"number"==typeof e[0]&&"number"==typeof e[1]}}}]);