(window.audiencerunChunk=window.audiencerunChunk||[]).push([[0],[,,,,,,,,,,,,,,,function(e,t){e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var i=function(e,t){var i=e[1]||"",s=e[3];if(!s)return i;if(t&&"function"==typeof btoa){var n=(a=s,"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(a))))+" */"),r=s.sources.map((function(e){return"/*# sourceURL="+s.sourceRoot+e+" */"}));return[i].concat(r).concat([n]).join("\n")}var a;return[i].join("\n")}(t,e);return t[2]?"@media "+t[2]+"{"+i+"}":i})).join("")},t.i=function(e,i){"string"==typeof e&&(e=[[null,e,""]]);for(var s={},n=0;n{if(!e)return e;const t=s.a.resolve("ADSERVER");try{return e.replace("d.audiencerun.com",t)}catch(t){return Object(n.h)(t),e}})},function(e,t,i){"use strict";var s=i(2);const n="_arun_tmp"+s.g;window[n]=window[n]||{};const r={set(e,t){window[n][e]=t,Object(s.e)(r,{...window[n]})},inArray:(e,t)=>!!r[e]&&-1!==r[e].indexOf(t),id:n};Object(s.e)(r,{...window[n]}),t.a=r},function(e,t,i){"use strict";i.d(t,"c",(function(){return d})),i.d(t,"e",(function(){return l})),i.d(t,"d",(function(){return c})),i.d(t,"a",(function(){return h})),i.d(t,"b",(function(){return p}));var s=i(2),n=i(16),r=i(10),a=i(0),o=i(1);const d=e=>{(new Image).src=e},l=({key:e,zh:t,winningBid:i})=>{const d={sk:e,zhid:t,iid:i.view_id,pcid:i.pcid,cpm:i.cpm,pm_guid:i.guid};if(!(e=>{let t=!0;return!Object(o.e)(e)&&(!!["sk","zhid","iid","pcid","cpm","pm_guid"].every(t=>Object.prototype.hasOwnProperty.call(e,t))&&(["sk","zhid","iid","pcid","pm_guid"].forEach(i=>{e[i]||(t=!1)}),["cpm"].forEach(i=>{Object(a.e)(e[i])||(t=!1)}),t))})(d)){const e="INVALID_PARAMS: One or more parameter is not valid for impressionPrintedUrl (formerly named `confirm_view_url`). Empty string returned.";return Object(s.i)({params:d,bidder:i.bidder}),Object(s.h)(e),""}return Object(r.e)(Object(n.a)("https://d.audiencerun.com/ps/ip"),d)},c=e=>{const t={iid:e.view_id};if(!t.iid){const i="INVALID_DATA: `iid` parameter cannot be empty for impressionClickedPixelUrl (formerly named `click_url`). Empty string returned.";return Object(s.i)({params:t,bidder:e.bidder}),Object(s.h)(i),""}return Object(r.e)(Object(n.a)("https://d.audiencerun.com/ps/ic"),{...t,re:""})},h=e=>{const{scriptKey:t,zoneHitId:i,identifier:a,caller:o,preview:d}=e;if(d)return"data:image/png;base64,iVBORw0KGgo=";if(!t||!i){const t="INVALID_PARAMS: One or more parameter is not valid for viewPixelUrl (p_v). Empty string returned.";return Object(s.i)({data:e}),Object(s.h)(t),""}const l={..."multiAds"===o&&{sf:a}};return Object(r.e)(`${Object(n.a)("https://d.audiencerun.com/c")}/${t}/ps/z/${i}`,l)},p=e=>{const{scriptKey:t,zoneHitId:i,identifier:a,caller:o,preview:d}=e;if(d)return"data:image/png;base64,iVBORw0KGgo=";if(!t||!i){const t="INVALID_PARAMS: One or more parameter is not valid in zoneHasPrintedUrl (z_hp). Empty string returned.";return Object(s.i)({data:e}),Object(s.h)(t),""}const l={..."multiAds"===o&&{sf:a}};return Object(r.e)(`${Object(n.a)("https://d.audiencerun.com/c")}/${t}/ps/hp/${i}`,l)}},,function(e,t,i){"use strict";i.d(t,"a",(function(){return r}));var s=i(2),n=i(0);const r=(e,t,i)=>{const r=new XMLHttpRequest,a=e.method||"GET";r.open(a,e.url,!0),e.timeout&&(r.timeout=e.timeout),e.withCredentials&&(r.withCredentials=!0),e.headers&&Object.keys(e.headers).forEach(t=>{r.setRequestHeader(t,e.headers[t])}),r.ontimeout=()=>{const t={status:408,statusText:"Request on timeout"};Object(n.c)(i)&&i(t),Object(s.h)(new Error(`${a} - Request failed with status ${t.status} - ${t.statusText} on ${e.url}`))},r.onload=()=>{if(r.status>=200&&r.status<300)return void(Object(n.c)(t)&&t(r.response));const o={status:r.status,statusText:r.statusText||"Request ended with an invalid HTTP status"};Object(n.c)(i)&&i(o),Object(s.h)(new Error(`${a} - Request failed with status ${o.status} - ${o.statusText} on ${e.url}`))},r.onerror=()=>{const t={status:r.status,statusText:"Request on error"};Object(n.c)(i)&&i(t),Object(s.h)(new Error(`${a} - Request failed with status ${t.status} - ${t.statusText} on ${e.url}`))},r.send(e.body)}},function(e,t,i){"use strict";i.d(t,"a",(function(){return A}));var s=i(2),n=i(22),r=i(6),a=i(0),o=i(1);class d{constructor(){this._cache={}}get _keys(){return Object.keys(this._cache)}has(e){return!Object(o.g)(this._cache[e])}get(e){return this.has(e)?Object(r.d)()>this._cache[e].expiry?(this.remove(e),null):this._cache[e]:null}set(e,t,i){this.has(e)||Object(a.h)(e)&&![e,t].some(o.e)&&(e=>Object(o.h)(e)&&e>5)(i)&&(this._cache[e]={value:t,expiry:Object(r.d)()+1e3*(i-5)})}remove(e){this.has(e)&&delete this._cache[e]}clear(){this._cache={}}geAll(){const e=[];return this._keys.forEach(t=>{const i=this.get(t);i&&e.push(i)}),e}}var l=new class{constructor(){this.bidCache=new d}add(...e){e.forEach(e=>{const{internalCacheId:t,ttl:i}=e;this.bidCache.set(t,e,i)})}remove(...e){e.forEach(e=>{const{internalCacheId:t}=e;this.bidCache.remove(t)})}retrieve(){return this.bidCache.geAll().map(e=>({...e.value,retrievedFromCache:!0,internalCacheExpiry:e.expiry}))}},c=i(17),h=i(16),p=i(24),u=i(5),b=i(3),m=i(25),g=i(12),f=i(7),v=i(18);const w=["0pbkzse0jx","5amc29xdoq","5fwqe3q6pz","6lnbqz5sw7","8b51fdzly3","agispq0edy","cut8635lnf","hxw0a3921x","iys7afsxge","kibz7l3zpe","l4bptixh58","ld5as5h3wq","n3apvlg1oa","pudao0e9gq","src9lz5jch","t0235jlanh","9czs73wdaj","clxwe4n76q","asrcnjbvyx","3wg1i75i3j","2nfvwgankx","m2i1yl03lw","am8dukqczj","6ydfgdzrca","5eyky1py1w","r3fu90luhu","co2z0yq7ho","2c18unvjl7","24k9kred4w","p20ax6h9zp","512es8fqyi","hy4tpu2a2c","e4kyf97ex1","oyeofu14x3","1dhdo10131","6vi5cdfxsb","272msblia9","tkqm8w23uk","369equla78","xqxhovuabt","9rper56hz7","c4cz8xr6z1","0inh7bksbz","476pofbr8d","cbozenva51","pwnulbvrds","nqcxekpzjt","018u7bu42n","ol8zovcrvs","6e0sjp3s5j","uxnlw75rvl","ofyt5ko67k","9vac4ezrxp","txcuznl027","we0d13rcip","5giy575uab","a8qi96or13","2botl3x2k2","e0ben3rk4r","69lu1vkak2","nhsdx106qf","p2y68g1dno","lub7b3ctos","04q1v3ukw9","wlju18zm0l","jzc0p5sam7","r7clb0ufob","3yt04vgj4c","itjrgt48a0","r4l2cydbw3","ls6yr4f2id","ijs3o9jes9","r01ozy3uqj","cpwi4u7bhy","su3bl3dx14","vb6q2kqpr2","esaosfnjwz","jdoj4fv3n4","vp50pgef15","zpro9m3xtz","wctzwyf0z5","94uhuxbi0q","gfzv1pdn7y","a6ksghtkw7","5sqtn3hryq","zqy6kq7roh","92y93fiprj","dywju3l4fd","c3p8v5632h","iyf80h5jaw","fgao0bfivw","20c6ih0pi5","boepbyducq","0zalwk05ck","j4wat3c0ha","9dhuvsbinh","f56ozan41q","icex0cbwcy","1ft1pwgbg7","14fohx7mcl","4px29ej5p9","z1zu0iut5n","0dwz4qvjb1","hd74a1yem1","bmk8dqifnk","ewjxtsmp3x","ka86hcfbkp","3cae4n07ht","l0i4i7x8mh","zf57fgpw3c","5nlxsgfpu0","vt4jqhbsae","rj9czynkav","fqs6y9an46","twz6dt56y3","wt7xbit0iv","3e0ur6zn0v","0r1bx1i8lt","prm2y6e7qz","evy8m41d1n","t912nqsl3w","hl2e2h2twz","xyr53fx1zs","srt576awca","dj2er0oawx","gs4m6ixvtu","wa56ndrjl9","dmwbj80fcg","lmeiufpjfm","2eya24iwky","1pb8xqi7i2","4dczbidi6s","um8giaut1g","yfypjoq0es","lgtecwjejp","p37prw86kw","86ea62odm8","2hr8i6a6hr","9ekdqgk5rt","6mci1vhokd","0eoq8ibvwf","2ojhyhih08","grzohvaway","4jx4lwawol","mnf6nvs5pl","jeb0g5frd2","soyqxuwk1z","ltbi3bazlh","ql1pg9jmy6","j4iphi3kzr","ybp979xm0g","zuvlcb60fp","slzneudipl","oekxeyixaz","1cu1h6wmjs","q54ufo9l9b","df6ir3g15k","8tk6df7x50","bztywlwegc","4pkuhx8tyr","g95pdzgvw9","0amu5bw18b"],y=["refresh_activated","max_refresh","refresh_delay","refresh_activation_cpm_threshold","refreshOnAdVisible"],O=["bidder","view_id","params","prebidServerActivated","prebidServerABTesting","pcid","internalCacheId","internalCacheExpiry","retrievedFromCache",...y];class j{constructor(e,t,i){if(this.nativeAdObj=t,this.nativeAdOptions=t.getOptions(),this.utils=t.utils,this.biddingId=Math.ceil(1e3*Math.random()),this.debugTitle=`Mode "${this.nativeAdOptions.mode}" for key "${this.nativeAdOptions.key}" / class "Bidding ${this.biddingId}" => `,this.usePrebidClientFeed=!this.nativeAdObj.s2sOnly,this.feedBidders=Object(b.a)(e,"bidders",[]).filter(Boolean),this.usePrebidClientFeed&&Object(o.e)(this.feedBidders))return c.a.set("breakFlux",!0),void Object(s.h)(new Error("Empty array of bidders provided."));if(this.loadFluxCount=i,this.biddingUUID=Object(o.d)(),this.window=e.window,this.config=Object.assign(e.config||{},{userSync:Object(b.a)(e,"config.userSync",{}),isGdprRequired:Object(b.a)(e,"config.isGdprRequired",this.nativeAdObj.isGdprRequired),affiliateId:this.nativeAdObj.affiliateId,s2sConfigEnabled:this.nativeAdObj.s2sConfigEnabled,reuseBidPropositions:Object(b.a)(e,"config.reuseBidPropositions",!0)}),this.prebidConfig={},this.bidderConfigs={},this.saveWinnerSize=this.nativeAdObj.saveWinnerSize||!1,this.bidders=[],this.usePrebidClientFeed){if(this.bidders=this.getFilteredBidders(),this.bidders.length<1)return void c.a.set("breakFlux",!0);0===this.nativeAdObj.flux.floorRefreshCallCount&&(this.nativeAdObj.flux.originalBidders=Object(b.b)(this.bidders))}this.adUnitCode=w.includes(this.nativeAdOptions.key)?this.nativeAdOptions.key:"nativeBids"+Math.ceil(1e7*Math.random()),this.size=e.size,this.adUnits=[],this.cpm=e.cpm||0,this.key=e.key,this.shouldCheckRedirect=this.nativeAdOptions.shouldCheckRedirect||!0,this.winnerbidderCode=null,this.winningBid={},this.callbackId=e.callbackId,this.callbackKey="callbackCriteo"+this.callbackId,this.imptrackers=e.imptrackers||[],this.vm=e.vm||0,this.jsContent=null,this.impressionClickedUrl="",this.isLoaded=!1,this.canSendPixel=!0,this.bannerWidth=0,this.bannerHeight=0,this.refreshUniqLoadFluxCount=this.refreshUniqLoadFluxCount||0,this.bidRequests=[],this.bidResponses={},this.noBidResponses={},this.biddersOnTimeout=[],this.userIdSources=[],this.minMetricsIterationCount=this.nativeAdObj.preloadBanners?Object(o.a)(Number(this.nativeAdObj.preloadBannersCount),1):1,this.applyBiddingConfig(),this.init()}setAdUnits(){this.adUnits=[];const e={};this.bidders.forEach(t=>{const i=p.f(t)||"banner",s=p.c(t);e[i]=e[i]?e[i]:{},e[i][s]=e[i][s]?e[i][s]:[],e[i][s].push(t)}),Object.keys(e).forEach(t=>{Object.keys(e[t]).forEach(i=>{const s=this.utils.topWindow.location.host+"/"+this.nativeAdOptions.key+"#"+i;this.adUnits.push({code:this.adUnitCode,mediaTypes:p.g(e[t][i],"0x0"!==i?i.split("x").map(Number):this.size),bids:e[t][i],renderer:{},ortb2Imp:{ext:{gpid:s,data:{pbadslot:s}}}})})})}initBiddingGlobalVars(){void 0===this.window.paubjs&&(this.window.paubjs={}),void 0===this.window.paubjs.que&&(this.window.paubjs.que=[]),this.utils.topWindow.__ARUN___metrics=this.utils.topWindow.__ARUN___metrics||{},this.metrics=this.utils.topWindow.__ARUN___metrics[this.nativeAdOptions.rid]||{},this.utils.topWindow.__ARUN___bidding_metrics=this.utils.topWindow.__ARUN___bidding_metrics||{},this.biddingMetrics=this.utils.topWindow.__ARUN___bidding_metrics[this.nativeAdOptions.rid]||{},c.a.set("winnerBidsTmp",c.a.winnerBidsTmp||[]),c.a.set("usedAdUnits",c.a.usedAdUnits||[]),this.window.paubjs.adUnits=[]}initEvents(){c.a.set(this.adUnitCode+"End",!1),this.window.paubjs.onEvent("auctionInit",e=>{void 0===this.metrics.firstAuctionInit&&(this.metrics.firstAuctionInit=e.timestamp)}),this.window.paubjs.onEvent("auctionEnd",e=>{const t=Object(r.d)(),{bidderRequests:i}=Object(b.b)(e);i.forEach(e=>{const{start:i,bids:s}=e;s.forEach(e=>{e.adUnitCode===this.adUnitCode&&this.bidRequests.push({...e,internalId:Object(o.b)(),timeToRespond:Object(r.a)(t,i)})})}),c.a.set(this.adUnitCode+"End",!0)}),this.window.paubjs.onEvent("bidTimeout",e=>{void 0===this.metrics.biddersOnTimeout&&(this.metrics.biddersOnTimeout=!0);const t=Object(b.b)(e)||[];this.biddersOnTimeout=t.filter(e=>e.adUnitCode===this.adUnitCode)}),this.window.paubjs.onEvent("adRenderFailed",e=>{const{adId:t,message:i}=Object(b.b)(e)||{};if((this.bidResponses.bids||[]).map(e=>e.adId).filter(Boolean).includes(t)||!Object(o.g)(t)&&t===this.winningBid.adId){const n=i||`Cannot render ad with '${t}'`;Object(s.i)(Object(b.i)({response:e,bid:this.winningBid})),Object(s.h)("AD_RENDER_FAILED: "+n)}})}applyBiddingConfig(){this.prebidConfig=p.h(this.config,this.bidders),this.bidderConfigs=Object(n.g)(this.config)}init(){this.initBiddingGlobalVars(),this.nativeAdObj.s2sOnly?this.handleS2SBidding():this.loadPrebid(()=>{this.requestBids()},e=>{Object(s.h)(e)})}requestBids(){this.window.paubjs.que.push(()=>{try{if(this.initEvents(),!this.replaceBiddersViewId(this.bidders)&&0===this.nativeAdObj.s2sBids.length)return void c.a.set("breakFlux",!0);if(!this.bidders.length)return this.nativeAdObj.s2sBids.length>0?void this.handleS2SBidding():void c.a.set("breakFlux",!0);if(this.bidderConfigs.forEach(e=>{this.window.paubjs.setBidderConfig(e)}),this.window.paubjs.setConfig(this.prebidConfig),this.window.paubjs.bidderSettings=p.e(),c.a.winnerBidsTmpSize&&(this.size=[c.a.winnerBidsTmpSize]),this.setAdUnits(),0===this.adUnits.length)return void c.a.set("breakFlux",!0);this.window.paubjs.addAdUnits(this.adUnits),this.window.paubjs.requestBids({bidsBackHandler:()=>{this.bidsResponse()}})}catch(e){Object(s.h)(e)}})}clearAdUnits(){(this.window.paubjs.adUnits||[]).forEach(e=>{e.code===this.adUnitCode&&Object(a.c)(this.window.paubjs.removeAdUnit)&&this.window.paubjs.removeAdUnit(e.code)})}checkRedirect(){if(this.shouldCheckRedirect)try{const e=Object(r.d)();this.etime=0,this.mouseleave=0,["touchcancel","touchend","touchleave","click","keydown"].forEach(e=>{this.utils.window.addEventListener(e,()=>{this.etime=Object(r.d)()})}),this.utils.document.body.addEventListener("mouseleave",e=>{this.mouseleave=e.clientY<=5?Object(r.d)():0}),this.utils.document.body.addEventListener("mouseout",()=>{this.mouseleave=0}),this.utils.window.addEventListener("beforeunload",()=>{const t=Object(r.a)(Object(r.d)(),e);t<15010&&!this.etime&&!this.mouseleave&&this.winningBid.cpm<.6&&(Object(s.i)(Object(b.i)({location:window.location.href,winningBid:this.winningBid})),Object(s.h)(`TOO_SHORT_NAVIGATION_TIME: [${t}ms] Redirection probability for ${this.winnerbidderCode} with a CPM of ${this.winningBid.cpm}.`))})}catch(e){}}bidsResponse(){const e=this.attachPostBidIframeToDocument(this.adUnitCode);!1!==e?(this.userIdSources=this.getUserIdSources(),this.buildBidResponses(),this.buildNoBidResponses(),this.winningBid=this.getWinningBid(),c.a.set("bidderCodeResponses",[].concat(c.a.bidderCodeResponses||[],Object(o.a)(this.bidResponses.bids,[]).map(e=>e.bidderCode))),Object(o.g)(this.winningBid)?this.onBidRejected():this.onBidAccepted(this.winningBid,e),this.clearAdUnits()):this.jsContent=!1}buildBidResponses(){const e=this.bidRequests.map(e=>e.bidId),t=this.window.paubjs.getBidResponsesForAdUnitCode(this.adUnitCode);t.bids=(t.bids||[]).filter(t=>e.includes(t.requestId)),this.bidResponses=t}buildNoBidResponses(){const e=this.bidRequests.map(e=>e.bidId),t=this.window.paubjs.getNoBidsForAdUnitCode(this.adUnitCode);t.bids=(t.bids||[]).filter(t=>e.includes(t.bidId)),this.noBidResponses=t}getUserIdSources(){const e=this.window.paubjs.getUserIdsAsEids();return Object(a.a)(e)?e.map(e=>e.source).filter(Boolean):[]}getWinningBid(){let e=[];const{bids:t=[]}=this.bidResponses;if(e.push(...t),!Object(o.e)(this.nativeAdObj.s2sBids)){const t=this.nativeAdObj.s2sBids.map(e=>this.createS2SBid(e));e.push(...t)}if(this.config.reuseBidPropositions){const t=l.retrieve();Object(o.e)(t)||e.push(...t)}if(e=e.filter(Boolean),Object(o.e)(e))return null;e=e.map(e=>this.withAdditionalProps(e)),e=e.filter(e=>this.isBidEligible(e)),e.sort(p.o);const i=Object(u.j)(e);if(Object(o.g)(i))return null;if(this.config.reuseBidPropositions){const t=e.filter(e=>e.internalCacheId!==i.internalCacheId&&!e.retrievedFromCache);Object(o.e)(t)||l.add(...t),Object(a.c)(i.markAsUsed)&&i.markAsUsed()}return i}getOriginalBidderOptions(e){if(e.retrievedFromCache)return e;if(e.is_s2s)return{};let t=Object(u.c)(this.bidRequests,t=>e.requestId===t.bidId)||{};return Object(o.e)(t)&&(t=Object(u.c)(this.bidRequests,t=>p.n(t,e))||{},Object(s.i)(Object(b.i)({key:this.nativeAdOptions.key,mode:this.nativeAdOptions.mode,bidRequests:this.bidRequests,bidderWithOptions:t,bid:e})),Object(s.h)("BIDDER_PARAMS_DEBUG: no bidder matches when using requestId, used another find predicate instead.")),Object(o.e)(t)?{}:Object(b.g)(t,O)}withAdditionalProps(e){if(!e)return null;const t={...e,guid:this.biddingUUID,is_s2s:e.is_s2s||!1,size:p.d(e),...this.getOriginalBidderOptions(e)};return t.floorMin=this.getFloorMin(t),t.retrievedFromCache=Object(o.a)(t.retrievedFromCache,!1),t.internalCacheId=Object(o.a)(t.internalCacheId,Object(o.d)()),t.internalCacheExpiry=Object(o.a)(t.internalCacheExpiry,-1),t.markAsUsed=()=>l.remove(t),t}replaceBiddersViewId(e){if(this.loadFluxCount<=1)return!0;const t=e.length;try{const i=new XMLHttpRequest,n=Object(h.a)("https://d.audiencerun.com/r/nid/")+t;i.open("GET",n,!1),i.send(null);const r="setRequestHeader"in i;if(r&&200!==i.status)throw new Error(`${"GET".toUpperCase()} - replaceBiddersViewId - Request failed with status ${i.status} - ${i.statusText} on ${n}`);if(r&&i.status>=200&&i.status<300){const r=i.responseText,o=Object(b.d)(r);Object(a.a)(o)||Object(s.j)(n,r,`INVALID_PAYLOAD: replaceBiddersViewId - response payload from ${n} should be an array.`),o.length{Object(u.f)(d,Object.keys(e)).every((e,t)=>e===d[t])&&(e.view_id=o[t])}),c.a.newIdsRequest.splice(0,e.length)}}catch(e){return Object(s.h)(e),!1}return!0}isOverMinimumBidFloor(e){return!!Object(u.k)(this.nativeAdObj.ignoredBiddersForTruncation,e.bidderCode)||(0===e.floorMin&&e.cpm>this.cpm||e.floorMin>0&&e.cpm>e.floorMin)}isOverTruncationFloor(e){return!!Object(u.k)(this.nativeAdObj.ignoredBiddersForTruncation,e.bidderCode)||(!!(this.nativeAdObj.msk&&this.nativeAdObj.floor>0)||(this.nativeAdObj.flux.nbRefresh>1||e.cpm>this.nativeAdObj.floor))}refreshRtbParams(e,t={}){if(Object(o.e)(e))return;y.filter(e=>!["refreshOnAdVisible"].includes(e)).every(t=>!Object(o.g)(e[t]))||(Object(s.i)(Object(b.i)({key:this.nativeAdOptions.key,mode:this.nativeAdOptions.mode,bidRequests:this.bidRequests,winningBid:e})),Object(s.h)(`MISSING_PROPERTIES: ${e.bidderCode} bidder has not all required refresh params, setting default instead.`));const i={...t,refreshRtb:Object(o.a)(e.refresh_activated,!0),refreshRtbMax:Object(o.a)(parseInt(e.max_refresh,10),-1),refreshRtbDelay:Object(o.a)(parseInt(e.refresh_delay,10),10),cpmThreshold:Object(o.a)(parseFloat(e.refresh_activation_cpm_threshold),0),refreshOnAdVisible:Object(o.a)(e.refreshOnAdVisible,!1)};if(-1!==i.refreshRtbMax&&this.nativeAdObj.flux.nbRefresh>i.refreshRtbMax)return;if(!i.refreshRtb)return;this.nativeAdOptions,this.nativeAdObj;Object.keys(i).forEach(e=>{Object.prototype.hasOwnProperty.call(i,e)&&(this.nativeAdOptions[e]=i[e],this.nativeAdObj[e]=i[e])});const n=parseFloat(e.cpm)>this.nativeAdObj.cpmThreshold;(this.nativeAdObj.flux.isRefreshPerWinnerBidActive||n)&&this.nativeAdObj.flux.refreshAfter(this.nativeAdObj.refreshRtb,this.nativeAdObj.refreshRtbDelay,this.nativeAdObj.refreshRtbMax,!1,!1,!0)}divideFloorsBy(e,t){if(!this.nativeAdOptions.refreshRtb)return;const i=this.nativeAdObj.preloadBanners?this.nativeAdObj.preloadBannersCount+1:2;this.loadFluxCount===i&&e&&e.forEach(e=>{e.params&&e.params.floorc&&(e.params.floorc=parseFloat(e.params.floorc)/t)})}cancelSendPixel(){this.canSendPixel=!1}getPreviousWinnerBidSize(){return!0===this.saveWinnerSize&&c.a.winnerBidsTmpSize?c.a.winnerBidsTmpSize[0]+"x"+c.a.winnerBidsTmpSize[1]:null}sendBidderPixel(){if(!this.canSendPixel)return!1;c.a.set("fluxIsLoaded",!1);const e=setInterval(()=>{c.a[this.adUnitCode+"End"]&&(clearInterval(e),this.winningBid?this.sendPixel(this.winningBid):(Object(s.i)({bidRequests:this.bidRequests,winningBid:this.winningBid}),Object(s.h)("Error sendBidderPixel : not found bidRequests.bidId === winningBid.requestId")))},50)}sendPixel(e){let t=Object(h.a)("https://d.audiencerun.com/r/spn/");void 0!==e.is_s2s&&e.is_s2s&&(t=Object(h.a)("https://d.audiencerun.com/r/spns/")),this.impressionClickedUrl=Object(v.d)(e),this.setBidderTmp(e);const i=t+e.view_id+"/"+this.winningBid.cpm+"/"+this.key;""===t||s.a||Object(v.c)(i);const n=Object(v.e)({...Object(b.g)(this.nativeAdOptions,["key","zh"]),winningBid:e});n&&this.imptrackers.push(n),c.a.set("fluxIsLoaded",!0)}setBidderTmp(e){c.a.set("winnerBidsTmp",[...c.a.winnerBidsTmp,e.view_id]),!0===this.saveWinnerSize&&!c.a.winnerBidsTmpSize&&this.bannerHeight&&c.a.set("winnerBidsTmpSize",[this.bannerWidth,this.bannerHeight])}loadPrebid(e,t){if(this.window.paubjs.libLoaded)return void(Object(a.c)(e)&&e());let i;i=s.c?"https://prebid.local.dev.blackcover.fr:9001/static/assets/audiencerun/dev/prebid.js?1658407711680":s.a?"https://ad.aruncdn.com/develop/j/prebid/pre.js?411":"https://ac.aruncdn.com/j/prebid/pre.js?411",i=Object(b.a)(this.window.document.querySelector("link[rel='preload'][href*='/j/prebid/pre.js?411']"),"href")||i,Object(g.b)(i,()=>{Object(a.c)(e)&&e()},t,this.window)}getBanner(){return null===this.winnerbidderCode?null:p.i(this.winningBid)?this.getBannerCriteo():"native"===p.f(this.winningBid)?this.getBannerNative():"video"===p.f(this.winningBid)?this.getBannerVideo():this.getBannerDefault()}getBannerDefault(){let e=null;return null!==this.jsContent&&(e=[],e.push({ver:1.1,vm:this.vm,ext:{guid:this.biddingUUID,bidderCode:this.winningBid.bidderCode,adUnitCode:this.winningBid.adUnitCode,cpm:this.winningBid.cpm,adType:"banner",viewId:this.winningBid.view_id,zoneHitId:this.nativeAdOptions.zh},imptrackers:this.imptrackers,cl:this.impressionClickedUrl,assets:[{data:{label:"jsContent",value:this.jsContent}},{data:{label:"iframeWidth",value:this.bannerWidth}},{data:{label:"iframeHeight",value:this.bannerHeight}}],containerId:this.adUnitCode})),e}getBannerVideo(){let e=null;return null!==this.jsContent&&(e=[],e.push({ver:1.1,vm:this.vm,ext:{guid:this.biddingUUID,bidderCode:this.winningBid.bidderCode,adUnitCode:this.winningBid.adUnitCode,cpm:this.winningBid.cpm,adType:"video",s2s:this.winningBid.is_s2s,hb_adid:this.winningBid.adserverTargeting.hb_adid,viewId:this.winningBid.view_id,zoneHitId:this.nativeAdOptions.zh},imptrackers:this.imptrackers,cl:this.impressionClickedUrl,assets:[{data:{label:"jsContent",value:this.jsContent}},{data:{label:"iframeWidth",value:this.bannerWidth}},{data:{label:"iframeHeight",value:this.bannerHeight}}],containerId:this.adUnitCode})),e}pushImptrackers(e){"native"===e&&this.winningBid.native&&this.winningBid.native.impressionTrackers&&(this.imptrackers=[...this.imptrackers,...this.winningBid.native.impressionTrackers])}getBannerNative(){this.pushImptrackers("native");const e=[],t={ver:1.1,link:this.impressionClickedUrl+encodeURIComponent(this.winningBid.native.clickUrl),vm:this.vm,ext:{guid:this.biddingUUID,bidderCode:this.winningBid.bidderCode,adUnitCode:this.winningBid.adUnitCode,cpm:this.winningBid.cpm,adType:"native",viewId:this.winningBid.view_id,zoneHitId:this.nativeAdOptions.zh},imptrackers:this.imptrackers,assets:[{title:{text:this.winningBid.native.title}},{img:{url:"//a.qwertize.com/i/s/?u="+encodeURIComponent(this.winningBid.native.image.url),w:382,h:200}},{data:{label:"source",value:this.winningBid.native.sponsoredBy}},{data:{label:"linkSource",value:""}}]};return this.winningBid.native.privacyLink&&this.winningBid.native.privacyIcon&&t.assets.push({data:{label:"privacy",value:{url:this.winningBid.native.privacyLink,img:this.winningBid.native.privacyIcon}}}),e.push(t),e}getBannerCriteo(){let e=null;const t=this.jsContent;return null===t||!1===t||t.products.length>0&&(e=[],t.products.forEach((i,s)=>{e=this.addCriteoData(e,i,t),void 0!==t.impression_pixels&&(e[s].imptrackers=[...t.impression_pixels.map(e=>e.url),...this.imptrackers])})),e}addCriteoData(e,t,i){const s=t.title||"",n=t.description||"",r=s.length<20&&n.length>20?n:s;return e.push({ver:1.1,link:this.impressionClickedUrl+encodeURIComponent(t.click_url),vm:this.vm,ext:{guid:this.biddingUUID,bidderCode:"criteo",adUnitCode:this.winningBid.adUnitCode,cpm:this.winningBid.cpm,adType:"native",source:"nativeCallback",zoneHitId:this.nativeAdOptions.zh,viewId:this.winningBid.view_id},assets:[{title:{text:r}},{img:{url:"//a.qwertize.com/i/s/?u="+encodeURIComponent(t.image.url),w:382,h:200}},{img:{url:"//a.qwertize.com/i/s/?u="+encodeURIComponent(t.image.url)+"&w=300&h=300",w:300,h:300,ext:{ratio:"1:1"}}},{data:{label:"price",value:t.price}},{data:{label:"source",value:i.advertiser.description}},{data:{label:"linkSource",value:this.impressionClickedUrl+encodeURIComponent(i.advertiser.logo_click_url)}},{data:{label:"privacy",value:{url:i.privacy.optout_click_url,img:i.privacy.optout_image_url}}},{data:{label:"description",value:t.description}}]}),e}getFilteredBidders(){let e=Object(b.b)(Object(o.e)(this.nativeAdObj.flux.updatedBidders)?this.feedBidders:this.nativeAdObj.flux.updatedBidders);if(this.nativeAdObj.excludedAdTypes.length>0&&(e=p.b(e,this.nativeAdObj.excludedAdTypes)),e=e.filter(e=>{const t=p.f(e)||"banner",i=p.c(e);return!c.a.inArray("excludeMediaTypes",t)&&!c.a.inArray("excludeSizes",i)}),!Object(a.c)(this.utils.topWindow.__tcfapi)&&this.prebidConfig.isGdprRequired&&(e=p.a(e,n.e)),this.loadFluxCount>1&&(e=p.a(e,n.f)),this.saveWinnerSize){const t=this.getPreviousWinnerBidSize();Object(o.g)(t)||(e=e.filter(e=>{const i=p.c(e);return!!("criteo"===e.bidder&&e.isNativeLegacy||["0x0","1x1"].includes(i)||t===i)}))}return e}applyInternalBidderParams(e){const t=e.find(e=>"criteo"===e.bidder&&e.isNativeLegacy);if(!Object(o.e)(t)){const e=this;t.params.nativeCallback=function(t){"function"==typeof e.window[e.callbackKey]&&e.window[e.callbackKey](t)}}return e}saveBiddingMetrics(e,t,i,s){const{bids:n=[]}=i||{};this.initializeBiddingMetrics(e,t,i,n,s);const a=this.getBidResponsesGlobal(e,t,n,s),d=this.bidders.map(e=>({bidder:e.bidder,floorc:Object(b.a)(e,"params.floorc",0),refreshRtb:Object(o.a)(e.refresh_activated,null),refreshDelay:Object(o.a)(e.refresh_delay,null),cpmThreshold:Object(o.a)(e.refresh_activation_cpm_threshold,null),refreshOnAdVisible:Object(o.a)(e.refreshOnAdVisible,!1)}));let l=[],c=[];Object(b.a)(e,"is_s2s",!1)&&(l=this.nativeAdObj.s2sBids.map(e=>({advertiser_name:e.bidder,cpm:Object(o.k)(e.cpm,4),mediaType:e.ad_type,bidfloor:e.floorc,size_banner_bidder:p.d(e),time_to_respond:e.ttr,is_s2s:e.is_s2s,source:e.source||"unknown",pcid:e.pcid||"unknown",advertiserDomains:Object(b.a)(e,"meta.advertiserDomains",[])})),c=this.nativeAdObj.s2sBids.map(e=>({bidder:e.bidder,floorc:e.floorc,refreshRtb:Object(o.a)(e.refresh_activated,null),refreshDelay:Object(o.a)(e.refresh_delay,null),cpmThreshold:Object(o.a)(e.refresh_activation_cpm_threshold,null),refreshOnAdVisible:Object(o.a)(e.refreshOnAdVisible,!1),is_s2s:!0}))),this.biddingMetrics.nb_refresh=this.nativeAdObj.flux.nbRefresh,this.biddingMetrics.max_refresh=Object(b.a)(e,"max_refresh",null),this.biddingMetrics.refresh_activated=Object(b.a)(e,"refresh_activated",!1),this.biddingMetrics.refresh_activation_cpm_threshold=Object(b.a)(e,"refresh_activation_cpm_threshold",null),this.biddingMetrics.refresh_delay=Object(b.a)(e,"refresh_delay",0),this.biddingMetrics.refresh_clear_interval=this.nativeAdObj.flux.refreshEnded,this.biddingMetrics.refresh_occurence=this.refreshUniqLoadFluxCount,this.biddingMetrics.refresh_occurence_time=Object(r.d)(),this.biddingMetrics.refreshOnAdVisible=Object(b.a)(e,"refreshOnAdVisible",!1),this.biddingMetrics.effective_refresh_delay=Math.round(this.nativeAdObj.flux.effectiveRefreshTime),this.biddingMetrics.user_frequency=Object(o.a)(this.nativeAdOptions.freqUser,0),this.biddingMetrics.bidfloor=Object(b.a)(e,"floorMin",0),this.biddingMetrics.floor=this.nativeAdObj.floor,this.biddingMetrics.bid_responses_global=[...a,...l],this.biddingMetrics.bidders_adserver=[...d,...c],this.biddingMetrics.bid_requests_count=this.bidRequests.length+l.length,this.biddingMetrics.bid_propositions=this.biddingMetrics.bid_responses_global.filter(e=>e.cpm),this.biddingMetrics.bid_responses_count=this.biddingMetrics.bid_responses_global.length,this.biddingMetrics.first_bid_responses_count=this.biddingMetrics.first_bid_responses_count||this.biddingMetrics.bid_responses_global.length,this.biddingMetrics.is_open=this.nativeAdObj.isOpen,this.biddingMetrics.pixel_view_send=this.nativeAdObj.isPixelViewSent,this.biddingMetrics.first_ssp_partner_winner=null,this.biddingMetrics.ssp_partner_winner=null,this.biddingMetrics.dsp_winner_id=null,this.biddingMetrics.first_dsp_winner_id=null,this.biddingMetrics.contacted_ssp_count=Object(u.n)(this.biddingMetrics.bidders_adserver,(e,t)=>e.bidder===t.bidder).length,this.biddingMetrics.advertiserDomains=Object(b.a)(e,"meta.advertiserDomains",[]),this.biddingMetrics.userIdSources=this.userIdSources,e?(this.biddingMetrics.impression_id=e.view_id,this.biddingMetrics.first_cpm=Object(o.k)(e.cpm,4),this.biddingMetrics.first_bidder_winner=e.bidderCode||e.bidder,this.biddingMetrics.mediaType=e.mediaType||e.ad_type,this.biddingMetrics.time_to_respond=e.timeToRespond||e.ttr,this.biddingMetrics.bidder_winner=e.bidderCode||e.bidder,this.biddingMetrics.is_s2s=e.is_s2s,this.biddingMetrics.source=e.source||"unknown",this.biddingMetrics.is_bid_accepted=!0):(this.biddingMetrics.impression_id=void 0,this.biddingMetrics.first_cpm=null,this.biddingMetrics.first_bidder_winner=null,this.biddingMetrics.mediaType=null,this.biddingMetrics.time_to_respond=null,this.biddingMetrics.bidder_winner=null,this.biddingMetrics.is_s2s=null,this.biddingMetrics.source=null,this.biddingMetrics.is_bid_accepted=!1),this.applyConditionalBiddingMetrics(),this.sendBiddingMetrics(Object(h.a)("https://d.audiencerun.com/pm"),this.nativeAdOptions.key,this.nativeAdOptions.mode,this.biddingMetrics,this.nativeAdObj.preview)}getBidResponsesGlobal(e,t,i,s){const n=[],r=[];return this.config.reuseBidPropositions&&Object(b.a)(e,"retrievedFromCache")&&n.push({id:e.adId,auctionGuid:e.guid,advertiser_name:e.bidder,cpm:Object(o.k)(e.cpm,4),mediaType:e.mediaType,bidfloor:Object(b.a)(e,"params.floorc",0),size_banner_bidder:p.d(e),time_to_respond:e.timeToRespond,source:e.source||"unknown",pcid:e.pcid||"unknown",advertiserDomains:Object(b.a)(e,"meta.advertiserDomains",[])}),t.forEach(e=>{const t=Object(u.c)(i,t=>p.n(e,t,n)),a=Object(u.c)(s,t=>p.n(e,t,r)),d=Object(b.a)(t,"meta.advertiserDomains",[]);t?n.push({id:t.adId,advertiser_name:t.bidder,cpm:Object(o.k)(t.cpm,4),mediaType:t.mediaType,bidfloor:Object(b.a)(e,"params.floorc",0),size_banner_bidder:p.d(t),time_to_respond:t.timeToRespond,source:t.source||e.src||"unknown",pcid:e.pcid||"unknown",advertiserDomains:d}):r.push({id:e.internalId,advertiser_name:e.bidder,mediaType:Object(o.a)(Object.keys(Object(b.a)(e,"mediaTypes",[]))[0],"none"),bidfloor:Object(b.a)(e,"params.floorc",0),size_banner_bidder:Object(b.a)(e,"params.sizec","0x0"),time_to_respond:a?-1:e.timeToRespond,source:e.src||"unknown",pcid:e.pcid||"unknown",advertiserDomains:d})}),[...n,...r]}sendBiddingMetrics(e,t,i,s,n=!1){this.nativeAdOptions.msk&&this.refreshUniqLoadFluxCount<=this.minMetricsIterationCount||Object(m.a)(e,"bidding",t,i,s,n)}getFloorMin(e){if(!e)return 0;if(e.is_s2s){const t=parseFloat(e.floorc);return t}const t=parseFloat(Object(b.a)(e,"params.floorc",0));return t}setJsContentForCriteo(e){if(e){this.window[this.callbackKey]=e=>{this.jsContent=!!Object(a.a)(Object(b.a)(e,"products"))&&e};try{this.window.paubjs.renderAd(e,this.winningBid.adserverTargeting.hb_adid)}catch(e){Object(s.i)(Object(b.i)({error:e,winningBid:this.winningBid})),Object(s.h)(new Error("setJsContentForCriteo => Error happened during this.window.paubjs execution"))}}}setJsContent(e,t,i){i&&!e.is_s2s?this.setJsContentForCriteo(t):"native"===p.f(e)?this.jsContent=this.winningBid.native:"video"===p.f(e)&&(e.vastXml||e.vastUrl)?this.jsContent=e.vastXml||e.vastUrl:"video"!==p.f(e)||e.is_s2s?"video"===p.f(e)&&e.is_s2s?this.jsContent=e.ad:(this.jsContent=e.ad,this.checkRedirect()):this.jsContent=`\x3c!-- ${e.adUnitCode} - outstream-video-prebid --\x3e`}createS2SBid(e){if(Object(o.e)(e))return null;const t=Object(f.b)(e.adm);return Object(o.e)(t)?(Object(s.i)(Object(b.i)({bid:e,guid:this.biddingUUID,key:this.nativeAdOptions.key,mode:this.nativeAdOptions.mode,zoneHitId:this.nativeAdOptions.zh})),Object(s.h)("INVALID_S2S_AD: parseHTML returned an empty string."),null):{ad:t,is_s2s:!0,source:e.source,bidder:e.bidder,bidderCode:e.bidder,adserverTargeting:{hb_adid:e.view_id,hb_size:p.d(e)},meta:{advertiserDomains:Object(b.a)(e,"meta.advertiserDomains",[])},cpm:e.cpm,width:e.w,height:e.h,ad_type:e.ad_type,ttr:e.ttr,ttl:e.ttl,view_id:e.view_id,floorc:e.floorc,refresh_activated:e.refresh_activated,max_refresh:e.max_refresh,refresh_delay:e.refresh_delay,refresh_activation_cpm_threshold:e.refresh_activation_cpm_threshold,refreshOnAdVisible:e.refreshOnAdVisible,pcid:e.pcid}}handleS2SBidding(){c.a.set(this.adUnitCode+"End",!0),this.winningBid=this.getWinningBid(),Object(o.g)(this.winningBid)?this.onBidRejected():this.onBidAccepted(this.winningBid,null)}isBidEligible(e){return null!==e&&Object(b.a)(e,"adserverTargeting.hb_adid")&&this.isOverTruncationFloor(e)&&this.isOverMinimumBidFloor(e)}onBidAccepted(e,t=null){const i=p.i(e);this.winnerbidderCode=e.bidderCode,c.a.set("winnerbidderCode",this.winnerbidderCode),c.a.set("hasCriteoNativeCallback",i),this.setJsContent(e,t,i),this.bannerWidth=e.width,this.bannerHeight=e.height,this.sendBidderPixel(),this.refreshRtbParams(e),this.saveBiddingMetrics(e,this.bidRequests,this.bidResponses,this.biddersOnTimeout),this.nativeAdObj.s2sBids=[]}onBidRejected(){this.jsContent=!1,this.winningBid={},c.a.set("isLoadedBanner",void 0),this.saveBiddingMetrics(null,this.bidRequests,this.bidResponses,this.biddersOnTimeout),Object(a.c)(Object(b.a)(this,"nativeAdObj.flux.updateBiddersFloor"))&&this.nativeAdObj.flux.updateBiddersFloor()}attachPostBidIframeToDocument(e){let t=!1;const i=this.window.document.createElement("iframe");i.id="postbid_if_"+e,i.frameBorder="no",i.style.width="0",i.style.height="0",this.window.document.body.appendChild(i);try{t=i.contentWindow.document}catch(e){return!1}return t}initializeBiddingMetrics(e,t,i,s,n){!!e&&e.is_s2s;this.refreshUniqLoadFluxCount=this.utils.topWindow.__ARUN___refreshUniqLoadFlux[this.nativeAdOptions.rid]+=1,this.biddingMetrics.guid=this.biddingUUID,this.biddingMetrics.zone_hit_id=this.nativeAdOptions.zh,this.biddingMetrics.script_key=this.nativeAdOptions.key,this.biddingMetrics.page_url=this.utils.topWindow.location.href,this.biddingMetrics.referer_url=this.utils.topWindow.document.referrer,this.biddingMetrics.seconds_since_last_refresh=Object(r.a)(Object(r.d)(),this.biddingMetrics.refresh_occurence_time),this.biddingMetrics.previous_bidder_winner=this.biddingMetrics.bidder_winner||null,this.biddingMetrics.previous_cpm=this.biddingMetrics.first_cpm||null,this.biddingMetrics.previous_ssp_partner_winner=this.biddingMetrics.ssp_partner_winner||null,this.biddingMetrics.previous_dsp_winner_id=this.biddingMetrics.first_dsp_winner_id||null,this.biddingMetrics.previous_bid_responses_count=this.biddingMetrics.bid_responses_count||0}applyConditionalBiddingMetrics(){if(this.nativeAdOptions.msk){const e=this.utils.topWindow["_arun_"+this.nativeAdOptions.msk];this.biddingMetrics.parent_script_key=this.nativeAdOptions.msk,e?(this.biddingMetrics.floor=e.floor||0,this.biddingMetrics.parent_zone_hit_id=e.zh||null,e.biddingMetrics=e.biddingMetrics||{},e.biddingMetrics[this.key]=e.biddingMetrics[this.key]||[],this.refreshUniqLoadFluxCount<=this.minMetricsIterationCount&&!e.biddingMetrics[this.key].some(e=>e.guid===this.biddingUUID)&&e.biddingMetrics[this.key].push(Object(b.b)(this.biddingMetrics))):this.biddingMetrics.parent_zone_hit_id=null}else this.biddingMetrics.parent_script_key=null,this.biddingMetrics.parent_zone_hit_id=null}}var _=i(31),k=i(10),x=i(20);class A{constructor(e,t,i){s.a&&(this.debugTitle=`Mode "${i.oOptions.mode}" for script_key ${i.oOptions.key} / class "Flux" => `),this.aFeeds=e||[],this.aBanners=[],this.aBannersTmp=[],this.window=t,this.nativeAd=i,this.refreshInterval=null,this.startRefreshTimeout=null,this.isLoaded=!1,this.isPreload=!1,this.refreshStarted=!1,this.refreshEnded=!1,this.refreshEndForced=!1,this.loadFluxCount=0,this.preloadLoadedCount=0,this.fluxTimeout=0,this.preloadCounter=this.nativeAd.preloadBannersCount,this.fluxReadyCallCount=0,this.nbRefresh=0,this.nativeAd.utils.topWindow.nbRefresh=this.nbRefresh,this.nativeAd.utils.topWindow.__ARUN___refreshUniqLoadFlux=this.nativeAd.utils.topWindow.__ARUN___refreshUniqLoadFlux||{},this.nativeAd.utils.topWindow.__ARUN___refreshUniqLoadFlux[this.nativeAd.oOptions.rid]=this.nativeAd.utils.topWindow.__ARUN___refreshUniqLoadFlux[this.nativeAd.oOptions.rid]||0,this.nbRefreshMax=10,this.refreshAfterTime=null,this.effectiveRefreshTime=null,this.refreshTime=0,this.isRefreshPerWinnerBidActive=!1,this.metrics=this.nativeAd.utils.topWindow.__ARUN___metrics[this.nativeAd.oOptions.rid]||{},this.floorRefreshCallCount=0,this.originalBidders=[],this.updatedBidders=[]}get maxRefreshReached(){return-1!==this.nbRefreshMax&&this.nbRefresh>this.nbRefreshMax}get canUpdateBiddersFloor(){return!(this.nativeAd.s2sOnly||!this.isRefreshPerWinnerBidActive||this.maxRefreshReached||this.preloadCounter>1)}isReady(e=!0){const t=setInterval(()=>{try{if(c.a.breakFlux&&(this.isLoaded=!0),this.isLoaded&&this.isPreloadDone()){if(Object(o.g)(this.metrics.fluxEnd)&&(this.metrics.fluxEnd=Object(r.d)()),this.metrics.fluxLoadingTime=this.metrics.fluxEnd-this.metrics.fluxInit,this.isPreload&&this.sortPreload(),0===this.fluxReadyCallCount&&this.nativeAd.msk)return this.fluxReadyCallCount++,this.isLoaded=!0,this.isPreload=!1,clearInterval(t),void this.delayFluxCallback(this.aBanners,e);this.fluxReadyCallCount++,this.nativeAd.fluxIsReadyCallback(this.aBanners,e),this.isPreload=!1,clearInterval(t)}}catch(e){Object(s.h)(e),clearInterval(t)}},51)}getBannersToUseInFlux(e=[]){if("doubleSky"!==this.nativeAd.oOptions.mode)return{bannersToUse:e,value:Object(_.b)(e)};let t=[],i=0;const s=Object(u.h)(Object(b.b)(e).map(e=>({...e,width:e.ext.bidderCode&&"native"===e.ext.adType?1:e.assets[1].data.value,height:e.ext.bidderCode&&"native"===e.ext.adType?1:e.assets[2].data.value})),"width");if(s[120]&&s[120].length>=2||s[160]&&s[160].length>=2||s[1]&&s[1].length>=1){const e={1:Object(o.a)(s[1]?s[1].sort((e,t)=>t.ext.cpm-e.ext.cpm).slice(0,6):null,[]),120:Object(o.a)(s[120]?s[120].sort((e,t)=>t.ext.cpm-e.ext.cpm).slice(0,2):null,[]),160:Object(o.a)(s[160]?s[160].sort((e,t)=>t.ext.cpm-e.ext.cpm).slice(0,2):null,[])},n=[{type:"1",value:Object(_.b)(e[1])},{type:"120",value:Object(_.b)(e[120])},{type:"160",value:Object(_.b)(e[160])}].reduce((e,t)=>e.value>t.value?e:t,0);n&&n.value>0&&(i=n.value,t=e[n.type]),["120","160"].some(e=>e===n.type)&&t.length<2&&(i=0,t=[])}return{bannersToUse:t,value:i}}delayFluxCallback(e,t){const i=this.nativeAd.msk,s=this.nativeAd.key,n="_arun_"+s,r="_arun_"+i,{bannersToUse:a,value:o}=this.getBannersToUseInFlux(e);this.nativeAd.utils.topWindow[n]=this.nativeAd.utils.topWindow[n]||{},this.nativeAd.utils.topWindow[n].key=s,this.nativeAd.utils.topWindow[n].status=0,this.nativeAd.utils.topWindow[n].mode=this.nativeAd.oOptions.mode,this.nativeAd.utils.topWindow[n].banners=Object(_.e)(a),this.nativeAd.utils.topWindow[n].native=this.nativeAd.iabBanners.length,this.nativeAd.utils.topWindow[n].value=o,this.nativeAd.utils.topWindow[n].render=e=>{e===i&&1!==this.nativeAd.utils.topWindow[n].status&&(this.nativeAd.fluxIsReadyCallback(a,t),this.nativeAd.utils.topWindow[n].status=1)},this.nativeAd.utils.topWindow[r]&&this.nativeAd.utils.topWindow[r].subAdFluxSettled(i,n)}sortPreload(){this.aBanners.length>1&&this.aBanners.sort((e,t)=>t.ext.cpm-e.ext.cpm)}isPreloadDone(){return this.nativeAd.preloadBanners&&this.preloadCounter>1&&this.loadFluxCount<=this.nativeAd.preloadBannersCount&&!c.a.breakFlux?(c.a.videoRendered&&this.preloadCounter++,this.isPreload=!0,this.isLoaded=!1,this.preloadCounter-=1,this.load(),!1):(this.preloadLoadedCount=this.getPreloadLoadedCount(),!0)}getPreloadLoadedCount(){const e=this.aBanners.filter(e=>"video"!==e.adType),t=Object(u.b)(e,e=>e.ext&&"criteo"===e.ext.bidderCode&&"nativeCallback"===e.ext.source,3);return 3===t.length?t.length:e.length}refreshAfter(e=!1,t=30,i=10,n=!1,a,o=!1){let d;o?(this.isRefreshPerWinnerBidActive=!0,d="refreshAfter => refresh per bidder winner is active for audiencerun adnetwork"):(this.isRefreshPerWinnerBidActive=!1,d="refreshAfter => backoffice options activated for audiencerun adnetwork"),!1!==e&&!0!==this.nativeAd.isPassbackCalled&&!1!==o&&(this.nbRefresh=this.nbRefresh||2,this.nativeAd.utils.topWindow.nbRefresh=this.nbRefresh,this.nbRefreshMax=i,this.refreshAfterTime=t,this.refreshInProgress=a||!1,this.refreshTime=Object(r.d)(),this.refreshInterval=setInterval(()=>{try{this.nativeAd.canRefresh&&!0===this.isLoaded&&!1===this.refreshInProgress&&(!0!==c.a.isVideoPlaying||n)&&(!1!==c.a.isLoadedBanner||0===c.a.isBidderRendered)&&this.isPreloadDone()&&(!c.a.videoRendered||n)&&(!c.a.isPlayerProcessing||n)&&(this.effectiveRefreshTime=null,this.refreshInProgress=!0,setTimeout(()=>{try{this.startRefresh(n)}catch(e){Object(s.h)(e)}},250))}catch(e){Object(s.h)(e)}},200))}startRefresh(e=!1){this.startRefreshTimeout=setTimeout(()=>{try{if(!0===this.nativeAd.isPassbackCalled)return void this.clearRefreshInterval();if(this.nativeAd.s2sOnly&&this.nativeAd.s2sBids.length<1)return void this.clearRefreshInterval();if(this.refreshEndForced)return void this.clearRefreshInterval();if(this.nativeAd.msk&&this.nbRefresh>1){const e="_arun_"+this.nativeAd.key;if(this.nativeAd.utils.topWindow[e]&&0===this.nativeAd.utils.topWindow[e].status)return void this.clearRefreshInterval()}if(this.maxRefreshReached)return void this.clearRefreshInterval();if(!this.nativeAd.canRefresh)return void(this.refreshInProgress=!1);if(!0===c.a.isVideoPlaying&&!1===e)return void(this.refreshInProgress=!1);const t=Object(r.d)();if(this.effectiveRefreshTime=Math.round(Object(r.b)(t-this.refreshTime)),this.refreshTime=Object(r.d)(),this.refreshStarted=!0,this.isPreload=!1,null===this.load())return void this.clearRefreshInterval();this.reset(),this.isReady(),this.refreshInProgress=!1,this.nbRefresh++}catch(e){this.clearRefreshInterval(),Object(s.h)(e)}},Object(r.c)(this.refreshAfterTime))}clearRefreshInterval(e=!1){clearInterval(this.refreshInterval),clearTimeout(this.startRefreshTimeout),this.refreshEndForced=e,this.refreshEnded=!0}reset(){this.aBanners=[],this.aBannersTmp=[],this.isLoaded=!1}load(){Object(o.g)(this.metrics.fluxInit)&&(this.metrics.fluxInit=Object(r.d)());const e=[],t=this.nativeAd.s2sOnly?1:12e3;return c.a.set("loadFluxCount",this.loadFluxCount),this.nativeAd.s2sOnly?(this.loadBannersFlux({window:window,regie:"s2s"},e),void this.fluxIsLoaded(e,t)):(this.aFeeds.forEach(t=>{this.loadBannersFlux(t,e)}),Object(o.e)(Object(b.a)(e,"0.bidders",[]))?(this.clearRefreshInterval(),null):void this.fluxIsLoaded(e,t))}loadBannersFlux(e,t){((e,t)=>{this.loadFluxCount+=1,c.a.set("loadFluxCount",this.loadFluxCount),this.fluxTimeout=e.config&&e.config.bidderTimeout?e.config.bidderTimeout:1200,t.push(new j(e,this.nativeAd,this.loadFluxCount))})(e,t)}fluxIsLoaded(e,t,i=0){setTimeout(()=>{try{let s=!0;e.forEach(e=>{null!==e.jsContent&&!1!==c.a.fluxIsLoaded||(s=!1)}),!s&&i{const t=e.getBanner();null!==t&&t.length>0&&(this.aBannersTmp=this.aBannersTmp.concat(t)),"bidding"===e.regie&&e.cancelSendPixel()}),this.aBanners=Object(u.m)([...this.aBannersTmp,...this.aBanners]),this.isLoaded=!0}divideGlobalFloorBy(e,t){if(!this.nativeAd.refreshRtb)return;const i=this.loadFluxCount+1,s=this.nativeAd.preloadBanners?this.nativeAd.preloadBannersCount+1:2;e.cpm;i===s&&e.cpm&&(e.cpm/=t)}updateBiddersFloor(){if(!this.canUpdateBiddersFloor)return;const e=Object(h.a)("https://d.audiencerun.com/floor-refresh");Object(o.e)(e)||(this.updatedBidders=Object(b.b)(this.originalBidders),Object(x.a)({url:Object(k.e)(e,{zoneHitId:this.nativeAd.hitId,refreshOccurrence:++this.floorRefreshCallCount}),method:"GET",timeout:5e3},e=>{try{const t=Object(b.d)(e)||{},{floors:i}=t;if(!Object(a.f)(i))return Object(s.i)(Object(b.i)({floors:i,key:this.nativeAd.key,zh:this.nativeAd.hitId})),void Object(s.h)("INVALID_PARAMS: Invalid 'floors' object provided.");if(Object(o.e)(i))return;this.updatedBidders.forEach(e=>{const t=i[e.pcid];if(!Object(p.k)(e,t))return Object(s.i)(Object(b.i)({floor:t,key:this.nativeAd.key,zh:this.nativeAd.hitId,pcid:e.pcid})),void Object(s.h)(`INVALID_PARAMS: Invalid 'floor' value provided for '${e.bidder}'.`);const{bidder:r,params:a}=e,o=Object(b.a)(n.c,r+".name");a[n.d]=t,o&&(a[o]=t)})}catch(e){Object(s.h)(e)}},e=>{}))}}},function(e,t,i){"use strict";i.d(t,"c",(function(){return l})),i.d(t,"d",(function(){return d})),i.d(t,"e",(function(){return p})),i.d(t,"f",(function(){return u})),i.d(t,"b",(function(){return b})),i.d(t,"a",(function(){return m})),i.d(t,"h",(function(){return w})),i.d(t,"g",(function(){return k})),i.d(t,"i",(function(){return _}));var s=i(2),n=i(16),r=i(1),a=i(4),o=i(0);const d="floorc",l={rubicon:{name:"floor",type:"number"},pubmatic:{name:"kadfloor",type:"string"},smartadserver:{name:"bidfloor",type:"number"},sovrn:{name:"bidfloor",type:"number"},improvedigital:{name:"bidFloor",type:"number"},emx_digital:{name:"bidfloor",type:"string"},sharethrough:{name:"bidfloor",type:"number"},unruly:{name:"floor",type:"number"},oftmedia:{name:"reserve",type:"number"},yieldmo:{name:"bidFloor",type:"number"},amx:{name:"floor",type:"number"},richaudience:{name:"bidfloor",type:"number"},appnexus:{name:"reserve",type:"number"},vidoomy:{name:"bidfloor",type:"number"},connectad:{name:"bidfloor",type:"number"},medianet:{name:"bidfloor",type:"number"}},c={asi:"ad6media.fr",sid:"7730",hp:1},h={asi:"qwertize.com",sid:"7730",hp:1},p=["pubmatic"],u=["admixer"],b=["admixer"],m=["adagio"],g={appnexus:"USD",eplanning:"USD"},f={default:{adServerCurrency:"USD",bidderCurrencyDefault:g,granularityMultiplier:1,defaultRates:{EUR:{USD:1.0796}}},eur:{adServerCurrency:"EUR",bidderCurrencyDefault:g,granularityMultiplier:1,defaultRates:{USD:{EUR:.9262689885142646}}}},v=[{name:"uid2"},{name:"criteo"},{name:"sharedId",storage:{type:"cookie",name:"_sharedID",expires:365}},{name:"id5Id",params:{partner:Object(r.a)(parseInt("981",10),0)},storage:{type:"html5",name:"id5id",expires:90,refreshInSeconds:28800}},{name:"amxId",storage:{name:"amxId",type:"html5",expires:30}}],w={standard:{storageAllowed:!0},improvedigital:{bidCpmAdjustment:e=>.6800499999999998*e},smartadserver:{bidCpmAdjustment:e=>.7218999999999999*e},appnexus:{bidCpmAdjustment:e=>.75*e},oftmedia:{bidCpmAdjustment:e=>.68*e},pubmatic:{bidCpmAdjustment:e=>.6800499999999998*e},rubicon:{bidCpmAdjustment:e=>.8*e*(1-.07)},eplanning:{bidCpmAdjustment:e=>.646*e},sovrn:{bidCpmAdjustment:e=>.8*e},criteo:{bidCpmAdjustment:e=>e*(.837-.05)},sharethrough:{bidCpmAdjustment:e=>.6475*e},luponmedia:{bidCpmAdjustment:e=>.8*e},richaudience:{bidCpmAdjustment:e=>.86*e},medianet:{bidCpmAdjustment:e=>.74*e},adagio:{bidCpmAdjustment:e=>.75*e},onetag:{bidCpmAdjustment:e=>.6*e},connectad:{bidCpmAdjustment:e=>.3*e},adpone:{bidCpmAdjustment:e=>.6*e},unruly:{bidCpmAdjustment:e=>.9*e},amx:{bidCpmAdjustment:e=>.95*e}},y=e=>e.prebidServerActivated,O=e=>!!e.prebidServerABTesting,j=e=>{const t={};return e.filter(O).forEach(e=>{t[e.bidder]=e.prebidServerABTesting}),t},_=(e,t)=>{const i=Object(a.j)(),d=(e=>e.filter(y))(t),{bidderTimeout:l,isGdprRequired:c,affiliateId:h,s2sConfigEnabled:p,userSync:u}=e,b=Object(r.a)(Number(l),1200),m=Object(r.a)(Number(u.auctionDelay),0),g={cmpApi:"iab",timeout:500,defaultGdprScope:!1},w={isGdprRequired:c,priceGranularity:"high",bidderTimeout:b,debug:s.a,criteo:{fastBidVersion:"latest"},rubicon:{singleRequest:!0},userSync:{userIds:v,iframeEnabled:!0,pixelEnabled:!0,syncEnabled:!0,filterSettings:{all:{bidders:"*",filter:"include"}},syncDelay:3e3,auctionDelay:m,aliasSyncEnabled:!0},currency:f.default,cache:{url:"https://prebid.adnxs.com/pbc/v1/cache"}};return p&&(w.s2sConfig=[{accountId:"1",bidders:d.map(e=>e.bidder),adapter:"prebidServer",enabled:!0,endpoint:{p1Consent:Object(n.a)("https://pbs.prd.audiencerun.com/openrtb2/auction"),noP1Consent:Object(n.a)("https://pbs.prd.audiencerun.com/openrtb2/auction")},syncEndpoint:{p1Consent:Object(n.a)("https://pbs.prd.audiencerun.com/cookie_sync"),noP1Consent:Object(n.a)("https://pbs.prd.audiencerun.com/cookie_sync")},syncTimeout:2e3,coopSync:!1,timeout:b,extPrebid:{cache:{vastxml:{returnCreative:!0}},origreferrer:i.document.referrer},allowUnknownBidderCodes:!1,testing:!0,bidderControl:j(d)}]),h&&(w.schain={validation:"strict",config:{ver:"1.0",complete:1,nodes:[{asi:"audiencerun.com",sid:h,hp:1}]}}),(c||Object(o.c)(i.__tcfapi))&&(w.consentManagement=g),w},k=e=>{const t={schain:{config:{nodes:[{asi:"audiencerun.com",sid:e.affiliateId,hp:1}]}}};return[{bidders:["improvedigital","sharethrough","rubicon","pubmatic"],config:{schain:{validation:"strict",config:{ver:"1.0",complete:1,nodes:[...t.schain.config.nodes,h]}}}},{bidders:["smartadserver"],config:{schain:{validation:"strict",config:{ver:"1.0",complete:1,nodes:[...t.schain.config.nodes,c]}}}},{bidders:["criteo"],config:{schain:{validation:"strict",config:{ver:"1.0",complete:1,nodes:[...t.schain.config.nodes,c]}},ortb2:{site:{publisher:{id:"1FP34J"}}}}},{bidders:["oftmedia"],config:{schain:{validation:"relaxed",config:{ver:"1.0",complete:1,nodes:[...t.schain.config.nodes,c,{asi:"152media.info",sid:"152M66",hp:1}]}}}}]}},function(e,t,i){"use strict";i.d(t,"a",(function(){return D}));var s=i(2),n=i(16),r=i(21),a=i(3);class o{constructor(e){switch(this.oData=e,this.assets=this.oData.assets,this.version=""+e.ver,this.img=null,this.width=null,this.height=null,this.imgWidth=null,this.imgHeight=null,this.imgSquare=null,this.imgSquareWidth=null,this.imgSquareHeight=null,this.iframeWidth=null,this.iframeHeight=null,this.title=null,this.link=null,this.linkFinal=null,this.description=null,this.source=null,this.linkSource=null,this.imptrackers=null,this.jstrackers=null,this.jsContent=null,this.cta=null,this.vm=null,this.privacy=null,this.clickLink=null,this.pix_delay=0,this.sourcePosition=e.sourcePosition||"bottom",this.imgBannerRatio=e.imgBannerRatio||"1.91:1",this.adType="native",this.viewId=Object(a.a)(e,"ext.viewId",0),this.version){case"1.1":this.setV1();break;case"banner":this.setBanner()}}setV1(){this.link=this.oData.link,this.imptrackers=this.oData.imptrackers,this.jstrackers=this.oData.jstracker,this.vm=parseInt(this.oData.vm,10),void 0!==this.oData.ext&&(this.linkFinal=this.oData.ext.linkFinal||null,this.bidderCode=this.oData.ext.bidderCode||null,this.adType=this.oData.ext.adType||"native"),void 0!==this.oData.cl&&(this.clickLink=this.oData.cl||null),void 0!==this.oData.del&&(this.pix_delay=this.oData.del||0),this.assets&&this.assets.forEach(e=>{this.setAsset(e)})}setBanner(){this.adType=this.oData.adType||"banner",this.iframeWidth=parseInt(this.oData.w,10),this.iframeHeight=parseInt(this.oData.h,10),this.width=parseInt(this.oData.w,10),this.height=parseInt(this.oData.h,10),this.jsContent=this.oData.adm}setImg(e){void 0!==e.ext&&void 0!==e.ext.ratio&&"1:1"===e.ext.ratio?(this.imgSquare=e.url,this.imgSquareWidth=parseInt(e.w,10)||300,this.imgSquareHeight=parseInt(e.h,10)||300):(this.img=e.url,this.imgWidth=parseInt(e.w,10)||382,this.imgHeight=parseInt(e.h,10)||200)}getImg(){return"1:1"===this.imgBannerRatio&&null!==this.imgSquare?{img:this.imgSquare,imgWidth:this.imgSquareWidth,imgHeight:this.imgHeight}:{img:this.img,imgWidth:this.imgWidth,imgHeight:this.imgHeight}}setAsset(e){if(void 0!==e.img&&this.setImg(e.img),void 0!==e.title&&(this.title=e.title.text),void 0!==e.data){const t=void 0!==e.data.label?e.data.label:"";switch(t){case"privacy":case"jsContent":case"source":case"cta":case"linkSource":this[t]=e.data.value;break;case"desc":this.description=e.data.value;break;case"iframeHeight":this[t]=e.data.value,this.height=e.data.value;break;case"iframeWidth":this[t]=e.data.value,this.width=e.data.value}}}getProperty(e){return this[e]||!1}getWidth(){return this.getProperty("width")||this.getProperty("imgWidth")||this.getProperty("iframeWidth")}getHeight(){return this.getProperty("height")||this.getProperty("imgHeight")||this.getProperty("iframeHeight")}}var d=i(18);class l{constructor(e,t,i){this.eVignette=null,this.lang=i.lang||"fr",this.logo=i.utils.logo,this.maxTitleLength=i.maxTitleLength||0,this.socialTemplate=i.socialTemplate||!1,this.dataBanner=e;const s=i.device;switch(t){case"textBlockRight-extended":this.eVignette=this.extended(e,s);break;case"display":this.eVignette=this.display(e);break;case"textBlockLeft-extended":this.eVignette=this.extended(e,s,"block-text-left");break;case"textBlockRight-header":case"textBlockRight-arrow":this.eVignette=this.arrowDesign(e);break;case"textBlockLeft-header":case"textBlockLeft-arrow":this.eVignette=this.arrowDesign(e,"block-text-left");break;case"textInImg":this.eVignette=this.textInImage(e);break;case"textAndSourceInImg":this.eVignette=this.textInImage(e,!0);break;case"textBlockLeft":this.eVignette=this.base(e,"block-text-left");break;case"textBlockRight":this.eVignette=this.base(e,"block-text-right");break;case"footerMini":this.eVignette=this.base(e,"footerMini");break;default:this.eVignette=this.base(e)}return this}getVignette(){return this.eVignette}base(e,t=""){const i=document.createElement("li"),s=document.createElement("p"),n=document.createElement("div"),r=e.getProperty("linkFinal"),a=e.getProperty("description"),o=this.addSource(e,r,"s-name");""!==t&&(i.className=t);const d=this.addImg(e),l=this.addLink(e.getProperty("link"),{target:"_blank",rel:"nofollow",className:"a-img-block"},r);if(this.socialTemplate&&!1!==a&&(n.classList.add("description"),n.innerHTML=a,l.appendChild(n)),l.appendChild(d),i.appendChild(l),e.getProperty("privacy")){const t=this.addPrivacy(e.getProperty("privacy"));l.appendChild(t)}const c=this.addTitle(e,r);return"top"===e.sourcePosition&&s.appendChild(o),s.appendChild(c),"bottom"===e.sourcePosition&&s.appendChild(o),i.appendChild(s),this.setPixelClickEvent(i,e),i}display(e){const t=document.createElement("div"),i=this.addImg(e),s=this.addLink(e.getProperty("link"),{target:"_blank",rel:"nofollow"},e.getProperty("linkFinal"));return t.style.textAlign="center",t.style.marginBottom="5px",s.appendChild(i),t.appendChild(s),t}arrowDesign(e,t=""){const i=e.getProperty("imgWidth")?e.getProperty("imgWidth"):382,s=e.getProperty("imgHeight")?e.getProperty("imgHeight"):200;let n=null;switch(i+"x"+s){case"320x50":n=this.arrowDesign320x50(e,t);break;case"382x200":n=this.arrowDesign382x200(e,t);break;case"728x90":n=this.arrowDesign728x90(e,t);break;default:throw new Error("Image avec un ratio incorrect ("+i+"x"+s+")")}if(null===n)throw new Error("Echec création template arrowDesign");return n}arrowDesign382x200(e,t){const i=document.createElement("li"),s=document.createElement("div"),n=document.createElement("div"),r=e.getProperty("linkFinal"),a=this.addSource(e,r,"",!0);""!==(t=void 0!==t?t:"")&&(i.className=t);const o=this.addImg(e);s.className="middle-block";const d=this.addLink(e.getProperty("link"),{target:"_blank",rel:"nofollow",className:"a-img-block"},r);if(d.appendChild(o),i.appendChild(d),e.getProperty("privacy")){const t=this.addPrivacy(e.getProperty("privacy"));d.appendChild(t)}const l=this.addLink(e.getProperty("link"),{target:"_blank",rel:"nofollow",innerHTML:e.getProperty("title")},r);"top"===e.sourcePosition&&n.appendChild(a),n.appendChild(l),"bottom"===e.sourcePosition&&n.appendChild(a),s.appendChild(n),i.appendChild(s);const c=this.addLink(e.getProperty("link"),{target:"_blank",rel:"nofollow",className:"arrow-link",innerHTML:'arrow'},r);return i.appendChild(c),this.setPixelClickEvent(i,e),i}arrowDesign728x90(e,t){const i=document.createElement("li"),s=e.getProperty("linkFinal");""!==(t=void 0!==t?t:"")&&(i.className=t);const n=this.addImg(e),r=this.addLink(e.getProperty("link"),{target:"_blank",rel:"nofollow",className:"a-img-block"},s);if(r.appendChild(n),e.getProperty("privacy")){const t=this.addPrivacy(e.getProperty("privacy"));r.appendChild(t)}return i.appendChild(r),this.setPixelClickEvent(i,e),i}arrowDesign320x50(e,t){const i=document.createElement("li"),s=this.addImg(e),n=e.getProperty("linkFinal");i.className="only-img";const r=this.addLink(e.getProperty("link"),{target:"_blank",rel:"nofollow"},n);return r.appendChild(s),i.appendChild(r),this.setPixelClickEvent(i,e),i}extended(e,t,i=""){const s=document.createElement("li"),n=document.createElement("p"),r=document.createElement("div"),a=document.createElement("div"),o=document.createElement("div"),d=document.createElement("div"),l=e.getProperty("linkFinal");let c="extended ";"mobile"===t&&(c="extended-mobile "),s.className=""!==i?c+i:c;const h=this.addImg(e),p=this.addLink(e.getProperty("link"),{target:"_blank",rel:"nofollow",className:"a-img-block-ext"},l);if(p.appendChild(h),o.appendChild(p),e.getProperty("privacy")){const t=this.addPrivacy(e.getProperty("privacy"));p.appendChild(t)}n.appendChild(this.addLogo());const u=this.addLink(e.getProperty("link"),{target:"_blank",rel:"nofollow",className:"banner-title",innerHTML:e.getProperty("title")},l);if(n.appendChild(u),e.getProperty("description")){const t=this.addLink(e.getProperty("link"),{target:"_blank",rel:"nofollow",className:"banner-desc",innerHTML:e.getProperty("description")},l);n.appendChild(t)}if(r.className="hide-overflow",r.appendChild(n),a.appendChild(r),d.appendChild(this.addPowerBy(e,l)),!1!==e.getProperty("cta")){const t=this.addLink(e.getProperty("link"),{target:"_blank",rel:"nofollow",className:"cta",innerHTML:e.getProperty("cta")},l);d.appendChild(t)}return a.className="native-desc",d.className="cta-power-by",a.appendChild(d),o.appendChild(a),s.appendChild(o),this.setPixelClickEvent(r,e),s}textInImage(e,t=!1){const i=document.createElement("li"),s=document.createElement("p"),n=e.getProperty("linkFinal"),r=this.addImg(e);let a="";a=t?"a-img-block with-src":"a-img-block";const o=this.addLink(e.getProperty("link"),{target:"_blank",rel:"nofollow",className:a},n);if(o.appendChild(r),i.appendChild(o),e.getProperty("privacy")){const t=this.addPrivacy(e.getProperty("privacy"));o.appendChild(t)}const d=document.createElement("div");d.className="tinimg-bg",o.appendChild(d);let l=e.getProperty("title");const c=e.getProperty("source")?55:90;l.length>c&&(l=l.substr(0,c)+" ...");const h=document.createElement("p");h.className=e.getProperty("source")?"tinimg":"tinimg-nosrc",h.innerHTML=l,h.title=e.getProperty("title"),o.appendChild(h);const p=this.addSource(e,n);return t?e.getProperty("source")&&o.appendChild(p):(s.appendChild(p),i.appendChild(s)),this.setPixelClickEvent(i,e),i}generateLinkFinal(e,t,i){e.href=i;const s=this.dataBanner.clickLink||t;let n=!1;return e.onmousedown=function(){n=!0,this.href=t},e.onmouseleave=function(){n=!1,this.href=t},e.onmouseover=function(){n=!0,this.href=i},e.addEventListener("contextmenu",(function(){n&&(this.href=s.replace("%26ndr%3D1",""))})),e}setPixelClickEvent(e,t){if(t.clickLink){const i=t.pix_delay,s=(e="click")=>{setTimeout(()=>{Object(d.c)(t.clickLink)},i)};e.onclick=function(e){1!==e.button&&s("click")},e.onmousedown=function(e){1===e.button&&s("onauxclick")}}}addPrivacy(e){const t=document.createElement("img");t.src=e.img,t.className="privacy-logo";const i=this.addLink(e.url,{target:"_blank",rel:"nofollow",className:"privacy-link"},!1);return i.appendChild(t),i}addLogo(){const e=document.createElement("img");let t="";switch(e.src=this.logo,e.className="regie-logo",this.lang){case"es":case"co":case"it":case"en":case"pt":case"br":default:t="https://www.audiencerun.com"}const i=this.addLink(t,{target:"_blank",rel:"nofollow",className:"regie-link"},!1);return i.appendChild(e),i}addSource(e,t,i="",s=!1){const n=e.getProperty("linkSource")||e.getProperty("link"),r=e.getProperty("source")?e.getProperty("source"):"",a=document.createElement("span"),o=this.addLink(n,{target:"_blank",rel:"nofollow",innerHTML:r},t);return""!==i&&(a.className=i),a.appendChild(o),s?o:a}addLink(e,t,i){let s=document.createElement("a");s.dataset.link=e,s.href=e;for(const e in t)s[e]=t[e];return!1!==i&&(s=this.generateLinkFinal(s,e,i)),s}addPowerBy(e,t){const i=e.getProperty("linkSource")||e.getProperty("link"),s=e.getProperty("source")?e.getProperty("source"):"",n=this.addLink(i,{target:"_blank",rel:"nofollow",innerHTML:s},t),r=document.createElement("span"),a=this.powerByHtml();return r.className="power-by-extended",r.innerHTML=a,r.appendChild(n),r}getUrlImg(e){let t=e.getImg().img;return e.getProperty("imgHeight")>200&&"1:1"!==e.getProperty("imgBannerRatio")&&(t="//a.qwertize.com/i/s/?u="+encodeURIComponent(t)),t}addImg(e,t=!1){const i=document.createElement("img"),n=this.getUrlImg(e),r=this;return i.src=n,i.alt=e.getProperty("title")||"audiencerun",i.className="1:1"===e.getProperty("imgBannerRatio")?"square-img-banner":"",e.getProperty("imgHeight")>200&&"1:1"!==e.getProperty("imgBannerRatio")&&(i.style.width=Math.round(2e4/e.getProperty("imgHeight"))+"%",i.style.display="block",i.style.margin="auto"),i.onerror=()=>{if(void 0!==i.parentNode){const a=()=>{const t=i.parentNode.getBoundingClientRect().width,s=100*t/e.getProperty("imgWidth"),n=Math.floor(e.getProperty("imgHeight")*s/100)-2,r=document.createElement("div"),a=document.createElement("div"),o=document.createElement("div"),d=document.createElement("div");r.className="spinner-wait",r.style.width=t-2+"px",r.style.height=n+"px",a.className="bounce1",o.className="bounce2",d.className="bounce3",r.appendChild(a),r.appendChild(o),r.appendChild(d),i.parentNode.appendChild(r),i.remove()};if(n.indexOf("a.cdn3.net")>=0)if(t)Object(s.h)(new Error("Impossible de charger image (4): "+n)),a();else{const t=new Image;t.onerror=()=>{Object(s.h)(new Error("Impossible de charger image (1): "+n)),a()},t.onload=()=>{const t=r.addImg(e,!0);i.parentNode.appendChild(t),i.remove()},t.src="https://a.cdn3.net/medias/u/36616.png"}else Object(s.h)(new Error("Impossible de charger image (3): "+n)),a()}},i.removeAttribute("width"),i.removeAttribute("height"),i}powerByHtml(){let e="";switch(this.lang){case"es":case"co":case"it":default:e="Ads by "}return e}addTitle(e,t){let i=e.getProperty("title");const s=this.maxTitleLength;return i.length>s&&0!==s&&(i=i.slice(0,s)+"..."),this.addLink(e.getProperty("link"),{target:"_blank",rel:"nofollow",innerHTML:i},t)}}var c=i(24),h=i(5);class p{constructor(e){this.oData=e,this.version=this.oData.ver,this.assets=this.oData.assets,this.video=this.oData.video,this.params={},this.width=0,this.height=0,this.title=null,this.description=null,this.link=null,this.linkSource=null,this.source=null,this.jsContent=null,this.imptrackers=null,this.jstrackers=null,this.clickLink=null,this.vastXml=null,this.vastUrl=null,this.jsContent=this.getAssetByLabel("jsContent"),this.setBannerProperties()}setBannerProperties(){if(this.jsContent=this.getAssetByLabel("jsContent"),this.source=this.getSource(this.jsContent)||"dailymotion",this.video={...this.video,outstream:!0,source:this.source,context:"oustream",ssp:Object(a.a)(this.oData,"ext.bidderCode","none"),guid:Object(a.a)(this.oData,"ext.guid","none"),cpm:Object(a.a)(this.oData,"ext.cpm","none"),zoneHitId:Object(a.a)(this.oData,"ext.zoneHitId","none"),viewId:Object(a.a)(this.oData,"ext.viewId","none")},"dailymotion"===this.source)return;void 0!==this.oData.cl&&(this.clickLink=this.oData.cl||null),this.assets.forEach(e=>{this.setAsset(e)}),this.link=this.oData.link,this.imptrackers=this.oData.imptrackers,this.jstrackers=this.oData.jstracker,this.width=this.oData.width,this.height=this.oData.height;const{vastXml:e,vastUrl:t}=this.getVast();"outstream"===this.source?(this.oData.ext&&this.oData.ext.hb_adid&&(this.video.id=this.oData.ext.hb_adid),this.video.platform="arunplayer",this.video.vastXml=e,this.video.vastUrl=t,this.vastXml=e,this.vastUrl=t):"prebid"===this.source&&(this.video.platform="prebid",this.vastXml=this.jsContent,this.video.vastXml=this.jsContent)}setAsset(e){if(void 0!==e.title&&(this.title=e.title.text),void 0!==e.data){const t=void 0!==e.data.label?e.data.label:"";switch(t){case"privacy":case"source":case"linkSource":this[t]=e.data.value;break;case"desc":this.description=e.data.value}}}getAssetByLabel(e){if(!e)return null;const t=Object(h.c)(this.assets,t=>t.data&&t.data.label===e);return t&&t.data&&t.data.value}getProperty(e,t=!1){return this[e]||t}getWidth(){return this.getProperty("width",0)}getHeight(){return this.getProperty("height",0)}getSource(){return Object(c.m)(this.jsContent)||Object(c.l)(this.jsContent)?"outstream":Object(c.j)(this.jsContent)?"prebid":""}getVast(){return{...Object(c.m)(this.jsContent)?{vastXml:this.jsContent}:{},...Object(c.l)(this.jsContent)?{vastUrl:this.jsContent}:{}}}}var u=i(17),b=i(1),m=i(0),g=i(12),f=i(20);const v=e=>{if(!Object(m.b)(e))return e;try{return{name:null!=e.name?e.name:"unknown",message:null!=e.message?e.message:"unknown",stack:null!=e.stack?e.stack:""}}catch(t){return e}};var w=i(11),y=i(6);const O=["arunplayer"],j=-1,_=0,k=1,x=["ready","error","destroy","loaded","start","skip","complete","allAdsCompleted","adProgress","click","pause"],A="An error occurred during player process.",C={3e3:"Player has not started after 30000ms timeout",3001:"Cannot get player instance after 10000ms timeout",3006:"Ad script could not be loaded",3008:"An error occurred during player process",3009:"Video ad marked as skipped or complete but player has not started at all",3010:"Video ad duration exceeded the maximum of 60000ms"},B=Object.keys(C),I=/^AdError (\d{1,4}):(.+)/;let T,P;class R{constructor(e,t){T=t,this.platform=e.platform||"none",s.a&&(P=`Mode "${T.oOptions.mode}" for script_key "${T.oOptions.key}" / Video class => ${this.platform} => `),this.id=e.id,this.vastXml=e.vastXml,this.vastUrl=e.vastUrl,this.vast={...this.vastXml?{content:this.vastXml,type:"XML"}:{},...this.vastUrl?{content:this.vastUrl,type:"URL"}:{}},this.ssp=e.ssp||"none",this.guid=e.guid,this.cpm=parseFloat(e.cpm).toFixed(4),this.zoneHitId=e.zoneHitId,this.viewId=e.viewId,this.size="mobile"===T.device||T.mobileMode?"slide"===T.oOptions.mode?[204,115]:[249,140]:[416,235],this.impressionPixels=e.impressionPixels||[],this.player={},this.deferLoad=e.deferLoad||T.deferVideoLoad||!1,this.initialized=!1,this.state=j,this.startTime=0,this.currentTime=0,this.duration=0,this.deferLoad||this.init()}get instance(){return this.player||Object(a.a)(T,"utils.window.__ARUN_PLAYER__.instances."+this.id,null)}init(e){if(!this.initialized)try{this.initialized=!0;const t=this.platform.toLowerCase();if(-1===O.indexOf(t))throw new Error(`Video - init() - ${t} video platform is not available in our list.`);if("arunplayer"===t){if(!this.id||Object(b.e)(this.vast))throw new Error("Video - init() - Missing player video properties.");this.preloadImaSdk(),this.loadPlayer(()=>{this.initPlayer(),Object(m.c)(e)&&e()},e=>{this.handleError(e)})}}catch(e){this.handleError(e)}}initPlayer(){try{setTimeout(()=>{try{this.player=new T.utils.window.__ARUN_PLAYER__("#"+this.id,{ads:{src:this.vast.content,debug:s.a},width:this.size[0],height:this.size[1]})}catch(e){this.handleError(e)}},0)}catch(e){this.handleError(e)}}preloadImaSdk(){const e="https://imasdk.googleapis.com/js/sdkloader/"+(s.b?"ima3_debug.js":"ima3.js");if(T.utils.document.querySelector("link[href='"+e+"'][rel='preload']"))return;const t=T.utils.document.createElement("link");t.href=e,t.rel="preload",t.as="script",T.utils.document.head.appendChild(t)}loadPlayer(e,t){if(T.utils.window.__ARUN_PLAYER__)return void(Object(m.c)(e)&&e());let i;i=s.b?"https://prebid.local.dev.blackcover.fr:9001/js/player.js?1658407711680":s.a?"https://ad.aruncdn.com/develop/f/native/player.js?3":"https://ac.aruncdn.com/f/nat/player.js?3",Object(g.b)(i,e,t,T.utils.window)}attachEvents(e={}){const t=Object(h.e)([...Object.keys(e),...x],x);if(t.length)throw new Error("Invalid events submitted: "+t.join(", "));const i=e=>{try{u.a.set("isVideoPlaying",!0),u.a.set("videoRendered",!0),this.startTime=this.startTime||Object(y.d)(),this.state=k,this.impressionPixels.forEach(e=>{Object(d.c)(e)}),Object(m.c)(e)&&e()}catch(e){this.handleError(e)}},n=e=>{try{if(this.state===j)throw new Error("Video ad marked as skipped or complete but player has not started at all.");Object(m.c)(e)&&e()}catch(e){this.handleError(e)}finally{u.a.set("isVideoPlaying",!1),u.a.set("videoRendered",!1)}},r={start:()=>{i(e.start)},complete:()=>{n(e.complete)},skip:()=>{n(e.skip)},error:e=>{this.handleError(e)},allAdsCompleted:()=>{n(e.allAdsCompleted)},adProgress:()=>{if(this.startTime=this.startTime||Object(y.d)(),this.currentTime=Object(y.d)(),this.duration=Math.floor(this.currentTime-this.startTime)+1e3,this.duration>6e4&&this.state===k){const e="Video ad duration exceeded the maximum of 60000ms.";Object(m.c)(this.onError)&&this.onError(new Error(e))}}};Object.keys(r).forEach(e=>{this.player.on(e,t=>{try{Object(m.c)(r[e])&&r[e](t)}catch(e){Object(s.h)(e)}})})}destroy(){if(this.state!==_&&this.instance)try{u.a.set("isVideoPlaying",!1),u.a.set("videoRendered",!1),u.a.set("isPlayerProcessing",!1),this.state=_,Object(a.a)(this.player,"destroy")&&Object(m.c)(this.player.destroy)&&this.player.destroy();const e=T.utils.document.querySelector("[data-player-id='"+this.id+"']");e&&e.parentNode&&e.parentNode.removeChild(e)}catch(e){this.handleError(e)}finally{delete this.instance}}onPlayerReady(e){const t=setTimeout(()=>{try{if(this.state===j)throw clearTimeout(t),new Error("Player has not started after 30000ms timeout.")}catch(e){clearTimeout(t),this.handleError(e)}},3e4);let i=0;const s=setInterval(()=>{i+=1;try{if(50*i>1e4)throw new Error("Cannot get player instance after 10000ms timeout.");!Object(b.e)(this.player)&&this.player instanceof T.utils.window.__ARUN_PLAYER__&&(clearInterval(s),u.a.set("isPlayerProcessing",!0),Object(m.c)(e)&&e(this))}catch(e){clearInterval(s),clearTimeout(t),this.handleError(e)}},50)}playAd(){this.state!==k&&setTimeout(()=>{try{this.player.init()}catch(e){this.handleError(e)}},0)}resizeAd(e,t){try{this.instance.ads.resize(e,t)}catch(e){this.handleError(e)}}getPlayerState(){return this.state}getErrorObject(e){const t=(e=>{const t=v(e);return null==t?"(unknown error)":Object(m.h)(t)?t:Object(m.f)(t)&&null!=t.message?t.message:Object(a.i)(t)})(e),i=I.exec(t);if(null!=i)return{errorCode:i[1],errorMessage:(i[2]||t).trim()};const s=Object(h.c)(B,e=>-1!==t.indexOf(C[e]));return s?{errorCode:s,errorMessage:t}:{errorCode:3008,errorMessage:A}}handleError(e){try{!Object(m.b)(e)&&Object(a.a)(e,"details")?this.createErrorLog(e.details):this.createErrorLog(e)}catch(e){this.createErrorLog(e)}finally{u.a.set("isVideoPlaying",!1),u.a.set("videoRendered",!1),u.a.set("isPlayerProcessing",!1),Object(m.c)(this.onError)&&this.onError(e)}}logPrebidMetricsError(e){const t=Object(n.a)("https://d.audiencerun.com/pme");if(!s.b&&t)try{Object(f.a)({url:t,method:"POST",withCredentials:!0,headers:{"Content-type":"application/javascript"},body:Object(a.i)(e)})}catch(e){Object(s.h)(e)}}logError(e){Object(s.i)(e),Object(s.h)("Player Error: "+e.message)}createErrorLog(e){try{const t=v(e),{message:i=A}=t,{errorCode:s,errorMessage:n}=this.getErrorObject(i),r={errorMessage:n,errorCode:parseInt(s,10),impressionId:parseInt(this.viewId,10),guid:this.guid,bidderWinner:this.ssp,cpm:this.cpm,zoneHitId:this.zoneHitId},o={message:i,context:"arunplayer",error:t,key:T.oOptions.key,mode:T.oOptions.mode,ssp:this.ssp,vast:this.vast,state:this.state,imaSdkLoaded:Boolean(Object(a.a)(T,"utils.window.google.ima")),documentHidden:Boolean(T.utils.document.hidden),cpus:Object(w.a)(),network:Object(w.d)()};this.logPrebidMetricsError(r),this.logError(o)}catch(e){Object(s.h)(e)}}}var E=i(22);class M{constructor(e,t,i=null){this.nativeAd=e,this.debugTitle=`Mode "${this.nativeAd.oOptions.mode}" for script_key "${this.nativeAd.oOptions.key}" / class "banners" => `,this.oBanner=t,e.templateNew&&void 0!==e.templateNew[e.utils.sDevice]?this.oBanner.template=e.templateNew[e.utils.sDevice]:this.oBanner.template=e.template||"base",null!==i&&(this.oBanner.template=i),this.bannerType="",this.oBanner.imgBannerRatio=t.imgBannerRatio||"1.91:1",this.oBanner.api={}}addTracking(e,t,i){const s=e.getProperty("bidderCode")?0:e.getProperty("vm");return"object"==typeof e.getProperty("imptrackers")&&e.getProperty("imptrackers").forEach(e=>{this.addTrackingImg(s,e,i)}),"object"==typeof e.getProperty("jstrackers")&&e.getProperty("jstrackers").forEach(e=>{this.addTrackingJS(s,e,i,t)}),"rtb"===this.bannerType&&void 0!==e.clickLink&&null!==e.clickLink&&(this.isOverAds=!1,this.clickLink=e.clickLink,-1!==this.nativeAd.currentDomainName.indexOf("justacote.com")?t.addEventListener("mouseenter",()=>{this.nativeAd.utils.window.focus(),this.isOverAds=!0}):(this.nativeAd.utils.window.focus(),t.addEventListener("mouseenter",()=>{this.isOverAds=!0})),t.addEventListener("mouseleave",()=>{this.isOverAds=!1}),this.nativeAd.utils.window.addEventListener("blur",()=>{this.sendPixelClick()})),t}sendPixelClick(){this.isOverAds&&Object(d.c)(this.clickLink),this.rightClicked=!1}addTrackingJS(e,t,i,s){if(e)void 0===this.nativeAd.pixelJsList[i]&&(this.nativeAd.pixelJsList[i]=[]),this.nativeAd.pixelJsList[i].push(t);else{const e=document.createElement("script");e.type="text/javascript",e.innerHTML=t,s.appendChild(e)}}addTrackingImg(e,t,i){e?(void 0===this.nativeAd.pixelImgList[i]&&(this.nativeAd.pixelImgList[i]=[]),this.nativeAd.pixelImgList[i].push(t)):"video"!==this.oBanner.adType&&Object(d.c)(t)}create(e,t="li"){return void 0!==this.oBanner.video||void 0!==this.oBanner.ext&&"video"===this.oBanner.ext.adType?this.createVideoBanner(e):this.createIabBanner(e,t)}createIabBanner(e,t){const i=new o(this.oBanner);let s=null;if(i.getProperty("img"))this.nativeAd.iNbBan++,s=this.createVignetteImg(e,i);else{if(!i.getProperty("jsContent"))return null;this.nativeAd.iNbBan++,s=this.createVignetteJs(e,i,t)}return s}createVideoBanner(e){const t=new p(this.oBanner);let i=null;return t.getProperty("video")?(this.nativeAd.iNbBan++,i="outstream"===t.source&&(t.vastXml||t.vastUrl)?this.createVignetteVideoOutstream(e,t):"prebid"===t.source&&t.vastXml?this.createVignetteVideoPrebid(e,t):this.createVignetteVideo(e,t),i):null}isSessionStorageEnabled(){try{const e="__mstorage__test";return window.sessionStorage.setItem(e,null),window.sessionStorage.removeItem(e),!0}catch(e){return!1}}injectBannersCounter(e){let t=1;if(this.isSessionStorageEnabled()){const e="__ARUN___c"+this.nativeAd.oOptions.iabDims,i="__ARUN___t"+this.nativeAd.oOptions.iabDims;t=parseInt(this.nativeAd.utils.topWindow.sessionStorage.getItem(i),10){try{if(t+=1,t>1)return void clearInterval(i);try{l.contentDocument&&l.contentDocument.document?e=l.contentDocument.document:l.contentDocument?e=l.contentDocument:l.contentWindow&&(e=l.contentWindow.document)}catch(e){l.src="data:text/html;charset=utf-8,"+encodeURIComponent(h),clearInterval(i),Object(s.i)(Object(a.i)({content:h,src:l.src,err:e,srcDocA:c,href:window.location.href,standalone:window.navigator.standalone})),Object(s.h)("INJECT_JS: iframe.src",!1)}e&&(clearInterval(i),e.open("text/html","replace"),e.write(""+h),e.close())}catch(e){Object(s.h)(e),clearInterval(i)}},30)}return l.addEventListener("load",()=>{!1===u.a.isLoadedBanner&&u.a.set("isLoadedBanner",!0)},!1),o.appendChild(l),(s.a||this.nativeAd.allowAdReport)&&this.addReportElements(o,t,p),o=this.addTracking(t,o,this.nativeAd.iNbBan),o.setAttribute("data-id",this.nativeAd.iNbBan),d&&o.classList.add("li-rtb"),e.nbBan++,o}addReportElements(e,t,i={}){try{const n=t.iframeWidth||t.width||0,r=t.iframeHeight||t.height||0,o={...i,reportId:Object(b.b)()};let d=null,l=!1;const c=this.nativeAd.utils.document.createElement("button");c.className="report-this-ad",c.innerHTML="Report this ad";const h=this.nativeAd.utils.document.createElement("div");h.className="report-this-ad-overlay",h.style.cssText+=`width:${n}px;height:${r}px;`,c.addEventListener("click",()=>{Object(b.g)(d)&&(e.setAttribute("data-report-overlay-visible",!0),h.innerHTML="REPORT-ID: "+o.reportId,l||(Object(s.i)(Object(a.i)(o)),Object(s.h)("REPORT_AD: received a user report event.",!1),l=!0),d=setTimeout(()=>{try{e.removeAttribute("data-report-overlay-visible"),d=null}catch(e){Object(s.h)(e)}},5e3))}),e.appendChild(c),e.appendChild(h)}catch(e){Object(s.h)(e)}}validateJSContent(e,t,i={}){try{const t=[e,""+e,encodeURIComponent(e)],n=t.every(e=>!Object(b.e)(e)&&-1===["null","undefined","false"].indexOf(e)),r={...i,validator:t};n||(Object(s.i)(Object(a.i)(r)),Object(s.h)("INVALID_JS_CONTENT: received an invalid content.",!1))}catch(e){Object(s.h)(e)}}createVignetteImg(e,t){let i=new l(t,this.oBanner.template,this.nativeAd).getVignette();return this.bannerType="native",i=this.addTracking(t,i,this.nativeAd.iNbBan),e.nbBan++,t.bidderCode&&i.setAttribute("data-bidder",t.bidderCode),i.setAttribute("data-id",this.nativeAd.iNbBan),i}createVignetteVideo(e,t){t.video.id=Object(b.c)();let i=document.createElement("li");const s=document.createElement("div");s.id=t.video.id,i.appendChild(s);const n=new R(t.video,this.nativeAd);return this.bannerType="video",this.oBanner.video=t.video,this.oBanner.api=n,i.className="video",i=this.addTracking(t,i,this.nativeAd.iNbBan),e.nbBan++,i.setAttribute("data-id",this.nativeAd.iNbBan),i}createVignetteVideoOutstream(e,t){this.bannerType="video";const i=Object(b.c)(),s={...t.video,id:i,impressionPixels:t.imptrackers};this.oBanner.video=s,this.oBanner.api=new R(s,this.nativeAd);const n=this.nativeAd.utils.document.createElement("li"),r=this.nativeAd.utils.document.createElement("div");return r.id=i,r.classList.add("arunplayer"),n.setAttribute("data-id",this.nativeAd.iNbBan),n.setAttribute("data-player-id",i),n.appendChild(r),e.nbBan++,n}createVignetteVideoPrebid(e,t){this.bannerType="videoPrebid",this.oBanner.video={...t.video,hb_adid:void 0!==this.oBanner.ext&&void 0!==this.oBanner.ext.hb_adid?this.oBanner.ext.hb_adid:null};let i=this.nativeAd.utils.document.createElement("li");const n=this.nativeAd.utils.document.createElement("div");return n.setAttribute("id",t.oData.containerId),i.appendChild(n),setTimeout(()=>{try{this.nativeAd.utils.window.paubjs.renderAd(n,this.oBanner.video.hb_adid)}catch(e){Object(s.h)(e)}},51),i=this.addTracking(t,i,this.nativeAd.iNbBan),i.setAttribute("data-id",this.nativeAd.iNbBan),i.classList.add("video"),e.nbBan++,i}}var U=i(32),L=i(4),S=i(10);const z=i(34).toString();class D{constructor(e){e=Object.assign(e,{z_hp:Object(d.b)({scriptKey:e.key,zoneHitId:e.zh,identifier:e.mode,caller:e.mode,preview:e.preview}),p_v:Object(d.a)({scriptKey:e.key,zoneHitId:e.zh,identifier:e.mode,caller:e.mode,preview:e.preview})}),s.a&&(this.debugTitle=`Mode "${e.mode}" for script_key "${e.key}" / class "NativeAd" => `),this.cssNative=z,this.oOptions=e,this.adserver=e.adserver,this.isGdprRequired=e.isGdprRequired,this.hitId=e.zh,this.utils=new s.d(e),this.currentDomainName=this.utils.currentDomainName,this.device=(()=>2===w.c()||this.utils.isTablet?"tablet":1===w.c()||this.utils.isMobile?"mobile":"desktop")(),this.orientation=(()=>[90,-90].some(e=>this.utils.window.orientation===e)?"landscape":"portrait")(),this.aVideoSizeAllowed=[],this.aBannerSourceAllowed=["rtb","native"],this.aBannerTypeAllowed=["native","banner","video"],this.bannerToUse=[],this.typeBannerUsed=[],this.typeBanner=null,this.container=null,this.elmUl=[],this.elmLi=[],this.nbCols=3,this.nbRows=2,this.isOpen=!1,this.closeAds=!1,this.closeByUser=!1,this.isLoaded=!1,this.aIsInVisible=[],this.bAdblockEnable=!1,this.iNbBan=0,this.isPixelViewSent=!1,this.printPixelSent=!1,this.pixelViewIsChecking=!1,this.specificPixelIsSend=[],this.pixelImgList=[],this.pixelJsList=[],this.maxBanner=this.nbCols*this.nbRows,this.video={},this.isPassbackCalled=!1,this.injectedBanners=[],this.deferVideoLoad=!1,this.os=w.e(),this.featureFlags={...this.utils.featureFlags},this._setupPublisherPage(),this.setAdOptions(),this.registerEvents()}get s2sOnly(){return(0===this.aFeeds.length||this.s2sForFirstBid)&&this.s2sBids.length>0}get canRefresh(){return!this.refreshOnAdVisible||Object(L.m)(this.container)&&this.visibleAds.some(e=>e.visible)&&this.canTimeVisibility}registerEvents(){this.utils.document.addEventListener("visibilitychange",()=>{this.onVisibilityChange()},!1)}checkValue(e,t){return void 0===e||""===e?t:"false"===e||"true"===e?"true"===e:e}init(e={}){const t=Object(b.a)(e.addStyleSheet,!0),i=Object(b.a)(e.responsiveData,!0),n=Object(b.a)(e.createContainer,!0),r=(Object(b.a)(e.classContainer,null),Object(b.a)(e.initAdblock,!0));if(this.utils.isCappingReached())return this.callSubAdFluxClosed(),!1;i&&this.initResponsiveData(),r&&this.initAdblock(),t&&this.utils.addStyleSheet(this.generateStyleSheet(this.oOptions)),n&&this.createContainer(),"undefined"==typeof IntersectionObserver&&s.d.prototype.addEvent(this.utils.window,"scroll",()=>{this.checkView()})}feedsBiddersAvailable(){return![this.aFeeds,this.s2sBids].every(b.e)}initAdblock(){}initResponsiveData(){let e=this.utils.sDevice;null!==this.aRowsCols&&(e=this.getDevicePrefix(e),void 0!==this.aRowsCols[this.sTypeEncart][e]?(this.nbRows=this.aRowsCols[this.sTypeEncart][e].rows,this.nbCols=this.aRowsCols[this.sTypeEncart][e].cols,this.maxBanner=this.nbCols*this.nbRows):Object(s.h)(new Error(`Config error - ${e} has no row/col set`))),null!==this.templateNew&&(e=this.utils.sDevice,this.template=this.templateNew[e])}getDevicePrefix(e){if("responsive"===this.sTypeEncart&&"desktop"===e){const t=this.utils.window.innerWidth||this.utils.window.document.body.clientWidth;e+=t>768?"-l":t<768&&t>350?"-m":"-s"}else if("mobile"===e||"tablet"===e){const t=this.utils.window.orientation;e+=90===t||-90===t?"-landscape":"-portrait"}return e}createTitle(){const e=this.mainTitle.match(/({try{this.sendAdViewTime(e,!1)}catch(e){Object(s.h)(e)}finally{clearTimeout(i)}},Object(y.c)(10-t)),r=setTimeout(()=>{try{this.sendAdViewTime(e,!1)}catch(e){Object(s.h)(e)}finally{clearTimeout(r)}},Object(y.c)(180-t));Object(L.o)(()=>{this.sendAdViewTime(e,!0)})}startAdTimer(e){this.metrics.formatVisibleFromStartTime||(this.metrics.formatVisibleFromStartTime=Object(y.d)()-this.metrics.startTime),e&&(e.visible=!0,Object(h.c)(this.visibleAds,t=>t.id===e.id||t.viewId===e.viewId)||this.visibleAds.push(e),null===e.timerId&&(e.timerId=setInterval(()=>{try{if(!e.visible||!this.canTimeVisibility)return;this.incrementVisibilityTiming(e)}catch(t){clearInterval(e.timerId),Object(s.h)(t)}},1e3)))}clearAdTimer(e){e&&(null!==e.timerId&&clearInterval(e.timerId),e.timerId=null,e.visible=!1)}handleAdVisibility(e,t){const i={id:e.getAttribute("data-id"),viewId:t.viewId,type:e.dataset.adType,node:e,time:0,visible:!1,timerId:null};Object(U.a)(i.node,(e,t,s)=>{s>.5?this.startAdTimer(i):this.clearAdTimer(i)})}incrementVisibilityTiming(e){e&&(e.time+=1,(0===this.lastIncrementTimestamp||Object(y.a)(Object(y.d)(),this.lastIncrementTimestamp)>=900)&&(this.lastIncrementTimestamp=Object(y.d)(),this.totalViewTime+=1),this.totalViewTime>=this.checkViewTimeout/1e3&&this.sendPixel(e.id))}onVisibilityChange(){this.utils.document.hidden?this.canTimeVisibility=!1:this.canTimeVisibility=!0}sendAdViewTime(e,t=!1){const i=(Object(a.b)(this.visibleAds)||[]).filter(Boolean),n=Object(a.f)(Object(h.h)(i,"viewId")).map(e=>e.reduce((e,t)=>({time:e.time+t.time,viewId:e.viewId}))),r=n.reduce((e,t)=>e+t.time,0);if(this.preview||0===this.totalViewTime||0===r||!i.length)return;const o={key:this.hitId,d:this.totalViewTime,c:n},d=Object(a.i)(o);if(Object(b.e)(o)||Object(a.f)(o).some(e=>!Object(m.e)(e)&&Object(b.e)(e))||Object(b.e)(d))return Object(s.i)(Object(a.i)({payload:o,data:d,ads:i,adsData:n,adsList:this.visibleAds,options:{mode:this.oOptions.mode,key:this.oOptions.key}})),void Object(s.h)(new Error("INVALID_PAYLOAD: Cannot make request through sendAdViewTime"));if(1!==s.b)if(t){if(navigator&&navigator.sendBeacon)try{navigator.sendBeacon(e,d)}catch(e){Object(s.h)(e)}}else Object(f.a)({url:e,method:"POST",withCredentials:!0,headers:{"Content-type":"text/plain;charset=UTF-8"},body:d})}addContent(e,t,i="1.91:1"){this.bannerToUse.forEach((s,n)=>{if(void 0!==t.startFrom&&null!==t.startFrom&&n=t.maxBan)return;if(n<=t.nbBan-1&&0!==t.nbBan)return;void 0===s.template&&(s.template=this.template),void 0===s.sourcePosition&&(s.sourcePosition=this.sourcePosition),s.imgBannerRatio=i;const r=new M(this,s),a=r.create(t,"li");null!==a&&(a.dataset.adType=s.adType,a.dataset.height=s.height,e.appendChild(a),this.elmLi.push(a),this.typeBannerUsed.push(r.bannerType),this.injectedBanners.push(s),this.video=r.oBanner.video,this.elmUl=e,this.handleAdVisibility(a,s))}),this.sendPrintPixel()}selectOnlyAllowedBanner(){this.bannerToUse=[],this.injectedBanners=[],this.selectOnlyAllowedIabBanner(),this.typeBanner=this.getTypeBannerUse()}getTypeBannerUse(){return this.bannerToUse.length?this.bannerToUse[0].adType:""}selectOnlyAllowedIabBanner(){let e=0;return this.iabBanners.forEach(t=>{const i=new o(t);t.adType=i.adType,t.width=i.getWidth(),t.height=i.getHeight(),t.viewId=i.viewId,-1!==["banner","native"].indexOf(i.adType)&&!1===this.isBannerSizeAllowed(i)||-1!==this.aBannerSourceAllowed.indexOf(i.bidderCode?"rtb":"native")&&-1!==this.aBannerTypeAllowed.indexOf(i.adType)&&(this.bannerToUse.push(t),e++)}),e}isBannerSizeAllowed(e=null){const t=e.getWidth(),i=e.getHeight();return-1!==this.aBannerSizeAllowed.indexOf(`${t}x${i}`)}isBannerTypeUsed(e){return-1!==this.typeBannerUsed.indexOf(e)}getBannerSizeUsed(){const e={width:1,height:1};return this.injectedBanners.length&&this.injectedBanners[0].height&&(e.width=this.injectedBanners[0].width,e.height=this.injectedBanners[0].height),e}injectContent(e=!0,t=null,i=!0){if(!0===this.isPassbackCalled)return;let s="";const n="_arun_"+this.key,r="_arun_"+this.msk,o=this.utils.topWindow[n],d=this.utils.topWindow[r];if(o&&(s=o.mode,this.msk&&o.cpmPassback>o.value&&o.passback))return void this.fetchPassback();if(this.msk&&Object(m.c)(Object(a.a)(d,"isOverTruncationFloor"))&&!d.isOverTruncationFloor(this.key,this.msk,s+' - nativeAd"'))return void(this.flux&&this.flux.clearRefreshInterval());if(i&&this.selectOnlyAllowedBanner(),t=t||this.container,this.bannerToUse.length<=0){if(this.isLoaded)return;return t.style.display="none",void this.fetchPassback()}const l=document.createElement("ul");t.appendChild(l);const c={nbBan:0,nbLoop:0,nbCols:this.nbCols,maxBan:this.maxBanner};if(this.addContent(l,c),this.onAdLoaded(),"bottom"===this.powerByPosition&&e&&void 0!==this.createPowerBy().nodeType){const e=this.createPowerBy();t.appendChild(e)}return l}initGlobals(){this.utils.window.__ARUN__=this.utils.window.__ARUN__||{},this.utils.window.__ARUN__.ads=this.utils.window.__ARUN__.ads||{},this.utils.window.__ARUN__.ads[this.oOptions.mode]=this.utils.window.__ARUN__.ads[this.oOptions.mode]||[];const e="_arun_"+this.key;this.utils.topWindow[e]=this.utils.topWindow[e]||{},this.utils.topWindow[e].fetchPassback=()=>this.fetchPassback(),this.utils.topWindow.__ARUN___metrics=this.utils.topWindow.__ARUN___metrics||{},this.metrics=this.utils.topWindow.__ARUN___metrics[this.oOptions.rid]||{},this.utils.topWindow.__ARUN___bidding_metrics=this.utils.topWindow.__ARUN___bidding_metrics||{},this.utils.topWindow.__ARUN___bidding_metrics[this.oOptions.rid]=this.utils.topWindow.__ARUN___bidding_metrics[this.oOptions.rid]||{},this.utils.topWindow.__ARUN___meta=this.utils.topWindow.__ARUN___meta||{},this.utils.topWindow.__ARUN___meta[this.oOptions.rid]=this.utils.topWindow.__ARUN___meta[this.oOptions.rid]||{},this.utils.topWindow.__ARUN___meta[this.oOptions.rid].mode=this.oOptions.mode}onAdLoaded(){this.isLoaded=!0,this.initGlobals();Object(h.c)(this.utils.window.__ARUN__.ads[this.oOptions.mode],e=>e.key===this.oOptions.key)||this.utils.window.__ARUN__.ads[this.oOptions.mode].push({key:this.oOptions.key,msk:Boolean(this.oOptions.msk),status:1}),this.metrics.formatContentLoadedFromStartTime||(this.metrics.formatContentLoadedFromStartTime=Object(y.d)()-this.metrics.startTime),Object(m.c)(Object(a.a)(this,"flux.updateBiddersFloor"))&&this.flux.updateBiddersFloor()}fetchPassback(){const e="_arun_"+this.key,t=this.utils.topWindow[e],i=(e,i="url")=>{if(Object(b.e)(e))return;let s;if("url"===i&&(s=document.createElement("script"),s.src=e),"iframe"===i&&this.msk&&t){if(document.querySelector("#smartag_passback_ads_"+t.key)){document.querySelector("#smartag_passback_ads_"+t.key);return void(this.isPassbackCalled=!0)}s=document.createElement("script"),s.setAttribute("type","text/javascript"),s.setAttribute("id","smartag_passback_ads_"+t.key),s.innerHTML=e}s.addEventListener("load",()=>{},!1),this.isPassbackCalled=!0,document.getElementsByTagName("body")[0].appendChild(s)};if(this.msk)return this.utils.window["_arun_"+this.key]&&(this.utils.window["_arun_"+this.key].callPassback=e=>{e===this.msk&&(""!==t.passback_code?i(t.passback_code,"iframe"):i(this.utils.call_pb,"url"))}),void(this.utils.window["_arun_"+this.msk]&&Object(m.c)(this.utils.window["_arun_"+this.msk].callPassback)&&this.utils.window["_arun_"+this.msk].callPassback(this.msk,"_arun_"+this.key));i(this.utils.call_pb,"url")}callSubAdFluxClosed(){if(this.msk){const e=this.msk,t="_arun_"+this.key,i="_arun_"+e;this.utils.topWindow[t]=this.utils.topWindow[t]||{},this.utils.topWindow[t].status=-1,this.utils.topWindow[i]&&this.utils.topWindow[i].subAdFluxClosed(e,t)}}callbackObserveView(e){const t=e[e.length-1],i=t.target.getAttribute("data-id");this.debugTitle,t.target.dataset.id,t.intersectionRatio;void 0===this.aIsInVisible[i]&&(this.aIsInVisible[i]=!1),t.intersectionRatio>.5?(this.aIsInVisible[i]=!0,setTimeout(()=>{try{this.aIsInVisible[i]&&this.sendPixel(i)}catch(e){Object(s.h)(e)}},this.checkViewTimeout)):this.aIsInVisible[i]=!1}checkView(){if(this.isPixelViewSent||""===this.utils.pixel_v)return!0;this.checkFirstBannerVisibility()&&!this.pixelViewIsChecking&&(this.pixelViewIsChecking=!0,setTimeout(()=>{try{this.pixelViewIsChecking=!1,this.checkFirstBannerVisibility()&&this.sendPixel()}catch(e){Object(s.h)(e)}},this.checkViewTimeout))}sendPixel(e=null){return!(!this.isPixelViewSent||null!==e)||(null!==e&&void 0!==this.specificPixelIsSend[e]||(this.isPixelViewSent||((new Image).src=this.utils.pixel_v,this.msk&&this.utils.window["_arun_"+this.msk]&&(this.utils.window["_arun_"+this.msk].callPixelView(this.oOptions.mode),this.utils.window["_arun_"+this.msk].insertAds()),this.utils.incrementCapping(),this.initAdViewRequests()),this.isPixelViewSent=!0,null!==e&&(this.specificPixelIsSend[e]=!0),null!==e&&void 0!==this.pixelImgList[e]?this.sendImgPixel(this.pixelImgList[e]):null===e&&this.pixelImgList.forEach(e=>{this.sendImgPixel(e)}),void(null!==e&&void 0!==this.pixelJsList[e]?this.sendJsPixel(this.pixelJsList[e]):null===e&&this.pixelJsList.forEach(e=>{this.sendJsPixel(e)}))))}sendPrintPixel(){this.printPixelSent||this.oOptions.z_hp&&(Object(d.c)(this.oOptions.z_hp),this.printPixelSent=!0,this.msk&&this.utils.window["_arun_"+this.msk]&&Object(m.c)(this.utils.window["_arun_"+this.msk].sendPrintPixel)&&this.utils.window["_arun_"+this.msk].sendPrintPixel(this.oOptions.mode))}sendImgPixel(e){e.forEach(e=>{(new Image).src=e})}sendJsPixel(e){e.forEach(e=>{const t=document.createElement("script");t.type="text/javascript",t.innerHTML=e,this.container.appendChild(t)})}checkFirstBannerVisibility(){const e=Math.max(this.utils.document.documentElement.clientHeight,this.utils.window.innerHeight),t=this.utils.document.querySelectorAll("."+this.utils.cssClassName+" ul li img")[0];if(void 0===t)return!1;const i=t.getBoundingClientRect(),s=i.height||t.height||0,n=i.bottom-Math.round(s/2)<0,r=i.top-e+Math.round(s/2)>=0;return!n&&!r}generateStyleSheet(e){let t=e.style||null,i=1;const n=e.styler||null,r=e.forceResp||s.d.prototype.isResponsive();void 0!==e.respAccepted&&(i=e.respAccepted),null!==this.styleNew&&void 0!==this.styleNew.desktop&&(t=this.styleNew.desktop);const a="."+this.utils.cssClassName;let o=this.replaceMacroStyleSheet(a,t);return null!==this.styleNew&&void 0!==this.styleNew.tablet&&"tablet"===this.utils.sDevice&&(o+=this.addSpecialStyle(this.styleNew.tablet,a,!1)),null!==this.styleNew&&void 0!==this.styleNew.mobile&&"mobile"===this.utils.sDevice&&(o+=this.addSpecialStyle(this.styleNew.mobile,a,!1)),r&&i&&(o+=this.addSpecialStyle(n,a,!0)),o}replaceMacroStyleSheet(e,t){let i=this.nbCols,s=this.nbCols,n=50,r=50;"desktop"!==this.utils.sDevice&&null!==this.aRowsCols&&(i=this.aRowsCols[this.sTypeEncart][this.utils.sDevice+"-portrait"].cols,s=this.aRowsCols[this.sTypeEncart][this.utils.sDevice+"-landscape"].cols,n=this.aRowsCols[this.sTypeEncart][this.utils.sDevice+"-portrait"].rows,r=this.aRowsCols[this.sTypeEncart][this.utils.sDevice+"-landscape"].rows);const a=(100-(i-1))/i,o=i+"n - "+(i-1),d=(100-(s-1))/s,l=s+"n - "+(s-1);let c=""+this.cssNative;return c=c.replace(/macro_url\(\"/g,'url("https://ac.aruncdn.com/f/nat/fonts').replaceAll("macro_url","url(https://ac.aruncdn.com/f/nat/fonts").replaceAll("macro_sprite_url","url(https://ac.aruncdn.com/f/nat/images/sprites.svg)").replaceAll("macro_arrow_url","url(https://ac.aruncdn.com/f/nat/images/arrow-transparent.svg)").replaceAll("macro_show_landscape","-n + "+s*r).replaceAll("-n + 1000","-n + "+s*r).replaceAll("macro_show_portrait","-n + "+n*i).replaceAll("-n + 2000","-n + "+n*i).replaceAll("macro_width_portrait",a).replaceAll("macro_nth_start_portrait",o).replaceAll("nth-child(100n - 0)","nth-child("+o+")").replaceAll("macro_width_landscape",d).replaceAll("macro_nth_start_landscape",l).replaceAll("nth-child(200n - 0)","nth-child("+l+")").replaceAll(".global-prefix-selector",".ar").replaceAll(".css-selector",e),c+=this.addSpecialStyle(t,e,!1),c}addSpecialStyle(e,t,i){if(null===e)return"";const s=`.${t} `;let n="";!0===i&&(n+="@media all and (max-width: 1024px){");for(const t in e){if(n+=s+t+"{","object"==typeof e[t])for(const i in e[t])n+=i+" : "+e[t][i]+";";else n+=e[t];n+="}"}return!0===i&&(n+="}"),n}fluxIsReadyCallback(e=[],t=!0){this.iabBanners=[...e,...this.iabBanners],this.injectContent(t)}getOptions(){return this.oOptions}setAdOptions(){this.excludeVideoOnDesktop=!Object(b.a)(this.oOptions.avd,!0),this.excludeVideoOnMobile=!Object(b.a)(this.oOptions.avm,!0),this.excludeVideo="desktop"===this.device&&this.excludeVideoOnDesktop||-1!==["tablet","mobile"].indexOf(this.device)&&this.excludeVideoOnMobile,this.excludedAdTypes=this.oOptions.eat||[],this.excludeVideo&&-1===this.excludedAdTypes.indexOf("video")&&this.excludedAdTypes.push("video"),this.bannersPriority=this.oOptions.bpr||["banner","native"],this.bannersObject={native:this.oOptions.b||[],banner:this.oOptions.c||[]},this.iabBanners=Object(h.d)(Object(a.f)(Object(a.h)(this.bannersObject,this.bannersPriority)).filter(e=>e&&e.length>0)),this.aBannerSizeAllowed=this.oOptions.bsa||["382x200"],this.aFeeds=this.oOptions.feeds||[],this.s2sBids=this.oOptions.s2s||[],this.s2sForFirstBid=Object(b.a)(this.oOptions.s2sForFirstBid,!1),this.videoBanners=this.oOptions.vd||[],this.autoMarge=this.oOptions.am||!1,this.aRowsCols=this.oOptions.aRowsCols||null,this.sTypeEncart=this.oOptions.type_encart||"fixe",this.lang=this.oOptions.lang||"fr",this.localUser=this.oOptions.localUser||!0,this.template=this.oOptions.tmpl||"base",this.templateNew=this.oOptions.tmpl_new||null,this.styleNew=this.oOptions.style_new||null,this.checkViewTimeout=this.oOptions.cvt||3e3,this.mainTitle=this.oOptions.mt||"Ailleurs sur le web",this.powerByPosition=this.oOptions.pbp||"bottom",this.powerByLength=null,this.sourcePosition=this.oOptions.sourcePos||"bottom",this.preloadBanners=Object(b.a)(this.oOptions.preloadBanners,!1),this.preloadBannersCount=Object(b.a)(this.preloadBanners?parseInt(this.oOptions.preloadBannersCount,10):null,0),this.animationTypeDelay=this.oOptions.animationTypeDelay||6,this.key=this.oOptions.key,this.refreshRtb=this.checkValue(this.oOptions.refreshRtb,!1),this.refreshRtbDelay=this.checkValue(this.oOptions.refreshRtbDelay,30),this.refreshRtbMax=parseInt(this.checkValue(this.oOptions.refreshRtbMax,1),10),this.saveWinnerSize=this.oOptions.saveWinnerSize||!1,this.totalViewTime=0,this.visibleAds=[],this.lastIncrementTimestamp=0,this.canTimeVisibility=!0,this.refreshOnAdVisible=Object(b.a)(this.oOptions.refreshOnAdVisible,!1),this.msk=this.oOptions.msk,this.secureIframe=this.oOptions.si||!1,this.floor=Object(b.a)(parseFloat(this.oOptions.floor),-1),this.preview=Object(b.a)(this.oOptions.preview,!1),this.affiliateId=this.utils.affiliateId,this.allowAdReport=Object(b.a)(this.oOptions.allowAdReport,!1),this.s2sConfigEnabled=Object(b.a)(this.oOptions.s2sConfigEnabled,!1),this.ignoredBiddersForTruncation=[...Object(b.a)(this.oOptions.ignoredBiddersForTruncation,[]),"marketperf"],this.isMobile=this.utils.isMobile,this.isTablet=this.utils.isTablet,this.mobileMode=this.isMobile||this.isTablet,this.tabletMode=this.utils.window.innerWidth>=728&&this.mobileMode&&2===w.c(),this.isDesktop="desktop"===this.device}_addCSPMetaTag(){if(!this.featureFlags.content_with_https_only)return;if(this.utils.topWindow.document.querySelector("meta[http-equiv='Content-Security-Policy']"))return;const e=Object.assign(this.utils.topWindow.document.createElement("meta"),{httpEquiv:"Content-Security-Policy",content:"upgrade-insecure-requests"});this.utils.topWindow.document.head.appendChild(e)}_setupPublisherPage(){this._addCSPMetaTag()}}},function(e,t,i){"use strict";i.d(t,"e",(function(){return b})),i.d(t,"h",(function(){return m})),i.d(t,"f",(function(){return g})),i.d(t,"c",(function(){return f})),i.d(t,"g",(function(){return w})),i.d(t,"a",(function(){return y})),i.d(t,"b",(function(){return O})),i.d(t,"m",(function(){return j})),i.d(t,"l",(function(){return _})),i.d(t,"j",(function(){return k})),i.d(t,"i",(function(){return x})),i.d(t,"n",(function(){return A})),i.d(t,"o",(function(){return C})),i.d(t,"d",(function(){return B})),i.d(t,"k",(function(){return I}));var s=i(3),n=i(22),r=i(9),a=i(10),o=i(1),d=i(0);const l=["0x0","1x1"],c=r.a,h="native",p="video",u="banner",b=()=>n.h,m=(e,t)=>Object(n.i)(e,t),g=e=>Object(d.f)(e)?e.mediaType||e.ad_type||Object(s.a)(e,"params.adType",""):"",f=e=>Object(s.a)(e,"params.sizec","0x0"),v=(e,t=[])=>{let i=null;return i="native"===e?{image:{required:!0,sizes:t},title:{required:!0,len:20},clickUrl:{required:!0}}:"video"===e?{context:"outstream",playerSize:[[640,360]],mimes:["video/mp4"],protocols:[3,6,7,8],maxduration:60,minduration:1,api:[2],linearity:2,startdelay:0,playbackmethod:[2,6],maxbitrate:100}:{sizes:t},i},w=(e,t)=>{const i={};return e.forEach(e=>{const{params:n={},bidder:r}=e,a="pubmatic"===r&&"native"===n.adType,o=n.adType?n.adType:"banner";Object(s.e)(i,{[o]:Object(s.e)(v(o,a?[150,50]:t),a?{sponsoredBy:!0}:{})})}),i},y=(e,t)=>e.filter(e=>-1===t.indexOf(e.bidder)),O=(e,t)=>e.filter(e=>{if(e.params)return!e.params.adType||e.params.adType&&-1===t.indexOf(e.params.adType)}),j=e=>!!e&&-1!==e.indexOf("!!e&&(Object(a.d)(e)||Object(a.c)(e)),k=e=>!!e&&-1!==e.indexOf("- outstream-video-prebid --\x3e"),x=e=>!!e&&("criteo"===e.bidder&&"banner"===e.mediaType&&-1!==(""+e.ad).indexOf("criteo_prebid_native_slots")),A=(e,t,i)=>{const n=Object(s.a)(e,"params.sizec","0x0"),r=Object(o.a)(Object.keys(Object(s.a)(e,"mediaTypes",[]))[0],"none");return e.bidder===t.bidder&&((!Object(d.a)(i)||!i.some(i=>!(i.advertiser_name!==t.bidder||i.id!==t.adId&&i.id!==e.internalId||i.size_banner_bidder!==t.size&&i.size_banner_bidder!==r)))&&(e.bidId===t.requestId||e.bidId===t.bidId||(!x(t)&&r===t.mediaType&&n===t.size||(t.mediaType===h&&r===t.mediaType&&-1!==l.indexOf(n)||(t.mediaType===p&&r===t.mediaType&&-1!==c.indexOf(n)||(!(!x(t)||-1===l.indexOf(n))||!(t.mediaType!==u||r!==p||!j(t.ad)&&!_(t.ad)||-1===c.indexOf(n)||-1===c.indexOf(t.size))))))))},C=(e,t)=>e.cpm===t.cpm&&(e.internalCacheExpiry>-1||t.internalCacheExpiry>-1)?-1===e.internalCacheExpiry?1:-1===t.internalCacheExpiry?-1:e.internalCacheExpiry-t.internalCacheExpiry:t.cpm-e.cpm,B=e=>{if(!e)return"0x0";let t=e.size;if(!Object(d.h)(t)){t=`${e.width||e.w||0}x${e.height||e.h||0}`}return null===t.match(/^([0-9]{1,3})x([0-9]{1,3})$/)?"0x0":t},I=(e,t)=>{const i=Object(s.a)(n.c,e.bidder+".type");return i?!Object(o.g)(t)&&typeof t===i:Object(d.e)(t)}},function(e,t,i){"use strict";i.d(t,"a",(function(){return o}));var s=i(2),n=i(1),r=i(3),a=i(20);const o=(e,t,i,o,d,l=!1)=>{switch(t){case"bidding":((e,t,i,o,d=!1)=>{const l=Object(r.b)(o);if(e&&!d)Object(n.e)(l)?(Object(s.i)(Object(r.i)({data:l,metrics:o,options:{mode:i,key:t}})),Object(s.h)(new Error("INVALID_PAYLOAD: Cannot make request through sendBiddingMetrics"))):Object(a.a)({url:e,method:"POST",withCredentials:!0,headers:{"Content-type":"application/x-www-form-urlencoded"},body:JSON.stringify(l)})})(e,i,o,d,l);break;default:Object(s.h)(new Error("sendMetrics: invalid context "+t))}}},,,,,,function(e,t,i){"use strict";i.d(t,"e",(function(){return a})),i.d(t,"b",(function(){return o})),i.d(t,"a",(function(){return d})),i.d(t,"d",(function(){return l})),i.d(t,"c",(function(){return c}));var s=i(1),n=i(4);i(3),i(2);var r=i(0);Object(n.j)();const a=e=>e.length?e.map(e=>({a:e.ext.adType,b:e.ext.bidderCode,c:e.ext.cpm,d:e.ext.guid})):[],o=e=>Object(s.a)(e?e.map(({ext:e})=>e.cpm).reduce((e,t)=>e+t,0):null,0),d=(e,t,i="banner")=>t&&i&&!Object(s.e)(e)&&Object(r.a)(e)?e.filter(e=>e.adType===i&&parseInt(e.width,10)===parseInt(t,10)&&(e.ext&&e.ext.bidderCode||"banner"===e.ver)):[],l=e=>!!e&&"native"===e.adType,c=e=>!!e&&("banner"===e.adType&&e.ext&&e.ext.bidderCode)},function(e,t,i){"use strict";i.d(t,"a",(function(){return r}));i(3);var s=i(5),n=i(1);const r=(e,t,i)=>{if("undefined"==typeof IntersectionObserver||null===e)return;let r;r=Object(n.e)(i)?{root:null,rootMargin:"0px",threshold:Object(s.l)(0,1,.01)}:i;const a=new IntersectionObserver(i=>{i.forEach(i=>{const s=i.intersectionRatio;t&&t(a,e,s,i)})},r);a.observe(e)}},,function(e,t,i){(e.exports=i(15)(!1)).push([e.i,'.css-selector a{-webkit-touch-callout:none!important}.css-selector ul .block-text-left .a-img-block{width:50%;float:right}.css-selector ul .block-text-left .a-img-block-ext{float:right}.css-selector ul .block-text-left .hide-overflow{float:left;width:calc(60% - 5px);margin-right:5px;margin-left:0;position:static}.css-selector ul .block-text-left .power-by-extended{right:auto;left:-5px}.css-selector ul .block-text-left p{width:calc(50% - 5px);float:left;margin-right:5px}.css-selector ul .block-text-left p span a{text-align:left}.css-selector ul .block-text-right .a-img-block{width:50%;float:left}.css-selector ul .block-text-right p{width:calc(50% - 5px);float:right;margin-left:5px;margin-right:0}.css-selector ul .block-text-right p span a{text-align:left;margin-top:0}.css-selector{text-decoration:none;line-height:normal;text-align:left}.css-selector .spinner-wait{width:70px;text-align:center;background-color:#fff;border:1px solid #000;margin-bottom:5px!important}.css-selector .spinner-wait>div{width:.75em;height:.75em;background-color:#000;position:relative;top:35%;border-radius:100%;display:inline-block;-webkit-animation:sk-bouncedelay 1.4s ease-in-out infinite both;animation:sk-bouncedelay 1.4s ease-in-out infinite both}.css-selector .spinner-wait .bounce1{-webkit-animation-delay:-.32s;animation-delay:-.32s}.css-selector .spinner-wait .bounce2{-webkit-animation-delay:-.16s;animation-delay:-.16s}@-webkit-keyframes sk-bouncedelay{0%,80%,to{-webkit-transform:scale(0)}40%{-webkit-transform:scale(1)}}@keyframes sk-bouncedelay{0%,80%,to{-webkit-transform:scale(0);transform:scale(0)}40%{-webkit-transform:scale(1);transform:scale(1)}}.css-selector>div{position:relative}.css-selector .adblock-sponsor{position:absolute;top:0;right:0;font-family:Arial,sans-serif;font-size:.7em}.css-selector li.video{width:100%;text-align:center}.css-selector a{text-shadow:unset;text-decoration:none!important;color:#000;display:inline-block!important;border:0!important}.css-selector a:before{content:"";display:none!important;position:inherit!important;line-height:inherit!important}.css-selector .power-by{height:20px;line-height:20px;font-size:.75em;float:right;margin-right:0;margin-left:10px}.css-selector .power-by img{height:1.15em;border:0!important;display:inline-block;vertical-align:middle;width:auto}.css-selector .power-by a{text-decoration:none;color:inherit}.css-selector .power-by-bottom{height:20px;margin-top:-6px;font-size:.75em;text-align:right;margin-right:0;margin-left:10px}.css-selector .power-by-bottom img{height:.9em!important;border:0!important;display:inline-block;vertical-align:middle;width:auto;margin:0;padding:0}.css-selector .power-by-bottom a{text-decoration:none;width:100%;color:#c7c7c7;text-transform:lowercase;font-size:10px}.css-selector .native-title{display:block;font-family:Roboto,Verdana,sans-serif;margin:0}.css-selector .native-title p{margin:0}.css-selector ul{padding:0;clear:both;text-align:left;list-style:none;margin:5px 0 0!important}@media (orientation:portrait){.css-selector ul li:nth-child(100n-0){margin-left:0!important;margin-right:0!important}}@media (orientation:landscape){.css-selector ul li:nth-child(200n-0){margin-left:0!important;margin-right:0!important}}.css-selector ul li:before{content:"";display:none!important}@media (orientation:landscape){.css-selector ul li:nth-child(-n+1000){display:inline-block}}@media (orientation:portrait){.css-selector ul li:nth-child(-n+2000){display:inline-block}}.css-selector ul li{display:none;margin:5px 0 5px 1%!important;vertical-align:top;text-decoration:none;padding-left:0!important;float:none}.css-selector ul li>iframe{margin:0!important}.css-selector ul li :before{content:"";display:none}@media (orientation:portrait){.css-selector ul li{width:macro_width_portrait%!important;max-width:macro_width_portrait%!important}}@media (orientation:landscape){.css-selector ul li{width:macro_width_landscape%!important;max-width:macro_width_portrait%!important}}.css-selector ul li>a{display:inline-block}.css-selector ul li a img{display:inline-block;width:100%;max-width:100%;text-decoration:none;border:0;max-height:200px;margin:0 0 5px!important;object-fit:cover}.css-selector ul li .a-img-block{text-decoration:none;position:relative;width:100%}.css-selector ul li .with-src img{display:block;margin-bottom:0!important}.css-selector ul li .with-src .tinimg-bg{height:calc(3.5em + 5px)}.css-selector ul li .with-src .tinimg{height:2.5em;bottom:calc(1em + 5px)}.css-selector ul li .with-src .tinimg,.css-selector ul li .with-src .tinimg-nosrc{font-size:.9em;line-height:1.3em;overflow:hidden;width:100%;box-sizing:border-box;padding-top:0;padding-bottom:0}.css-selector ul li .with-src .tinimg-nosrc{height:3.5em;bottom:5px}.css-selector ul li .with-src span:before{content:"(";display:"inline"}.css-selector ul li .with-src span{display:block;width:100%;position:absolute;height:1em;line-height:1em;font-size:.8em;color:#fff!important;bottom:5px;margin:0 5px}.css-selector ul li .with-src span a{color:#fff!important}.css-selector ul li .with-src span:after{content:")"}.css-selector ul li p{display:inline-block;width:100%;text-align:left;font-family:Arial,sans-serif;margin-top:0!important;margin-bottom:0!important;padding-bottom:0!important;word-break:break-word;overflow:hidden}@media (max-width:500px){.css-selector ul li p{margin:0}}.css-selector ul li p>a{display:inline-block;font-size:15px;text-decoration:none;color:#000;width:100%}.css-selector ul li p span a{display:block;font-size:11px;text-decoration:none;color:grey;margin-top:10px;text-transform:uppercase;text-align:initial;letter-spacing:.2px}@media (max-width:1000px){.css-selector ul li p span a{font-size:10px}}@media (max-width:700px){.css-selector ul li p span a{font-size:9px}}@media (max-width:500px){.css-selector ul li p span a{font-size:8px}}.css-selector ul li[data-ad-type=video]{background:#000}.css-selector ul li[data-ad-type=video] .op-player:not(.op-ads--active){position:relative;z-index:0}.css-selector ul li[data-ad-type=video] .op-player:not(.op-ads--active):before{content:"";display:block;position:absolute;z-index:0;background:#000;top:0;right:0;bottom:0;left:0;width:100%;height:100%}.css-selector ul li[data-ad-type=video]:after{content:"";position:absolute;-webkit-animation:loading 1s linear infinite;animation:loading 1s linear infinite;border-radius:50%;border:2px solid rgba(201,209,217,.25);border-top-color:#c9d1d9;display:block;height:32px;width:32px;left:50%;margin-left:-16px;margin-top:-16px;top:50%;z-index:0}@-webkit-keyframes loading{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes loading{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}.css-selector ul li[data-ad-type=video] video{width:100%;height:100%;display:block;position:relative;z-index:-1!important}.css-selector ul li .report-this-ad{-webkit-appearance:none;-moz-appearance:none;background-color:#f3f3f3;border:none;border-top-right-radius:4px;bottom:0;color:#0f1111;cursor:pointer;font-family:sans-serif;font-size:11px;left:0;margin:0;display:none;outline:none;padding:2px 4px;position:absolute;text-align:center;text-decoration:none;transition:all .15s ease;z-index:1092!important}.css-selector ul li .report-this-ad:hover{background-color:#dadada}.css-selector ul li .report-this-ad-overlay{position:absolute;top:0;left:0;background-color:#f8fafc;color:#0f1111;display:none;align-items:center;justify-content:center;font-family:sans-serif;font-size:11px;font-weight:500}.css-selector ul li:hover .report-this-ad{display:block}.css-selector ul li[data-report-overlay-visible=true] .report-this-ad-overlay{display:flex}.css-selector .privacy-link{position:absolute;right:0;top:0}.css-selector .privacy-logo{width:auto}.css-selector .tinimg,.css-selector .tinimg-nosrc{display:block;position:absolute;bottom:0;left:0;margin:0;text-align:left;width:calc(100% - 10px);padding:5px;color:#fff;line-height:20px;text-overflow:ellipsis;text-transform:uppercase;font-weight:700;height:calc(50% - 10px);overflow-y:hidden}.css-selector .tinimg-bg{display:block;position:absolute;bottom:0;left:0;text-align:left;width:100%;height:50%;background:#000;opacity:.65}.css-selector .hideAd{position:absolute!important;bottom:-99999999px!important;height:1px!important;width:1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important}',""])}]]);