(function(){var x={},L=function(ab){var Y={};var aa={architecture:"sua_arch",bitness:"sua_bit",platformVersion:"sua_pf_vr",platform:"sua_pf_br",mobile:"sua_mob",brands:"sua_br",fullVersionList:"sua_br",model:"sua_model"};function Z(ac){ac=ac||[];ac.forEach(function(ad){ad.version=ad.version.split?ad.version.split("."):ad.version});return JSON.stringify(ac)}Object.keys(x).forEach(function(ac){switch(ac){case"architecture":case"bitness":case"platform":case"model":Y[aa[ac]]=x[ac];break;case"platformVersion":Y[aa[ac]]=(x[ac]||"").replaceAll(".",",");break;case"mobile":Y[aa[ac]]=x[ac]===true?1:0;break;case"fullVersionList":Y[aa[ac]]=Z(x[ac]);break;case"brands":if(!Y[ac]){Y[aa[ac]]=Z(x[ac])}break}});if(ab===false){return Y}var X=[];Object.keys(Y).forEach(function(ac){X.push(ac+"="+(ac==="sua_pf_vr"?Y[ac]:encodeURIComponent(Y[ac])))});return(X.join("&"))},F=function(){if(window.navigator&&window.navigator.userAgentData){if(window.navigator.userAgentData.brands){x.brands=window.navigator.userAgentData.brands;x.mobile=window.navigator.userAgentData.mobile;x.platform=window.navigator.userAgentData.platform}function X(){if(window.navigator.userAgentData.getHighEntropyValues){var Y=navigator.userAgentData.getHighEntropyValues(["architecture","model","bitness","platformVersion","fullVersionList"]).then(function(Z){x=Z})}}X()}};F();var M=window,d=function(Y){var X={70328:""};return(X.hasOwnProperty(Y))},G=function(Y){var X={70328:""};return(X.hasOwnProperty(Y))},y=function(Y){var X={70328:""};return(X.hasOwnProperty(Y))},A=true,T=function(Y){var X=A?"s://sshowads":"://showads";return"http"+X+".pubmatic.com/AdServer/AdServerServlet?operId=201&rs=2&"},P=function(){var Y="",X=document.domain;if(X&&X!==""){try{Y=(document.URL==decodeURIComponent(document.URL))?document.URL:decodeURIComponent(document.URL)}catch(Z){Y=document.URL}Y=(Y.indexOf("http")===0)?Y:""}return Y.substr(0,512)},O=console.log.bind(console,"PubMatic:"),s=function(X){return typeof X==="function"},m=function(){return"https:"},B=(function(){try{return M.localStorage&&s(M.localStorage.getItem)&&s(M.localStorage.setItem)}catch(X){return false}})(),Q="PubMatic",C="PubMatic_USP",l="PubMatic_GPP",U={YES:"Yes",NO:"No",UNDECIDED:"Undecided"},e=function(X,aa){var Z=M.document.createElement("script");Z.type="text/javascript";Z.src=X;Z.async=true;if(s(aa)){Z.onload=Z.onreadystatechange=aa}var Y=M.document.getElementsByTagName("script")[0];Y&&Y.parentNode&&s(Y.parentNode.appendChild)&&Y.parentNode.appendChild(Z)},a=((M.__cmp||M.__tcfapi)?1:0),R=function(ab,aa){var Y=0,X=ab.length,Z=false;for(;Y((new Date()).getTime()-(24*60*60*1000))){Z.c=X.c;Z.g=X.g}else{}}}}return Z},b=function(Y){var X;if(!B){return}try{X=M.localStorage.getItem(Q)}catch(Z){}if(X&&typeof X==="string"&&X!=="null"){try{X=JSON.parse(X)}catch(Z){X={}}if(X.hasOwnProperty(Y)){delete X[Y];try{M.localStorage.setItem(Q,JSON.stringify(X))}catch(Z){}}}},W=function(){return c},S=function(Z,aa){var X=1;function ag(){var ah={};function ai(){if(ah.usPrivacy){Z(ah)}else{}}return{consentDataCallback:function(aj,ak){if(ak&&aj.uspString){ah.usPrivacy=aj.uspString}ai()}}}var Y=ag();var af={};try{window.__uspapi("getUSPData",X,Y.consentDataCallback)}catch(ae){var ad=window;var ac;while(!ac){try{if(ad.frames.__uspapiLocator){ac=ad}}catch(ae){}if(ad===window.top){break}ad=ad.parent}if(!ac){return aa("USP CMP not found.")}ab("getUSPData",ac,Y.consentDataCallback)}function ab(aj,ai,al){window.__uspapi=function(ao,am,aq){var an=Math.random()+"";var ap={__uspapiCall:{command:ao,version:am,callId:an}};af[an]=aq;ai.postMessage(ap,"*")};window.addEventListener("message",ah,false);window.__uspapi(aj,X,ak);function ah(an){var am=an&&an.data&&an.data.__uspapiReturn;if(am&&am.callId){if(typeof af[am.callId]!=="undefined"){af[am.callId](am.returnValue,am.success);delete af[am.callId]}}}function ak(am,an){window.removeEventListener("message",ah,false);al(am,an)}}},r=function(Y,aa){function Z(ac){var ab=!!(ac&&ac.usPrivacy);if(!ab){return}q(Y,"c",ac.usPrivacy);if(aa){aa("USP")}}function X(){if(aa){aa("USP")}}S(Z,X);setTimeout(function(){X("USP: Failed to retrieve user consent data from CMP, failure callback calling..")},100)},q=function(aa,X,Z){var Y;if(!B){return}try{Y=M.localStorage.getItem(C)}catch(ab){}if(Y&&typeof Y==="string"&&Y!=="null"){try{Y=JSON.parse(Y)}catch(ab){Y={}}}else{Y={}}if(Y){if(!Y.hasOwnProperty(aa)){Y[aa]={}}Y[aa].t=(new Date()).getTime();Y[aa][X]=Z}try{M.localStorage.setItem(C,JSON.stringify(Y))}catch(ab){}},u=function(aa){var Z={c:""};if(!B){return Z}var Y;try{Y=M.localStorage.getItem(C)}catch(ab){}if(Y&&typeof Y==="string"&&Y!=="null"){try{Y=JSON.parse(Y)}catch(ab){Y={}}if(Y.hasOwnProperty(aa)){var X=Y[aa];if(X&&X.c&&X.t){if(X.t&&parseInt(X.t)>((new Date()).getTime()-(24*60*60*1000))){Z.c=X.c}else{}}}}return Z},V=function(){return["sectionChange","signalStatus"]},w=function(X){if(X&&X.signalStatus==="ready"){return true}else{return false}},p=function(X,Y){var ae="__gpp";var ad={};function Z(ah,ai){if(!ai){Y(ah,ai)}else{if(ah&&w(ah.pingData)&&V().includes(ah.eventName)){X(ah.pingData,ai)}}}function af(){window[ae]("addEventListener",Z)}if(window[ae]){if(typeof window[ae]==="function"){af()}else{setTimeout(function(){if(typeof window[ae]==="function"){af()}},500)}}else{if(window!==top){var ab=window;var ag;while(!ag){try{if(ab.frames.__gppLocator){ag=ab}}catch(ac){}if(ab===window.top){break}ab=ab.parent}aa("addEventListener",ag,Z)}else{setTimeout(function(){if(typeof window[ae]==="function"){af()}},500)}}function aa(aj,al,am){window.__gpp=function(aq,at,an,ao){if(!al){ak();return Y({msg:"GPP: CMP not found"},false)}var ap=Math.random()+"";var ar={__gppCall:{command:aq,parameter:an,version:ao,callId:ap}};ad[ap]=at;al.postMessage(ar,"*")};window.addEventListener("message",ai,false);window.__gpp(aj,ah,null,"1.1");function ai(ao){var an={};try{an=(typeof ao.data==="string")?JSON.parse(ao.data):ao.data}catch(aq){}if(an&&an.__gppReturn&&an.__gppReturn.callId){var ap=an.__gppReturn;if(typeof ad[ap.callId]==="function"){ad[ap.callId](ap.returnValue,ap.success);ad[ap.callId]=null}}}function ak(){window.removeEventListener("message",ai,false)}function ah(an,ao){ak();am(an,ao)}}},v=function(ab,af){var Y=76;var X=false;function aa(ag){if(!ag){return ag}return ag.reduceRight(function(ah,ai){return Object.assign(ai,ah)},{})}function Z(ah,ag){return ah.reduce(function(aj,ai){return(aj&&aj[ai]!==undefined)?aj[ai]:undefined},ag)}function ad(ag){if(ag&&ag.VendorConsent&&ag.VendorConsent.length&&ag.VendorConsent.includes(Y)){return true}else{return false}}function ae(ai){if(ai&&ai.gppString){var ah=ai.applicableSections;if(ah&&ah.length&&ah.indexOf(2)!==-1){var ag=aa(Z(["parsedSections","tcfeuv2"],ai));if(ad(ag)){N(ab,"GPP",ai.gppString,ai.applicableSections)}else{f(ab)}}else{N(ab,"GPP",ai.gppString,ai.applicableSections)}}if(af&&!X){X=true;af("GPP")}}function ac(){if(X){return}if(af){X=true;af("GPP")}}p(ae,ac);setTimeout(function(){ac("GPP: Failed to retrieve user consent data from CMP, failure callback calling..")},500)},K=function(X){var Y={consentKey:"c",additionalKey:"g"};if(X==="GPP"){Y.consentKey="gpp";Y.additionalKey="gpp_sid"}return Y},N=function(ac,X,ab,Y){var Z;var aa=K(X);if(!B){return}try{Z=M.localStorage.getItem(l)}catch(ad){}if(Z&&typeof Z==="string"&&Z!=="null"){try{Z=JSON.parse(Z)}catch(ad){Z={}}}else{Z={}}if(Z){if(!Z.hasOwnProperty(ac)){Z[ac]={}}Z[ac].t=(new Date()).getTime();Z[ac][aa.consentKey]=encodeURIComponent(ab);Z[ac][aa.additionalKey]=Y}try{M.localStorage.setItem(l,JSON.stringify(Z))}catch(ad){}},i=function(ac,X){var aa=K(X);var ab={};ab[aa.consentKey]="";if(!B){return ab}var Z;try{Z=M.localStorage.getItem(l)}catch(ad){}if(Z&&typeof Z==="string"&&Z!=="null"){try{Z=JSON.parse(Z)}catch(ad){Z={}}if(Z.hasOwnProperty(ac)){var Y=Z[ac];if(Y&&Y[aa.consentKey]&&Y.t){if(Y.t&&parseInt(Y.t)>((new Date()).getTime()-(24*60*60*1000))){ab[aa.consentKey]=Y[aa.consentKey];if(typeof Y[aa.additionalKey]==="object"&&Y[aa.additionalKey].length){ab[aa.additionalKey]=Y[aa.additionalKey].join(",")}else{ab[aa.additionalKey]=Y[aa.additionalKey]}}else{}}}}return ab},f=function(Y){if(!B){return}var X;try{X=M.localStorage.getItem(l)}catch(Z){}if(X&&typeof X==="string"&&X!=="null"){try{X=JSON.parse(X)}catch(Z){X={}}if(X.hasOwnProperty(Y)){delete X[Y];try{M.localStorage.setItem(l,JSON.stringify(X))}catch(Z){}}}},D=function(ac,ab){var ae,aa,Y,X={};X.av="0",X.ap="-1x-1";try{document.write("");ae=document.getElementById("t_"+ac);if(ae){if(typeof ae.getBoundingClientRect==="function"){aa=ae.getBoundingClientRect();Y=window.innerHeight||document.body.clientHeight;X.av=(aa.top<\/script>')},n=function(){var X=g.LRID,Y;if(X==0){}else{Y=g.AL[X];h.showAd({pubId:Y.pubId,siteId:Y.siteId,adId:Y.adId,width:Y.width,height:Y.height,kadNetwork:g.LNID})}},h=window.PubMatic||(window.PubMatic={}),g=h.Mobile||(h.Mobile={iGAC:false,CCTU:null,CCTF:null,CCTFA:[],PCT:null,PW:null,AL:{},LS:{},CIDs:[],ECPM:0,ACPM:0,LNID:null,OID:null,LRID:0});h.showAd=h.showAd||function(X){var Y=new H(X);if(Y.rid){g.AL[Y.rid]=Y}};window.processPubMaticBid=window.processPubMaticBid||function(X){var Y,aa,ae,ad=g.AL,Z=X.PubMatic_Bid,ac=X.meta_data;if(ac&&Z){if(Z.creative_tag&&Z.tracking_url){Y=ad[ac.rid]||false;if(Y){g.LNID=Z.network_id||null;g.OID=Z.oid||null;Y.CTU=Z.click_tracking_url||null;Y.LPU=Z.landing_page||null;if(Z.campaign_id){g.CIDs.push(Z.campaign_id)}g.ECPM=Z.ecpm||0;g.ACPM=Z.acpm||0;try{document.write(''+Z.creative_tag+"");z(Z.tracking_url)}catch(ab){}aa=document.getElementById(Y.rid);if(Y.CTU&&aa&&typeof document.addEventListener==="function"){ae=function(ai){var ag=this,ah=ad[ag.id],ak,af=ah.CTU;if(ah&&!ah.iCTS&&af){if(y(ah.pubId)&&d(ah.pubId)&&ah.CCTF&&G(ah.pubId)){ai.preventDefault();ai.stopPropagation()}function aj(){if(!ah.iCTS){var al=document.createElement("script");al.setAttribute("src",A?af.replace("http://","https://"):af);al.setAttribute("type","text/javascript");function am(){if(d(ah.pubId)&&ah.CCTF){if(typeof ah.CCTF=="function"){try{if(G(ah.pubId)){ah.CCTFA.unshift(ah.LPU?ah.LPU:"")}ah.CCTF.apply(window,ah.CCTFA)}catch(an){}}}}al.addEventListener("load",am,true);al.addEventListener("error",am,true);ag.appendChild(al);ah.iCTS=true}}if(ah.CCTU){ak=document.createElement("script");ak.setAttribute("src",A?ah.CCTU.replace("http://","https://"):ah.CCTU);ak.setAttribute("type","text/javascript");ak.addEventListener("load",aj,true);ak.addEventListener("error",aj,true);document.body.appendChild(ak)}else{aj()}}};if(Y.kadNetwork&&g.PCT&&g.PW){g.PW.removeEventListener("click",g.PCT,true)}aa.addEventListener("click",ae,true);g.PCT=ae;g.PW=aa}}}}};h.AHT=window.PubMatic_AHT||0;if(h.AHT==2){h.AHT=window.PubMatic_AHT=0;n()}})();