(function(){var e=document.createElement(`style`);e.textContent=`:root{--adv-label-text:""}div.adv-wrapper{flex-direction:column;justify-content:center;align-items:center;display:flex;max-height:700px!important}div.pubtech-adv-container{margin:35px 0;position:relative;text-align:center!important;justify-content:center!important;display:flex!important}.pubtech-adv-sticky{top:10px;position:-webkit-sticky!important;position:sticky!important}.st-placement.inScreen{z-index:2147483647!important}div.advblockshown:before{content:var(--adv-label-text);color:#999;text-align:center;clear:both;font-family:Verdana,Geneva,sans-serif;font-size:11px;line-height:22px;display:block}div.advblockshown{clear:both}div.anchor-slot{z-index:99999;justify-content:center;align-items:center;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;display:flex;position:fixed;top:0}div.anchor-slot.anchor-slot-desktop-type{padding:15px;right:50%;transform:translate(50%)}div.anchor-slot.anchor-slot-mobile-type{width:100%;padding:10px 0;right:0}div.rendered-slot div.anchor-slot{-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px);box-shadow:0 0 5px rgba(0,0,0,.2)}span#anchor-slot-close-button{color:#fff;cursor:pointer;background-color:rgba(0,0,0,.7);border-radius:50%;display:none;position:absolute;bottom:5px;right:5px}div.rendered-slot div.anchor-slot span#anchor-slot-close-button{display:block!important}div.anchor-slot span#anchor-slot-close-button.anchor-slot-desktop-button{width:25px;height:25px;font-size:18px;line-height:25px}div.anchor-slot span#anchor-slot-close-button.anchor-slot-mobile-button{width:20px;height:20px;font-size:12px;line-height:20px}div.hide-adv-label div.advblockshown:before{display:none!important}.pos-right-adv{float:left;opacity:1;visibility:visible;z-index:10;border:0;width:160px;min-width:160px;max-width:160px;height:620px;min-height:620px;max-height:620px;margin:0;padding:0;transition-duration:0s;display:block;top:50px;right:calc(50vw + 700px);overflow:visible;position:fixed!important}.pos-left-adv{float:left;opacity:1;visibility:visible;z-index:10;border:0;width:160px;min-width:160px;max-width:160px;height:620px;min-height:620px;max-height:620px;margin:0;padding:0;transition-duration:0s;display:block;top:50px;left:calc(50vw + 700px);overflow:visible;position:fixed!important} /*$vite$:1*/`,document.head.appendChild(e);function t(e,t){if(t.has(e))throw TypeError(`Cannot initialize the same private elements twice on an object`)}function n(e,n,r){t(e,n),n.set(e,r)}function r(e,t,n){if(typeof e==`function`?e===t:e.has(t))return arguments.length<3?t:n;throw TypeError(`Private element is not present on this object`)}function i(e,t,n){return e.set(r(e,t),n),n}function a(e,t){return e.get(r(e,t))}var o=new WeakMap,s=new WeakMap,c=new WeakMap,l=new WeakMap,u=class e{constructor(){var e;n(this,o,void 0),n(this,s,new Set),n(this,c,new Map),n(this,l,new Set),i(o,this,(e=document.head)==null?document.getElementsByTagName(`head`)[0]:e)}static getInstance(){return d._==null&&(d._=new e),d._}loadScript(e){let{appendToBody:t=!1,async:n=!0,onScriptLoaded:r,scriptTag:i,scriptUrl:u}=e;if(u.length===0)return;if(a(s,this).has(u)){typeof r==`function`&&this.onReadyScript(i,r);return}let d=document.createElement(`script`);d.type=`text/javascript`,d.async=n,d.setAttribute(`data-cfasync`,`false`),d.src=u,d.onload=()=>{var e;a(l,this).add(i),typeof r==`function`&&r();let t=(e=a(c,this).get(i))==null?[]:e;for(let e of t)e();a(c,this).delete(i)},!t||document.body==null?a(o,this).appendChild(d):document.body.appendChild(d),a(s,this).add(u)}onReadyScript(e,t){if(a(l,this).has(e)){t();return}let n=a(c,this).get(e);if(n!=null){n.push(t);return}a(c,this).set(e,[t])}},d={_:null},f=0,p=0,m=!0;function h(){m=!0}window.addEventListener(`resize`,h,{passive:!0}),window.addEventListener(`orientationchange`,h,{passive:!0});function g(){m&&(f=window.innerWidth,p=window.innerHeight,m=!1)}function _(){return g(),f}function v(){return g(),p}function y(e,t,n,r,i,a,o){try{var s=e[a](o),c=s.value}catch(e){n(e);return}s.done?t(c):Promise.resolve(c).then(r,i)}function b(e){return function(){var t=this,n=arguments;return new Promise(function(r,i){var a=e.apply(t,n);function o(e){y(a,r,i,o,s,`next`,e)}function s(e){y(a,r,i,o,s,`throw`,e)}o(void 0)})}}var x={DESKTOP:`desktop`,MOBILE:`mobile`,TABLET:`tablet`};function S(){let e=_();return e>=1025?x.DESKTOP:e<1025&&e>=768?x.TABLET:x.MOBILE}function C(){let e=S();return{isDesktop:e===x.DESKTOP,isMobile:e===x.MOBILE,isTablet:e===x.TABLET}}function ee(){return _()>=768?x.DESKTOP:x.MOBILE}function w(){return document.readyState===`interactive`||document.readyState===`complete`}function T(e){if(w())return e(),()=>{};function t(){e()}return document.addEventListener(`DOMContentLoaded`,t),()=>{document.removeEventListener(`DOMContentLoaded`,t)}}function E(){return window.location.pathname.split(`/`).filter(Boolean)}function D(){let e={};return new URLSearchParams(window.location.search).forEach((t,n)=>{e[n]=t}),e}function O(){var e;let t=document.querySelector(`meta[property="og:type"]`);if(t){var n;return(n=t.getAttribute(`content`))==null?``:n}let r=document.querySelector(`meta[name="page-type"]`);return(e=r==null?void 0:r.getAttribute(`content`))==null?``:e}function te(e){function t(e){return e.toLowerCase().replace(/[:\s]/g,`_`)}let n={},r=new Set(e.map(e=>t(e))),i=Array.from(document.querySelectorAll(`meta[name], meta[property]`));for(let e of i){var a,o;let i=(a=(o=e.getAttribute(`name`))==null?e.getAttribute(`property`):o)==null?``:a;if(i.length===0)continue;let c=t(i);if(r.has(c)){var s;n[c]=(s=e.getAttribute(`content`))==null?``:s}}return n}function k(){var e;let t=Array.from(document.querySelectorAll(`script[type="application/ld+json"]`)),n=``;for(let e of t)try{var r;let t=JSON.parse((r=e.textContent)==null?``:r);if(Array.isArray(t))for(let e of t){var i;n=(i=A(e))==null?n:i}else{var a;n=(a=A(t))==null?n:a}}catch(e){}if(n.length>0)return n;let o=document.querySelector(`meta[name="author"]`);return(e=o==null?void 0:o.getAttribute(`content`))==null?``:e}function A(e){if(typeof e==`object`&&e&&`author`in e){let t=e;if(t.author!==null&&typeof t.author==`object`&&`name`in t.author){let e=t.author;if(typeof e.name==`string`&&e.name.length>0)return e.name}}return null}function j(e){return typeof e==`function`}function ne(e){return typeof e==`object`&&!!e&&`then`in e&&typeof e.then==`function`}function M(e){return j(e)?e():e}function re(e){return N.apply(this,arguments)}function N(){return N=b(function*(e){return j(e)?e():(ne(e),e)}),N.apply(this,arguments)}function P(e){let t=window.document.cookie.match(`(^|;)\\s*`+e+`\\s*=\\s*([^;]*)\\s*(;|$)`);return t?decodeURIComponent(t[2]):null}function ie(e,t,n=null,r=`Lax`){let i=``,a=Number(n);if(a>0){let e=new Date;e.setTime(e.getTime()+a*1e3*60),i=`; expires=${e.toUTCString()}`}let o=` ;domain=${ae(window.location.hostname)}`,s=r!=null&&r.toLowerCase()==`none`?`; Secure`:``;window.document.cookie=`${e}=${encodeURIComponent(t)}${i}; path=/${o}${r?`; SameSite=${r}`:``}${s}`}function ae(e){if(e==null||e===`localhost`)return``;e.startsWith(`www.`)||(e=`www.`+e);let t=e.split(`.`),n=t[t.length-2],r=/^[0-9]+$/.test(e.split(`:`)[0].split(`.`).join(``)),i=2;return!r&&t.length>3&&n.length<4&&(i=3),`.`+t.reverse().slice(0,i).reverse().join(`.`)}function oe(e){return e?(e^se()>>e/4).toString(16):`10000000-1000-4000-8000-100000000000`.replace(/[018]/g,oe)}function se(){return window&&window.crypto&&typeof window.crypto.getRandomValues==`function`?crypto.getRandomValues(new Uint8Array(1))[0]%16:Math.random()*16}function ce(e){return!!new URLSearchParams(window.location.search).get(e)}function le(e){return!!ue(e)||ce(e)}function ue(e){try{return window.localStorage.getItem(e)}catch(t){return console.error(`Error while getting ${e} from local storage`,t),null}}function de(e){return new Promise(t=>{e.getState()!==`prerendering`&&t(),e.on(`stateChange`,function n(r){r!==`prerendering`&&(e.on(`stateChange`,n),t())})})}function fe(e){if(e!==void 0)return e.language;throw Error(`Navigator is not defined`)}function pe(e){let t=document.createElement(`style`);t.appendChild(document.createTextNode(e)),document.head.appendChild(t)}function me(){return new Promise(e=>{let t=!1,n,r=()=>{t||(t=!0,n!==void 0&&clearTimeout(n),e(!0))};if(`scheduler`in window&&typeof window.scheduler==`object`&&window.scheduler!=null){if(`yield`in window.scheduler&&typeof window.scheduler.yield==`function`)return window.scheduler.yield().then(r,r);if(`postTask`in window.scheduler&&typeof window.scheduler.postTask==`function`){let e=window.scheduler.postTask(r,{priority:`user-visible`});ne(e)&&e.then(void 0,r);return}}n=setTimeout(r,0),window.requestAnimationFrame(()=>{setTimeout(()=>{r()},0)})})}function he(){let e=`direct`,t=document.referrer;if(!t)return e;try{let e=[`facebook.com`,`instagram.com`,`twitter.com`,`linkedin.com`,`reddit.com`,`tiktok.com`,`pinterest.com`,`tumblr.com`,`snapchat.com`,`weibo.com`,`wechat.com`,`t.co`],n=[`google.com`,`google.co.uk`,`google.de`,`google.fr`,`google.es`,`google.it`,`bing.com`,`yahoo.com`,`duckduckgo.com`,`baidu.com`,`yandex.com`,`yandex.ru`,`ecosia.org`,`startpage.com`],r=new URL(t).hostname.toLowerCase().replace(/^www\./,``),i=e=>r===e||r.endsWith(`.`+e);if(e.some(i))return`social`;if(n.some(i))return`organic`}catch(e){}return e}function ge(e,t){ve(e,t,!0)}function _e(e,t){ve(e,t,!1)}function ve(e,t,n){if(!(e==null||e.parentNode==null)){if(n){e.parentNode.insertBefore(t,e.nextSibling);return}e.parentNode.insertBefore(t,e)}}function ye(){try{typeof window.ptecpre==`object`&&window.ptecpre!==null&&Array.isArray(window.ptecpre.queue)||(window.ptecpre={queue:[]})}catch(e){console.error(e)}}function be(){ye();let e=window.ptecpre.queue;Array.isArray(e)&&e.forEach(function(e){e()}),Te(window.ptecpre)}function xe(){try{typeof window.ptec==`object`&&window.ptec!==null&&Array.isArray(window.ptec.queue)||(window.ptec={queue:[]})}catch(e){console.error(e)}}function Se(e){xe();let t=window.ptec.queue;Array.isArray(t)&&t.forEach(function(t){t(e)}),Te(window.ptec,e)}var Ce={queue:[]};function we(e){let t=Ce.queue;Array.isArray(t)&&t.forEach(function(t){t(e)}),Te(Ce,e)}function Te(e,t=null){Object.isFrozen(e)||(e.queue={push:e=>e(t)},Object.freeze(e))}function Ee(e,t=S()){let n=[];if(e==null)return n;let r=De(e,t);if(r!=null){var i,a;let t=(i=(a=e.getAttribute(r))==null?void 0:a.split(`,`))==null?[]:i;for(let e of t){if(e===`fluid`){n.push(`fluid`);continue}let t=e.split(`x`);t[0]!=null&&t[1]!=null&&!Number.isNaN(t[0])&&!Number.isNaN(t[1])&&n.push([parseInt(t[0]),parseInt(t[1])])}}return n}function De(e,t){if(e.hasAttribute(`data-size-`+t)&&e.getAttribute(`data-size-`+t)!==``)return`data-size-`+t;if(t===x.TABLET&&e.hasAttribute(`data-size-`+x.DESKTOP)&&e.getAttribute(`data-size-`+x.DESKTOP)!==``)return`data-size-`+x.DESKTOP;if(e.hasAttribute(`data-size`)&&e.getAttribute(`data-size`)!==``)return`data-size`}function Oe(e,t=!0,n=!1,r=!1){let i=document.createElement(`div`);if(i.id=e,i.classList.add(`adv-wrapper`),!t)return r&&i.classList.add(`pubtech-adv-sticky`),i;let a=document.createElement(`div`);return a.classList.add(`container_${e}`,`pubtech-adv-container`),e.includes(`C_`)&&a.classList.add(`pubtech-adv-incontent`,`pubtech-adv-bg`),n&&a.classList.add(`pubtech-adv-bg`),r&&a.classList.add(`pubtech-adv-sticky`),a.appendChild(i),a}function ke({actionType:e=`default`,customParagraphIndexSelection:t,elementContainer:n,elementsList:r,enableStickyBox:i=!1,frequency:a=3,isInfiniteScroll:o=!1,isInsertAfter:s=!0,isSubElementDirectDescendant:c=!0,logger:l,maxNumberOfElements:u=8,minParagraphLength:d,offset:f=0,sizeMappingApi:p,skipLastParagraph:m=!1,subElementType:h=`p`}){let g=r?[...r]:Ae(p,l,u),_=g.length;if(_===0)return l.debug(`=== insertDynamicSlots === No slot IDs to add, exit!`),!1;l.debug(`=== insertDynamicSlots === slotIds available are: ${g}`),l.debug(`=== insertDynamicSlots === Start insert slots at paragraph index: ${f} and a frequency of: ${a}`),l.debug(`=== insertDynamicSlots === isInsertAfter is selected to: ${s}`),l.debug(`=== insertDynamicSlots === The subElementType is: ${h}`);let v;if(e==="default")l.debug(`=== insertDynamicSlots === Selected the default actionType`),v=c?document.querySelectorAll(n+` > `+h):document.querySelectorAll(n+` `+h);else if(e===`elementList`)l.debug(`=== insertDynamicSlots === Selected the elementList actionType`),v=document.querySelectorAll(n);else return l.debug(`=== insertDynamicSlots === No valid actionType selected: ${e}, exit!`),!1;let y=v.length;if(y===0)return l.debug(`=== insertDynamicSlots === totalParagraphsOrDomElementsCount is 0, exit!`),!1;l.debug(`=== insertDynamicSlots === totalParagraphsOrDomElementsCount is: ${y}`);let b=[];if(t==null)if(d!=null&&d>0){l.debug(`=== insertDynamicSlots === Checking if minParagraphLength is: ${d}`);let e=[];for(let t=0;t=d&&e.push(t)}let t=e.length;if(t===0)return l.debug(`=== insertDynamicSlots === No paragraph matching the selected criteria was found, exit!`),!1;l.debug(`=== insertDynamicSlots === Found valid paragraphs at index: ${e}`);for(let n=f;n0||o)&&(document.getElementById(e)==null?(l.debug(`=== insertDynamicSlots === createAdvSlotElement with ID: ${e}, referenceNode:`,t),s?ge(t,Oe(e,!0,!1,i)):_e(t,Oe(e,!0,!1,i))):l.debug(`=== insertDynamicSlots === Element already found, skip!`))}}return!0}function Ae(e,t,n){t.debug(`=== insertDynamicSlots === Start generate slot Ids`);let r=[];for(let t=1;t<=n;t++){let n=`C_${t}`;e.getAdUnitSizes(n).length>0&&r.push(n)}return r}function je({pageContainer:e,elementContainer:t,logger:n,sizeMappingApi:r,subElementType:i,excludeElements:a,frequency:o,offset:s,skipMinTextLength:c=!1,elementsList:l,isInfiniteScroll:u=!1,skipParagraphs:d,skipCheckImageNextParagraph:f=!1,skipInsertingPointWebsiteCallback:p,isSubElementDirectChildOfElementContainer:m=!0}){if(document.querySelector(e)==null)return n.debug(`[ARTICLE ADVANCED ADS] | Page Class/Id not found ${e}`),!1;if(document.querySelector(t)==null)return n.debug(`[ARTICLE ADVANCED ADS] | Post Container not found ${t}`),!1;let h=typeof i==`string`&&i.length>0?i:`p`,g=m?document.querySelectorAll(`${t} > ${h}`):document.querySelectorAll(`${t} ${h}`),_=g.length;if(_===0)return n.debug(`[ARTICLE ADVANCED ADS] | Total paragraph count is 0`),!1;n.debug(`[ARTICLE ADVANCED ADS] | Total paragraph count is ${_}`);let v=d==null?[]:d,y=Me({elementsList:l,excludeElements:a,logger:n,sizeMappingApi:r});n.debug(`[ARTICLE ADVANCED ADS] | Added list ${y}`),n.debug(`[ARTICLE ADVANCED ADS] | Start getting paragraphs`);let b=0,x=!1;for(let e=0;e<_-1;e++){var S;if(y.length===0){n.debug(`[ARTICLE ADVANCED ADS] | All ad slot inserted`);break}if(s!=null&&s>0&&e<=s-1){n.debug(`[ARTICLE ADVANCED ADS] | Skip for offset index: ${e} offset: ${s}`);continue}if(v.includes(e)){n.debug(`[ARTICLE ADVANCED ADS] | Skip paragraph number: ${e}`);continue}if(!(e%o===0||x&&e-b>=2))continue;let t=g[e];if(n.debug(`[ARTICLE ADVANCED ADS] | Index: ${e} - Frequency: ${o} - i % frequency = ${e%o} - skipFrequency = ${x}`),n.debug(`[ARTICLE ADVANCED ADS] | lastInsertedParagraph: ${b} // i - lastInsertedParagraph = ${e-b}`),t==null){n.debug(`[ARTICLE ADVANCED ADS] | Reference node undefined or null skip`),x=!0;continue}let i=(S=t.textContent)==null?``:S;if(c&&i.split(/\s/).length<5){n.debug(`[ARTICLE ADVANCED ADS] | Short text skip`);continue}if(typeof p==`function`)try{let e=p(t);if((e==null?void 0:e.skipFrequency)===!0&&(x=!0),(e==null?void 0:e.continue)===!0)continue}catch(e){n.debug(`ArticleAdvancedAds error skipInsertingPointWebsiteCallback:`,e)}let a=g[e+1];if(!f&&a!=null&&a.getElementsByTagName(`img`).length>0&&e%3==0){n.debug(`[ARTICLE ADVANCED ADS] | Image in next paragraph skip`),x=!0;continue}if(t.getElementsByTagName(`img`).length>0){n.debug(`[ARTICLE ADVANCED ADS] | Paragraph with image skip`),x=!0;continue}x&&(n.debug(`[ARTICLE ADVANCED ADS] | skip frequency = true, set to false`),x=!1);let l=y.shift();l!=null&&(n.debug(`ARTICLE ADVANCED ADS ==> Inserting element ${l}`),(r.getAdUnitSizes(l).length>0||u)&&document.getElementById(l)==null&&t.parentNode!=null?(t.parentNode.insertBefore(Oe(l),t.nextSibling),b=e,n.debug(`[ARTICLE ADVANCED ADS] | ADDING ${l}`)):n.debug(`[ARTICLE ADVANCED ADS] | Element ${l} not found in sizeMapping`))}return!0}function Me({elementsList:e,excludeElements:t,logger:n,sizeMappingApi:r}){if(e!=null)return n.debug(`[ARTICLE ADVANCED ADS] | Elementlist defined, adding custom slots`),[...e];n.debug(`[ARTICLE ADVANCED ADS] | Elementlist undefined, adding default slots`);let i=[];for(let e=1;e<=11;e++){let n=`C_${e}`;t!=null&&t.length>0&&t.includes(n)||r.getAdUnitSizes(n).length>0&&i.push(n)}return i}function Ne({startingIndex:e,availableSlotCount:t,availableParagraphCount:n,frequency:r}){let i=[];for(let a=e;a0)}function Be(e){if(ze(e.override))return e.override;let t=e.getAdUnitSizes(e.divId);return ze(t)?t:e.getAdUnitSizes(e.adUnitKey)}function Ve(e){var t,n,r;let i={desktop:F({},(t=e==null?void 0:e.desktop)==null?{}:t),mobile:F({},(n=e==null?void 0:e.mobile)==null?{}:n),tablet:F({},(r=e==null?void 0:e.tablet)==null?{}:r)},a=S();return{addSizeMaps(e,t){var n,r,o;i[a][e]=[...(n=i[a][e])==null?[]:n,...(r=(o=t[a])==null?void 0:o[e])==null?[]:r]},clearSizeMapping(){i.desktop={},i.mobile={},i.tablet={}},getAdUnitSizes(e,t=a){return i[t][e]||[]},getSizeMapping(e){return i[e]},removeAdUnitSizes(e,t=a){delete i[t][e]},setAdUnitSizes(e,t,n=a){i[n][e]=t}}}var I={Prebid:`prebid`,Gpt:`gpt`,PrebidClientRender:`prebid-client-render`,Fallback:`fallback`},He={Success:`success`,Continue:`continue`,Failure:`failure`,Unfilled:`unfilled`},Ue=`slot:unfilled`,We=`slot:filled`,Ge=`slot:onLoad`,Ke=`slot:renderEnded`,qe=`slot:responseReceived`,Je=`auction:phaseCompleted`,Ye=`batchSelling:dominationDetected`,Xe=function(e){return e[e.NoDefinableSlot=0]=`NoDefinableSlot`,e[e.FunctionalError=1]=`FunctionalError`,e}({}),Ze=`pt1-ppid-v2`;function Qe(){let e=P(Ze);return(!e||e.length===0)&&(e=oe(),ie(Ze,e,1440*365)),e}function $e(e){e.setPublisherProvidedId(Qe())}function et(){let e=``,t=[],n=window.ads_targeting_map;if(n!=null)n.category!=null&&n.category.length>0&&(t=typeof n.category==`string`?[n.category]:n.category),typeof n.page==`string`&&(e=n.page);else{var r,i,a,o,s;let n=document.querySelector(`meta[property='og:type']`);if(n!=null){let t=n.getAttribute(`content`);t!=null&&t===`article`&&(e=`articolo`)}document.body!=null&&document.body.className.length>0&&document.body.className.split(` `).indexOf(`home`)>=0&&(e=`homepage`),(((r=window.location)==null?void 0:r.pathname)===``||((i=window.location)==null?void 0:i.pathname)===`/`||((a=window.location)==null?void 0:a.pathname)==null)&&(e=`homepage`),(o=window.location)!=null&&o.hostname&&((s=window.location)==null?void 0:s.hostname.indexOf(`forum`))>=0&&(e=`forum`);let l=document.querySelector(`meta[property='og:section']`),u=document.querySelector(`meta[property='article:section']`);c(l),c(u);function c(e){if(e!=null){let n=e.getAttribute(`content`);if(n!=null&&n!==``){let e=n.split(`,`);for(let n of e)t.push(n.trim())}}}}return{pageTargeting:e,sectionsTargeting:t}}function tt(e){return e?e.includes(`Firefox`)?`Mozilla Firefox`:e.includes(`SamsungBrowser`)?`Samsung Internet`:e.includes(`Opera`)||e.includes(`OPR`)?`Opera`:e.includes(`Trident`)?`Microsoft Internet Explorer`:e.includes(`Edge`)?`Microsoft Edge (Legacy)`:e.includes(`Edg`)?`Microsoft Edge (Chromium)`:e.includes(`Chrome`)?`Google Chrome or Chromium`:e.includes(`Safari`)?`Apple Safari`:`unknown`:`unknown`}function L(e,n){t(e,n),n.add(e)}window.googletag=window.googletag||{cmd:[]};var nt=`ptechsdepth`,rt=[`active`,`passive`],it=`Google Publisher Tag library was overridden or is not available`;function at(){let e=window.googletag;if(e==null)throw Error(it);return e}function ot(e){var t;let n=at();if(n.apiReady)return e();if(typeof((t=n.cmd)==null?void 0:t.push)!=`function`)throw Error(it);n.cmd.push(()=>{e()})}var st=class extends Error{constructor(e){super(e),this.name=`NoDefinableSlotError`}};function ct(e){if(e.fetchGpt){let e=document.getElementsByTagName(`script`),t=`https://securepubads.g.doubleclick.net/tag/js/gpt.js`,n=!0;for(let r of e)if(r.getAttribute(`src`)===t){n=!1;break}n&&u.getInstance().loadScript({scriptTag:`securepubads`,scriptUrl:t})}return e.fetchGoogleTag&&u.getInstance().loadScript({scriptTag:`googletag`,scriptUrl:`https://www.googletagservices.com/tag/js/gpt.js`}),t=>{var n;return new gt(F(F({},e),{},{prefixFullNameAd:(n=t.overridePrefixFullNameAd)==null?e.prefixFullNameAd:n,siteCategory:t.siteCategory,contextManager:t.contextManager,eventDispatcher:t.eventDispatcher,consentReader:t.consentReader,divIdToAdUnitKeyMapping:t.divIdToAdUnitKeyMapping,getAdUnitSizes:t.getAdUnitSizes}))}}var lt=new WeakMap,ut=new WeakMap,dt=new WeakMap,ft=new WeakMap,pt=new WeakMap,mt=new WeakMap,ht=new WeakMap,R=new WeakSet,gt=class{constructor({divIdToAdUnitKeyMapping:e,disableInitialLoad:t=!0,getAdUnitSizes:o,prefixFullNameAd:s,siteCategory:c,contextManager:l,eventDispatcher:u,globalTargetingTransformer:d,slotTargetingTransformer:f,personalizedAds:p,consentReader:m}){L(this,R),n(this,lt,void 0),n(this,ut,void 0),n(this,dt,void 0),n(this,ft,void 0),n(this,pt,void 0),n(this,mt,new Set),n(this,ht,void 0),i(ht,this,e),i(dt,this,o),i(lt,this,s),i(ft,this,d),i(pt,this,f),i(ut,this,l),l.on(`contextUpdated`,({context:e,navigationContext:t})=>{r(R,this,Ct).call(this,{siteCategory:c,context:e,navigationContext:t})}),l.on(`visibilityChanged`,e=>{ot(()=>{window.googletag.setConfig({targeting:{tab_visible:rt.includes(e)?`yes`:`no`}})})});let h=l.getCurrentContext();r(R,this,Ct).call(this,{siteCategory:c,context:h,navigationContext:h.navigationContext}),ot(()=>{window.googletag.setConfig({singleRequest:!0,disableInitialLoad:t,centering:!0,autoRefresh:{backForwardCache:!1}}),window.googletag.pubads().addEventListener(`slotOnload`,e=>{let t={EVENT_NAME:Ge,adUnitKey:e.slot.getSlotElementId(),adProvider:`gpt`};u.dispatch(t)}),window.googletag.pubads().addEventListener(`slotResponseReceived`,e=>{let t=e.slot.getSlotElementId(),n=a(ht,this)&&a(ht,this)[t]?a(ht,this)[t]:t,r=e.slot.getResponseInformation(),i=F(F({EVENT_NAME:qe,divId:t,adUnitKey:n,isEmpty:r===null,adProvider:`gpt`},typeof(r==null?void 0:r.lineItemId)==`number`?{lineItemId:r.lineItemId}:{}),typeof(r==null?void 0:r.creativeId)==`number`?{creativeId:r.creativeId}:{});u.dispatch(i)}),window.googletag.pubads().addEventListener(`slotRenderEnded`,e=>{let t=e.slot.getSlotElementId(),n=F(F({EVENT_NAME:Ke,divId:t,adUnitKey:a(ht,this)&&a(ht,this)[t]?a(ht,this)[t]:t,isEmpty:e.isEmpty,adProvider:`gpt`},typeof e.lineItemId==`number`?{lineItemId:e.lineItemId}:{}),typeof e.creativeId==`number`?{creativeId:e.creativeId}:{});u.dispatch(n)}),p!==void 0&&window.googletag.pubads().setPrivacySettings({nonPersonalizedAds:!p}),$e(window.googletag.pubads()),window.googletag.enableServices()}),m&&m.onConsentReleased({onConsentCallback:e=>{ot(()=>{window.googletag.pubads().setPrivacySettings({nonPersonalizedAds:!e.personalizedAds})})}})}getPrefixFullNameAd(){return a(lt,this)}hasDefinedSlot(e){return a(mt,this).has(e)}destroySlot(e){r(R,this,bt).call(this,()=>{let t=googletag.pubads().getSlots().find(t=>t.getSlotElementId()===e);t!=null&&googletag.destroySlots([t]),a(mt,this).delete(e)})}defineSlot({adUnitKey:e,divId:t,refreshCount:n=0,overrideSlotName:r,overrideTargeting:i,overrideAdUnitSizes:a,slotType:o=`display`,existingGoogleTagSlot:s}){return this.defineSlots([{adUnitKey:e,divId:t,refreshCount:n,overrideSlotName:r,overrideTargeting:i,overrideAdUnitSizes:a,slotType:o,existingGoogleTagSlot:s}]).then(e=>e[0])}defineSlots(e){return r(R,this,bt).call(this,()=>{let t=[];for(let n of e)t.push(r(R,this,vt).call(this,n));return t})}refreshSlot(e){return this.refreshSlots([e]).then(e=>e[0])}refreshSlots(e){return r(R,this,bt).call(this,()=>{let t=[];for(let n of e){let e=r(R,this,yt).call(this,n);if(e==null)throw new st(`No defined slot found for adUnitKey: `+n.adUnitKey+` and divId: `+n.divId);t.push(e)}return r(R,this,_t).call(this,t)})}sellAdSlot({adUnitKey:e,divId:t,refreshCount:n=0,overrideSlotName:r,overrideTargeting:i,overrideAdUnitSizes:a,slotType:o=`display`,existingGoogleTagSlot:s}){return this.sellAdSlots([{adUnitKey:e,divId:t,refreshCount:n,overrideSlotName:r,overrideTargeting:i,overrideAdUnitSizes:a,slotType:o,existingGoogleTagSlot:s}]).then(e=>e[0])}sellAdSlots(e){return r(R,this,bt).call(this,()=>{let t=[];for(let n of e)t.push(r(R,this,vt).call(this,n));return r(R,this,_t).call(this,t)})}};function _t(e){let t=Array.from(e);return window.googletag.pubads().refresh(t),t}function vt({adUnitKey:e,divId:t,refreshCount:n=0,overrideSlotName:i,overrideTargeting:o,overrideAdUnitSizes:s,slotType:c=`display`,existingGoogleTagSlot:l}){let u=a(lt,this)+(typeof i==`string`?i:e);if(c===`outOfPageInterstitial`)return r(R,this,xt).call(this,{fullNameAd:u,divId:t,overrideTargeting:o});if(c===`outOfPageRightSideRail`||c===`outOfPageLeftSideRail`)return r(R,this,St).call(this,{fullNameAd:u,divId:t,side:c===`outOfPageRightSideRail`?`right`:`left`,overrideTargeting:o});let d=document.getElementById(t);if(d==null)throw new st(`No HTML element found with id: `+t);let f=a(mt,this).has(t)?r(R,this,yt).call(this,{adUnitKey:e,divId:t,overrideSlotName:i}):l==null?googletag.defineSlot(u,Be({getAdUnitSizes:a(dt,this),divId:t,adUnitKey:e,override:s}),t):l;if(f==null)throw new st(`No definable slot found for adUnitKey: `+e+` and divId: `+t);return f.addService(googletag.pubads()),f.setConfig({targeting:o==null?r(R,this,wt).call(this,{adUnitKey:e,htmlSlotElement:d,refreshCount:n}):o,collapseDiv:`DISABLED`}),a(mt,this).add(t),f}function yt({adUnitKey:e,divId:t,overrideSlotName:n}){let r=googletag.pubads().getSlots(),i=r.find(e=>e.getSlotElementId()===t);if(i!=null)return i;let o=a(lt,this)+(typeof n==`string`?n:e);return r.find(e=>e.getAdUnitPath()===o)}function bt(e){return new Promise((t,n)=>{try{ot(()=>{try{t(e())}catch(e){n({reason:e instanceof st?Xe.NoDefinableSlot:Xe.FunctionalError,message:e instanceof Error?e.message:`Unknown error`})}})}catch(e){n({reason:Xe.FunctionalError,message:it})}})}function xt({fullNameAd:e,divId:t,overrideTargeting:n}){var r;let i=(r=googletag.enums)==null||(r=r.OutOfPageFormat)==null?void 0:r.INTERSTITIAL;if(i==null)throw Error(`GPT OutOfPageFormat.INTERSTITIAL unavailable`);if(a(mt,this).has(t)){let t=googletag.pubads().getSlots().find(t=>t.getAdUnitPath()===e);if(t)return t}let o=googletag.defineOutOfPageSlot(e,i);if(o==null)throw new st(`No definable out-of-page interstitial slot for adUnitPath: `+e);return a(mt,this).add(t),n!=null&&o.setConfig({targeting:n}),o.addService(googletag.pubads()),o}function St({fullNameAd:e,divId:t,side:n,overrideTargeting:i}){var o,s;let c=n===`right`?(o=googletag.enums)==null||(o=o.OutOfPageFormat)==null?void 0:o.RIGHT_SIDE_RAIL:(s=googletag.enums)==null||(s=s.OutOfPageFormat)==null?void 0:s.LEFT_SIDE_RAIL;if(c==null)throw Error(`GPT OutOfPageFormat.${n===`right`?`RIGHT_SIDE_RAIL`:`LEFT_SIDE_RAIL`} unavailable`);if(a(mt,this).has(t)){let t=googletag.pubads().getSlots().find(t=>t.getAdUnitPath()===e);if(t)return t}let l=googletag.defineOutOfPageSlot(e,c);if(l==null)throw new st(`No definable out-of-page ${n} side rail slot for adUnitPath: `+e);a(mt,this).add(t);let u=document.getElementById(t),d=i==null?r(R,this,wt).call(this,{adUnitKey:t,htmlSlotElement:u==null?document.createElement(`div`):u,refreshCount:0}):i;return l.setConfig({targeting:d}),l.addService(googletag.pubads()),l}function Ct({siteCategory:e,context:t,navigationContext:n}){let r=Number(P(nt));r===0?r=1:n!==`infinite-scroll`&&r++;let i=t.navigationContext!==`initial`||document.referrer.indexOf(window.location.hostname)===-1,{pageTargeting:o,sectionsTargeting:s}=et(),c={"site-category":e==null?null:[...e],browser:tt(navigator.userAgent),pageview:i?`1`:`0`,sessiondepth:String(r),tab_visible:rt.includes(t.lifecycleState)?`yes`:`no`,pagina:o,section:s};ot(()=>{window.googletag.setConfig({targeting:a(ft,this)?a(ft,this).call(this,c):c})}),ie(nt,r)}function wt({adUnitKey:e,htmlSlotElement:t,refreshCount:n}){let r={};if(t!=null&&t.getAttribute(`data-targeting`)!=null)try{for(let[e,n]of Object.entries(JSON.parse(t.getAttribute(`data-targeting`)||`{}`)))r[e]=n}catch(e){}let i=a(ut,this).getCurrentContext().path,o=i.split(`/`)[1]||`home`;return r=F(F({},r),{},{SPurl:o.length>0?o.slice(-40):`home`,path:i.slice(-40),Refresh:String(n)}),a(pt,this)?a(pt,this).call(this,e,t,r):r}var Tt,Et=class e{constructor({logKey:e,label:t}){this.isDebug=!1,this.label=`%cENGINE`,le(e)&&(this.isDebug=!0),typeof t==`string`&&(this.label=`${this.label} ${t}`)}debug(t,...n){this.isDebug&&console.debug(this.label,e.logStyle,t,...n)}error(t,...n){console.trace(this.label,e.errorStyle,t,...n)}warn(t,...n){this.isDebug&&console.warn(this.label,e.warnStyle,t,...n)}};Tt=Et,Tt.logStyle=`background: #43A047; padding: 2px 4px;`,Tt.errorStyle=`background: #E53935; padding: 2px 4px;`,Tt.warnStyle=`background: #FB8C00; padding: 2px 4px;`;var Dt=`PREBID_NO_BIDS_CONFIGURED`;function Ot(e){return e instanceof Error&&typeof e==`object`&&!!e&&`code`in e&&e.code===Dt}var kt=new WeakMap,At=new WeakMap,jt=new WeakMap,Mt=new WeakMap,z=new WeakMap,Nt=new WeakMap,Pt=new WeakMap,Ft=new WeakMap,It=new WeakMap,Lt=new WeakMap,Rt=new WeakMap,zt=new WeakMap,Bt=new WeakMap,Vt=new WeakMap,Ht=new WeakMap,Ut=new WeakMap,B=new WeakSet,Wt=class{constructor({gpt:e,prebidAdapter:t,eventDispatcher:o,timeout:s=3e3,callbacks:c={},usePrebidClientRenderOnGptUnfilled:l,divIdToAdUnitKeyMapping:u,pageLifecycleManager:d,batchSelling:f,onAdSlotSell:p,isAdvDisabled:m}){if(L(this,B),n(this,kt,void 0),n(this,At,void 0),n(this,jt,void 0),n(this,Mt,void 0),n(this,z,void 0),n(this,Nt,void 0),n(this,Pt,void 0),n(this,Ft,new Map),n(this,It,void 0),n(this,Lt,void 0),n(this,Rt,void 0),n(this,zt,void 0),n(this,Bt,void 0),n(this,Vt,void 0),n(this,Ht,new Set),n(this,Ut,new Map),i(kt,this,e),i(At,this,t),i(jt,this,o),i(Mt,this,s),i(z,this,c),i(Lt,this,d),i(Rt,this,p),i(zt,this,m==null?(()=>!1):m),i(Pt,this,l!==!1),i(It,this,u),f){let e=e=>{let t=Nn(e);return i(Vt,this,t),t};if(typeof f==`function`){let t=f();t instanceof Promise?i(Bt,this,t.then(e)):i(Vt,this,e(t))}else f instanceof Promise?i(Bt,this,f.then(e)):i(Vt,this,e(f))}i(Nt,this,r(B,this,_n).call(this,e,t)),a(Lt,this).on(`virtualPageLoad`,e=>{e.type===`spa-route`&&r(B,this,rn).call(this)})}sell(e,t){var n;if(a(zt,this).call(this))return;(n=a(Rt,this))==null||n.call(this,r(B,this,Gt).call(this,e));let i=jn(a(Ft,this).get(e.divId),t);i&&a(Ft,this).set(e.divId,i),a(Bt,this)&&!a(Vt,this)?a(Bt,this).then(()=>{r(B,this,Kt).call(this,e,r(B,this,Jt).call(this,e.divId))}):r(B,this,Kt).call(this,e,r(B,this,Jt).call(this,e.divId))}clearAdSlotState(e){a(Ft,this).delete(e)}};function Gt(e){var t;let n=(t=a(It,this))==null?void 0:t[e.divId];return n?F(F({},e),{},{adUnitKey:n}):e}function Kt(e,t,n=!1){var i=this;return b(function*(){let o=r(B,i,Cn).call(i,t==null?void 0:t.callbacks),s=r(B,i,Gt).call(i,e),c={params:s,prebidSucceeded:!1,failedPhases:[],disableBatchSelling:n,excludeFromRefresh:(t==null?void 0:t.excludeFromRefresh)===!0},l=r(B,i,gn).call(i,t);yield de(a(Lt,i));for(let e of l){if(!e.canRun(c))continue;let t=yield e.execute(c);if(On(t))return;if(t.served){r(B,i,bn).call(i,e.phase,c,s,e.successCallback(o));return}let n=En(t),a=Dn(t);if(n){r(B,i,yn).call(i,e.phase,s,t.message,e.continuationCallback(o),c.excludeFromRefresh);continue}if(a&&(r(B,i,vn).call(i,e.phase,c,s,e.unfilledCallback(o)),e.phase!==I.Fallback))return;kn(t)&&(c.failedPhases.push(e.phase),r(B,i,xn).call(i,e.phase,s,t.error,t.originalError,e.failureCallback(o),c.excludeFromRefresh))}yield me()})()}function qt(e){var t;let n=(t=a(Vt,this))==null?void 0:t.slotRefsByDivId.get(e);if(!(!n||a(Ht,this).has(n.batchId)))return n}function Jt(e){var t;let n=a(Ft,this).get(e),i=(t=r(B,this,qt).call(this,e))==null?void 0:t.slot;return jn(n,Mn(i==null?void 0:i.sellOptions))}function Yt(e,t){let n=r(B,this,Jt).call(this,e);return t===I.Prebid?(n==null?void 0:n.excludePrebid)!==!0:t!==I.Gpt||(n==null?void 0:n.excludeGpt)!==!0}function Xt(e,t,n,i,o,s,c){a(Ut,this).has(e)||a(Ut,this).set(e,new Map);let l=a(Ut,this).get(e);l.has(t)||l.set(t,{items:new Map});let u=l.get(t);return new Promise((a,l)=>{u.items.set(n.divId,{params:n,options:i,ctx:o,resolve:a,reject:l});let d=function(){var e=b(function*(){u.timeoutId!=null&&(clearTimeout(u.timeoutId),u.timeoutId=void 0);let e=Array.from(u.items.values());u.items.clear();try{let n=yield c(e);for(let r of e){var t;let e=(t=n[r.params.divId])==null?{served:!1,error:`No result returned for slot ${r.params.divId}`}:t;r.resolve(e)}}catch(t){for(let n of e)n.reject(t)}});return function(){return e.apply(this,arguments)}}();s.slotList.filter(e=>r(B,this,Yt).call(this,e.divId,t)).every(e=>u.items.has(e.divId))?d():u.timeoutId==null&&(u.timeoutId=window.setTimeout(()=>{u.timeoutId=void 0;let n=Array.from(u.items.values());u.items.clear(),r(B,this,tn).call(this,e,t,s,n,`Batch phase timed out before all slots queued`)},s.timeout))})}function Zt(e,t,n,i){return r(B,this,Xt).call(this,e.batchId,I.Prebid,t.params,r(B,this,Jt).call(this,t.params.divId),t,e.batchDefinition,e=>r(B,this,Qt).call(this,e,n,i))}function Qt(e,t,n){var i=this;return b(function*(){let o=[],s=e.map(e=>{var t;return o.push((t=e.params.overridePrebidAdUnitCode)==null?e.params.adUnitKey:t),{adUnitKey:e.params.adUnitKey,customSizes:e.params.overrideAdUnitSizes,divId:e.params.divId,overridePrebidAdUnitCode:e.params.overridePrebidAdUnitCode,refreshCount:e.params.refreshCount,sspParams:e.params.sspParams}});try{let c=yield r(B,i,dn).call(i,n,e.map(e=>e.params));yield a(Mt,i)?Tn(t.runBatchAuction(s),a(Mt,i)):t.runBatchAuction(s),n&&(yield t.setTargetingForGPT(o),yield r(B,i,fn).call(i,{adUnitKeys:o,divIds:e.map(e=>e.params.divId),googleSlots:c,prebidAdapter:t}));let l={};for(let t of e)t.ctx.prebidSucceeded=!0,l[t.params.divId]={served:!1,continueNextHandler:!0,message:`Prebid auction executed for ${t.params.adUnitKey}, moving to next handler`};return l}catch(t){let r={},i=Ot(t);for(let a of e)n?r[a.params.divId]={served:!1,continueNextHandler:!0,message:i?`Prebid has no bids configured for ${a.params.adUnitKey}, moving to GPT handler`:`Prebid auction failed or timed out for ${a.params.adUnitKey}, moving to GPT handler`}:r[a.params.divId]={served:!1,error:An(t,`Prebid auction failed or timed out`),originalError:t};return r}})()}function $t(e,t,n,i){return r(B,this,Xt).call(this,e.batchId,I.Gpt,t.params,r(B,this,Jt).call(this,t.params.divId),t,e.batchDefinition,t=>r(B,this,en).call(this,t,e,n,i))}function en(e,t,n,i){var a=this;return b(function*(){let{batchId:o,batchDefinition:s}=t,c=e.map(e=>e.params),l=e.map(e=>r(B,a,hn).call(a,e.params.divId,`MonetizationManager:batchGptResponseCheck:${o}:${e.params.divId}`));try{let t=Promise.all(l.map(e=>e.promise));yield r(B,a,ln).call(a,c,n);let f=yield t;r(B,a,an).call(a,o,s,f);let p=new Map(f.map((t,n)=>[e[n].params.divId,t])),m={};for(let t of e){var u,d;(u=(d=p.get(t.params.divId))==null?void 0:d.isEmpty)==null||u?m[t.params.divId]={served:!1,emptyAd:!0,continueNextHandler:!!i,message:`GPT rendered empty for ${t.params.adUnitKey}, attempting Prebid client render`}:m[t.params.divId]={served:!0}}return m}catch(t){for(let e of l)e.cancel();r(B,a,on).call(a,o,s,`GPT batch failed before domination could be verified`,void 0,t);let n={};for(let r of e)i&&r.ctx.prebidSucceeded?n[r.params.divId]={served:!1,continueNextHandler:!0,message:`GPT sellAdSlots failed for ${r.params.adUnitKey}, attempting Prebid client render`}:n[r.params.divId]={served:!1,error:An(t,`GPT sellAdSlots failed`),originalError:t};return n}})()}function tn(e,t,n,i,o){var s;let c=new Map(i.map(e=>[e.params.divId,e])),l=a(Ut,this).get(e);if(l)for(let e of l.values()){e.timeoutId!=null&&(clearTimeout(e.timeoutId),e.timeoutId=void 0);for(let t of e.items.values())c.set(t.params.divId,t);e.items.clear()}r(B,this,nn).call(this,e);let u=Array.from(c.values()),d={batchId:e,phase:t,slots:u.map(e=>({adUnitKey:e.params.adUnitKey,divId:e.params.divId})),reason:o};r(B,this,wn).call(this,(s=n.callbacks)==null?void 0:s.onBatchSplit,d);for(let e of u)e.resolve({served:!1,cancelled:!0}),r(B,this,Kt).call(this,e.params,a(Ft,this).get(e.params.divId),!0)}function nn(e){a(Ht,this).add(e),a(Ut,this).delete(e)}function rn(){a(Ht,this).clear(),a(Ut,this).clear()}function an(e,t,n){var i;let o=new Map;for(let e of n)(e==null?void 0:e.adProvider)===`gpt`&&o.set(e.divId,e);let s=[];for(let e of t.slotList){let t=o.get(e.divId);if(!t)return;s.push(t)}let c=s.find(e=>e.isEmpty);if(c){r(B,this,on).call(this,e,t,`GPT rendered at least one batch slot empty`,c);return}let l=s.map(e=>e.lineItemId);if(!(l.every(e=>typeof e==`number`)&&new Set(l).size===1)){r(B,this,on).call(this,e,t,`GPT rendered the batch, but the slots do not share the same lineItemId`,s[s.length-1]);return}let u={EVENT_NAME:Ye,batchId:e,slots:r(B,this,sn).call(this,t),lineItemId:l[0],adProvider:s[0].adProvider};a(jt,this).dispatch(u),r(B,this,wn).call(this,(i=t.callbacks)==null?void 0:i.onDomination,u)}function on(e,t,n,i,a){var o;let s=F(F({batchId:e,slots:r(B,this,sn).call(this,t),reason:n},i?{trigger:i}:{}),a?{originalError:a}:{});r(B,this,nn).call(this,e),r(B,this,wn).call(this,(o=t.callbacks)==null?void 0:o.onFallback,s)}function sn(e){return e.slotList.map(e=>{var t,n,r;return{adUnitKey:(t=(n=e.adUnitKey)==null?(r=a(It,this))==null?void 0:r[e.divId]:n)==null?e.divId:t,divId:e.divId}})}function cn(e,t){return r(B,this,mn).call(this,e,t)?t.refreshSlot(e):t.sellAdSlot(e)}function ln(e,t){return e.every(e=>r(B,this,mn).call(this,e,t))?t.refreshSlots(e):t.sellAdSlots(e)}function un(e,t){return b(function*(){if(e&&typeof e.defineSlot==`function`)return e.defineSlot(t)})()}function dn(e,t){return b(function*(){return e&&typeof e.defineSlots==`function`?e.defineSlots(t):[]})()}function fn({adUnitKeys:e,divIds:t,googleSlots:n,prebidAdapter:i}){var a=this;return b(function*(){if(typeof i.getHighestCpmBids==`function`)for(let s=0;s=.04&&e<=.99?e.toString():null})});continue}u.setConfig({targeting:F(F({},r(B,a,pn).call(a,u)),{},{pt_fp:null,no_bid:Math.random()<.5?`1`:`0`})})}})()}function pn(e){if(typeof e.getConfig==`function`){let t=e.getConfig(`targeting`).targeting;if(t!=null)return F({},t)}return Object.fromEntries(e.getTargetingKeys().map(t=>[t,e.getTargeting(t)]))}function mn(e,t){return typeof t.hasDefinedSlot==`function`&&typeof t.refreshSlot==`function`&&typeof t.refreshSlots==`function`&&t.hasDefinedSlot(e.divId)}function hn(e,t){let n=!1,r,i,o=e=>{n||(n=!0,r==null||r(),i==null||i(e))};return{promise:new Promise(n=>{i=n;let s=a(jt,this).subscribe({eventName:qe,subscriberName:t,callback:t=>{t.divId===e&&t.adProvider===`gpt`&&o(t)}});r=()=>s.unsubscribe()}),cancel:()=>{o()}}}function gn(e){return!(e!=null&&e.excludePrebid)&&!(e!=null&&e.excludeGpt)&&typeof(e==null?void 0:e.useClientSideRenderFallback)!=`boolean`?a(Nt,this):r(B,this,_n).call(this,e.excludeGpt?void 0:a(kt,this),e.excludePrebid?void 0:a(At,this),{useClientSideRenderFallback:e.useClientSideRenderFallback})}function _n(e,t,{useClientSideRenderFallback:n}={}){let i=this,o=a(Mt,this),s=typeof n==`boolean`?n:a(Pt,this),c=[];return t&&c.push({phase:I.Prebid,successCallback:e=>e.onPrebidSuccess,failureCallback:e=>e.onPrebidFailure,continuationCallback:e=>e.onPrebidContinuation,unfilledCallback:e=>e.onUnfilled,canRun:()=>!0,execute(n){return b(function*(){let a=n.disableBatchSelling?void 0:r(B,i,qt).call(i,n.params.divId);if(a)return r(B,i,Zt).call(i,a,n,t,e);try{var s;let a=[],c=yield r(B,i,un).call(i,e,n.params);yield o?Tn(t.runAuction({adUnitKey:n.params.adUnitKey,customSizes:n.params.overrideAdUnitSizes,divId:n.params.divId,overridePrebidAdUnitCode:n.params.overridePrebidAdUnitCode,refreshCount:n.params.refreshCount,sspParams:n.params.sspParams}),o):t.runAuction({adUnitKey:n.params.adUnitKey,customSizes:n.params.overrideAdUnitSizes,divId:n.params.divId,overridePrebidAdUnitCode:n.params.overridePrebidAdUnitCode,refreshCount:n.params.refreshCount,sspParams:n.params.sspParams}),a.push((s=n.params.overridePrebidAdUnitCode)==null?n.params.adUnitKey:s),n.prebidSucceeded=!0,e&&(yield t.setTargetingForGPT(a),yield r(B,i,fn).call(i,{adUnitKeys:a,divIds:[n.params.divId],googleSlots:c?[c]:[],prebidAdapter:t}))}catch(t){return e?{served:!1,continueNextHandler:!0,message:Ot(t)?`Prebid has no bids configured for `+n.params.adUnitKey+`, moving to GPT handler`:`Prebid auction failed or timed out for `+n.params.adUnitKey+`, moving to GPT handler`}:{served:!1,error:An(t,`Prebid auction failed or timed out`),originalError:t}}return{served:!1,continueNextHandler:!0,message:`Prebid auction executed for `+n.params.adUnitKey+`, moving to next handler`}})()}}),e&&c.push({phase:I.Gpt,successCallback:e=>e.onGptSuccess,failureCallback:e=>e.onGptFailure,continuationCallback:e=>e.onGptContinuation,unfilledCallback:e=>e.onUnfilled,canRun:()=>!0,execute(n){return b(function*(){let a=n.disableBatchSelling?void 0:r(B,i,qt).call(i,n.params.divId);if(a)return r(B,i,$t).call(i,a,n,e,t);let o=s&&n.params.slotType!==`outOfPageInterstitial`,c=o?r(B,i,hn).call(i,n.params.divId,`MonetizationManager:gptResponseCheck`):void 0;try{var l,u;return yield r(B,i,cn).call(i,n.params,e),o&&((l=(u=yield c.promise)==null?void 0:u.isEmpty)==null||l)?{served:!1,emptyAd:!0,continueNextHandler:!!t,message:`GPT rendered empty for `+n.params.adUnitKey+`, attempting Prebid client render`}:{served:!0}}catch(e){return c==null||c.cancel(),t&&n.prebidSucceeded?{served:!1,continueNextHandler:!0,message:`GPT sellAdSlot failed for `+n.params.adUnitKey+`, attempting Prebid client render`}:{served:!1,error:An(e,`GPT sellAdSlot failed`),originalError:e}}})()}}),t&&c.push({phase:I.PrebidClientRender,successCallback:e=>e.onClientRenderSuccess,failureCallback:e=>e.onClientRenderFailure,continuationCallback:e=>e.onClientRenderContinuation,canRun:e=>e.prebidSucceeded,unfilledCallback:e=>e.onUnfilled,execute(e){return b(function*(){try{return(yield t.renderWinningBid(document,e.params.divId,e.params.adUnitKey))?{served:!0}:{served:!1,emptyAd:!0,error:`No winning Prebid bid to render`}}catch(e){return{served:!1,error:An(e,`Client-side Prebid render failed`),originalError:e}}})()}}),c.push({phase:I.Fallback,successCallback:()=>void 0,failureCallback:e=>e.onFallback,unfilledCallback:e=>e.onUnfilled,continuationCallback:()=>void 0,canRun:()=>!0,execute:function(){var e=b(function*(e){return{served:!1,emptyAd:!0,continueNextHandler:!1,error:`All selling systems failed for adUnitKey: `+e.params.adUnitKey}});return function(t){return e.apply(this,arguments)}}()}),c}function vn(e,t,n,i){let o={EVENT_NAME:Ue,adUnitKey:n.adUnitKey,divId:n.divId,phase:e,context:t};r(B,this,wn).call(this,i,o);let s=`Ad unit ${n.adUnitKey} unfilled at phase ${e}`;r(B,this,Sn).call(this,e,n,He.Unfilled,s,t.excludeFromRefresh),a(jt,this).dispatch(o)}function yn(e,t,n,i,a){let o={adUnitKey:t.adUnitKey,divId:t.divId,phase:e,type:He.Continue,message:n};r(B,this,wn).call(this,i,o),r(B,this,Sn).call(this,e,t,He.Continue,n,a)}function bn(e,t,n,i){let o={adUnitKey:n.adUnitKey,divId:n.divId,phase:e,type:He.Success};r(B,this,wn).call(this,i,o);let s={EVENT_NAME:We,adUnitKey:n.adUnitKey,divId:n.divId,phase:e,context:t};r(B,this,Sn).call(this,e,n,He.Success,void 0,t.excludeFromRefresh),a(jt,this).dispatch(s)}function xn(e,t,n,i,a,o){let s={adUnitKey:t.adUnitKey,divId:t.divId,phase:e,type:He.Failure,error:n,originalError:i};r(B,this,wn).call(this,a,s),r(B,this,Sn).call(this,e,t,He.Failure,n,o)}function Sn(e,t,n,r,i){a(jt,this).dispatch(F(F({EVENT_NAME:Je,adUnitKey:t.adUnitKey,divId:t.divId,phase:e,outcome:n,sellParams:t},i?{excludeFromRefresh:i}:{}),r?{error:r}:{}))}function Cn(e){var t,n,r,i,o,s,c,l,u,d,f;return e?{onPrebidSuccess:(t=e.onPrebidSuccess)==null?a(z,this).onPrebidSuccess:t,onPrebidFailure:(n=e.onPrebidFailure)==null?a(z,this).onPrebidFailure:n,onPrebidContinuation:(r=e.onPrebidContinuation)==null?a(z,this).onPrebidContinuation:r,onGptSuccess:(i=e.onGptSuccess)==null?a(z,this).onGptSuccess:i,onGptFailure:(o=e.onGptFailure)==null?a(z,this).onGptFailure:o,onGptContinuation:(s=e.onGptContinuation)==null?a(z,this).onGptContinuation:s,onClientRenderSuccess:(c=e.onClientRenderSuccess)==null?a(z,this).onClientRenderSuccess:c,onClientRenderFailure:(l=e.onClientRenderFailure)==null?a(z,this).onClientRenderFailure:l,onClientRenderContinuation:(u=e.onClientRenderContinuation)==null?a(z,this).onClientRenderContinuation:u,onFallback:(d=e.onFallback)==null?a(z,this).onFallback:d,onUnfilled:(f=e.onUnfilled)==null?a(z,this).onUnfilled:f}:a(z,this)}function wn(e,t){if(e)try{e(t)}catch(e){}}function Tn(e,t){return new Promise((n,r)=>{let i=setTimeout(()=>r(Error(`Auction timed out after ${t}ms`)),t);e.then(e=>{clearTimeout(i),n(e)},e=>{clearTimeout(i),r(e)})})}function En(e){return e.served===!1&&`continueNextHandler`in e&&e.continueNextHandler===!0}function Dn(e){return e.served===!1&&`emptyAd`in e&&e.emptyAd===!0&&(!(`continueNextHandler`in e)||e.continueNextHandler!==!0)}function On(e){return e.served===!1&&`cancelled`in e&&e.cancelled===!0}function kn(e){return e.served===!1&&`error`in e&&typeof e.error==`string`}function An(e,t){return typeof(e==null?void 0:e.message)==`string`?e.message:t}function jn(e,t){if(!e&&!t)return;let n=e!=null&&e.callbacks||t!=null&&t.callbacks?F(F({},e==null?void 0:e.callbacks),t==null?void 0:t.callbacks):void 0;return F(F(F({},e),t),n?{callbacks:n}:{})}function Mn(e){if(!e)return;let t=F({},e);return delete t.callbacks,t}function Nn(e){let t=new Map,n=new Map;for(let[r,i]of Object.entries(e.batches)){let e=new Map,a=[],o={batchId:r,callbacks:i.callbacks,slotList:a,slots:e,timeout:i.timeout};for(let[t,s]of Object.entries(i.slots)){let i=Pn(t,s);e.set(t,i),a.push(i),n.set(t,{batchId:r,batchDefinition:o,slot:i})}t.set(r,o)}return{batches:t,slotRefsByDivId:n}}function Pn(e,t){return t===!0?{divId:e}:F(F({},t),{},{divId:e})}function Fn(e){return e===void 0?!1:In(e)||Ln(e)}function In(e){return e!==void 0&&RegExp(`(googlebot/|Googlebot-Mobile|Googlebot-Image|Google favicon|Mediapartners-Google|hotjar|yahoo|bingbot|slurp|java|wget|curl|Commons-HttpClient|Python-urllib|libwww|httpunit|nutch|phpcrawl|msnbot|jyxobot|FAST-WebCrawler|FAST Enterprise Crawler|biglotron|teoma|convera|seekbot|gigablast|exabot|ngbot|ia_archiver|GingerCrawler|webmon|httrack|webcrawler|grub.org|UsineNouvelleCrawler|antibot|netresearchserver|speedy|fluffy|bibnum.bnf|findlink|msrbot|panscient|yacybot|AISearchBot|IOI|ips-agent|tagoobot|MJ12bot|dotbot|woriobot|yanga|buzzbot|mlbot|yandexbot|purebot|Linguee Bot|Voyager|CyberPatrol|voilabot|baiduspider|citeseerxbot|spbot|twengabot|postrank|turnitinbot|scribdbot|page2rss|sitebot|linkdex|Adidxbot|blekkobot|ezooms|Mail.RU_Bot|discobot|heritrix|findthatfile|europarchive.org|NerdByNature.Bot|sistrix crawler|ahrefsbot|Aboundex|domaincrawler|wbsearchbot|summify|ccbot|edisterbot|seznambot|ec2linkfinder|gslfbot|aihitbot|intelium_bot|facebookexternalhit|yeti|RetrevoPageAnalyzer|lb-spider|sogou|lssbot|careerbot|wotbox|wocbot|ichiro|DuckDuckBot|lssrocketcrawler|drupact|webcompanycrawler|acoonbot|openindexspider|gnam gnam spider|web-archive-net.com.bot|backlinkcrawler|coccoc|integromedb|content crawler spider|toplistbot|seokicks-robot|it2media-domain-crawler|ip-web-crawler.com|siteexplorer.info|elisabot|proximic|changedetection|blexbot|arabot|WeSEE:Search|niki-bot|CrystalSemanticsBot|rogerbot|360Spider|psbot|InterfaxScanBot|Lipperhey SEO Service|CC Metadata Scaper|g00g1e.net|GrapeshotCrawler|urlappendbot|brainobot|fr-crawler|binlar|SimpleCrawler|Livelapbot|Twitterbot|cXensebot|smtbot|bnf.fr_bot|A6-Indexer|ADmantX|Facebot|OrangeBot|memorybot|AdvBot|MegaIndex|SemanticScholarBot|ltx71|nerdybot|xovibot|BUbiNG|Qwantify|archive.org_bot|Applebot|TweetmemeBot|crawler4j|findxbot|SemrushBot|yoozBot|lipperhey|y!j-asr|Domain Re-Animator Bot|AddThis|Chrome-Lighthouse|AdsBot-Google-Mobile|AdsBot-Google)`,`i`).test(e)}function Ln(e){return e!==void 0&&RegExp(`(01h4x.com|360Spider|404checker|404enemy|80legs|ADmantX|AIBOT|ALittle Client|ASPSeek|Abonti|Aboundex|Aboundexbot|Acunetix|AfD-Verbotsverfahren|AhrefsBot|AiHitBot|Aipbot|Alexibot|AllSubmitter|Alligator|AlphaBot|Anarchie|Anarchy|Anarchy99|Ankit|Anthill|Apexoo|Aspiegel|Asterias|Atomseobot|Attach|AwarioRssBot|AwarioSmartBot|BBBike|BDCbot|BDFetch|BLEXBot|BackDoorBot|BackStreet|BackWeb|Backlink-Ceck|BacklinkCrawler|Badass|Bandit|Barkrowler|BatchFTP|Battleztar Bazinga|BetaBot|Bigfoot|Bitacle|BlackWidow|Black Hole|Blackboard|Blow|BlowFish|Boardreader|Bolt|BotALot|Brandprotect|Brandwatch|Buck|Buddy|BuiltBotTough|BuiltWith|Bullseye|BunnySlippers|BuzzSumo|CATExplorador|CCBot|CODE87|CSHttp|Calculon|CazoodleBot|Cegbfeieh|CensysInspect|CheTeam|CheeseBot|CherryPicker|ChinaClaw|Chlooe|Citoid|Claritybot|Cliqzbot|Cloud mapping|Cocolyzebot|Cogentbot|Collector|Copier|CopyRightCheck|Copyscape|Cosmos|Craftbot|Crawling at Home Project|CrazyWebCrawler|Crescent|CrunchBot|Curious|Custo|CyotekWebCopy|DBLBot|DIIbot|DSearch|DTS Agent|DataCha0s|DatabaseDriverMysqli|Demon|Deusu|Devil|Digincore|DigitalPebble|Dirbuster|Disco|Discobot|Discoverybot|Dispatch|DittoSpyder|DnBCrawler-Analytics|DnyzBot|DomCopBot|DomainAppender|DomainCrawler|DomainSigmaCrawler|DomainStatsBot|Domains Project|Dotbot|Download Wonder|Dragonfly|Drip|ECCP/1.0|EMail Siphon|EMail Wolf|EasyDL|Ebingbong|Ecxi|EirGrabber|EroCrawler|Evil|Exabot|Express WebPictures|ExtLinksBot|Extractor|ExtractorPro|Extreme Picture Finder|EyeNetIE|Ezooms|FDM|FHscan|FemtosearchBot|Fimap|Firefox/7.0|FlashGet|Flunky|Foobot|Freeuploader|FrontPage|Fuzz|FyberSpider|Fyrebot|G-i-g-a-b-o-t|GT::WWW|GalaxyBot|Genieo|GermCrawler|GetRight|GetWeb|Getintent|Gigabot|Go!Zilla|Go-Ahead-Got-It|GoZilla|Gotit|GrabNet|Grabber|Grafula|GrapeFX|GrapeshotCrawler|GridBot|HEADMasterSEO|HMView|HTMLparser|HTTP::Lite|HTTrack|Haansoft|HaosouSpider|Harvest|Havij|Heritrix|Hloader|HonoluluBot|Humanlinks|HybridBot|IDBTE4M|IDBot|IRLbot|Iblog|Id-search|IlseBot|Image Fetch|Image Sucker|IndeedBot|Indy Library|InfoNaviRobot|InfoTekies|Intelliseek|InterGET|InternetSeer|Internet Ninja|Iria|Iskanie|IstellaBot|JOC Web Spider|JamesBOT|Jbrofuzz|JennyBot|JetCar|Jetty|JikeSpider|Joomla|Jorgee|JustView|Jyxobot|Kenjin Spider|Keybot Translation-Search-Machine|Keyword Density|Kinza|Kozmosbot|LNSpiderguy|LWP::Simple|Lanshanbot|Larbin|Leap|LeechFTP|LeechGet|LexiBot|Lftp|LibWeb|Libwhisker|LieBaoFast|Lightspeedsystems|Likse|LinkScan|LinkWalker|Linkbot|LinkextractorPro|LinkpadBot|LinksManager|LinqiaMetadataDownloaderBot|LinqiaRSSBot|LinqiaScrapeBot|Lipperhey|Lipperhey Spider|Litemage_walker|Lmspider|Ltx71|MFC_Tear_Sample|MIDown tool|MIIxpc|MJ12bot|MQQBrowser|MSFrontPage|MSIECrawler|MTRobot|Mag-Net|Magnet|Mail.RU_Bot|Majestic-SEO|Majestic12|Majestic SEO|MarkMonitor|MarkWatch|Mass Downloader|Masscan|Mata Hari|MauiBot|Mb2345Browser|MeanPath Bot|Meanpathbot|Mediatoolkitbot|MegaIndex.ru|Metauri|MicroMessenger|Microsoft Data Access|Microsoft URL Control|Minefield|Mister PiX|Moblie Safari|Mojeek|Mojolicious|MolokaiBot|Morfeus Fucking Scanner|Mozlila|Mr.4x3|Msrabot|Musobot|NICErsPRO|NPbot|Name Intelligence|Nameprotect|Navroad|NearSite|Needle|Nessus|NetAnts|NetLyzer|NetMechanic|NetSpider|NetZIP|Net Vampire|Netcraft|Nettrack|Netvibes|NextGenSearchBot|Nibbler|Niki-bot|Nikto|NimbleCrawler|Nimbostratus|Ninja|Nmap|Nuclei|Nutch|Octopus|Offline Explorer|Offline Navigator|OnCrawl|OpenLinkProfiler|OpenVAS|Openfind|Openvas|OrangeBot|OrangeSpider|OutclicksBot|OutfoxBot|PECL::HTTP|PHPCrawl|POE-Component-Client-HTTP|PageAnalyzer|PageGrabber|PageScorer|PageThing.com|Page Analyzer|Pandalytics|Panscient|Papa Foto|Pavuk|PeoplePal|Petalbot|Pi-Monster|Picscout|Picsearch|PictureFinder|Piepmatz|Pimonster|Pixray|PleaseCrawl|Pockey|ProPowerBot|ProWebWalker|Probethenet|Psbot|Pu_iN|Pump|PxBroker|PyCurl|QueryN Metasearch|Quick-Crawler|RSSingBot|RankActive|RankActiveLinkBot|RankFlex|RankingBot|RankingBot2|Rankivabot|RankurBot|Re-re|ReGet|RealDownload|Reaper|RebelMouse|Recorder|RedesScrapy|RepoMonkey|Ripper|RocketCrawler|Rogerbot|SBIder|SEOkicks|SEOkicks-Robot|SEOlyticsCrawler|SEOprofiler|SEOstats|SISTRIX|SMTBot|SalesIntelligent|ScanAlert|Scanbot|ScoutJet|Scrapy|Screaming|ScreenerBot|ScrepyBot|Searchestate|SearchmetricsBot|Seekport|SemanticJuice|Semrush|SemrushBot|SentiBot|SeoSiteCheckup|SeobilityBot|Seomoz|Shodan|Siphon|SiteCheckerBotCrawler|SiteExplorer|SiteLockSpider|SiteSnagger|SiteSucker|Site Sucker|Sitebeam|Siteimprove|Sitevigil|SlySearch|SmartDownload|Snake|Snapbot|Snoopy|SocialRankIOBot|Sociscraper|Sogou web spider|Sosospider|Sottopop|SpaceBison|Spammen|SpankBot|Spanner|Spbot|Spinn3r|SputnikBot|Sqlmap|Sqlworm|Sqworm|Steeler|Stripper|Sucker|Sucuri|SuperBot|SuperHTTP|Surfbot|SurveyBot|Suzuran|Swiftbot|Szukacz|T0PHackTeam|T8Abot|Teleport|TeleportPro|Telesoft|Telesphoreo|Telesphorep|TheNomad|The Intraformant|Thumbor|TightTwatBot|Titan|Toata|Toweyabot|Tracemyfile|Trendiction|Trendictionbot|True_Robot|Turingos|Turnitin|TurnitinBot|TwengaBot|Twice|Typhoeus|URLy.Warning|URLy Warning|UnisterBot|Upflow|V-BOT|VB Project|VCI|Vacuum|Vagabondo|VelenPublicWebCrawler|VeriCiteCrawler|VidibleScraper|Virusdie|VoidEYE|Voil|Voltron|WASALive-Bot|WBSearchBot|WEBDAV|WISENutbot|WPScan|WWW-Collector-E|WWW-Mechanize|WWW::Mechanize|WWWOFFLE|Wallpapers|Wallpapers/3.0|WallpapersHD|WeSEE|WebAuto|WebBandit|WebCollage|WebCopier|WebEnhancer|WebFetch|WebFuck|WebGo IS|WebImageCollector|WebLeacher|WebPix|WebReaper|WebSauger|WebStripper|WebSucker|WebWhacker|WebZIP|Web Auto|Web Collage|Web Enhancer|Web Fetch|Web Fuck|Web Pix|Web Sauger|Web Sucker|Webalta|WebmasterWorldForumBot|Webshag|WebsiteExtractor|WebsiteQuester|Website Quester|Webster|Whack|Whacker|Whatweb|Who.is Bot|Widow|WinHTTrack|WiseGuys Robot|Wonderbot|Woobot|Wotbox|Wprecon|Xaldon WebSpider|Xaldon_WebSpider|Xenu|YoudaoBot|Zade|Zauba|Zermelo|Zeus|Zitebot|ZmEu|ZoomBot|ZoominfoBot|ZumBot|ZyBorg|adscanner|archive.org_bot|arquivo-web-crawler|arquivo.pt|autoemailspider|backlink-check|cah.io.community|check1.exe|clark-crawler|coccocbot|cognitiveseo|com.plumanalytics|crawl.sogou.com|crawler.feedback|crawler4j|dataforseo.com|demandbase-bot|domainsproject.org|eCatch|evc-batch|facebookscraper|gopher|heritrix|instabid|internetVista monitor|ips-agent|isitwp.com|iubenda-radar|linkdexbot|lwp-request|lwp-trivial|magpie-crawler|meanpathbot|mediawords|muhstik-scan|netEstate NE Crawler|oBot|page scorer|pcBrowser|plumanalytics|polaris version|probe-image-size|ripz|s1z.ru|satoristudio.net|scalaj-http|scan.lol|seobility|seocompany.store|seoscanners|seostar|serpstatbot|sexsearcher|sitechecker.pro|siteripz|sogouspider|sp_auditbot|spyfu|sysscan|tAkeOut|trendiction.com|trendiction.de|ubermetrics-technologies.com|voyagerx.com|webgains-bot|webmeup-crawler|webpros.com|webprosbot|x09Mozilla|x22Mozilla|xpymep1.exe|zauba.io|zgra)`,`i`).test(e)}var Rn=null;function zn({adUnitSizeConfig:e,logger:t,isOnPostInjection:n=!1,device:r}){let i=`unknown`;try{i=fe(window.navigator)}catch(e){console.error(`Error while getting browser language`,e)}if(Fn(window.navigator.userAgent)&&i!==`it-IT`)return;t.debug(`== Scale iframe == Is enabled`),Rn==null?(t.debug(`== Scale iframe == Configuring MutationObserver`),Rn=new MutationObserver(e=>{for(let n of e){let e=n.target;t.debug(`== Scale iframe == Detected mutation ${n.type} inside the ${e.id} container`);let r=n.type===`childList`&&e.firstElementChild!=null&&e.firstElementChild.tagName===`IFRAME`,i=n.type===`attributes`&&e.tagName===`IFRAME`;if(r||i)try{let n=e.closest(`div[data-unit-key]`);if(n==null){t.debug(`== Scale iframe == Parent element with data-unit-key attribute not found for the mutated element with id ${e.id}, skipping scaling.`);continue}let r=n.dataset.unitKey;if(r==null){t.debug(`== Scale iframe == adUnitKey not found for the mutated element with id ${e.id}, skipping scaling.`);continue}Wn({adUnitKey:r,containerWidth:n.dataset.scaleiframeWidth,containerHeight:n.dataset.scaleiframeHeight,logger:t})}catch(e){t.debug(`== Scale iframe == Something gone wrong while scaling the iframe`,e)}}})):t.debug(`== Scale iframe == MutationObserver is already configured`);let a={desktop:{},mobile:{},tablet:{}};typeof e==`object`&&e[r]!=null&&(n?a[r]=e[r]:a[r]=F(F({},a[r]),e[r]));let o=a[r];for(let e in o){let n=document.querySelector(`div#${e}`);n==null?t.debug(`== Scale iframe ${e} == Container not found, skip..`):(n.dataset.unitKey=e,o[e].containerWidth!=null&&(n.dataset.scaleiframeWidth=String(o[e].containerWidth)),o[e].containerHeight!=null&&(n.dataset.scaleiframeHeight=String(o[e].containerHeight)),t.debug(`== Scale iframe ${e} == Observing container for mutations.. If the container width is ${o[e].containerWidth} and container height is ${o[e].containerHeight}, the iframes inside will be scaled accordingly.`),Rn.observe(n,{attributes:!0,attributeFilter:[`width`,`height`],childList:!0,subtree:!0}))}}var Bn=5,Vn=50;function Hn(e){let t=typeof e==`number`?e:Number(String(e==null?``:e).replace(`px`,``).trim());return Number.isFinite(t)&&t>1?t:null}function Un({iframe:e,adUnitKey:t,logger:n,allowLayoutRead:r}){let i=[{label:`getAttribute`,read:()=>({width:e.getAttribute(`width`),height:e.getAttribute(`height`)})},{label:`style`,read:()=>({width:e.style.width,height:e.style.height})},{label:`getBoundingClientRect`,read:()=>{let t=e.getBoundingClientRect();return{width:t.width,height:t.height}}}],a=null,o=null;for(let e of r?i:i.slice(0,-1)){var s,c;let r=e.read(),i=Hn(r.width),l=Hn(r.height);if(n.debug(`== Scale iframe ${t} == iframeWidth is ${i} and iframeHeight is ${l} from ${e.label}`),a=(s=a)==null?i:s,o=(c=o)==null?l:c,a!=null&&o!=null)break}return a==null||o==null?null:{width:a,height:o}}function Wn({adUnitKey:e,containerHeight:t,containerWidth:n,logger:r,attempt:i=0}){r.debug(`== Scale iframe ${e} == Scale iframe starting..`),r.debug(`== Scale iframe ${e} == containerWidth is ${n} and containerHeight is ${t}`);let a=document.querySelector(`div#${e} iframe`);if(a==null){r.debug(`== Scale iframe ${e} == Iframe not found, exit..`);return}if(a.getAttribute(`scaled-iframe`)===`true`){r.debug(`== Scale iframe ${e} == Already applied, exit..`);return}let o=Un({iframe:a,adUnitKey:e,logger:r,allowLayoutRead:i>0});if(o==null){if(i===0&&a.dataset.scaleiframeRetryPending===`true`){r.debug(`== Scale iframe ${e} == Size not measurable yet, a retry is already pending, exit..`);return}let o=i+1;if(o>=Bn){delete a.dataset.scaleiframeRetryPending,r.debug(`== Scale iframe ${e} == Size still not measurable after ${Bn} attempts, giving up..`);return}a.dataset.scaleiframeRetryPending=`true`,r.debug(`== Scale iframe ${e} == Size not measurable yet, retrying (${o}/${Bn})`),requestAnimationFrame(()=>{setTimeout(()=>{Wn({adUnitKey:e,containerHeight:t,containerWidth:n,logger:r,attempt:o})},Vn)});return}delete a.dataset.scaleiframeRetryPending;let s=o.width,c=o.height;r.debug(`== Scale iframe ${e} == Final iframeWidth ${s} and iframeHeight ${c} detected`);let l;n!=null&&(l=Math.min(Number(n)/s,v()/c),r.debug(`== Scale iframe ${e} == The scaling factor for the container width is: ${l}`));let u;t!=null&&(u=Math.min(Number(t)/c,_()/s),r.debug(`== Scale iframe ${e} == The scaling factor for the container height is: ${u}`));let d;if(l!=null&&u!=null)d=Math.min(l,u);else{var f;d=(f=l)==null?u:f}r.debug(`== Scale iframe ${e} == The scaling factor is: ${d}`),typeof d==`number`&&!isNaN(d)&&d<1?(r.debug(`== Scale iframe ${e} == The scale iframe is needed`),a.setAttribute(`scaled-iframe`,`true`),a.style.transformOrigin=`top left`,a.style.transform=`scale(${d})`,a.style.width=`${s}px`,a.style.height=`${c}px`,a.style.maxWidth=`none`,a.parentElement!=null&&(a.parentElement.style.width=`${d*s}px`,a.parentElement.style.height=`${d*c}px`,a.parentElement.style.overflow=`hidden`,a.parentElement.style.justifyContent=`flex-start`,a.parentElement.style.alignItems=`flex-start`)):(r.debug(`== Scale iframe ${e} == The iframe not need to be scaled`),a.setAttribute(`scaled-iframe`,`false`))}var Gn=`:root{--floorad-desktop-bg:transparent;--floorad-mobile-bg:#fafafa}div#floorad-container{justify-content:center;align-items:center;width:100%;height:100px;display:flex}div#floorad-container.bottom-slot{position:fixed}div#floorad-container.desktop-container{-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px);background-color:var(--floorad-desktop-bg);z-index:9999998;box-shadow:0 0 5px rgba(0,0,0,.2)}div#floorad-container.bottom-slot.desktop-container{bottom:0;left:0;transform:translateY(calc(100% + 10px))}div#floorad-container.bottom-slot.desktop-container.rendered-floorad{transform:translateY(0)!important}div#floorad-container.mobile-container{z-index:2147483640}div#floorad-container.bottom-slot.mobile-container{background-color:var(--floorad-mobile-bg);bottom:0;left:0;transform:translate(calc(-100% - 10px));box-shadow:0 0 5px rgba(0,0,0,.2)}div#floorad-container.anchor-slot.mobile-container{background-color:transparent}div#floorad-container.bottom-slot.mobile-container.rendered-floorad{transform:translate(0)!important}div#floorad-container.anchor-slot.mobile-container.rendered-floorad{background-color:var(--floorad-mobile-bg);box-shadow:0 0 5px rgba(0,0,0,.2)}div#floorad-close-button{position:absolute;left:0}div#floorad-close-button.desktop-button{cursor:pointer;z-index:1;width:35px;height:100%}div#floorad-close-button.mobile-button{text-align:center;width:30px;height:30px}div#floorad-container.bottom-slot div#floorad-close-button.mobile-button{background-color:var(--floorad-mobile-bg);border-radius:0 12px 0 0;top:-30px;box-shadow:0 -1px 1px rgba(0,0,0,.2)}div#floorad-container.anchor-slot div#floorad-close-button.mobile-button{background-color:transparent;display:none;top:60px}div#floorad-container.anchor-slot.rendered-floorad div#floorad-close-button.mobile-button{display:block}span#floorad-close-button-text{color:#000;text-align:center;text-shadow:0 0 3px #fff,0 0 5px #fff}div#floorad-close-button.desktop-button span#floorad-close-button-text{width:100%;font-size:18px;position:absolute;top:50%;transform:translateY(-50%)}div#floorad-close-button.mobile-button span#floorad-close-button-text{z-index:1;line-height:30px;position:relative}div#floorad-no-click{position:absolute}div#floorad-no-click.desktop-no-click{width:115px;height:140%;bottom:0;left:-40px}div#floorad-no-click.mobile-no-click{left:0}div#floorad-container.bottom-slot div#floorad-no-click.mobile-no-click{width:65px;height:85px;top:-55px}div#floorad-container.anchor-slot div#floorad-no-click.mobile-no-click{width:40px;height:40px;top:55px}div#F_M{overflow:hidden}div#floorad-container>div#F_D,div#floorad-container>div#F_M{justify-content:center;align-items:center;height:100%;display:flex;overflow:hidden}`,Kn=`plugin:completed`;function qn(e,t,n){return Jn.apply(this,arguments)}function Jn(){return Jn=b(function*(e,t,n){let r=Array.isArray(e)?e:[e],i=[];for(let e=0;e0&&(yield me(),n.debug(`Yielded to the main thread before starting compile plugin [${a.pluginName}]`)),i.push(new Promise(e=>{try{let r=a.run(r=>{r.type===`error`&&n.error(`Compile plugin [${a.pluginName}] error:`,r.message);let i=r.type===`completed`&&r.deliveryStatus!==void 0?{deliveryStatus:r.deliveryStatus}:void 0;t.dispatch({EVENT_NAME:Kn,metadata:i,pluginName:a.pluginName,outcome:r.type===`completed`?`success`:r.type}),e()});r instanceof Promise&&r.catch(r=>{n.error(`Compile plugin [${a.pluginName}] threw:`,r),t.dispatch({EVENT_NAME:Kn,pluginName:a.pluginName,outcome:`error`}),e()})}catch(r){n.error(`Compile plugin [${a.pluginName}] threw synchronously:`,r),t.dispatch({EVENT_NAME:Kn,pluginName:a.pluginName,outcome:`error`}),e()}}))}Promise.allSettled(i)}),Jn.apply(this,arguments)}function Yn(e,t,n){let r=Object.entries(e).sort(([e],[t])=>Number(e)-Number(t)).map(([,e])=>e),i=[],a={},o=new Map,s=new Map;for(let e of r)e.plugin!==null&&s.set(e.plugin.pluginName,e);let c=0,l=null,u=null,d=new Map;function f(e,t){return t!==void 0&&d.get(e)===t}function p(e,t){try{var n;let r=(n=e.softTeardown)==null?void 0:n.call(e,t);return r==null?void 0:r.catch(t=>{console.debug(`Plugin [${e.pluginName}] soft teardown rejected:`,t)})}catch(t){console.debug(`Plugin [${e.pluginName}] soft teardown threw:`,t);return}}function m(e,t,n){let i;for(let a=r.length-1;a>=0;a--){let o=r[a].plugin;if((o==null?void 0:o.softTeardown)!=null&&!f(o.pluginName,t)){if(i!=null){i=i.then(()=>{if(e===c)return p(o,n)});continue}i=p(o,n)}}return i}function h(e,t,n,r){let i={afterFlowOnly:r,completions:new Map,token:e,url:t,virtualNavigationType:n};return g(i),i}function g(e){for(let{plugin:t}of r){if(t===null||e.completions.has(t.pluginName)||f(t.pluginName,e.url))continue;let n=o.get(t.pluginName);if(n===void 0||e.afterFlowOnly&&n.position!==`engine:afterFlow`)continue;let r,i=new Promise(e=>{r=e});e.completions.set(t.pluginName,{promise:i,settle:r}),delete a[t.pluginName]}}function _(e,t){return v.apply(this,arguments)}function v(){return v=b(function*(e,t){let n=t;for(;n!==c;){n=c;let t=(l==null?void 0:l.token)===n?l.closing:void 0;if(t!=null&&(yield t),n!==c)continue;let r=u;if(r===null||r.token!==n)return;let i=x(e,r);if(i.length===0)return;yield Promise.all(i)}}),v.apply(this,arguments)}function y(){let e=u;if(e!==null){u=null;for(let{settle:t}of e.completions.values())t()}}function x(e,t){var n;let r=(n=s.get(e))==null?void 0:n.waitFor;if(r===void 0)return[];let i=[];for(let n of r){if(typeof n!=`string`||n===e)continue;let r=t.completions.get(n);r!==void 0&&i.push(r.promise)}return i}function S(e,t){for(let{plugin:n}of r){if(n===null)continue;if(t.token!==c)return;let r=o.get(n.pluginName);r===void 0||r.position!==e||t.completions.has(n.pluginName)&&C(n.pluginName,r,t)}}function C(e,t,n){return ee.apply(this,arguments)}function ee(){return ee=b(function*(e,t,r){try{let i=x(e,r);if(i.length>0&&(yield Promise.all(i)),r.token!==c)return;if(typeof t.getShouldRun==`function`){let e=t.getShouldRun({context:n,pluginOutcomes:a});if(!(e instanceof Promise?yield e:e)||r.token!==c)return}r.url!==void 0&&d.set(e,r.url),yield t.run(r.virtualNavigationType)}catch(t){console.debug(`Plugin [${e}] rerun failed:`,t)}finally{var i;(i=r.completions.get(e))==null||i.settle()}}),ee.apply(this,arguments)}function w(e,t){let n=(l==null?void 0:l.token)===t.token?l.closing:void 0;if(n==null){S(e,t);return}n.then(()=>{t.token===c&&S(e,t)})}function T(e,n){return typeof n==`string`?a[n]!==void 0||s.get(n)===void 0?Promise.resolve():new Promise(r=>{let{unsubscribe:i}=t.subscribe({eventName:Kn,subscriberName:`chain-wait-${e}-for-${n}`,callback:e=>{var t;e.pluginName===n&&(a[e.pluginName]={deliveryStatus:(t=e.metadata)==null?void 0:t.deliveryStatus,outcome:e.outcome},i(),r())}})}):n}function E(e,t){if(t.type!==`virtual`)return;let r=t.virtualNavigationType;if(r===void 0||r===`infinite-scroll`)return;let i=r===`bfcache-restore`?void 0:t.url;if(e===`engine:beforeFlow`){let t=++c;if(l=null,y(),n.adSlotLifecycleApi.isAdvDisabled())return;let a=h(t,i,r,!1);u=a;let o=m(t,i,r);o==null?g(a):l={closing:o.then(()=>{t===c&&g(a)}),token:t},w(e,a);return}if(n.adSlotLifecycleApi.isAdvDisabled()){y();return}let a=c,o=u!==null&&u.token===a?u:null;o===null&&(o=h(a,i,r,!0),u=o),w(e,o)}for(let e of[To,Eo])t.subscribe({eventName:e,subscriberName:`chain-virtual-navigation-${e}`,callback:t=>E(e,t)});for(let e of r){var D;let r=e.plugin;if(r===null)continue;let s=r.pluginName,{getShouldRun:l,timeout:u,waitFor:f}=e;r.onDisableAds!=null&&t.subscribe({eventName:To,subscriberName:`${s}-disable-ads`,callback:function(){var e=b(function*(e){var t;e.type===`virtual`&&e.virtualNavigationType!==void 0&&n.adSlotLifecycleApi.isAdvDisabled()&&(yield(t=r.onDisableAds)==null?void 0:t.call(r,e.virtualNavigationType))});return function(t){return e.apply(this,arguments)}}()});let p={pluginName:s,onDisableAds:(D=r.onDisableAds)==null?void 0:D.bind(r),run(e){let t=c,i=(f==null?[]:f).map(e=>T(s,e));(function(){var f=b(function*(){yield Promise.all(i),c!==t&&(yield _(s,t));let f=!1,p=e=>{a[s]={deliveryStatus:e.type===`completed`?e.deliveryStatus:void 0,outcome:e.type===`completed`?`success`:e.type}},m=t=>{if(f)return;f=!0,p(t);let n=t.type===`completed`?t.onVirtualNavigationHook:void 0;n!=null&&(console.debug(`Plugin [${s}] completed with a virtual navigation hook at ${n.position}.`),o.set(s,{getShouldRun:l,position:n.position,run:n.run})),e(t)},h;if(u!==void 0&&u>0&&(h=setTimeout(()=>{m({type:`timeout`,message:`Plugin [${s}] timed out after ${u}ms`})},u)),typeof l==`function`){let e=l({context:n,pluginOutcomes:a});if(!(e instanceof Promise?yield e:e)){m({type:`skipped`});return}}d.set(s,window.location.href);let g=r.run(e=>{if(h!==void 0&&clearTimeout(h),f){p(e);return}m(e)});g instanceof Promise&&g.catch(e=>{h!==void 0&&clearTimeout(h),m({type:`error`,message:String(e)})})});return function(){return f.apply(this,arguments)}})()().catch(t=>{e({type:`error`,message:String(t)})})}};i.push(p)}return i}function Xn(e,t,n,r){let i={},a=0;for(let[,n]of Object.entries(e)){if(!n)continue;let e=null;try{e=n.getPluginInstance(t)}catch(e){r.error(`Plugin factory threw during initialization:`,e)}i[a]={plugin:e,getShouldRun:n.getShouldRun,waitFor:n.waitFor,timeout:n.timeout},a++}return Yn(i,n,t)}var Zn=new Map([[7,{prefix:`usnat`,optOutFields:[`SaleOptOut`,`SharingOptOut`,`TargetedAdvertisingOptOut`]}],[8,{prefix:`usca`,optOutFields:[`SaleOptOut`,`SharingOptOut`]}],[9,{prefix:`usva`,optOutFields:[`SaleOptOut`,`TargetedAdvertisingOptOut`]}],[10,{prefix:`usco`,optOutFields:[`SaleOptOut`,`TargetedAdvertisingOptOut`]}],[12,{prefix:`usct`,optOutFields:[`SaleOptOut`,`TargetedAdvertisingOptOut`]}],[13,{prefix:`usfl`,optOutFields:[`SaleOptOut`,`TargetedAdvertisingOptOut`]}]]),Qn=[2,7,9,10],$n=100,er=50;function tr(){return{cmpUiShown:!1,consentManagementMetadata:{},consentManagementType:``,personalizedAds:!0}}var nr=new WeakMap,rr=new WeakMap,ir=new WeakMap,ar=new WeakMap,or=new WeakMap,sr=new WeakMap,cr=new WeakMap,lr=new WeakMap,ur=new WeakMap,dr=new WeakMap,fr=new WeakMap,pr=new WeakMap,V=new WeakSet,mr=class{constructor(){L(this,V),n(this,nr,new Set),n(this,rr,0),n(this,ir,`fallback`),n(this,ar,!1),n(this,or,null),n(this,sr,null),n(this,cr,!0),n(this,lr,!1),n(this,ur,null),n(this,dr,null),n(this,fr,null),n(this,pr,er)}onConsentReleased(e){var t,n;let o=e==null?void 0:e.onConsentCallback,s=(t=e==null?void 0:e.waitUntilPersonalizedAdsIsTrue)!=null&&t,c=(n=e==null?void 0:e.once)!=null&&n,l=o?{callback:o,waitForPersonalized:s,once:c}:null;return l&&a(nr,this).add(l),a(dr,this)&&l?(r(V,this,Sr).call(this,l,a(dr,this)),()=>{a(nr,this).delete(l)}):(a(lr,this)||((e==null?void 0:e.attemptThreshold)!==void 0&&i(pr,this,e.attemptThreshold),i(lr,this,!0),r(V,this,hr).call(this)),()=>{l&&a(nr,this).delete(l)})}hasUserAcceptedConsent(){return a(cr,this)}consentManagementApiUsed(){return a(ir,this)}destroy(){i(ar,this,!0),r(V,this,wr).call(this),r(V,this,Tr).call(this),r(V,this,Er).call(this),a(nr,this).clear()}};function hr(){var e;if(!a(ar,this)){if(window.__tcfapi){r(V,this,gr).call(this);return}if(window.__gpp){r(V,this,_r).call(this);return}if(window.__uspapi){r(V,this,vr).call(this);return}if(i(rr,this,(e=a(rr,this),e++,e)),a(pr,this)!==null&&a(rr,this)>=a(pr,this)){r(V,this,yr).call(this);return}i(ur,this,setTimeout(()=>{r(V,this,hr).call(this)},$n))}}function gr(){let e=window.__tcfapi;e&&e(`addEventListener`,2,(e,t)=>{if(a(ar,this)||!t||(i(fr,this,e.listenerId),e.eventStatus!==`tcloaded`&&e.eventStatus!==`useractioncomplete`))return;i(cr,this,Qn.every(t=>e.purpose.consents[t]===!0));let n={cmpUiShown:e.eventStatus===`useractioncomplete`,consentManagementMetadata:{},consentManagementType:`tcf`,personalizedAds:a(cr,this)};i(ir,this,`tcf`),a(cr,this)&&window.dispatchEvent(new Event(`cookie_accepted`)),r(V,this,br).call(this,n)})}function _r(){let e=window.__gpp;if(!e)return;let t=e=>{if(a(ar,this)||(i(sr,this,e.listenerId),e.eventName!==`signalStatus`||e.data!==`ready`))return;let{applicableSections:t,parsedSections:n}=e.pingData,o,s;for(let e of t){let t=Zn.get(e);if(t){o=t,s=e;break}}if(!o||s===void 0){r(V,this,Er).call(this),window.__tcfapi?r(V,this,gr).call(this):window.__uspapi?r(V,this,vr).call(this):r(V,this,yr).call(this);return}let c=n[o.prefix];if(c&&c.length>0){let e=c[0];for(let t of o.optOutFields)if(e[t]===1){i(cr,this,!1);break}}let l={cmpUiShown:!1,consentManagementMetadata:{gppSectionId:s},consentManagementType:`gpp`,personalizedAds:a(cr,this)};i(ir,this,`gpp`),r(V,this,br).call(this,l)};i(or,this,t),e(`addEventListener`,t)}function vr(){let e=window.__uspapi;e&&e(`getUSPData`,1,(e,t)=>{if(a(ar,this))return;if(!t||e.version!==1){r(V,this,yr).call(this);return}let n={cmpUiShown:!1,consentManagementMetadata:{uspString:e.uspString},consentManagementType:`usp`,personalizedAds:!0};i(ir,this,`usp`),i(dr,this,n),r(V,this,xr).call(this,n)})}function yr(){let e=tr();console.log(`ConsentReader: no CMP detected, using fallback`),i(dr,this,e),r(V,this,xr).call(this,e)}function br(e){i(dr,this,e),r(V,this,xr).call(this,e),r(V,this,Cr).call(this)?console.log(`ConsentReader: listener kept active for non-once subscribers`,e):(r(V,this,Tr).call(this),r(V,this,Er).call(this))}function xr(e){for(let t of Array.from(a(nr,this)))r(V,this,Sr).call(this,t,e)}function Sr(e,t){e.waitForPersonalized&&!t.personalizedAds||(e.callback(t),e.once&&a(nr,this).delete(e))}function Cr(){for(let e of a(nr,this))if(!e.once)return!0;return!1}function wr(){a(ur,this)!==null&&(clearTimeout(a(ur,this)),i(ur,this,null))}function Tr(){a(fr,this)!==null&&window.__tcfapi&&(window.__tcfapi(`removeEventListener`,2,()=>{},a(fr,this)),i(fr,this,null))}function Er(){a(sr,this)!==null&&window.__gpp&&a(or,this)&&(window.__gpp(`removeEventListener`,a(or,this),a(sr,this)),i(or,this,null),i(sr,this,null))}var Dr,Or=200,kr=`spa-route`;function Ar(){var e;return typeof PerformanceObserver<`u`&&!!((e=PerformanceObserver.supportedEntryTypes)!=null&&e.includes(`soft-navigation`))}function jr(e){return e===`unknown`?kr:e}function Mr(){return typeof location>`u`?null:location.href}var Nr=new WeakMap,Pr=new WeakMap,Fr=new WeakMap,Ir=new WeakMap,Lr=new WeakMap,Rr=new WeakMap,zr=new WeakMap,Br=new WeakMap,Vr=new WeakMap,Hr=new WeakMap,Ur=new WeakMap,Wr=new WeakMap,Gr=new WeakMap,H=new WeakSet,Kr=class e{constructor(){L(this,H),n(this,Nr,{stateChange:new Set,bfcacheRestore:new Set,virtualPageLoad:new Set,networkChange:new Set,viewTransition:new Set}),n(this,Pr,new Set),n(this,Fr,[]),n(this,Ir,null),n(this,Lr,null),n(this,Rr,void 0),n(this,zr,0),n(this,Br,null),n(this,Vr,Mr()),n(this,Hr,Mr()),n(this,Ur,Or),n(this,Wr,!1),n(this,Gr,kr),i(Rr,this,r(H,this,qr).call(this))}static init(){if(e.instance)return e.instance;let t=new e;return e.instance=t,r(H,t,Yr).call(t),t}static getInstance(){return e.instance}static resetForTesting(){let t=e.instance;t&&r(H,t,ni).call(t),e.instance=null}getState(){return a(Rr,this)}on(e,t){let n=a(Nr,this)[e];return n.add(t),()=>{n.delete(t)}}registerManagedObserver(e){let t={setup:e,teardown:null};return t.teardown=e(),a(Pr,this).add(t),()=>{t.teardown&&t.teardown(),a(Pr,this).delete(t)}}configure(e={}){var t;r(H,this,Zr).call(this);let n=e.provider==null&&e.useSoftNavigationApis===!0&&Ar();if(n&&r(H,this,Xr).call(this),e.titleObserver!==!1){var a,o;let t=(a=e.titleObserver)==null?{}:a,c=jr((o=t.reportsAs)==null?kr:o);if(n&&c===`spa-route`)console.warn(`[PLM] 'spa-route' is already covered by the soft-navigation observer, skipping the title observer to avoid double-reporting it`);else{var s;i(Ur,this,(s=t.debounceDuration)==null?Or:s),i(Gr,this,c),i(Wr,this,!0),r(H,this,$r).call(this)}}(t=e.provider)==null||t.call(e,e=>{this.handleVirtualPageLoad(e)})}transitionTo(e){let t=a(Rr,this);t!==e&&(i(Rr,this,e),r(H,this,ti).call(this,`stateChange`,e,t))}handleVirtualPageLoad(e){var t=this;return b(function*(){if(r(H,t,ei).call(t,e))return;let n=jr(e.type);if(n===`spa-route`){let e=Array.from(a(Pr,t));for(let t of e)t.teardown&&(t.teardown(),t.teardown=null);yield Promise.resolve();for(let t of e)t.teardown=t.setup()}r(H,t,ti).call(t,`virtualPageLoad`,e),n===`spa-route`&&a(Wr,t)&&(yield new Promise(e=>setTimeout(e,0)),r(H,t,$r).call(t))})()}};Dr=Kr;function qr(){return typeof document>`u`?`active`:`prerendering`in document&&document.prerendering?`prerendering`:document.visibilityState===`hidden`?`hidden`:document.hasFocus()?`active`:`passive`}function Jr(){document.visibilityState===`hidden`?this.transitionTo(`hidden`):document.hasFocus()?this.transitionTo(`active`):this.transitionTo(`passive`)}function Yr(){r(H,this,U).call(this,document,`visibilitychange`,()=>{r(H,this,Jr).call(this)}),r(H,this,U).call(this,window,`focus`,()=>{document.visibilityState===`visible`&&this.transitionTo(`active`)}),r(H,this,U).call(this,window,`blur`,()=>{document.visibilityState===`visible`&&this.transitionTo(`passive`)}),r(H,this,U).call(this,document,`freeze`,()=>{this.transitionTo(`frozen`)}),r(H,this,U).call(this,document,`resume`,()=>{document.visibilityState===`hidden`?this.transitionTo(`hidden`):document.hasFocus()?this.transitionTo(`active`):this.transitionTo(`passive`)}),r(H,this,U).call(this,window,`pageshow`,e=>{e.persisted&&(this.transitionTo(`active`),r(H,this,ti).call(this,`bfcacheRestore`,{isOnline:navigator.onLine}))}),r(H,this,U).call(this,window,`pagehide`,e=>{e.persisted?this.transitionTo(`frozen`):this.transitionTo(`terminated`)}),r(H,this,U).call(this,window,`online`,()=>{r(H,this,ti).call(this,`networkChange`,!0)}),r(H,this,U).call(this,window,`offline`,()=>{r(H,this,ti).call(this,`networkChange`,!1)}),`prerendering`in document&&document.prerendering&&r(H,this,U).call(this,document,`prerenderingchange`,()=>{this.transitionTo(`active`)}),`onpageswap`in window&&r(H,this,U).call(this,window,`pageswap`,e=>{r(H,this,ti).call(this,`viewTransition`,e,`swap`)}),`onpagereveal`in window&&r(H,this,U).call(this,window,`pagereveal`,e=>{r(H,this,ti).call(this,`viewTransition`,e,`reveal`)})}function Xr(){let e=new PerformanceObserver(e=>{for(let t of e.getEntries())this.handleVirtualPageLoad({url:t.name||location.href,type:`spa-route`})});e.observe({type:`soft-navigation`,buffered:!0}),i(Lr,this,()=>e.disconnect())}function Zr(){i(Wr,this,!1),i(Vr,this,Mr()),i(Hr,this,Mr()),i(Gr,this,kr),i(Ur,this,Or),r(H,this,Qr).call(this),a(Lr,this)&&(a(Lr,this).call(this),i(Lr,this,null))}function Qr(){a(Ir,this)&&(a(Ir,this).disconnect(),i(Ir,this,null)),a(Br,this)!==null&&(clearTimeout(a(Br,this)),i(Br,this,null))}function $r(){r(H,this,Qr).call(this);let e=null,t=new MutationObserver(()=>{a(Br,this)!==null&&clearTimeout(a(Br,this)),i(Br,this,setTimeout(()=>{var t,n;if(i(Br,this,null),document.title==e)return;e=document.title;let r=(t=Mr())==null?``:t,o=r!==a(Hr,this);i(Hr,this,r),i(zr,this,(n=a(zr,this),n++,n)),this.handleVirtualPageLoad({url:o?r:`${r}#pt-title-${a(zr,this)}`,type:a(Gr,this)})},a(Ur,this)))});function n(){let n=document.querySelector(`title`);if(!n){console.log(`[PLM] No element found, skipping title observer`);return}e=document.title,t.observe(n,{childList:!0,characterData:!0,subtree:!0})}T(function(){document.readyState==`interactive`?document.addEventListener(`readystatechange`,()=>{document.readyState==`complete`&&n()}):n()}),i(Ir,this,t)}function ei({url:e}){return e===a(Vr,this)?!0:(i(Vr,this,e),!1)}function ti(e,...t){let n=Array.from(a(Nr,this)[e]);for(let e of n)e(...t)}function U(e,t,n){e.addEventListener(t,n),a(Fr,this).push(()=>{e.removeEventListener(t,n)})}function ni(){for(let e of a(Fr,this))e();a(Fr,this).length=0,r(H,this,Zr).call(this);for(let e of Array.from(a(Pr,this)))e.teardown&&e.teardown();a(Pr,this).clear();for(let e of Object.keys(a(Nr,this)))a(Nr,this)[e].clear()}Dr.instance=null;var ri=[`og:type`,`article:section`,`article:tag`,`page-type`],ii=new Set([`active`,`passive`,`hidden`,`frozen`]),ai=new WeakMap,oi=new WeakMap,si=new WeakMap,ci=new WeakMap,li=new WeakMap,ui=new WeakMap,di=new WeakMap,W=new WeakSet,fi=class{constructor(e,t){var a;L(this,W),n(this,ai,[]),n(this,oi,{contextUpdated:new Set,visibilityChanged:new Set,networkChanged:new Set}),n(this,si,[]),n(this,ci,void 0),n(this,li,void 0),n(this,ui,void 0),n(this,di,null),i(ci,this,(a=e==null?void 0:e.metaTagWhitelist)==null?ri:a),i(li,this,t==null?((e,t)=>{console.error(`ContextManager: ${e}`,t)}):t),i(ui,this,r(W,this,pi).call(this,`initial`)),r(W,this,hi).call(this),w()||r(W,this,vi).call(this)}getCurrentContext(){return r(W,this,_i).call(this,a(ui,this))}on(e,t){let n=a(oi,this)[e];return n.add(t),()=>{n.delete(t)}}registerContextTransformer(e){a(ai,this).push(e)}destroy(){for(let e of a(si,this))e();a(si,this).length=0,a(di,this)&&(a(di,this).call(this),i(di,this,null));for(let e of Object.keys(a(oi,this)))a(oi,this)[e].clear();a(ai,this).length=0}};function pi(e){let t=Kr.getInstance(),n=t?t.getState():`active`;return Object.freeze({url:window.location.href,host:window.location.host,pathSegments:Object.freeze(E()),path:window.location.pathname,queryParams:Object.freeze(D()),pageType:O(),customTargeting:Object.freeze(te(a(ci,this))),lifecycleState:n,navigationContext:e,isOnline:navigator.onLine,author:k()})}function mi(e,t){return Object.freeze(F(F({},a(ui,this)),{},{[e]:t}))}function hi(){let e=Kr.getInstance();e&&(a(si,this).push(e.on(`virtualPageLoad`,e=>{let t=e.type===`infinite-scroll`?`infinite-scroll`:`spa-route`;r(W,this,gi).call(this,t)})),a(si,this).push(e.on(`bfcacheRestore`,()=>{r(W,this,gi).call(this,`bfcache-restore`)})),a(si,this).push(e.on(`stateChange`,e=>{ii.has(e)&&(i(ui,this,r(W,this,mi).call(this,`lifecycleState`,e)),r(W,this,yi).call(this,`visibilityChanged`,e))})),a(si,this).push(e.on(`networkChange`,e=>{i(ui,this,r(W,this,mi).call(this,`isOnline`,e)),r(W,this,yi).call(this,`networkChanged`,e)})))}function gi(e){let t=a(ui,this);i(ui,this,r(W,this,pi).call(this,e)),r(W,this,yi).call(this,`contextUpdated`,{context:r(W,this,_i).call(this,a(ui,this)),previousContext:r(W,this,_i).call(this,t),navigationContext:e})}function _i(e){let t=e;for(let e of a(ai,this))try{t=Object.freeze(e(t))}catch(e){return a(li,this).call(this,`transformer threw during pipeline execution`,e),t}return t}function vi(){i(di,this,T(()=>{i(di,this,null),r(W,this,gi).call(this,`initial`)}))}function yi(e,...t){let n=Array.from(a(oi,this)[e]);for(let e of n)e(...t)}var bi=new WeakMap,xi=new WeakMap,G=new WeakMap,Si=class{constructor(e){n(this,bi,0),n(this,xi,void 0),n(this,G,{}),i(xi,this,e)}subscribe({callback:e,eventName:t,priority:n,subscriberName:r,waitFor:i}){a(G,this)[t]||(a(G,this)[t]={});let o=n==null?a(bi,this):n;for(;a(G,this)[t][o];)o++;return a(G,this)[t][o]={callback:e,subscriberName:r,waitFor:i},{unsubscribe:()=>{delete a(G,this)[t][o]}}}dispatch(e){let t=e.EVENT_NAME;if(a(xi,this).isDebug&&(a(xi,this).debug(`Dispatching event ${t}`,e),a(xi,this).debug(`Subscribers for event ${t}:`,a(G,this)[t]?Object.values(a(G,this)[t]).map(e=>e.subscriberName):`No subscribers`)),!a(G,this)[t])return;let n=Object.keys(a(G,this)[t]).map(Number).sort((e,t)=>t-e);for(let r of n){let{callback:n,subscriberName:i,waitFor:o}=a(G,this)[t][r];try{o?o.then(()=>{n(e)}).catch(t=>{a(xi,this).error(`Something went wrong in ${i} waitFor, subscribed to the event: ${e.EVENT_NAME}`,t)}):n(e)}catch(t){a(xi,this).error(`Something went wrong in ${i}, subscribed to the event: ${e.EVENT_NAME}`,t)}}}},Ci=`slot:missing-element`,wi=`slot:missing-element:abandoned`,Ti=new WeakMap,Ei=new WeakMap,Di=new WeakMap,Oi=new WeakMap,ki=new WeakMap,Ai=new WeakMap,ji=new WeakMap,Mi=new WeakMap,Ni=new WeakMap,Pi=new WeakMap,Fi=new WeakMap,Ii=new WeakMap,Li=new WeakSet,Ri=class{constructor({monetizationManager:e,eventDispatcher:t,logger:o,observerRootMargin:s}){L(this,Li),n(this,Ti,1e3),n(this,Ei,`500px 15px`),n(this,Di,`300px 15px`),n(this,Oi,S()),n(this,ki,void 0),n(this,Ai,void 0),n(this,ji,void 0),n(this,Mi,new Map),n(this,Ni,new Map),n(this,Pi,void 0),n(this,Fi,new Map),n(this,Ii,void 0),i(ki,this,t),i(ji,this,o),i(Pi,this,e);let c=s||(a(Oi,this)===x.MOBILE?a(Di,this):a(Ei,this));i(Ai,this,new IntersectionObserver(r(Li,this,zi).bind(this),{threshold:0,rootMargin:c}))}register(e,t){let n=document.getElementById(e.divId);if(n!=null){a(Fi,this).set(e.divId,{slot:e,options:t}),a(Ai,this).observe(n);return}a(ji,this).warn(`Element ${e.divId} not found at registration time, starting recovery`),r(Li,this,Bi).call(this,e,t),a(ki,this).dispatch({EVENT_NAME:Ci})}destroy(){r(Li,this,Hi).call(this),r(Li,this,Ui).call(this)}};function zi(e){for(let t of e){if(!t.isIntersecting)continue;let e=t.target.id;if(!a(Fi,this).has(e))continue;let{slot:n,options:r}=a(Fi,this).get(e);a(Pi,this).sell(n,r),a(Fi,this).delete(e),a(Ai,this).unobserve(t.target)}}function Bi(e,t){a(Mi,this).set(e.divId,{slot:e,options:t}),a(Ii,this)==null&&(i(Ii,this,new MutationObserver(r(Li,this,Vi).bind(this))),a(Ii,this).observe(document.body,{childList:!0,subtree:!0}));let n=setTimeout(()=>{a(Mi,this).has(e.divId)&&(a(ji,this).warn(`Element ${e.divId} was never found, the slot has been abandoned for this session`),a(Mi,this).delete(e.divId),a(ki,this).dispatch({EVENT_NAME:wi}),a(Mi,this).size===0&&r(Li,this,Hi).call(this))},a(Ti,this));a(Ni,this).set(e.divId,n)}function Vi(){for(let[e,{slot:t,options:n}]of a(Mi,this)){let r=document.getElementById(e);if(r==null)continue;let i=a(Ni,this).get(e);i!=null&&(clearTimeout(i),a(Ni,this).delete(e)),a(Fi,this).set(e,{slot:t,options:n}),a(Ai,this).observe(r),a(Mi,this).delete(e)}a(Mi,this).size===0&&r(Li,this,Hi).call(this)}function Hi(){a(Ii,this)!=null&&(a(Ii,this).disconnect(),i(Ii,this,void 0),a(Mi,this).clear(),a(Ni,this).clear())}function Ui(){a(Ai,this).disconnect(),a(Fi,this).clear()}var Wi=new WeakMap,Gi=new WeakMap,Ki=new WeakMap,qi=new WeakMap,Ji=new WeakSet,Yi=class{constructor(e){L(this,Ji),n(this,Wi,new Map),n(this,Gi,new Set),n(this,Ki,new Map),n(this,qi,!1);for(let[t,n]of Object.entries(e==null?{}:e))for(let e of n==null?[]:n)this.setAdSlotAsDisposableOnVirtualNavigation(e,t)}registerAdSlot(e){var t;a(Ki,this).set(e.divId,{adUnitKey:e.adUnitKey,prebidAdUnitCode:(t=e.overridePrebidAdUnitCode)==null?e.adUnitKey:t});let n=e.disposableOnVirtualNavigation;if(n==null)return;let r=Array.isArray(n)?n:[n];for(let t of r)this.setAdSlotAsDisposableOnVirtualNavigation(e.divId,t)}setAdSlotAsDisposableOnVirtualNavigation(e,t){var n;let r=(n=a(Wi,this).get(e))==null?new Set:n;r.add(t),a(Wi,this).set(e,r)}isAdSlotDisposableOnVirtualNavigation(e,t){var n,r;return(n=(r=a(Wi,this).get(e))==null?void 0:r.has(t))!=null&&n}setAdSlotAsSelfManaged(e){a(Gi,this).add(e)}isAdSlotSelfManaged(e){return a(Gi,this).has(e)}isAdvDisabled(){return a(qi,this)}lockSell(e){if(!a(qi,this)){i(qi,this,!0);for(let t of Array.from(a(Ki,this).keys()))r(Ji,this,Xi).call(this,t,e)}}unlockSell(){i(qi,this,!1)}disposeAdSlots(e,t){for(let n of Array.from(a(Ki,this).keys()))this.isAdSlotDisposableOnVirtualNavigation(n,e)&&r(Ji,this,Xi).call(this,n,t)}resetSoldAdSlots(e,t){for(let n of Array.from(a(Ki,this).keys()))this.isAdSlotSelfManaged(n)||!t(n)||r(Ji,this,Xi).call(this,n,e,{keepContainer:!0})}};function Xi(e,{gpt:t,monetizationManager:n,prebidAdapter:r,refreshManager:i},{keepContainer:o=!1}={}){let s=a(Ki,this).get(e);if(s==null)return;let{prebidAdUnitCode:c}=s;try{i.unscheduleSlotRefresh(e)}catch(t){console.error(`Failed to unschedule refresh for ${e}`,t)}try{t==null||t.destroySlot(e)}catch(t){console.error(`Failed to destroy GPT slot for ${e}`,t)}try{r==null||r.removeAdUnit(c)}catch(e){console.error(`Failed to remove Prebid unit for ${c}`,e)}if(n.clearAdSlotState(e),!o)try{let t=document.getElementById(e);if(t!=null){var l;((l=t.closest(`.pubtech-adv-container`))==null?t:l).remove()}}catch(t){console.error(`Failed to remove DOM container for ${e}`,t)}a(Ki,this).delete(e)}var Zi=`slot:mrcImpressionReached`,Qi=[`F_D`,`F_M`,`S_1`,`S_2`],$i=5,ea=1e3,ta=3e4,na=5,ra=1e3,ia=new WeakMap,aa=new WeakMap,oa=new WeakMap,sa=new WeakMap,ca=new WeakMap,la=new WeakMap,ua=new WeakMap,da=new WeakMap,fa=new WeakMap,pa=new WeakMap,ma=new WeakMap,ha=new WeakMap,K=new WeakMap,ga=new WeakMap,_a=new WeakMap,va=new WeakMap,ya=new WeakMap,ba=new WeakMap,xa=new WeakMap,Sa=new WeakMap,q=new WeakSet,Ca=class{constructor({adUnitsExcludedFromRefresh:e,config:t,contextManager:o,customAdUnitRefreshConfigMap:s,disableAutoRefresh:c,eventDispatcher:l,monetizationManager:u,pageLifecycleManager:d}){if(L(this,q),n(this,ia,new Set([`O_SKIN`,`O_INTERSTITIAL`,`O_INTERSTITIAL_G`])),n(this,aa,void 0),n(this,oa,void 0),n(this,sa,void 0),n(this,ca,void 0),n(this,la,void 0),n(this,ua,void 0),n(this,da,void 0),n(this,fa,void 0),n(this,pa,void 0),n(this,ma,new Set),n(this,ha,void 0),n(this,K,new Map),n(this,ga,new Map),n(this,_a,void 0),n(this,va,void 0),n(this,ya,void 0),n(this,ba,null),n(this,xa,!1),n(this,Sa,!0),i(sa,this,r(q,this,Na).bind(this)),i(ca,this,o),i(la,this,s),i(ua,this,c===!0),i(da,this,l),i(fa,this,u),i(pa,this,d),i(ha,this,F({consecutiveUnfilledBeforeGoogleExclusion:null,firstUnfilledRetryTime:ea,refreshBlockTime:ta,refreshLimit:na,refreshOnlyOnVisiblePage:!0,requireMrcImpressionBeforeRefresh:!0,sequentialUnfilledLimit:$i,visibilityPollingTime:1e3},t)),Array.isArray(e))for(let t of e)a(ia,this).add(t);i(aa,this,a(da,this).subscribe({callback:e=>r(q,this,wa).call(this,e),eventName:Je,subscriberName:`RefreshManager`})),i(oa,this,a(da,this).subscribe({callback:e=>r(q,this,Ga).call(this,e),eventName:Ye,subscriberName:`RefreshManager:domination`})),i(va,this,a(ca,this).on(`visibilityChanged`,()=>{r(q,this,ka).call(this)&&r(q,this,Ua).call(this)})),i(ya,this,a(pa,this).on(`networkChange`,e=>{i(Sa,this,e),e&&r(q,this,ka).call(this)&&r(q,this,Ua).call(this)})),i(_a,this,a(pa,this).on(`bfcacheRestore`,()=>{r(q,this,Wa).call(this)}))}expediteSlotRefresh(e,t,n,i){if(a(ua,this))return;let{slot:o}=r(q,this,ja).call(this,t,e,n,i);o.unfilledRetryTimeout!=null&&(clearTimeout(o.unfilledRetryTimeout),o.unfilledRetryTimeout=null),o.refreshBlockTimeout!=null&&(clearTimeout(o.refreshBlockTimeout),o.refreshBlockTimeout=null),o.refreshLocked=!1,r(q,this,za).call(this,e,o),r(q,this,Oa).call(this,e,o)}unscheduleSlotRefresh(e){let t=a(K,this).get(e);t!=null&&(a(ma,this).delete(e),a(K,this).delete(e),a(ga,this).delete(e),r(q,this,Ha).call(this,t),r(q,this,Ia).call(this,e),t.mrcImpressionReached||a(da,this).dispatch({EVENT_NAME:Zi,adUnitKey:t.adUnitKey,divId:e}))}teardown(){var e;a(aa,this).unsubscribe(),a(oa,this).unsubscribe(),a(_a,this).call(this),a(va,this).call(this),a(ya,this).call(this);for(let e of a(K,this).values())r(q,this,Ha).call(this,e);a(ma,this).clear(),a(K,this).clear(),a(ga,this).clear(),(e=a(ba,this))==null||e.disconnect(),i(ba,this,null);try{window.googletag.pubads().removeEventListener(`slotVisibilityChanged`,a(sa,this)),i(xa,this,!1)}catch(e){}}isSlotRegistered(e){return a(K,this).has(e)}isMrcReached(e){let t=a(K,this).get(e);return t==null?!0:(r(q,this,za).call(this,e,t),t.mrcImpressionReached)}whenMrcReached(e){let t=a(K,this).get(e);return t==null||(r(q,this,za).call(this,e,t),t.mrcImpressionReached)?Promise.resolve():new Promise(n=>{let{unsubscribe:i}=a(da,this).subscribe({callback:t=>{t.divId===e&&(i(),n())},eventName:Zi,subscriberName:`RefreshManager:whenMrcReached:${e}`});if(t.isVisible&&t.lastVisibilityUpdateTime!=null){setTimeout(()=>{r(q,this,za).call(this,e,t)},ra-t.totalVisibleTime);return}r(q,this,La).call(this,e,t)})}};function wa(e){if(a(ua,this)||e.excludeFromRefresh===!0)return;let t=e.outcome;if(t!==He.Success&&t!==He.Unfilled)return;let n=e.adUnitKey;if(n==null||n.length===0||a(ia,this).has(n))return;let i=e.phase===I.Gpt?`gpt`:`prebid`,o=e.divId,{slot:s,slotRefreshConfig:c}=r(q,this,ja).call(this,n,o);if(!s.isExausted){if(e.sellParams!=null&&(s.sellParams=e.sellParams),Qi.includes(s.adUnitKey)||r(q,this,Ma).call(this,i,o),t===He.Unfilled){r(q,this,Ea).call(this,o,s,c);return}r(q,this,Ta).call(this,o,s,c)}}function Ta(e,t,n){r(q,this,Ha).call(this,t),t.consecutiveUnfilledCount=0,r(q,this,Ba).call(this,t),Qi.includes(t.adUnitKey)&&(t.isVisible=!0,t.lastVisibilityUpdateTime=Math.round(performance.now())),r(q,this,La).call(this,e,t);let i=setTimeout(()=>{t.refreshBlockTimeout===i&&(t.refreshBlockTimeout=null,t.refreshLocked=!1,r(q,this,Oa).call(this,e,t))},n.refreshBlockTime);t.refreshBlockTimeout=i}function Ea(e,t,n){var i,a,o;if(t.consecutiveUnfilledCount+=1,t.consecutiveUnfilledCount>=((i=n.sequentialUnfilledLimit)==null?$i:i))return r(q,this,Va).call(this,e,t);t.unfilledRetryTimeout!=null&&clearTimeout(t.unfilledRetryTimeout),t.refreshBlockTimeout!=null&&(clearTimeout(t.refreshBlockTimeout),t.refreshBlockTimeout=null);let s=n.consecutiveUnfilledBeforeGoogleExclusion;s!=null&&t.consecutiveUnfilledCount>=s&&(t.excludeGpt=!0);let c=t.consecutiveUnfilledCount===1?(a=n.firstUnfilledRetryTime)==null?ea:a:(o=n.refreshBlockTime)==null?ta:o,l=setTimeout(()=>{t.unfilledRetryTimeout===l&&(t.unfilledRetryTimeout=null,t.refreshLocked=!1,r(q,this,Oa).call(this,e,t))},c);t.unfilledRetryTimeout=l}function Da(e,t){let n=a(K,this).get(e);if(!(n==null||n.isExausted)){if(t)n.isVisible||(n.isVisible=!0,n.lastVisibilityUpdateTime=Math.round(performance.now()));else{n.isVisible&&(r(q,this,za).call(this,e,n),n.isVisible=!1,n.lastVisibilityUpdateTime=null,r(q,this,Ra).call(this,n));return}r(q,this,za).call(this,e,n),r(q,this,Oa).call(this,e,n)}}function Oa(e,t){var n;if(t.isExausted||t.refreshLocked)return;if(!r(q,this,ka).call(this)){a(ma,this).add(e);return}if(a(ha,this).requireMrcImpressionBeforeRefresh&&!Qi.includes(t.adUnitKey)&&!t.mrcImpressionReached){t.isVisible&&r(q,this,La).call(this,e,t);return}a(ma,this).delete(e),r(q,this,Ra).call(this,t);let{slotRefreshConfig:i}=r(q,this,ja).call(this,t.adUnitKey,e);if(t.refreshCount>=((n=i.refreshLimit)==null?na:n))return r(q,this,Va).call(this,e,t);t.refreshLocked=!0,t.refreshCount+=1,a(fa,this).sell(F(F({},t.sellParams),{},{adUnitKey:t.adUnitKey,divId:e,refreshCount:t.refreshCount}),{excludeGpt:t.excludeGpt})}function ka(){if(!a(Sa,this))return!1;let e=a(pa,this).getState();return[`active`,`passive`].includes(e)?!0:e===`hidden`&&!a(ha,this).refreshOnlyOnVisiblePage}function Aa(e,t,n,r){var i,o,s;let c=F({adUnitKey:e,consecutiveUnfilledCount:0,excludeGpt:!1,isExausted:!1,isVisible:!1,lastVisibilityUpdateTime:null,mrcImpressionReached:!1,refreshBlockTimeout:null,refreshCount:0,refreshLocked:!0,totalVisibleTime:0,unfilledRetryTimeout:null,visibilityPollingInterval:null},n),l=F(F(F({},a(ha,this)),r),(i=(o=a(la,this))==null?void 0:o[t])==null?(s=a(la,this))==null?void 0:s[e]:i);return a(K,this).set(t,c),a(ga,this).set(t,l),{slot:c,slotRefreshConfig:l}}function ja(e,t,n,i){let o=a(K,this).get(t),s=a(ga,this).get(t);return o!=null&&s!=null?{slot:o,slotRefreshConfig:s}:r(q,this,Aa).call(this,e,t,n,i)}function Ma(e,t){if(e===`gpt`)try{a(xa,this)||(window.googletag.pubads().addEventListener(`slotVisibilityChanged`,a(sa,this)),i(xa,this,!0)),r(q,this,Ia).call(this,t);return}catch(e){}r(q,this,Pa).call(this,t)}function Na(e){let t=e.slot.getSlotElementId();if(!a(K,this).has(t))return;let n=e.inViewPercentage>=50;r(q,this,Da).call(this,t,n)}function Pa(e){if(a(ba,this)!=null){r(q,this,Fa).call(this,e);return}typeof window>`u`||typeof IntersectionObserver>`u`||(i(ba,this,new IntersectionObserver(e=>{for(let t of e){let e=t.target.id;a(K,this).has(e)&&r(q,this,Da).call(this,e,t.isIntersecting)}},{root:null,rootMargin:`0px`,threshold:.5})),r(q,this,Fa).call(this,e))}function Fa(e){var t;let n=document.getElementById(e);n!=null&&((t=a(ba,this))==null||t.observe(n))}function Ia(e){var t;let n=document.getElementById(e);n!=null&&((t=a(ba,this))==null||t.unobserve(n))}function La(e,t){t.visibilityPollingInterval==null&&(t.visibilityPollingInterval=setInterval(()=>{if(t.isExausted||!t.isVisible||t.mrcImpressionReached){r(q,this,Ra).call(this,t);return}r(q,this,za).call(this,e,t),t.mrcImpressionReached&&(r(q,this,Ra).call(this,t),r(q,this,Oa).call(this,e,t))},a(ha,this).visibilityPollingTime))}function Ra(e){e.visibilityPollingInterval!=null&&(clearInterval(e.visibilityPollingInterval),e.visibilityPollingInterval=null)}function za(e,t){if(!t.isVisible||t.lastVisibilityUpdateTime==null)return;let n=Math.round(performance.now()),r=n-t.lastVisibilityUpdateTime;r>0&&(t.totalVisibleTime+=r,t.lastVisibilityUpdateTime=n),!(t.mrcImpressionReached||t.totalVisibleTime<ra)&&(t.mrcImpressionReached=!0,a(da,this).dispatch({EVENT_NAME:Zi,adUnitKey:t.adUnitKey,divId:e}))}function Ba(e){e.isVisible=!1,e.lastVisibilityUpdateTime=null,e.mrcImpressionReached=!1,e.totalVisibleTime=0,r(q,this,Ra).call(this,e)}function Va(e,t){t.isExausted||(t.isExausted=!0,this.unscheduleSlotRefresh(e))}function Ha(e){e.refreshBlockTimeout!=null&&(clearTimeout(e.refreshBlockTimeout),e.refreshBlockTimeout=null),e.unfilledRetryTimeout!=null&&(clearTimeout(e.unfilledRetryTimeout),e.unfilledRetryTimeout=null),r(q,this,Ra).call(this,e)}function Ua(){for(let e of a(ma,this)){let t=a(K,this).get(e);t!=null&&r(q,this,Oa).call(this,e,t)}}function Wa(){for(let[e,t]of a(K,this)){if(r(q,this,Ba).call(this,t),Qi.includes(t.adUnitKey)){t.isVisible=!0,t.lastVisibilityUpdateTime=Math.round(performance.now());continue}r(q,this,Ia).call(this,e),r(q,this,Fa).call(this,e)}}function Ga(e){for(let t of e.slots)this.unscheduleSlotRefresh(t.divId)}var Ka;window.__pubtech_queue_on_consent=window.__pubtech_queue_on_consent||[],window.__pubtech_queue_on_consent.push(function(e){e!=null&&(Ka=e)});var qa=new WeakMap,Ja=new WeakMap,Ya=new WeakMap,Xa=new WeakMap,Za=new WeakMap,Qa=new WeakMap,$a=new WeakMap,eo=new WeakMap,to=new WeakMap,no=new WeakMap,ro=new WeakSet,io=class{constructor({consentReader:e,contextManager:t,customProperties:a,disableAds:o,logger:s,navigationTrackingOptions:c,pageLifecycleManager:l,websiteId:u}){L(this,ro),n(this,qa,void 0),n(this,Ja,void 0),n(this,Ya,void 0),n(this,Xa,void 0),n(this,Za,void 0),n(this,Qa,void 0),n(this,$a,new Set),n(this,eo,void 0),n(this,to,void 0),n(this,no,[]),i(qa,this,e),i(Ja,this,t),i(to,this,M(a)),i(Ya,this,o),i(Xa,this,s),i(Za,this,F({spaRoute:!0,infiniteScroll:!1,bfcacheRestore:!0},c)),i(Qa,this,l),i(eo,this,u),r(ro,this,oo).call(this)}trackView(e){var t=this;return b(function*(){let n=(e==null?void 0:e.path)||document.location.pathname;a($a,t).has(n)||(a($a,t).add(n),!(yield re(a(Ya,t)))&&(i(to,t,F(F({},a(to,t)),e==null?void 0:e.onDemandCustomProperties)),r(ro,t,ao).call(t,n)))})()}teardown(){for(let e of a(no,this))e();i(no,this,[])}};function ao(e){let t={w_id:a(eo,this),pn:e,wd:_(),sc:he(),metrics:{pv:{v:1,metadata:F({consent:String(a(qa,this).hasUserAcceptedConsent()),consentApiUsed:a(qa,this).consentManagementApiUsed()},a(to,this))}},metadata:{product:`engine`}};typeof Ka==`string`&&(t.ct=Ka);for(let e of[`https://producer-ovh-node01.intelligence.pubtech.ai:8443/website-metrics`])try{let n=new XMLHttpRequest;n.open(`POST`,e),n.setRequestHeader(`Content-Type`,`application/json`),n.send(JSON.stringify(t)),a(Xa,this).debug(`Sending a new page view request`,t)}catch(e){a(Xa,this).error(`Error while tracking the page view`,e)}}function oo(){let e=a(Za,this).bfcacheRestore,t=a(Za,this).infiniteScroll,n=a(Za,this).spaRoute;if(n||t){let e=a(Ja,this).on(`contextUpdated`,({context:e,navigationContext:r})=>{if(r===`spa-route`&&n){a($a,this).clear(),this.trackView({path:e.path,onDemandCustomProperties:{navigationContext:r}});return}r===`infinite-scroll`&&t&&this.trackView({path:e.path,onDemandCustomProperties:{navigationContext:r}})});a(no,this).push(e)}if(e){let e=a(Qa,this).on(`bfcacheRestore`,()=>{a($a,this).clear(),this.trackView({onDemandCustomProperties:{navigationContext:`bfcache-restore`}})});a(no,this).push(e)}}var so=`font-weight: bold; font-size: 50px;color: red; text-shadow: 3px 3px 0 rgb(217,31,38) , 6px 6px 0 rgb(226,91,14) , 9px 9px 0 rgb(245,221,8) , 12px 12px 0 rgb(5,148,68) , 15px 15px 0 rgb(2,135,206) , 18px 18px 0 rgb(4,77,145) , 21px 21px 0 rgb(42,21,113)`,co=new Set([`VIP`,`O_INTERSTITIAL_G`]),lo=new Set([`O_SKIN`]),uo=[{color:`green`,minCount:6,text:`ottimale, monetizzazione al top`},{color:`yellow`,minCount:5,text:`buono, monetizzazione nella norma`},{color:`orange`,minCount:2,text:`basso, monetizzazione sotto la media`},{color:`red`,minCount:0,text:`troppo basso, monetizzazione compromessa!`}];function fo(e){console.debug(`%cPubtech.ai Banner Debug`,so);let t=new Set,n=0;for(let r of Object.keys(e)){if(document.getElementById(r)!=null){t.add(r),lo.has(r)||n++;continue}co.has(r)&&t.add(r)}console.table([...t]);let r=po(n);console.debug(`%cNumero di banner in pagina: ${r.text}`,`color:${r.color};font-size: 14px;`)}function po(e){let t=uo.find(({minCount:t})=>e>=t);return t==null?uo[uo.length-1]:t}var mo=22;function ho({adUnitKey:e,element:t,otherBlocksToLabel:n,sizes:r,stableMinHeight:i}){var a,o;if((i==null?void 0:i.enabled)===!1||!go(e)||!(i==null||(a=i.excludeAdUnits)==null)&&a.includes(e))return;let s=vo(_o(e,n)?mo:0,r,(o=i==null?void 0:i.strategy)==null?`median`:o);s!=null&&(t.style.minHeight=`${s}px`)}function go(e){let t=e.toUpperCase();return![`O_`,`F_`,`S_`].some(e=>t.startsWith(e))}function _o(e,t){return e.includes(`C_`)||e.includes(`D_`)||e.includes(`B_`)||(t==null?void 0:t.includes(e))===!0}function vo(e,t,n){let r=t.filter(e=>Array.isArray(e)).map(e=>e[1]);if(r.length===0)return;let i;return n===`median`?i=yo(r):n===`tallest`&&(i=Math.max(...r)),i==null?void 0:i+e}function yo(e){let t=[...e].sort((e,t)=>e-t),n=Math.floor(t.length/2);return t.length%2==0?(t[n-1]+t[n])/2:t[n]}var bo=new Set([`O_INTERSTITIAL`,`O_INTERSTITIAL_G`,`O_SKIN`]);function xo(e){console.debug(`%cFORMAT_PREVIEW_MODE ON`,`background: #E53935; padding: 2px 4px;`);for(let[t,n]of Object.entries(e)){if(bo.has(t))continue;let e=document.getElementById(t);if(e==null){console.debug(`AdUnit container not found for ${t}, skip`);continue}let r=n.filter(e=>Array.isArray(e));if(r.length===0){console.debug(`AdUnit ${t} has no fixed size to preview, skip`);continue}let[i,a]=r[0];e.innerHTML=` <p>${t}</p> <p>${r.map(e=>e.join(`x`)).join(`, `)}</p> `,e.style.cssText=` align-items:center; background-color:#cbcbcb; display:flex; flex-direction:column; font-size:28px; font-weight:700; height:${a}px; justify-content:center; margin-bottom:15px; margin-top:15px; text-align:center; width:${i}px; `}}var So=`/21832376849/TM_OnBoarding_TEST/TM_OnBoarding_TEST_`,Co=`TM_OnBoarding_TEST`;function wo(e){return console.debug(`%cTEST_FORMAT_MODE ON`,`background: #E53935; padding: 2px 4px;`,`every ad slot is requested on ${So}`),F(F({},e),{},{fullNameAd:So,slug:Co})}var To=`engine:beforeFlow`,Eo=`engine:afterFlow`,Do=Kr.init(),Oo=new fi,ko=new mr,J=new Et({logKey:`debug_engine`,label:`CORE`}),Ao=new u;window.__engine_inspection={buildId:`[develop]-[2026-10-26_12:50:06]`},window.ptechen=window.ptechen||{},window.ptechvip=window.ptechvip||{},window.ptechen.cmd=window.ptechen.cmd||[],ye(),xe();function jo(e,t){return Mo.apply(this,arguments)}function Mo(){return Mo=b(function*(e,t){var n,r,i,a,o,s,c,l,u,d,f,p,m;let h=(n=t==null?void 0:t.pageLifecycleManager)==null?Do:n,g=(r=t==null?void 0:t.contextManager)==null?Oo:r,_=(i=t==null?void 0:t.consentReader)==null?ko:i,v=new io({consentReader:_,contextManager:g,customProperties:(a=e.trackingOptions)==null?void 0:a.customProperties,disableAds:(o=e.execution)==null?void 0:o.disableAds,logger:J,navigationTrackingOptions:(s=e.trackingOptions)==null?void 0:s.navigationTrackingOptions,pageLifecycleManager:h,websiteId:e.website.websiteId}),y=(c=(l=e.execution)==null?void 0:l.virtualNavigationConfig)==null?{}:c,b=(u=y.titleObserver)==null?((d=e.compilePlugins)==null?void 0:d.infiniteScroll)==null&&void 0:u;h.configure(F(F({},y),{},{titleObserver:b}));let x=new Promise(e=>{let t=_.onConsentReleased({onConsentCallback:n=>{setTimeout(()=>{t()},0),e(n)},attemptThreshold:100,once:!0})}),C=S();(f=e.execution)!=null&&f.waitDomReady&&(yield Ro()),(p=e.adInventoryConfig)!=null&&p.advLabelText&&document.documentElement.style.setProperty(`--adv-label-text`,`'${e.adInventoryConfig.advLabelText}'`);let ee={config:e,consentReader:_,consentReady:x,contextManager:g,device:C,pageLifecycleManager:h,viewTracker:v};if(yield re((m=e.execution)==null?void 0:m.disableAds)){J.warn(`Ads are disabled via execution config: the engine is not built. It will boot on the first virtual navigation where disableAds resolves false.`),No(ee);return}yield Po(ee)}),Mo.apply(this,arguments)}function No(e){let t=!1,n=e.pageLifecycleManager.on(`virtualPageLoad`,()=>{if(t)return;function r(){return i.apply(this,arguments)}function i(){return i=b(function*(){var r;(yield re((r=e.config.execution)==null?void 0:r.disableAds))||t||(t=!0,n(),yield Po(e))}),i.apply(this,arguments)}r().catch(e=>{J.error(`Deferred engine boot failed:`,e)})})}function Po(e){return Fo.apply(this,arguments)}function Fo(){return Fo=b(function*({config:e,consentReader:t,consentReady:n,contextManager:r,device:i,pageLifecycleManager:a,viewTracker:o}){var s,c,l,u,d,f,p,m,h,g,_,v;let y=le(`format_preview`),x=le(`debug_format`);!y&&!x&&(yield o.trackView());let S=x?wo(e.website):e.website,C=new Si(J),w=Ve(e.sizeMapping),T=(s=e.googlePublisherTagProvider)==null?void 0:s.call(e,{contextManager:r,eventDispatcher:C,consentReader:t,divIdToAdUnitKeyMapping:(c=e.adInventoryConfig)==null?void 0:c.divIdToAdUnitKeyMapping,getAdUnitSizes:w.getAdUnitSizes,overridePrefixFullNameAd:x?S.fullNameAd:void 0,siteCategory:S.siteCategory}),E=yield n,D;try{var O,te;yield me();let n=e.prebidAdapterProvider&&!x?yield re(e.prebidAdapterProvider):void 0;D=n==null?void 0:n({consentReader:t,consentManagementType:E.consentManagementType,contextManager:r,customFloorModelGroups:e.customFloorModelGroups,customFloorModelVersion:e.customFloorModelVersion,customFloorValues:e.customFloorPriceValues,device:i,deviceForSSP:ee(),divIdToAdUnitKeyMapping:(O=e.adInventoryConfig)==null?void 0:O.divIdToAdUnitKeyMapping,domain:S.websiteDomain,eventDispatcher:C,fullNameAd:(te=S.fullNameAd)==null?``:te,sizeMappingRegistry:w,logger:J,pageLifecycleManager:a,personalizedAds:E.personalizedAds,sellerId:S.sellerId,websiteId:S.websiteId,websiteSlug:S.slug}),yield me()}catch(e){J.error(`Failed to initialize PrebidAdapter:`,e)}let k=new Yi(e.disposableAdSlots),A=new Wt({gpt:T,prebidAdapter:D,eventDispatcher:C,divIdToAdUnitKeyMapping:(l=e.adInventoryConfig)==null?void 0:l.divIdToAdUnitKeyMapping,pageLifecycleManager:a,batchSelling:e.batchSelling,timeout:!1,onAdSlotSell:e=>k.registerAdSlot(e),isAdvDisabled:()=>k.isAdvDisabled()}),j=new Ca({adUnitsExcludedFromRefresh:(u=e.autoRefreshOptions)==null?void 0:u.adUnitsExcludedFromRefresh,config:(d=e.autoRefreshOptions)==null?void 0:d.config,contextManager:r,customAdUnitRefreshConfigMap:(f=e.autoRefreshOptions)==null?void 0:f.customAdUnitRefreshConfigMap,disableAutoRefresh:(p=e.autoRefreshOptions)==null?void 0:p.disableAutoRefresh,monetizationManager:A,eventDispatcher:C,pageLifecycleManager:a}),ne=new Ri({monetizationManager:A,eventDispatcher:C,logger:J,observerRootMargin:e.lazyLoadingRootMargin});C.subscribe({eventName:We,subscriberName:`Engine`,callback:t=>{var n;let r=t.adUnitKey,i=_o(r,(n=e.adInventoryConfig)==null?void 0:n.otherBlocksToLabel);if(ze(w.getAdUnitSizes(t.adUnitKey))&&i){let e=document.getElementById(t.adUnitKey);e!=null&&e.classList.add(`advblockshown`)}}});let M={config:e,consentReader:t,contextManager:r,eventDispatcher:C,gpt:T,lazyLoader:ne,logger:J,monetizationManager:A,pageLifecycleManager:a,prebidAdapter:D,refreshApi:{expediteSlotRefresh:j.expediteSlotRefresh.bind(j),isMrcReached:j.isMrcReached.bind(j),teardown:j.teardown.bind(j),unscheduleSlotRefresh:j.unscheduleSlotRefresh.bind(j),whenMrcReached:j.whenMrcReached.bind(j)},adSlotLifecycleApi:{isAdSlotDisposableOnVirtualNavigation:k.isAdSlotDisposableOnVirtualNavigation.bind(k),setAdSlotAsDisposableOnVirtualNavigation:k.setAdSlotAsDisposableOnVirtualNavigation.bind(k),isAdSlotSelfManaged:k.isAdSlotSelfManaged.bind(k),setAdSlotAsSelfManaged:k.setAdSlotAsSelfManaged.bind(k),isAdvDisabled:k.isAdvDisabled.bind(k)},scriptLoader:Ao,sizeMappingApi:w};function N(){return P.apply(this,arguments)}function P(){return P=b(function*(){var t;(yield re((t=e.execution)==null?void 0:t.disableAds))?k.lockSell({gpt:T,monetizationManager:A,prebidAdapter:D,refreshManager:j}):k.unlockSell()}),P.apply(this,arguments)}if(yield N(),e.compilePlugins&&!y){var ie;let t=new Et({logKey:`debug_engine`,label:`COMPILE_PLUGINS`}),n=Xn(e.compilePlugins,F(F({},M),{},{device:i,domain:S.websiteDomain,fullNameAd:(ie=S.fullNameAd)==null?``:ie,isDesktop:i===`desktop`,isMobile:i===`mobile`,isTablet:i===`tablet`,sellerId:S.sellerId}),C,t);n.length>0&&qn(n,C,t)}if(we({ctx:M,device:i,isDesktop:i===`desktop`,isMobile:i===`mobile`,isTablet:i===`tablet`}),be(),yield me(),typeof((m=e.hooks)==null?void 0:m.beforeFlow)==`function`)try{e.hooks.beforeFlow(M)}catch(e){J.error(`Before flow hook error:`,e)}if(le(`banner_debug`)&&fo(w.getSizeMapping(i)),y){xo(w.getSizeMapping(i));return}if(C.dispatch({EVENT_NAME:To,type:`standard`}),Io({customInstantSlotToSell:(h=e.adInventoryConfig)==null?void 0:h.customInstantSlotToSell,device:i,otherBlocksToLabel:(g=e.adInventoryConfig)==null?void 0:g.otherBlocksToLabel,stableMinHeight:(_=e.adInventoryConfig)==null?void 0:_.stableMinHeight,isAdSlotSelfManaged:k.isAdSlotSelfManaged.bind(k),lazyLoader:ne,monetizationManager:A,sizeMappingRegistry:w}),C.dispatch({EVENT_NAME:Eo,type:`standard`}),typeof((v=e.hooks)==null?void 0:v.afterFlow)==`function`)try{e.hooks.afterFlow(M)}catch(e){J.error(`After flow hook error:`,e)}function ae(e){return oe.apply(this,arguments)}function oe(){return oe=b(function*(t){var n,r,a,o,s;if(yield N(),t.type===`bfcache-restore`?k.resetSoldAdSlots({gpt:T,monetizationManager:A,prebidAdapter:D,refreshManager:j},e=>w.getSizeMapping(i)[e]!=null&&document.getElementById(e)!=null):k.disposeAdSlots(t.type,{gpt:T,monetizationManager:A,prebidAdapter:D,refreshManager:j}),t.type!==`infinite-scroll`&&(D==null||D.removeUserSyncs()),yield me(),typeof((n=e.hooks)==null?void 0:n.beforeVirtualFlow)==`function`)try{e.hooks.beforeVirtualFlow(F(F({},M),{},{virtualPageContext:t}))}catch(e){J.error(`Before virtual flow hook error:`,e)}else J.warn(`No beforeVirtualFlow hook provided, skipping.`);if(C.dispatch({EVENT_NAME:To,type:`virtual`,url:t.url,virtualNavigationType:t.type}),Io({customInstantSlotToSell:(r=e.adInventoryConfig)==null?void 0:r.customInstantSlotToSell,device:i,otherBlocksToLabel:(a=e.adInventoryConfig)==null?void 0:a.otherBlocksToLabel,stableMinHeight:(o=e.adInventoryConfig)==null?void 0:o.stableMinHeight,isAdSlotSelfManaged:k.isAdSlotSelfManaged.bind(k),lazyLoader:ne,monetizationManager:A,sizeMappingRegistry:w,refreshManager:j,virtualNavigationType:t.type}),C.dispatch({EVENT_NAME:Eo,type:`virtual`,url:t.url,virtualNavigationType:t.type}),typeof((s=e.hooks)==null?void 0:s.afterVirtualFlow)==`function`)try{e.hooks.afterVirtualFlow(F(F({},M),{},{virtualPageContext:t}))}catch(e){J.error(`After virtual flow hook error:`,e)}else J.warn(`No afterVirtualFlow hook provided, skipping.`)}),oe.apply(this,arguments)}a.on(`virtualPageLoad`,e=>{ae(e)}),a.on(`bfcacheRestore`,()=>{ae({url:window.location.href,type:`bfcache-restore`})}),Se({ctx:M,device:i,isDesktop:i===`desktop`,isMobile:i===`mobile`,isTablet:i===`tablet`})}),Fo.apply(this,arguments)}function Io({customInstantSlotToSell:e,device:t,isAdSlotSelfManaged:n,lazyLoader:r,monetizationManager:i,otherBlocksToLabel:a,sizeMappingRegistry:o,refreshManager:s,stableMinHeight:c,virtualNavigationType:l}){let u=Lo(t,o,a,c),d=new Set({desktop:[`F_D`,`S_1`,`S_2`],tablet:[`F_D`],mobile:[`F_M`]}[t]);if(e!=null){let n=M(e);if(n[t]instanceof Set)for(let e of n[t])d.add(e)}let f=new Set([`F_M`,`F_D`,`S_1`,`S_2`].filter(e=>u.has(e))),p=new Set([...u].filter(e=>!f.has(e))),m=[...f,...p];for(let e of m)if((n==null?void 0:n(e))!==!0){if(s&&s.isSlotRegistered(e)){l!==`infinite-scroll`&&s.expediteSlotRefresh(e,e);continue}d.has(e)?i.sell({adUnitKey:e,divId:e,refreshCount:0}):r.register({adUnitKey:e,divId:e})}for(;window.ptechen.cmd.length>0;)window.ptechen.cmd.shift()()}function Lo(e,t,n,r){let i=new Set,a=t.getSizeMapping(e),o=Object.keys(a);for(let s of o){let o=document.getElementById(s);if(o==null)continue;i.add(s);let c=Ee(o,e);c.length>0&&t.setAdUnitSizes(s,c),ho({adUnitKey:s,element:o,otherBlocksToLabel:n,sizes:a[s],stableMinHeight:r})}return i}function Ro(){return new Promise(e=>{document.readyState===`loading`?document.addEventListener(`DOMContentLoaded`,()=>e(),{once:!0}):e()})}var zo=300,Bo=1300,Vo={desktop:{F_D:{containerHeight:100}},tablet:{F_D:{containerHeight:100}},mobile:{F_M:{containerHeight:100}}};function Ho({sizeMapping:e,anchorSlotContainerSelector:t,closeButton:n=!0,enableRefreshOnInfiniteScroll:r=!1,floorAdDesktopBg:i=`transparent`,scaleIframeConfig:a=Vo,scaleIframeOnPostInjection:o=!1,transformFloorAdToAnchorSlot:s=!1}){let c=new Et({logKey:`debug_engine`,label:`FLOOR_AD_PLUGIN`});return l=>{let u=l.isMobile?`F_M`:`F_D`,d=l.isMobile?e.mobile:e.desktop,f=`floorad-container`;if(!d)return null;l.sizeMappingApi.addSizeMaps(u,e),l.adSlotLifecycleApi.setAdSlotAsSelfManaged(u);let p;r&&l.eventDispatcher.subscribe({eventName:To,subscriberName:`floorAdInfiniteScrollRefresh`,callback:e=>{if(e.type===`virtual`&&e.virtualNavigationType===`infinite-scroll`&&!l.adSlotLifecycleApi.isAdvDisabled()&&document.getElementById(f)!=null){if(!l.refreshApi.isMrcReached(u)){c.debug(`Infinite scroll: the impression on screen is not viewable yet, leaving it alone`);return}c.debug(`Infinite scroll: expediting the floor ad refresh`),l.refreshApi.expediteSlotRefresh(u,u)}}});function m(){l.monetizationManager.sell({adUnitKey:u,divId:u,refreshCount:0})}function h(){if(document.getElementById(f)!=null){c.debug(`Floor ad bar already in place, skipping setup`);return}let e=document.getElementById(u);e==null&&(e=document.createElement(`div`),e.id=u);let r=document.createElement(`div`);if(r.id=f,l.isMobile?r.classList.add(`mobile-container`):(r.classList.add(`desktop-container`),r.style.setProperty(`--floorad-desktop-bg`,`${i}`)),r.appendChild(e),n){let e=document.createElement(`div`);e.id=`floorad-no-click`;let t=document.createElement(`div`);t.id=`floorad-close-button`;let n=document.createElement(`span`);n.id=`floorad-close-button-text`,n.innerText=`X`,l.isMobile?(e.classList.add(`mobile-no-click`),t.classList.add(`mobile-button`)):(e.classList.add(`desktop-no-click`),t.classList.add(`desktop-button`)),e.addEventListener(`click`,function(e){return e.preventDefault(),e.stopPropagation(),!1}),t.addEventListener(`click`,function(){var e=b(function*(){yield me(),g()});function t(){return e.apply(this,arguments)}return t}()),t.appendChild(n),r.appendChild(e),r.appendChild(t)}if(s){c.debug(`Anchor slot with selector: ${t}`);let e=document.querySelector(t);e==null?(c.debug(`Anchor slot container not found, enable bottom floor-ad`),r.classList.add(`bottom-slot`),document.body.appendChild(r)):(c.debug(`Anchor slot container found`,e),r.classList.add(`anchor-slot`),e.appendChild(r))}else r.classList.add(`bottom-slot`),document.body.appendChild(r);o&&(l.sizeMappingApi.addSizeMaps(`F_D`,{desktop:{F_D:[[990,250],[970,250]]},tablet:{F_D:[[990,250],[970,250]]}}),l.sizeMappingApi.addSizeMaps(`F_M`,{mobile:{F_M:[[990,250],[970,250],[728,90]]}}),zn({adUnitSizeConfig:a,logger:c,isOnPostInjection:!0,device:l.device}),c.debug(`Scale iframe enabled on post injection with config:`,a)),m(),p==null||p.unsubscribe(),p=l.eventDispatcher.subscribe({eventName:We,subscriberName:`floorAdPluginSubscriber`,callback:e=>{if(e.adUnitKey!==u)return;let t=document.getElementById(f);if(t==null||t.classList.contains(`rendered-floorad`))return;let n=!0,r=l.isMobile?Bo:zo;setTimeout(b(function*(){if(l.prebidAdapter!=null&&l.isMobile)try{(yield l.prebidAdapter.getAllWinningBids()).forEach(e=>{e.status===`rendered`&&e.bidder===`seedtag`&&e.adUnitCode===`F_M`&&document.getElementById(`inScreen`)!=null&&(n=!1)})}catch(e){c.error(`Error while getting winning bids from Prebid Adapter:`,e)}if(!n)return;let e=document.getElementById(f);e!=null&&e.classList.add(`rendered-floorad`)}),r)}})}function g(){var e;p==null||p.unsubscribe(),p=void 0,l.refreshApi.unscheduleSlotRefresh(u),(e=document.getElementById(f))==null||e.remove()}return{pluginName:`floorAd`,onDisableAds:g,softTeardown:e=>{if(document.getElementById(f)!=null){if(e===`bfcache-restore`){g();return}if(l.refreshApi.isMrcReached(u)){g();return}return l.refreshApi.whenMrcReached(u).then(g)}},run(e){c.debug(`Running floorAd plugin for ${l.isMobile?`mobile`:`desktop`} with ad unit key ${u} and sizes:`,d),pe(Gn),h(),e({type:`completed`,onVirtualNavigationHook:{position:To,run:h}})}}}}function Uo({googleInterstitialUnitKey:e=`O_INTERSTITIAL_G`,sizeMapping:t}){return{name:`google`,canRun(e){return e.enginePluginContext.gpt!=null},execute(n){return new Promise(r=>{var i,a;n.logger.debug(`Loading Google interstitial`);let o=n.enginePluginContext.gpt;if(o==null){r({served:!1,error:`GooglePublisherTag not available on engine context`});return}(i=document.getElementById(n.adUnitKey))==null||i.remove();let s=o.getPrefixFullNameAd()+e,c=n.enginePluginContext.contextManager.getCurrentContext().path.split(`/`)[1]||`home`,l=c.length>0?c.slice(-40):`home`;try{window.googletag.pubads().addEventListener(`impressionViewable`,function e(t){t.slot.getAdUnitPath()===s&&(n.logger.debug(`Google interstitial impression viewable, persisting capping`),n.setCappingCookie(),window.googletag.pubads().removeEventListener(`impressionViewable`,e))})}catch(e){n.logger.debug(`Failed to subscribe to impressionViewable: ${String(e)}`)}n.enginePluginContext.adSlotLifecycleApi.setAdSlotAsSelfManaged(e),n.enginePluginContext.monetizationManager.sell({adUnitKey:e,divId:e,slotType:`outOfPageInterstitial`,overrideTargeting:{SPurl:l,Refresh:`0`},overrideAdUnitSizes:(a=t[n.enginePluginContext.device])==null?void 0:a[e]},{excludePrebid:!0,callbacks:{onGptSuccess:()=>{n.setupCloseRendering({interstitialLayerTimeout:10})}}}),r({served:!0,deferred:!0})})}}}function Wo(e){var t,n,r,i;(t=window).pbstck!=null||(t.pbstck={}),(n=window.pbstck).sdk!=null||(n.sdk={});let a=(i=(r=window.pbstck.sdk)[e])==null?r[e]={}:i;a.g=`Pubstack`,a.q!=null||(a.q=[]),window.Pubstack={cmd:function(...e){var t,n;(t=a.q)==null||t.push([`cmd`,e]),((n=a.p)==null?[]:n).forEach(t=>{t([`cmd`,e])})}};let o=document.createElement(`script`);o.id=`pubstack`,o.type=`text/javascript`,o.async=!0,o.setAttribute(`data-cfasync`,`false`),o.src=`https://boot.pbstck.com/v1/tag/${e}`,document.head.appendChild(o)}var Go=`div[id^=O_INTERSTITIAL],div[id^=O_INTERSTITIAL] div#oIntLayer{position:fixed;top:0;left:0}div[id^=O_INTERSTITIAL]{opacity:0;background:rgba(0,0,0,.95);justify-content:center;align-items:center;transition:opacity 1s ease-in;display:flex;overflow:hidden}div[id^=O_INTERSTITIAL].pt-filled{opacity:1;z-index:2147483647;width:100%;height:100%}div[id^=O_INTERSTITIAL] div#oIntLayer{z-index:2147483647;width:100%;height:100%}div[id^=O_INTERSTITIAL].pt-filled div[id^=nat_]>.nat-justify-center,div[id^=O_INTERSTITIAL].pt-filled .ob-smartfeed-wrapper .ob-widget.ob-feed-layout{background-color:#fff}div[id^=O_INTERSTITIAL] div#cont-close-interstitial,div[id^=O_INTERSTITIAL] div#ptech-timer-interstitial,div[id^=O_INTERSTITIAL] button#close-ptech-interstitial{z-index:2147483647;width:32px;height:32px}div[id^=O_INTERSTITIAL] div#cont-close-interstitial{position:fixed;top:10px;right:10px}div[id^=O_INTERSTITIAL] div#cont-close-interstitial.top-large{top:50px!important}div[id^=O_INTERSTITIAL] div#ptech-timer-interstitial,div[id^=O_INTERSTITIAL] button#close-ptech-interstitial{color:#000;background:#fff;border:1px solid #000;border-radius:18px;justify-content:center;align-items:center;font-size:16px;font-weight:700;display:flex}div[id^=O_INTERSTITIAL] button#close-ptech-interstitial{cursor:pointer}#ogy-ad-slot.ogy_ad_slot_element.ogy_ad_slot_element--force-index,#inScreen.st-placement .st-reset{z-index:2147483642!important}.ptech-filled-interstitial{overflow:hidden}`;function Ko(e,t){var n;let r=parseInt((n=P(e))==null?``:n),i=1;isNaN(r)||(i=r+1),ie(e,i,t,void 0)}function qo({cookieName:e,frequency:t,disabled:n}){var r;if(n)return!1;let i=Number((r=P(e))==null?``:r);return!isNaN(i)&&i>=t}function Jo(e){let t=document.getElementById(e);if(t!=null)return t;let n=document.createElement(`div`);return n.id=e,document.body.appendChild(n),n}var Yo=11e3,Xo=1e3;function Zo({adUnitKey:e=`O_INTERSTITIAL`,closeButtonDuration:t=3,interstitialCappingCookieName:n=`pt_icapping`,interstitialCappingFrequency:r=1,interstitialCappingMinutes:i=5,interstitialDelay:a,isInterstitialCappingDisabled:o=!1,scrollThresholdForRefresh:s=200,startAfterUserScroll:c=!1,providersOrderedExecution:l}){let u=new Et({logKey:`debug_interstitial`,label:`INTERSTITIAL`});u.debug(`Starting..`);let d=le(`debug_interstitial`),f=ce(`google_preview`);f&&u.debug(`Google preview: no interstitial capping`);let p=o||f,m=l;return qo({cookieName:n,frequency:r,disabled:p})?(u.debug(`Capping limit reached at factory time, plugin opts out`),()=>null):o=>{let l=null,h=!1,g,_=[],y,x,S=0,C=null,ee=()=>{let e=_;_=[];for(let t of e)t()},w=()=>{var t;g!==void 0&&(clearInterval(g),g=void 0),x!==void 0&&(clearTimeout(x),x=void 0),ee(),(t=document.getElementById(e))==null||t.remove();try{document.body.classList.remove(`ptech-filled-interstitial`)}catch(e){u.debug(e)}},T=()=>{let t=(e,t)=>{try{t()}catch(t){u.debug(`Error ${e} while cancelling the pending interstitial sell`,t)}};t(`unscheduling the refresh`,()=>o.refreshApi.unscheduleSlotRefresh(e)),t(`destroying the GPT slot`,()=>{var t;return(t=o.gpt)==null?void 0:t.destroySlot(e)}),t(`removing the Prebid ad unit`,()=>{var t;return(t=o.prebidAdapter)==null?void 0:t.removeAdUnit(e)}),t(`clearing the cached sell options`,()=>o.monetizationManager.clearAdSlotState(e))},E=()=>{S++,l!=null&&(window.removeEventListener(`scroll`,l),l=null),y!==void 0&&(clearTimeout(y),y=void 0),T(),w()};return{pluginName:`interstitial`,onDisableAds:E,softTeardown:t=>{if(t===`bfcache-restore`){E(),C==null||C(`closed by a bfcache restore`);return}if(document.getElementById(e)==null||g===void 0){E(),C==null||C(`interrupted by a virtual navigation`);return}return new Promise(e=>{_.push(e)}).then(()=>{E(),C==null||C(`interrupted by a virtual navigation`)})},run(_){pe(Go);let T=()=>{p||Ko(n,i)},E=({interstitialLayerTimeout:n})=>{if(document.getElementById(`ovmcnt`)!=null){u.debug(`Reservation detected, skipping close rendering`);return}let r=document.getElementById(e);if(r==null){u.debug(`Interstitial container missing, cannot setup close rendering`);return}try{document.body.classList.add(`ptech-filled-interstitial`)}catch(e){u.debug(e)}r.classList.add(`pt-filled`),r.removeAttribute(`style`);let i=document.createElement(`div`);i.id=`cont-close-interstitial`;try{v()===window.screen.height&&navigator.userAgent.match(/instagram/i)&&i.classList.add(`top-large`)}catch(e){u.debug(e)}let a=document.createElement(`button`);a.id=`close-ptech-interstitial`,a.type=`button`,a.setAttribute(`aria-label`,`Close interstitial`),a.innerHTML=`x`,a.onclick=()=>w();let o=document.createElement(`div`);o.id=`ptech-timer-interstitial`,o.setAttribute(`aria-live`,`polite`),o.innerHTML=String(t),i.appendChild(o),r.appendChild(i);let s=t,c=setInterval(()=>{--s,s<=0?(clearInterval(c),g=void 0,o.remove(),i.appendChild(a),a.focus(),ee()):o.innerHTML=String(s)},Xo);g=c;let l=document.createElement(`div`);l.id=`oIntLayer`,l.onclick=e=>{u.debug(`Layer prevented unintentional click`),e.preventDefault(),e.stopPropagation()},setTimeout(()=>{u.debug(`Removing click-protection layer`),l.remove()},n),r.appendChild(l),!f&&!d?x=setTimeout(()=>{x=void 0,document.getElementById(e)===r&&(u.debug(`Auto-closing interstitial after timeout`),w())},Yo):u.debug(`Debug or Google preview enabled: skipping auto-close`)},D=t=>({enginePluginContext:o,adUnitKey:e,logger:u,isGooglePreview:f,isDebug:d,setCappingCookie:T,setupCloseRendering:e=>{if(t!==S){u.debug(`Ignoring close rendering asked for by a superseded interstitial cycle`);return}E(e)},closeInterstitial:()=>{if(t!==S){u.debug(`Ignoring close asked for by a superseded interstitial cycle`);return}w()}}),O=(e,t)=>{h||(h=!0,_({type:`completed`,deliveryStatus:t,message:e,onVirtualNavigationHook:{position:Eo,run:e=>{if(e!=`infinite-scroll`){if(qo({cookieName:n,frequency:r,disabled:p})){u.debug(`Skipping virtual interstitial chain due to capping limit`);return}k(!1)}}}}))};C=O;let te=function(){var t=b(function*(t){let i=S,a=D(i),o=!1,s=(e,n)=>{o||(o=!0,u.debug(`Interstitial chain finished: ${e}`),window.dispatchEvent(new Event(`pubtech_interstitial_done`)),t&&O(e,n))};Jo(e);for(let e of m){if(i!==S){s(`superseded by a newer interstitial cycle`);return}if(!e.canRun(a)){u.debug(`Skipping provider "${e.name}" — canRun returned false`);continue}if(qo({cookieName:n,frequency:r,disabled:p})){s(`capping limit reached mid-chain`,`no-fill`);return}u.debug(`Running provider "${e.name}"`);let t;try{t=yield e.execute(a)}catch(t){u.debug(`Provider "${e.name}" threw: ${String(t)}`);continue}if(i!==S){s(`superseded by a newer interstitial cycle`);return}if(t.served){s(`served by ${e.name}`,t.deferred?void 0:`filled`);return}if(`error`in t){u.debug(`Provider "${e.name}" errored: ${t.error}`);continue}u.debug(`Provider "${e.name}" returned empty, advancing chain`)}s(`all providers exhausted`,`no-fill`)});return function(e){return t.apply(this,arguments)}}(),k=e=>{let t=()=>{l!=null&&(window.removeEventListener(`scroll`,l),l=null)},n=()=>{if(window.scrollY>=s){t(),u.debug(`Scroll threshold already met, starting chain`),te(e);return}if(l!=null){u.debug(`Scroll listener already active, skipping duplicate registration`);return}u.debug(`Awaiting scroll threshold before starting chain`),l=()=>{window.scrollY<s||(t(),te(e))},window.addEventListener(`scroll`,l)};if(c){n();return}te(e)};a!=null&&a>0&&!f?(u.debug(`Interstitial delay set, waiting ${a}s before starting chain`),y=setTimeout(()=>k(!0),a*1e3)):k(!0)}}}}var Qo=`__engine_prebid_ready__`,$o=`https://ads.talkscreativity.com/assets/publisher/ilsoftwareit/prebid.C9013Bz8.js`,es=3;function ts(){let e={attempt:0,lastError:`UNKNOWN`},t=null;return new Promise((n,r)=>{let i=e=>{if(t!=null&&(t.onerror=null),!is(e)){r(Error(`[Engine] Prebid provider received via event is not a function`));return}n(e.detail)},a=()=>{e.attempt+=1;let n=os();t=n,n.onerror=t=>{if(e.lastError=ns(t),n.parentNode!=null&&n.parentNode.removeChild(n),e.attempt>=es){document.removeEventListener(Qo,i),r(Error(`[Engine] Failed to load prebid bundle: `+n.src+` - `+e.lastError+` (attempts: `+e.attempt+`)`));return}if(e.lastError===`ERR_NET_OFFLINE`){as().then(a);return}a()},document.head.appendChild(n)};document.addEventListener(Qo,i,{once:!0}),a()})}function ns(e){let t=String(e);return(e instanceof Event?e.target:null)instanceof HTMLScriptElement||(t=`ERR_NO_SCRIPT_ELEMENT`),navigator.onLine||(t=`ERR_NET_OFFLINE`),t}function rs(e){return typeof e==`function`}function is(e){return e instanceof CustomEvent&&rs(e.detail)}function as(){return navigator.onLine?Promise.resolve():new Promise(e=>{window.addEventListener(`online`,()=>{e()},{once:!0})})}function os(){let e=document.createElement(`script`);return e.src=$o,e.async=!0,e}function ss({isStandardSetupCloseRenderingRequired:e=!0,sizeMapping:t}){return{name:`prebid`,canRun(e){return t[e.enginePluginContext.device]!=null},execute(n){return new Promise(r=>{var i;let a=()=>{n.logger.debug(`Prebid interstitial served`),n.setCappingCookie(),e?setTimeout(()=>n.setupCloseRendering({interstitialLayerTimeout:1500}),300):n.setupCloseRendering({interstitialLayerTimeout:0}),r({served:!0})},o={callbacks:{onGptSuccess:a,onClientRenderSuccess:a,onUnfilled:()=>{n.logger.debug(`Prebid interstitial returned empty`);let e=document.getElementById(n.adUnitKey);e!=null&&(e.innerHTML=``),r({served:!1,empty:!0})},onFallback:()=>{n.logger.debug(`Prebid interstitial auction failed`),r({served:!1,error:`All auction phases failed for interstitial`})}}};n.enginePluginContext.adSlotLifecycleApi.setAdSlotAsSelfManaged(n.adUnitKey),n.enginePluginContext.monetizationManager.sell({adUnitKey:n.adUnitKey,divId:n.adUnitKey,overrideAdUnitSizes:(i=t[n.enginePluginContext.device])==null?void 0:i[n.adUnitKey]},o)})}}}function cs(){if(document.querySelector(`link[href="https://imasdk.googleapis.com/js/sdkloader/ima3.js"]`)==null)try{let e=document.createElement(`link`);e.rel=`preload`,e.href=`https://imasdk.googleapis.com/js/sdkloader/ima3.js`,e.as=`script`,(document.head||document.getElementsByTagName(`head`)[0]).appendChild(e)}catch(e){}}function ls(e,t,n){let r=`https://ads.talkscreativity.com/assets/product/mn-player.js`;t===`pre_prod`?r=`https://devads.talkscreativity.com/assets/product/mn-player_pre_prod.js`:t===`dev`&&(r=`https://devads.talkscreativity.com/assets/product/mn-player_dev.js`),window._mnPlayerConfig=window._mnPlayerConfig||[],typeof window.mnPlayerQueue==`object`&&typeof window.mnPlayerQueue.queue==`object`||(window.mnPlayerQueue={queue:[]}),e.debug(`Loading MnPlayer script with version: ${t}`),n.loadScript({scriptTag:`mn-player`,scriptUrl:r})}var us={desktop:3,mobile:2,tablet:4},ds=`it`;function fs(e,t){return`&url=${encodeURIComponent(window.location.href)}&hl=${ps()}&dth=${us[e]}&ppid=${encodeURIComponent(Qe())}&wta=1`+(t==null?``:`&vconp=${t}`)}function ps(){var e;let t=((e=document.documentElement.lang)==null?``:e).split(`-`)[0].trim().toLowerCase();return/^[a-z]{2,3}$/.test(t)?t:ds}function ms({isMobile:e,logger:t,ogury:n,vipInstance:r,vipPosition:i}){if(t.debug(`Start insert ogury`),!e){r.refreshVideo();return}t.debug(`Ogury ready`);try{var a;let e=document.createElement(`script`);e.setAttribute(`type`,`text/javascript`),e.setAttribute(`src`,`https://mwtw.presage.io/v1/tag.js`),e.setAttribute(`async`,`true`),document.body.appendChild(e);let o={callbacks:{on_ad_complete:()=>{hs({logger:t,vipInstance:r})},on_error:()=>{gs({logger:t,vipInstance:r})},on_no_ad:()=>{gs({logger:t,vipInstance:r})}}};if(n.second_call_ad_unit_id!==void 0&&(o.ad_unit_id=n.second_call_ad_unit_id),window.top==null)return;window.top.OG_ad_units=(a=window.top.OG_ad_units)==null?[]:a,window.top.OG_ad_units.push({ad_unit_id:n.first_call_ad_unit_id,asset_key:n.first_call_asset_key,callbacks:{on_ad_complete:()=>{hs({logger:t,vipInstance:r})}},params:{gravity:i,max_height:180,max_width:180,y_margin:100},passback:o})}catch(e){t.debug(`Ogury error:`,e)}}function hs({logger:e,vipInstance:t}){e.debug(`Called ogury on_ad_complete`),t.updateAdStartCount(),t.refreshVideo()}function gs({logger:e,vipInstance:t}){e.debug(`Called ogury on_no_ad/on_error, refresh video`),t.refreshVideo()}function _s({logger:e,sellerId:t,vipInstance:n,viralizeId:r}){var i,a;e.debug(`Start insert viralize`),window.vpt=(i=window.vpt)==null?{}:i,window.vpt.queue=(a=window.vpt.queue)==null?[]:a,window.vpt.queue.push(()=>{var t,i,a,o,s,c,l,u;(t=window.vpt)==null||(i=t.on)==null||i.call(t,(a=(o=window.vpt.EVENTS)==null?void 0:o.AD_IMPRESSION)==null?`AD_IMPRESSION`:a,()=>{e.debug(`Viralize AD_IMPRESSION`),n.updateAdStartCount()}),(s=window.vpt)==null||(c=s.on)==null||c.call(s,(l=(u=window.vpt.EVENTS)==null?void 0:u.END)==null?`END`:l,t=>{e.debug(`Viralize AD_END ${t==null?void 0:t.zid}`),(t==null?void 0:t.zid)===r&&n.refreshVideo()})});let o=document.createElement(`script`);o.setAttribute(`data-wid`,`auto`),o.type=`text/javascript`,o.src=`https://ads.viralize.tv/display/?zid=`+r+`&u=`+encodeURIComponent(window.location.href)+`&schain=1.0,1!talksmedia.it,`+t+`,1,,,`,document.body.appendChild(o)}var vs=new WeakMap,ys=new WeakMap,bs=new WeakMap,Y=new WeakMap,xs=new WeakMap,Ss=new WeakMap,Cs=new WeakMap,X=new WeakMap,ws=new WeakMap,Ts=new WeakMap,Es=new WeakMap,Ds=new WeakMap,Os=new WeakMap,ks=new WeakMap,As=new WeakMap,js=new WeakMap,Ms=new WeakMap,Ns=new WeakMap,Ps=new WeakMap,Fs=new WeakMap,Is=new WeakMap,Ls=new WeakMap,Rs=new WeakMap,Z=new WeakMap,zs=new WeakMap,Bs=new WeakMap,Vs=new WeakMap,Hs=new WeakMap,Us=new WeakMap,Ws=new WeakMap,Q=new WeakMap,Gs=new WeakMap,Ks=new WeakMap,$=new WeakSet,qs=class{constructor(e){L(this,$),n(this,vs,void 0),n(this,ys,void 0),n(this,bs,void 0),n(this,Y,void 0),n(this,xs,void 0),n(this,Ss,void 0),n(this,Cs,void 0),n(this,X,void 0),n(this,ws,void 0),n(this,Ts,void 0),n(this,Es,void 0),n(this,Ds,void 0),n(this,Os,void 0),n(this,ks,`https://pubads.g.doubleclick.net/gampad/ads?iu=/21775744923/external/single_preroll_skippable&sz=640x480&ciu_szs=300x250%2C728x90&gdfp_req=1&output=vast&unviewed_position_start=1&env=vp&impl=s&correlator=`),n(this,As,void 0),n(this,js,void 0),n(this,Ms,void 0),n(this,Ns,void 0),n(this,Ps,void 0),n(this,Fs,void 0),n(this,Is,void 0),n(this,Ls,void 0),n(this,Rs,0),n(this,Z,0),n(this,zs,[]),n(this,Bs,[]),n(this,Vs,!1),n(this,Hs,null),n(this,Us,0),n(this,Ws,500),n(this,Q,0),n(this,Gs,void 0),n(this,Ks,void 0),i(vs,this,e.adPlayLimit),i(ys,this,e.enginePluginContext.device),i(bs,this,e.getTargeting),i(Y,this,e.injectedBannerPluginApi),i(xs,this,e.enginePluginContext.adSlotLifecycleApi.isAdvDisabled),i(Ss,this,e.isMnPlayerScriptLoaded),i(Cs,this,e.enginePluginContext.isMobile),i(X,this,e.logger),i(ws,this,e.otherVipConfig),i(Ts,this,e.playerConfig),i(Es,this,e.playerPosition),i(Ds,this,e.plcmtParameter),i(Os,this,e.enginePluginContext.prebidAdapter),i(As,this,e.refreshLimit),i(js,this,e.runOnEnd),i(Ms,this,e.scriptLoader),i(Ns,this,e.enginePluginContext.sellerId),i(Ps,this,e.vastIU),i(Fs,this,e.vconpParameter),i(Is,this,e.videoTargeting),i(Ls,this,e.vtrTargeting)}init(){var e=this;return b(function*(){var t;if(a(xs,e).call(e)){r($,e,ic).call(e);return}let n=a(Z,e);i(Q,e,(t=a(Q,e),t++,t));let o=r($,e,Js).call(e);if(a(Os,e)){let t={adUnitKey:`VIP`,placement:a(Ds,e),vast:o};yield a(Os,e).buildVideoVast(t,(t,o)=>{n===a(Z,e)&&(i(Ks,e,o),r($,e,Ys).call(e,{vast:t}))},a(X,e));return}n===a(Z,e)&&(i(Ks,e,void 0),r($,e,Ys).call(e,{vast:o}))})()}refreshVideo(e=!1){if(e){r($,this,ac).call(this);return}let t=a(Rs,this)>=a(vs,this)||a(Q,this)>a(As,this);if(a(Q,this)===3&&typeof a(ws,this)==`object`&&a(Us,this)===0){let{loadOtherVipAfterFirstEmptyVideo:e,ogury:n,viralize:i}=a(ws,this);if(!t&&e&&(i!=null||n!=null)){a(X,this).debug(`Invoking the other vip`),r($,this,Qs).call(this,n,i);return}}if(!t){a(Y,this)==null?i(Ws,this,a(Q,this)<=5?500:2500):(i(Ws,this,a(Q,this)===1?7e3:3500),a(Q,this)===1&&a(Y,this).injectBannerInsideVideoPlayer(a(Hs,this))),a(X,this).debug(`Refresh VIP and start again`);let e=a(Z,this);r($,this,ec).call(this),i(Gs,this,setTimeout(()=>{i(Gs,this,void 0),e===a(Z,this)&&this.init()},a(Ws,this)));return}if(typeof a(ws,this)==`object`&&a(Us,this)===0){let{ogury:e,viralize:t}=a(ws,this);if(a(Rs,this)<a(vs,this)&&(t!=null||e!=null)){a(X,this).debug(`Invoking the other vip`),r($,this,Qs).call(this,e,t);return}}r($,this,ac).call(this)}teardown(){r($,this,$s).call(this)}reset(){r($,this,$s).call(this),i(Rs,this,0),i(Us,this,0),i(Q,this,0)}isDeliveringAd(){var e;return a(Vs,this)||((e=a(Y,this))==null?void 0:e.isOnScreen())===!0}whenDeliveryFinished(){var e;return a(Vs,this)?new Promise(e=>{a(Bs,this).push(e)}):((e=a(Y,this))==null?void 0:e.isOnScreen())===!0?a(Y,this).whenViewTimeElapsed():Promise.resolve()}whenCycleFinished(){return new Promise(e=>{a(zs,this).push(e)})}updateAdStartCount(){var e;i(Vs,this,!0),i(Rs,this,(e=a(Rs,this),e++,e)),a(X,this).debug(`Update ad start count to ${a(Rs,this)}`)}updateRefreshCount(){var e;i(Q,this,(e=a(Q,this),e++,e)),a(X,this).debug(`Update refresh count to ${a(Q,this)}`)}};function Js(){if(le(`preview_video`))return a(X,this).debug(`Preview video`),a(ks,this);let e=[],t=``;if(window.googletag!=null&&typeof window.googletag.getConfig==`function`){var n,r,i,o,s,c,l,u;let a=window.googletag.getConfig(`targeting`);t=(n=(r=(i=a.targeting)==null?void 0:i.pageTargeting)==null?(o=a.targeting)==null?void 0:o.pagina:r)==null?``:n,e=(s=(c=(l=a.targeting)==null?void 0:l.sectionsTargeting)==null?(u=a.targeting)==null?void 0:u.section:c)==null?[]:s}if(typeof a(bs,this)==`function`){var d,f;let n=a(bs,this).call(this);e=(d=n.sectionsTargeting)==null?e:d,t=(f=n.pageTargeting)==null?t:f}let p=Array.isArray(e)?e.join(`,`):e,m=Array.isArray(t)?t.join(`,`):t,h=a(Ds,this)===1?`instream`:`vp`;return`https://pubads.g.doubleclick.net/gampad/ads?sz=640x480%7C400x300%7C360x640%7C640x360&iu=${a(Ps,this)}&gdfp_req=1&env=${h}&output=xml_vmap1&plcmt=${a(Ds,this)}&ad_rule=1&vpos=preroll&ad_type=video&unviewed_position_start=1`+fs(a(ys,this),a(Fs,this))+`&description_url=`+encodeURIComponent(window.location.href)+`&cust_params=${a(Is,this)}%3D`+encodeURIComponent(p)+`%26pagina%3D${m}%26refresh%3D${a(Q,this)}`+a(Ls,this)}function Ys({vast:e}){if(e.indexOf(`hb_uuid%3Dundefined`)>-1&&(Math.random()<.5?e+=`%26no_bid%3D1`:e+=`%26no_bid%3D0`),a(Hs,this)!=null){a(X,this).debug(`MnPlayer instance is defined, start adv library`),a(Hs,this).startAdvLibrary(e,!0);return}a(X,this).debug(`MnPlayer instance is null, setting configs and load player`);let t=a(Z,this);if(a(Ss,this)){var n;a(X,this).debug(`Push loadMnPlayer to the player queue`),(n=window.mnPlayerQueue)==null||n.queue.push(()=>r($,this,Xs).call(this,e,t));return}a(X,this).debug(`Call loadMnPlayer when script will be ready`),a(Ms,this).onReadyScript(`mn-player`,()=>{var n;(n=window.mnPlayerQueue)==null||n.queue.push(()=>r($,this,Xs).call(this,e,t))})}function Xs(e,t){var n=this;return b(function*(){if(t!==a(Z,n))return;let o={};if(typeof a(Ts,n)==`function`?o=yield a(Ts,n).call(n):typeof a(Ts,n)==`object`&&(o=a(Ts,n)),t!==a(Z,n))return;let s=F({adTagUrl:e,autoPlay:!0,behavior:`inslide`,onPlayerReady:e=>{r($,n,Zs).call(n,e)},playerPosition:a(Es,n),startAdWithVolume:!0},o);a(X,n).debug(`MnPlayer is ready`),i(Hs,n,window.loadMnPlayer(s))})()}function Zs(e){a(X,this).debug(`Define MnPlayer events`);let t=a(Z,this),n=()=>t===a(Z,this);e.on(`AD_CLOSED`,()=>{a(X,this).debug(`MnPlayer AD_CLOSED`),n()&&this.refreshVideo()}),e.on(`AD_LOADED`,()=>{a(X,this).debug(`MnPlayer AD_LOADED`)}),e.on(`AD_STARTED`,()=>{var e;a(X,this).debug(`MnPlayer AD_STARTED`),n()&&((e=a(Y,this))==null||e.unscheduleRefresh(),this.updateAdStartCount())}),e.on(`AD_IMPRESSION`,e=>{var t;a(X,this).debug(`MnPlayer AD_IMPRESSION`,e),n()&&((t=a(Ks,this))==null||t.call(this,e))}),e.on(`AD_ERROR`,e=>{a(X,this).debug(`MnPlayer AD_ERROR, try refresh video`,e),n()&&this.refreshVideo()}),e.on(`ALL_ADS_COMPLETED`,()=>{a(X,this).debug(`MnPlayer ALL_ADS_COMPLETED`),n()&&this.refreshVideo()}),e.on(`PLAYER_CLOSED`,()=>{a(X,this).debug(`MnPlayer PLAYER_CLOSED`),n()&&this.refreshVideo(!0)})}function Qs(e,t){let n=r($,this,tc).call(this);if(t!=null){a(X,this).debug(`Can insert Viralize`),i(Us,this,1),_s({logger:a(X,this),sellerId:a(Ns,this),vipInstance:n,viralizeId:t});return}e!=null&&(a(X,this).debug(`Can insert Ogury`),i(Us,this,1),ms({isMobile:a(Cs,this),logger:a(X,this),ogury:e,vipInstance:n,vipPosition:a(Es,this)===`right`?`BOTTOM_RIGHT`:`BOTTOM_LEFT`}))}function $s(){var e,t;i(Z,this,(e=a(Z,this),e++,e)),i(Ks,this,void 0),r($,this,ec).call(this),i(Vs,this,!1),(t=a(Y,this))==null||t.teardown(a(Hs,this)),r($,this,nc).call(this),r($,this,rc).call(this),r($,this,ic).call(this)}function ec(){a(Gs,this)!==void 0&&(clearTimeout(a(Gs,this)),i(Gs,this,void 0))}function tc(){let e=a(Z,this),t=()=>e===a(Z,this)?!0:(a(X,this).debug(`Ignoring a call from an other-vip provider whose cycle has already been replaced`),!1);return{refreshVideo:e=>{t()&&this.refreshVideo(e)},updateAdStartCount:()=>{t()&&this.updateAdStartCount()}}}function nc(){let e=a(Hs,this);if(i(Hs,this,null),e!=null)try{typeof e.destroy==`function`?e.destroy():typeof e.dispose==`function`&&e.dispose()}catch(e){a(X,this).debug(`Error destroying the MnPlayer instance`,e)}try{var t;(t=document.getElementById(`mn-outstream-container`))==null||t.remove()}catch(e){a(X,this).debug(`Error removing the MnPlayer container`,e)}}function rc(){let e=a(Bs,this);i(Bs,this,[]);for(let t of e)t()}function ic(){let e=a(zs,this);i(zs,this,[]);for(let t of e)t()}function ac(){a(X,this).debug(`Regular VIP done`),i(Vs,this,!1);let e=a(Y,this);if(e!=null&&e.isOnScreen()){a(X,this).debug(`Injected banner still on screen, waiting for its view time before completing`);let t=a(Z,this);e.whenViewTimeElapsed().then(()=>{if(t!==a(Z,this)){a(X,this).debug(`Injected banner view time elapsed for a cycle that has already been replaced`);return}r($,this,oc).call(this)});return}r($,this,oc).call(this)}function oc(){if(a(Y,this)!=null)try{a(Y,this).teardown(a(Hs,this))}catch(e){a(X,this).debug(`Error tearing down injected banner plugin`,e)}try{var e;a(X,this).debug(`Call handle video content resume`),(e=a(Hs,this))==null||e.handleVideoContentResume()}catch(e){a(X,this).debug(`Error resuming video content`,e)}r($,this,rc).call(this);try{typeof a(js,this)==`function`&&a(js,this).call(this)}catch(e){a(X,this).error(`Error on runOnEnd function`,e)}a(X,this).debug(`Dispatch video events`),a(Rs,this)>0?window.dispatchEvent(new Event(`pubtechVideoAdServed`)):(window.dispatchEvent(new Event(`AdvVideoNotFilled`)),window.dispatchEvent(new Event(`pubtechVideoAdMissed`))),window.dispatchEvent(new Event(`pubtech_video_done`)),r($,this,ic).call(this)}function sc(e){cs();let t=new Et({logKey:`debug_video`,label:`VIP`}),n=u.getInstance(),r=!1;return document.querySelector(`script[src*="talkscreativity.com/assets/product/mn-player"]`)==null?ls(t,e.version,n):(t.debug(`MnPlayer script already loaded`),r=!0),i=>{var a;let o=(a=M(e.overrideVastIU))==null?i.fullNameAd+`VIP`:a,s=M(e.vtrTargeting),c=s?`%26SPurl_4time%3D${s}`:``,l=null;typeof e.injectedBannerPlugin==`function`&&(l=e.injectedBannerPlugin({adSlotLifecycleApi:i.adSlotLifecycleApi,domain:i.domain,eventDispatcher:i.eventDispatcher,logger:t,monetizationManager:i.monetizationManager,refreshApi:i.refreshApi,sizeMappingApi:i.sizeMappingApi}));let u;return{pluginName:`vip`,onDisableAds:()=>{var e;(e=document.getElementById(`mn-outstream-container`))==null||e.remove(),u==null||u.teardown()},softTeardown:e=>{if(e===`bfcache-restore`){u==null||u.teardown();return}if((u==null?void 0:u.isDeliveringAd())!==!0){u==null||u.teardown();return}return u.whenDeliveryFinished().then(()=>u==null?void 0:u.teardown())},run(a){var s,d,f,p,m;t.debug(`Starting vip plugin`);let h=()=>{a({type:`completed`,onVirtualNavigationHook:{position:To,run:function(){if(u===void 0)return Promise.resolve();u.reset();let e=u.whenCycleFinished();return u.init(),e}}})},g=M(e.vconpParameter);u=new qs({adPlayLimit:(s=e.adPlayLimit)==null?1:s,enginePluginContext:i,getTargeting:e.getTargeting,injectedBannerPluginApi:l,isMnPlayerScriptLoaded:r,logger:t,otherVipConfig:e.otherVipConfig,playerConfig:e.playerConfig,playerPosition:(d=e.playerPosition)==null?`right`:d,plcmtParameter:(f=M(e.plcmtParameter))==null?2:f,refreshLimit:(p=M(e.refreshLimit))==null?5:p,runOnEnd:h,scriptLoader:n,vastIU:o,vconpParameter:g===void 0?1:g,videoTargeting:(m=e.videoTargeting)==null?`videoTargeting`:m,vtrTargeting:c}),u.init()}}}}var cc=`:root{--side-rail-site-width:1200px;--side-rail-offset:1225px;--side-rail-top:50px;--side-rail-width:160px;--side-rail-height:620px;--side-rail-z-index:10}#O_SKIN{z-index:99999;top:0;right:0;max-width:1px!important;max-height:1px!important;position:fixed!important}.pos-left-adv{z-index:var(--side-rail-z-index);left:calc((100vw - var(--side-rail-site-width)) / 2 + var(--side-rail-offset));top:var(--side-rail-top);visibility:visible;float:left;opacity:1;width:var(--side-rail-width);min-width:var(--side-rail-width);max-width:var(--side-rail-width);height:var(--side-rail-height);min-height:var(--side-rail-height);max-height:var(--side-rail-height);border:0;margin:0;padding:0;transition-duration:0s;display:block;overflow:visible;position:fixed!important}.pos-right-adv{z-index:var(--side-rail-z-index);right:calc((100vw - var(--side-rail-site-width)) / 2 + var(--side-rail-offset));top:var(--side-rail-top);visibility:visible;float:left;opacity:1;width:var(--side-rail-width);min-width:var(--side-rail-width);max-width:var(--side-rail-width);height:var(--side-rail-height);min-height:var(--side-rail-height);max-height:var(--side-rail-height);border:0;margin:0;padding:0;transition-duration:0s;display:block;overflow:visible;position:fixed!important}.fixedFs{position:fixed!important;top:70px!important}`,lc=[`--side-rail-site-width`,`--side-rail-offset`,`--side-rail-top`,`--side-rail-width`,`--side-rail-height`],uc=1539;function dc(e){if(document.body!=null){document.body.classList.add(e);return}let t=new MutationObserver(()=>{document.body!=null&&(t.disconnect(),document.body.classList.add(e))});t.observe(document.documentElement,{childList:!0})}function fc({desktopMinWidth:e=1260,fallbackToSideRails:t=!0,onSideRailRender:n,onSkinRender:r,railHeight:i=620,railWidth:a=160,reserveSideRailsBodyClass:o=!1,scaleIframeOnPostInjection:s=!1,scrollStickyOffset:c=70,scrollStickyThreshold:l=57,setupMobileSkinContainer:u,sideRailDomClassMap:d,sideRailsBodyClass:f,sideRailsOffset:p=1225,sideRailsSiteWidth:m=1200,sideRailsSizeMapping:h,sideRailsTop:g=50,skinBodyClass:v=[],skinBodyClassToRemoveOnRefresh:y=[`tksskin`,`has-skin-adv`],skinClickElementsToRemoveOnRefresh:x=[`barra_click_top`,`barra_click_sx`,`barra_click_dx`],skinSizeMapping:S,topHeaderSelector:ee=`header#header`,useNativeGoogleSideRailSlots:w=!1,useSkinSlot:T=!0}){var E,D;let O=new Et({logKey:`debug_engine`,label:`WRAPPER_AD_PLUGIN`}),te={S_1:(E=d==null?void 0:d.S_1)==null?`pos-left-adv`:E,S_2:(D=d==null?void 0:d.S_2)==null?`pos-right-adv`:D},k=_(),A=f!=null&&M(o)&&!C().isMobile&&M(t)&&k>=e&&k<uc;return A&&dc(f),o=>{let d=o.isMobile&&typeof u==`function`;for(let e of[`O_SKIN`,`S_1`,`S_2`])o.adSlotLifecycleApi.setAdSlotAsSelfManaged(e),o.adSlotLifecycleApi.setAdSlotAsDisposableOnVirtualNavigation(e,`spa-route`);function C(){for(let e of x){let t=document.getElementById(e);t!=null&&(t.parentElement!=null&&t.parentElement.tagName.toLowerCase()===`a`?t.parentElement.remove():t.remove())}}let E=[],D=[],k,j,ne=!1,re=!1,N={S_1:!1,S_2:!1},P={S_1:!1,S_2:!1};function ie(){var e;for(let e of E)e.unsubscribe();E=[],document.body.classList.remove(...v,...y),C(),(e=document.getElementById(`O_SKIN`))==null||e.remove()}function ae(){var e,t;if(ne){k&&(window.removeEventListener(`scroll`,k),k=void 0),j&&(window.removeEventListener(`resize`,j),j=void 0),re=!1,(e=document.getElementById(`S_1`))==null||e.remove(),(t=document.getElementById(`S_2`))==null||t.remove();for(let e of lc)document.documentElement.style.removeProperty(e);f&&document.body.classList.remove(f),o.refreshApi.unscheduleSlotRefresh(`S_1`),o.refreshApi.unscheduleSlotRefresh(`S_2`);for(let e of D)e.unsubscribe();D=[],N.S_1=!1,N.S_2=!1,ne=!1}}return{pluginName:`wrapperAd`,onDisableAds:()=>{ie(),ae()},run(x){return b(function*(){if(o.isMobile&&(!d||!T)){x({type:`completed`,message:`Skin not applicable`});return}if(!o.isMobile&&_()<e){x({type:`completed`,message:`Not enough space for skin or side rails`});return}pe(cc);function b(){let e=`O_SKIN`,n=document.getElementById(e);n==null&&(n=document.createElement(`div`),n.id=e,document.body.prepend(n)),n.style.cssText=`max-width: 1px; max-height: 1px; overflow: hidden;`;let i=e=>{r==null||r({context:o,isEmpty:e,logger:O}),e||(O.debug(`O_SKIN loaded successfully`),document.body.classList.add(...v),ae());for(let e of E)e.unsubscribe();E=[]};E=[o.eventDispatcher.subscribe({eventName:Ue,subscriberName:`wrapperAdSkinUnfilledSubscriber`,callback:e=>{e.adUnitKey===`O_SKIN`&&i(!0)}}),o.eventDispatcher.subscribe({eventName:We,subscriberName:`wrapperAdSkinFilledSubscriber`,callback:e=>{e.adUnitKey===`O_SKIN`&&i(!1)}})],o.monetizationManager.sell({adUnitKey:e,divId:e,overrideAdUnitSizes:S},{useClientSideRenderFallback:!o.isMobile,excludeFromRefresh:!0,callbacks:{onUnfilled:()=>{var e;O.debug(`O_SKIN unfilled, executing fallback routine`),document.body.classList.remove(...v,...y),A&&document.body.classList.add(f),C(),(e=document.getElementById(`O_SKIN`))==null||e.remove(),M(t)&&!o.isMobile&&ce()}}})}function oe(){re||(re=!0,k=()=>{let e=document.querySelector(ee),t=e?e.getBoundingClientRect():null,n=document.getElementById(`S_1`),r=document.getElementById(`S_2`);if(t&&t.bottom<l)n==null||n.classList.add(`fixedFs`),r==null||r.classList.add(`fixedFs`),document.documentElement.style.setProperty(`--side-rail-top`,`${c}px`);else{n==null||n.classList.remove(`fixedFs`),r==null||r.classList.remove(`fixedFs`);let e=t?t.bottom+30:g;document.documentElement.style.setProperty(`--side-rail-top`,`${e}px`)}},j=()=>{(N.S_1||N.S_2)&&f&&(_()<uc?document.body.classList.add(f):document.body.classList.remove(f))},window.addEventListener(`scroll`,k,{passive:!0}),window.addEventListener(`resize`,j),j())}function se(e){let t=document.getElementById(e);t==null&&(t=document.createElement(`div`),t.id=e,t.className=te[e],document.body.prepend(t));let n=document.documentElement.style;n.setProperty(`--side-rail-site-width`,`${m}px`),n.setProperty(`--side-rail-offset`,`${p}px`),n.setProperty(`--side-rail-width`,`${a}px`),n.setProperty(`--side-rail-height`,`${i}px`);let r={adUnitKey:e,divId:e,refreshCount:0};o.monetizationManager.sell(r,{excludePrebid:!1,excludeFromRefresh:!1,callbacks:{onGptFailure:()=>{O.debug(`Pubtech side rail ${e} failed to render`)}}}),s&&zn({adUnitSizeConfig:{desktop:{[e]:{containerWidth:a}},tablet:{[e]:{containerWidth:a}},mobile:{[e]:{containerWidth:a}}},logger:O,isOnPostInjection:!0,device:o.device}),oe(),k==null||k()}function ce(){if(o.isMobile&&ne)return;if(!h){o.logger.warn(`Side rails size mapping is not provided. Side rails will not be set up`);return}o.sizeMappingApi.addSizeMaps(`S_1`,h),o.sizeMappingApi.addSizeMaps(`S_2`,h);for(let n of[`S_1`,`S_2`]){var e,t;w&&((e=window.googletag)==null||(e=e.enums)==null||(e=e.OutOfPageFormat)==null?void 0:e.RIGHT_SIDE_RAIL)!=null&&((t=window.googletag)==null||(t=t.enums)==null||(t=t.OutOfPageFormat)==null?void 0:t.LEFT_SIDE_RAIL)!=null?(O.debug(`wrapperAd plugin: Sell Google side rail for ${n}`),P[n]=!0,o.monetizationManager.sell({adUnitKey:n,divId:n,slotType:n===`S_1`?`outOfPageRightSideRail`:`outOfPageLeftSideRail`},{excludePrebid:!0,excludeFromRefresh:!0,callbacks:{onGptFailure:()=>{O.debug(`Google side rail ${n} could not be defined, waiting for the unfilled event to fall back`)}}})):se(n)}let r=(e,t)=>{if(t&&P[e]){O.debug(`Google side rail ${e} empty, falling back to pubtech side rail`),n==null||n({adUnitKey:e,context:o,isEmpty:!0,isGoogleSideRail:!0,logger:O}),P[e]=!1,se(e);return}n==null||n({adUnitKey:e,context:o,isEmpty:t,isGoogleSideRail:P[e],logger:O}),N[e]=!t,j&&j()};D=[o.eventDispatcher.subscribe({eventName:Ue,subscriberName:`wrapperAdSideRailsUnfilledSubscriber`,callback:e=>{e.adUnitKey!==`S_1`&&e.adUnitKey!==`S_2`||r(e.adUnitKey,!0)}}),o.eventDispatcher.subscribe({eventName:We,subscriberName:`wrapperAdSideRailsFilledSubscriber`,callback:e=>{e.adUnitKey!==`S_1`&&e.adUnitKey!==`S_2`||r(e.adUnitKey,!1)}})],ne=!0}if(T){if(d)try{yield u==null?void 0:u({context:o,logger:O})}catch(e){O.error(`Error in setupMobileSkinContainer`,e)}b()}else ce();x({type:`completed`,onVirtualNavigationHook:{position:To,run:function(e){e!==`spa-route`&&e!==`bfcache-restore`||(O.debug(`${e} detected, rebuilding skin or side rails`),ie(),ae(),A&&document.body.classList.add(f),T?b():ce())}}})})()}}}}var pc=ts();Wo(`0df9b9b0-42af-4fd9-8e31-5ba59435cd7e`);var{isDesktop:mc,isMobile:hc}=C();window._mnPlayerConfig=window._mnPlayerConfig||[],window._mnPlayerConfig.push({autoPlay:!0,autoPlayCheckRequired:!0,behavior:`inslide`,closeButton:{enabled:!0,hideOnAdComplete:!1,position:`top-right`,showAfter:hc?15:30,showAfterAdComplete:!1,text:`X`},startAdWithVolume:!0,style:{"inslide-offset-bottom":hc?`10px`:`30px`,color:`#D97706`}});var gc=[`C_1`,`C_2`,`C_3`,`C_4`,`C_5`,`C_6`],_c;function vc(){return _c!=null||(_c=document.querySelector(`.tag-offerte`)!=null||document.querySelector(`.no-adv`)!=null||window.location.pathname.includes(`/offerte/`)),_c}function yc(){return hc?[[1,1]]:[[1,1],[1800,1e3]]}function bc(){document.body.classList.contains(`single_post`)&&_e(document.querySelector(`.articles-container`),Oe(`SKIN_CONT_MOB`,!1))}function xc(e){let t=e.nextElementSibling;if((t==null?void 0:t.nodeName)===`P`&&t.innerText===``&&(t=t.nextElementSibling),(t==null?void 0:t.nodeName)===`DIV`)return{skipFrequency:!0,continue:!0}}var Sc=0,Cc=1;function wc(e){T(()=>{setTimeout(()=>{var t;((t=window.UI)==null?void 0:t.infinite)!=null&&window.UI.infinite.loadCallbackStack.push(()=>{Sc++,e({type:`infinite-scroll`,url:`${window.location.href}#pt-infinite-${Sc}`})})},1e3)})}function Tc(e){var t,n,r;if(e.virtualPageContext.type===`bfcache-restore`)return;(t=window.googletag)==null||(n=t.pubads)==null||n.call(t).setTargeting(`infinite_scroll`,`1`);let i=null;for(let e of document.querySelectorAll(`article[id^="post-"]`))if(!e.hasAttribute(`infinite-loaded`)){e.setAttribute(`infinite-loaded`,`1`),i=e.id.replace(`post-`,``);break}if(i!=null){(r=document.querySelector(`#post-${i} .stickySidebar`))==null||r.appendChild(Oe(`D_1_${Cc}`)),je({pageContainer:`#post-${i}`,elementContainer:`#post-${i} .post-content-single`,logger:e.logger,sizeMappingApi:e.sizeMappingApi,frequency:3,skipMinTextLength:!0,elementsList:gc.map(e=>`${e}_${Cc}`),isInfiniteScroll:!0,skipInsertingPointWebsiteCallback:xc});for(let t of[...gc,`D_1`]){let n=`${t}_${Cc}`,r=e.sizeMappingApi.getAdUnitSizes(t);document.getElementById(n)==null||r.length===0||e.lazyLoader.register({adUnitKey:t,divId:n,overrideAdUnitSizes:r,overridePrebidAdUnitCode:n})}Cc++}}function Ec(e){var t,n;let r=`#custom_html-15, #custom_html-13 {height:auto!important;} `;if(hc?r+=`div[class^="container_C_1"], div[class^="container_C_3"], div[class^="container_C_5"] { min-height:630px!important; }div[class^="container_C_2"], div[class^="container_C_4"], div[class^="container_C_6"] { min-height:350px!important; }.pubtech-adv-sticky { height:fit-content; position:sticky; top:35px; } `:r+=`.container_C_1, .container_C_2, .container_C_3, .container_C_4, .container_C_5, .container_C_6 { min-height:290px!important;overflow:hidden!important; }.container_D_2 { margin-top:0!important; }.pubtech-adv-sticky { display:flex; align-items:center; }`,pe(r),mc){let e=document.querySelector(`.main-container`);(e==null?void 0:e.firstElementChild)!=null&&_e(e.firstElementChild,Oe(`T_1`,!1))}(t=document.querySelector(`article[id^="post-"]`))==null||t.setAttribute(`infinite-loaded`,`1`),(n=document.querySelector(`div.stickySidebar`))==null||n.appendChild(Oe(`D_1`)),window.location.pathname!==`/`&&ke({elementContainer:`.post-content-single`,frequency:3,isInfiniteScroll:!0,logger:e.logger,maxNumberOfElements:6,offset:0,sizeMappingApi:e.sizeMappingApi})}jo({adInventoryConfig:{advLabelText:`advertisement`,stableMinHeight:{excludeAdUnits:[`T_1`]}},compilePlugins:{vip:{getPluginInstance:sc({playerPosition:`left`,refreshLimit:()=>hc?3:6,version:`prod`})},wrapperAd:{getPluginInstance:fc({desktopMinWidth:1025,fallbackToSideRails:!1,setupMobileSkinContainer:bc,skinSizeMapping:yc()})},interstitial:{getPluginInstance:Zo({interstitialCappingMinutes:15,interstitialDelay:10,providersOrderedExecution:[ss({sizeMapping:{mobile:{O_INTERSTITIAL:[[300,250],[336,280],[320,480],[300,600],[160,600],[120,600],[250,250],[200,200],[1,2]]}}}),Uo({sizeMapping:{mobile:{O_INTERSTITIAL_G:[[1,1]]}}})]}),getShouldRun:()=>Promise.resolve(hc)},floorAd:{getPluginInstance:Ho({scaleIframeOnPostInjection:!0,sizeMapping:{mobile:{F_M:[[320,100],[320,75],[320,50],[300,100],[300,50],[375,100],[1,1]]}}}),waitFor:[`vip`,new Promise(e=>{window.addEventListener(`pubtech_video_done`,()=>e(),{once:!0})})]}},execution:{disableAds:vc,virtualNavigationConfig:{provider:wc,titleObserver:!1},waitDomReady:!0},googlePublisherTagProvider:ct({fetchGpt:!0,prefixFullNameAd:`/21832376849,21779056331/ilsoftwareit/ilsoftwareit_`}),hooks:{beforeFlow:Ec,beforeVirtualFlow:Tc},prebidAdapterProvider:pc,sizeMapping:{desktop:{T_1:[[970,250]],C_1:[[300,250],[250,250],[200,200],[468,60],[320,50],[320,100],[300,50],[300,100],`fluid`],C_2:[[300,250],[250,250],[200,200],[468,60],[320,50],[320,100],[300,50],[300,100],`fluid`],C_3:[[300,250],[250,250],[200,200],[468,60],[320,50],[320,100],[300,50],[300,100],`fluid`],C_4:[[300,250],[250,250],[200,200],[468,60],[320,50],[320,100],[300,50],[300,100],`fluid`],C_5:[[300,250],[250,250],[200,200],[468,60],[320,50],[320,100],[300,50],[300,100],`fluid`],C_6:[[300,250],[250,250],[200,200],[468,60],[320,50],[320,100],[300,50],[300,100],`fluid`],D_1:[[300,250],[336,280],[250,250],[200,200]]},tablet:{C_1:[[300,250],[336,280],[250,250],[200,200],[468,60],[320,50],[320,100],[300,50],[300,100]],C_2:[[300,250],[336,280],[250,250],[200,200],[468,60],[320,50],[320,100],[300,50],[300,100]],C_3:[[300,250],[336,280],[250,250],[200,200],[468,60],[320,50],[320,100],[300,50],[300,100]],C_4:[[300,250],[336,280],[250,250],[200,200],[468,60],[320,50],[320,100],[300,50],[300,100]],C_5:[[300,250],[336,280],[250,250],[200,200],[468,60],[320,50],[320,100],[300,50],[300,100]],C_6:[[300,250],[336,280],[250,250],[200,200],[468,60],[320,50],[320,100],[300,50],[300,100]],D_1:[[300,250],[336,280],[250,250],[200,200]]},mobile:{C_1:[[300,600],[300,250],[336,280],[250,250],[200,200],[320,50],[320,100],[300,50],[300,100],[300,300],`fluid`],C_2:[[300,250],[336,280],[250,250],[200,200],[320,50],[320,100],[300,50],[300,100],[300,300]],C_3:[[300,600],[300,250],[336,280],[250,250],[200,200],[320,50],[320,100],[300,50],[300,100],[300,300],`fluid`],C_4:[[300,250],[336,280],[250,250],[200,200],[320,50],[320,100],[300,50],[300,100],[300,300]],C_5:[[300,600],[300,250],[336,280],[250,250],[200,200],[320,50],[320,100],[300,50],[300,100],[300,300],`fluid`],C_6:[[300,250],[336,280],[250,250],[200,200],[320,50],[320,100],[300,50],[300,100],[300,300]]}},trackingOptions:{navigationTrackingOptions:{infiniteScroll:!0}},website:{fullNameAd:`/21832376849,21779056331/ilsoftwareit/ilsoftwareit_`,sellerId:`31`,websiteDomain:`ilsoftware.it`,slug:`ilsoftwareit`,websiteId:309}})})(); //# sourceMappingURL=init.js.map