@schibsted/advertory 2.71.17 → 2.72.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (125) hide show
  1. package/core/aftenposten/es/index.css +1 -1
  2. package/core/aftenposten/es/index.d.ts +3 -1
  3. package/core/aftenposten/es/index.js +1 -1
  4. package/core/aftenposten/index.d.ts +3 -1
  5. package/core/aftenposten/index.js +1 -1
  6. package/core/aftenpostenv2/es/index.css +1 -1
  7. package/core/aftenpostenv2/es/index.d.ts +3 -1
  8. package/core/aftenpostenv2/es/index.js +1 -1
  9. package/core/aftonbladet/es/index.css +1 -1
  10. package/core/aftonbladet/es/index.d.ts +3 -1
  11. package/core/aftonbladet/es/index.js +1 -1
  12. package/core/aftonbladet/index.d.ts +3 -1
  13. package/core/aftonbladet/index.js +1 -1
  14. package/core/aftonbladetv2/es/index.css +1 -1
  15. package/core/aftonbladetv2/es/index.d.ts +3 -1
  16. package/core/aftonbladetv2/es/index.js +1 -1
  17. package/core/bt/es/index.css +1 -1
  18. package/core/bt/es/index.d.ts +3 -1
  19. package/core/bt/es/index.js +1 -1
  20. package/core/bt/index.d.ts +3 -1
  21. package/core/bt/index.js +1 -1
  22. package/core/btv2/es/index.css +1 -1
  23. package/core/btv2/es/index.d.ts +3 -1
  24. package/core/btv2/es/index.js +1 -1
  25. package/core/e24/es/index.css +1 -1
  26. package/core/e24/es/index.d.ts +3 -1
  27. package/core/e24/es/index.js +1 -1
  28. package/core/e24/index.d.ts +3 -1
  29. package/core/e24/index.js +1 -1
  30. package/core/fotbollskanalen/es/index.css +1 -1
  31. package/core/fotbollskanalen/es/index.d.ts +3 -1
  32. package/core/fotbollskanalen/es/index.js +1 -1
  33. package/core/fotbollskanalen/index.d.ts +3 -1
  34. package/core/fotbollskanalen/index.js +1 -1
  35. package/core/godare/index.d.ts +3 -1
  36. package/core/godare/index.js +1 -1
  37. package/core/godt/index.d.ts +3 -1
  38. package/core/godt/index.js +1 -1
  39. package/core/klart/index.d.ts +3 -1
  40. package/core/klart/index.js +1 -1
  41. package/core/koket/es/index.css +1 -1
  42. package/core/koket/es/index.d.ts +3 -1
  43. package/core/koket/es/index.js +1 -1
  44. package/core/koket/index.d.ts +3 -1
  45. package/core/koket/index.js +1 -1
  46. package/core/kompakt/index.d.ts +3 -1
  47. package/core/kompakt/index.js +1 -1
  48. package/core/minmote/index.d.ts +3 -1
  49. package/core/minmote/index.js +1 -1
  50. package/core/pent/index.d.ts +3 -1
  51. package/core/pent/index.js +1 -1
  52. package/core/sa/es/index.css +1 -1
  53. package/core/sa/es/index.d.ts +3 -1
  54. package/core/sa/es/index.js +1 -1
  55. package/core/sa/index.d.ts +3 -1
  56. package/core/sa/index.js +1 -1
  57. package/core/sav2/es/index.css +1 -1
  58. package/core/sav2/es/index.d.ts +3 -1
  59. package/core/sav2/es/index.js +1 -1
  60. package/core/svd/es/index.css +1 -1
  61. package/core/svd/es/index.d.ts +3 -1
  62. package/core/svd/es/index.js +1 -1
  63. package/core/svd/index.d.ts +3 -1
  64. package/core/svd/index.js +1 -1
  65. package/core/svdv2/es/index.css +1 -1
  66. package/core/svdv2/es/index.d.ts +3 -1
  67. package/core/svdv2/es/index.js +1 -1
  68. package/core/tek/index.d.ts +3 -1
  69. package/core/tek/index.js +1 -1
  70. package/core/tv4/es/index.d.ts +3 -1
  71. package/core/tv4/es/index.js +1 -1
  72. package/core/tv4/index.d.ts +3 -1
  73. package/core/tv4/index.js +1 -1
  74. package/core/tvnu/index.d.ts +3 -1
  75. package/core/tvnu/index.js +1 -1
  76. package/core/vg/es/index.css +1 -1
  77. package/core/vg/es/index.d.ts +3 -1
  78. package/core/vg/es/index.js +1 -1
  79. package/core/vg/index.d.ts +3 -1
  80. package/core/vg/index.js +1 -1
  81. package/core/vgv2/es/index.css +1 -1
  82. package/core/vgv2/es/index.d.ts +3 -1
  83. package/core/vgv2/es/index.js +1 -1
  84. package/features/ad-native/index.d.ts +2 -0
  85. package/features/ad-native/index.js +1 -1
  86. package/features/dr-edition/es/index.d.ts +2 -0
  87. package/features/dr-edition/index.d.ts +2 -0
  88. package/features/kilkaya/es/index.d.ts +2 -0
  89. package/features/kilkaya/index.d.ts +2 -0
  90. package/features/tracker/index.d.ts +4 -1
  91. package/features/tracker/index.js +1 -1
  92. package/package.json +1 -1
  93. package/sites/aftenposten/es/index.css +1 -1
  94. package/sites/aftenpostenv2/es/index.css +1 -1
  95. package/sites/aftonbladet/es/index.css +1 -1
  96. package/sites/aftonbladetv2/es/index.css +1 -1
  97. package/sites/bt/es/index.css +1 -1
  98. package/sites/btv2/es/index.css +1 -1
  99. package/sites/e24/es/index.css +1 -1
  100. package/sites/fotbollskanalen/es/index.css +1 -1
  101. package/sites/koket/es/index.css +1 -1
  102. package/sites/sa/es/index.css +1 -1
  103. package/sites/sav2/es/index.css +1 -1
  104. package/sites/svd/es/index.css +1 -1
  105. package/sites/svdv2/es/index.css +1 -1
  106. package/sites/vg/es/index.css +1 -1
  107. package/sites/vgv2/es/index.css +1 -1
  108. package/types/core/interface/ast.d.ts +1 -1
  109. package/types/core/interface/config.d.ts +2 -0
  110. package/types/features/ad-native/trackers/trackers.d.ts +1 -1
  111. package/types/features/ad-server-side/banner-object.d.ts +4 -0
  112. package/types/features/ad-server-side/banner-object.test.d.ts +1 -0
  113. package/types/features/ad-server-side/cogwheel.d.ts +3 -0
  114. package/types/features/ad-server-side/constants.d.ts +2 -0
  115. package/types/features/ad-server-side/index.d.ts +5 -0
  116. package/types/features/ad-server-side/keywords.d.ts +3 -0
  117. package/types/features/ad-server-side/keywords.test.d.ts +1 -0
  118. package/types/features/ad-server-side/native-request.d.ts +42 -0
  119. package/types/features/ad-server-side/native-request.test.d.ts +1 -0
  120. package/types/features/ad-server-side/server-side-xandr-renderer.d.ts +3 -0
  121. package/types/features/ad-server-side/server-side-xandr-service.d.ts +7 -0
  122. package/types/features/cogwheel/index.d.ts +1 -1
  123. package/types/features/interface/ad-native.d.ts +1 -0
  124. package/types/features/interface/ad-server-side.d.ts +48 -0
  125. package/types/features/tracker/index.d.ts +3 -2
@@ -1 +1 @@
1
- "use strict";function e(e,t,n,o){return new(n||(n=Promise))(function(i,a){function r(e){try{s(o.next(e))}catch(e){a(e)}}function d(e){try{s(o.throw(e))}catch(e){a(e)}}function s(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(r,d)}s((o=o.apply(e,t||[])).next())})}function t(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var n,o;require("react/jsx-runtime"),"function"==typeof SuppressedError&&SuppressedError;var i=t(function(){if(o)return n;o=1;var e=function(e){return function(e){return!!e&&"object"==typeof e}(e)&&!function(e){var n=Object.prototype.toString.call(e);return"[object RegExp]"===n||"[object Date]"===n||function(e){return e.$$typeof===t}(e)}(e)},t="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function i(e,t){return!1!==t.clone&&t.isMergeableObject(e)?l((n=e,Array.isArray(n)?[]:{}),e,t):e;var n}function a(e,t,n){return e.concat(t).map(function(e){return i(e,n)})}function r(e){return Object.keys(e).concat(function(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[]}(e))}function d(e,t){try{return t in e}catch(e){return!1}}function s(e,t,n){var o={};return n.isMergeableObject(e)&&r(e).forEach(function(t){o[t]=i(e[t],n)}),r(t).forEach(function(a){(function(e,t){return d(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))})(e,a)||(d(e,a)&&n.isMergeableObject(t[a])?o[a]=function(e,t){if(!t.customMerge)return l;var n=t.customMerge(e);return"function"==typeof n?n:l}(a,n)(e[a],t[a],n):o[a]=i(t[a],n))}),o}function l(t,n,o){(o=o||{}).arrayMerge=o.arrayMerge||a,o.isMergeableObject=o.isMergeableObject||e,o.cloneUnlessOtherwiseSpecified=i;var r=Array.isArray(n);return r===Array.isArray(t)?r?o.arrayMerge(t,n,o):s(t,n,o):i(n,o)}return l.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(e,n){return l(e,n,t)},{})},n=l}());const a=["deviceType","pageType","placements","takeover","refreshConfig","editableConfiguration"],r={adRequested:()=>{},adAvailable:e=>{},adLoaded:e=>{},adNoBid:e=>{},adError:(e,t)=>{},adCollapse:()=>{},adRequestFailure:e=>{},adBadRequest:e=>{},adLoadedMediated:e=>{},adNoBidMediated:e=>{}},d=6;class s{set(e){this.config=e}modifyConfigProperties(e){if(!this.config)throw new Error("Config was accessed before it had been initialized.");const t={};for(const n of a){const o=e[n];void 0!==o&&(t[n]=o)}Object.assign(this.config,t),Object.prototype.hasOwnProperty.call(e,"pageOptions")&&void 0!==e.pageOptions&&(this.config.pageOptions=Object.assign(Object.assign({},this.config.pageOptions),e.pageOptions)),Object.prototype.hasOwnProperty.call(e,"tcf")&&void 0!==e.tcf&&(this.config.tcf=Object.assign(Object.assign({},this.config.tcf),e.tcf))}get(){if(!this.config)throw new Error("Config was accessed before it had been initialized.");return this.config}getHandlers(){if(!this.siteHandlers)throw new Error("Handlers were accessed before it had been initialized.");return this.siteHandlers}setHandlers(e){this.siteHandlers=i(s.DEFAULT_SITE_HANDLERS,e)}}s.DEFAULT_SITE_HANDLERS={siteEvents:r,initNativeAd:function(){}};const l=new s,c=l.modifyConfigProperties.bind(l),p=(e,t)=>{const n="[Advertory LOG]: ";location.search.includes("ast_debug=true")&&(t?console.log(n,e,t):console.log(n,e))},u=864e5,v=(()=>{const e=e=>{const t=window.localStorage.getItem(e);if(!t)return null;try{return JSON.parse(t)}catch(e){return p("Error with parsing localStorage data"),null}},t=(e,t)=>{window.localStorage.setItem(e,JSON.stringify(t))};return{get:e,set:t,setWithTimestamp:(e,n,o=u)=>{const i={data:n,expirationTime:(new Date).getTime()+o};t(e,JSON.stringify(i))},getByTimestamp:(t,n=u)=>{const o=e(t);if(!o)return null;if(!n)return o;try{const{expirationTime:e,data:t}=JSON.parse(o);return(new Date).getTime()<=e?t:null}catch(e){return p("Error with parsing localStorage data"),null}}}})(),g="glimrTags",h=["glwe_","glwet_"],m={geofenceTags:[],geoTags:[],weatherTags:[]},f=e=>new URLSearchParams(window.location.search).get(e),y="takeover",b="native_override_desc2",w=e=>new Promise(t=>{if(!window._tcf_||!(null==e?void 0:e.enabled))return void t(!1);const n=(()=>{if(!window._tcf_)return null;const e=window._tcf_.getPermissionSync("CMP:advertising");if(null===e)return null;const t=Number(e);return p("Advertising permission value obtained synchronously: ",e),Boolean(t)})();if(null!==n)return void t(n);let o=!1;const i=e=>{o||(p("Resolving advertising permission value obtained"),o=!0,t(e))},a=setTimeout(()=>{p("Advertising permission timed out, resolving with false"),i(!1)},3e3);window._tcf_.onTcfReady(()=>{p("On Tcf Ready called, waiting for permission"),clearTimeout(a)}),window._tcf_.getPermission("CMP:advertising",e=>{clearTimeout(a);const t=Number(e);p("Advertising permission value obtained asynchronously: ",e),i(Boolean(t))})}),x={NO:"no",SE:"se"},E="cmp:loaded";let k="undefined"!=typeof window?window._tcf_:void 0,T=!1;const I=(t,n,o)=>{const i=!!(null==t?void 0:t.enabled),a=(null==t?void 0:t.timeout)||3e3,r=f("bypass_tcf"),d=()=>{if(!(null==t?void 0:t.enabled))return!0;if(((e,t)=>e?!!t&&(p("TCF bypass param detected, returning consent: true"),!0):(p("TCF is not enabled, returning consent: true"),!0))(i,r))return!0;if(T)return null;if(!k)throw new Error("[Advertory]: getConsentSync method was called before the tcfManager was available.");const e=k.getConsentedToAllSync();return p(`TCF consented to all is: ${e}`),k.getConsentedToAllSync()};return{initConsentManager:()=>(null==t?void 0:t.enabled)?new Promise((e,t)=>{if(p("Getting TCF consent manager..."),window._tcf_)return p("TCF consent manager is already available"),k=window._tcf_,void e(k);p("TCF consent manager is not available");const n=()=>{p("CMP loaded, resolving consent manager..."),o&&clearTimeout(o),window._tcf_?(k=window._tcf_,e(k)):t(new Error("CMP loaded but window._tcf_ is not defined"))},o=setTimeout(()=>{document.removeEventListener(E,n),T=!0,t(new Error("Timeout waiting for CMP to load"))},a);p("Listening for CMP loaded event..."),document.addEventListener(E,n,{once:!0})}):Promise.resolve(null),getConsentSync:d,getConsentAsync:()=>e(void 0,void 0,void 0,function*(){if(null==t?void 0:t.schibstedAdChoicesOverrideValue)return p(`Schibsted Ad Choices override value is set, returning override value: ${t.schibstedAdChoicesOverrideValue}`),Boolean(Number(t.schibstedAdChoicesOverrideValue));const e=(null==t?void 0:t.schibstedAdChoicesEnabled)&&o===x.SE,n=(null==t?void 0:t.schibstedAdChoicesEnabled)&&o===x.NO;if(e||n)return p("Schibsted Ad Choices is enabled, getting advertising permissions..."),yield w(t);if(!(null==t?void 0:t.enabled))return!0;const i=d();return null!==i?i:yield new Promise((e,t)=>{try{if(!k)throw new Error("[Advertory]: getConsentAsync method was called before the tcfManager was available.");let t=!1;const n=n=>{t||(t=!0,e(n))},o=setTimeout(()=>{p("TCF isConsentedToAll timed out, resolving with false"),n(!1)},a);k.onTcfReady(()=>{p("On Tcf Ready called, waiting for consent"),clearTimeout(o)}),k.isConsentedToAll(t=>{clearTimeout(o),e(t)})}catch(e){t(e)}})})}},A=(t,n,o,...i)=>e(void 0,[t,n,o,...i],void 0,function*(e,t,n,o="NOT SPECIFIED FEATURE"){if(!(null==e?void 0:e.schibstedConsentToPayEnabled))return p(`Schibsted Consent to Pay is not enabled, returning true for ${o}`),!0;if(null==e?void 0:e.schibstedAdChoicesOverrideValue)return p(`Schibsted Ad Choices override value is set, returning override value: ${null==e?void 0:e.schibstedAdChoicesOverrideValue} for ${o}`),Boolean(Number(null==e?void 0:e.schibstedAdChoicesOverrideValue));const{getConsentAsync:i}=I(e,0,n);return(yield i())?(p(`Schibsted Ad Choices consent given according to TCF consent manager for ${o}`),!0):(p(`Schibsted Ad Choices consent not given according to TCF consent manager for ${o}`),!1)}),S=(...t)=>e(void 0,[...t],void 0,function*(e=l.get()){const{tcf:t,isMobileApp:n,country:o}=e;if(null==t?void 0:t.schibstedConsentToPayEnabled){return yield A(t,n,o,"glimr")}const{getConsentAsync:i}=I(t,0,o);return yield i()}),C=()=>e(void 0,void 0,void 0,function*(){const{glimr:t}=l.get();if(!(yield S())||!(null==t?void 0:t.enabled))return void p("No consent for glimr data fetching.");const n=yield(o=500,e(void 0,void 0,void 0,function*(){return yield Promise.race([e(void 0,void 0,void 0,function*(){const e=yield import("glimr-sdk");return e.default||e}),new Promise(e=>setTimeout(()=>e(!1),o))])}));var o;if(n)try{n.setTagCacheTimeInSeconds(300),yield new Promise(e=>{n.getTags(t.clientId,(t,n)=>{v.setWithTimestamp(g,{tags:t,tagMappings:n}),e(!0)})})}catch(e){p(`Error during getting glimr data: ${e}`)}else p("Timeout (500ms) while loading glimr package. Skipping glimr data fetching.",{glimr:n})}),P={svd:"svd",vg:"vg",godare:"godare",aftenposten:"no-aftenposten",sa:"no-stavangeraftenblad",bt:"no-bergenstidende",aftonbladet:"aftonbladet",e24:"e24",minmote:"minmote",pent:"pent",godt:"godt",tek:"no-tek"},O=e=>h.some(t=>e.startsWith(t)),L=e=>e.startsWith("glgc_"),j=e=>!O(e)&&!L(e),$=e=>e===x.NO?"no-sno":"se-generic",N=()=>{const{country:e,publisher:t}=l.get();return`${e}-${t}`},_=(e,t)=>{const n=q();if(!n)return m;const o=((e=[])=>e.filter(O))(n),i=((e=[])=>e.filter(L))(n),a=((e=[],t,n)=>{const o=e.filter(j);if(n&&t){const{publisher:e}=t,n=P[e]||e;o.push(n)}return o})(n,e,t);return{geoTags:a,geofenceTags:i,weatherTags:o}},q=()=>{const e=v.getByTimestamp(g);return e&&"string"!=typeof e?null==e?void 0:e.tags:null},z={get:(t,n)=>e(void 0,void 0,void 0,function*(){const e=yield fetch(t,n);if(!e.ok)throw new Error(e.statusText);return yield e.json()}),post:(t,n,o)=>e(void 0,void 0,void 0,function*(){const e=JSON.stringify(o),i=yield fetch(t,{method:"POST",headers:n,body:e});if(!i.ok)throw new Error(i.statusText);return yield i.json()})},D="advertory:ppids-cache",M={[x.SE]:`SCH${x.SE.toUpperCase()}-EnvHash`,[x.NO]:`SCH${x.NO.toUpperCase()}-EnvHash`},B={[x.SE]:`SCH${x.SE.toUpperCase()}-UserHash`,[x.NO]:`SCH${x.NO.toUpperCase()}-UserHash`},R={[x.SE]:`sch${x.SE}-envhash-v3`,[x.NO]:`sch${x.NO}-envhash-v3`},F={[x.SE]:`sch${x.SE}-userhash-v3`,[x.NO]:`sch${x.NO}-userhash-v3`},V={[x.SE]:`'sch${x.SE}-iosid-v3'`,[x.NO]:`'sch${x.NO}-iosid-v3'`},U={[x.SE]:`sch${x.SE}-androidid-v3`,[x.NO]:`sch${x.NO}-androidid-v3`},H={[x.SE]:"sdrn:schibsted.com:user",[x.NO]:"sdrn:spid.no:user"};class W{constructor(){this.eids=[]}add(e,t){return e&&this.eids.push({id:e,source:t}),this}buildRyEids(){return this.eids.map(({id:e,source:t})=>({source:t,uids:[{id:e,atype:1,ext:{stype:"ppuid"}}]}))}buildEids(){return[...this.eids]}buildVideoEids(){return this.eids.map(({id:e,source:t})=>`${t},${e}`).join("|")}buildNorstatPath(){const e=this.eids[0];return e?`${e.source}-${e.id}`:""}buildNorstatQuery(e){const t=new URLSearchParams;return this.eids.slice(1).forEach(({id:n,source:o})=>{t.append(e,`${o}-${n}`)}),t}}const K=new class{constructor(){this.ppid1=null,this.ppid2=null}processPPIDs(t){return e(this,arguments,void 0,function*(e,t=1e4){var n,o;const i=yield Promise.race([new Promise(e=>{setTimeout(()=>e({xandr:{ppId1:"",ppId2:""}}),t)}),e.instance.getAdvertisingIdentifiers()]);this.setPPIDs(null===(n=i.xandr)||void 0===n?void 0:n.ppId1,null===(o=i.xandr)||void 0===o?void 0:o.ppId2)})}getPPIDs(){var e,t;return null!==this.ppid1&&null!==this.ppid2||p("PPIDv2s accessed before they have been initialized"),{ppid1:null!==(e=this.ppid1)&&void 0!==e?e:"",ppid2:null!==(t=this.ppid2)&&void 0!==t?t:""}}setPPIDs(e,t){this.ppid1=null!=e?e:"",this.ppid2=null!=t?t:""}},G=new class{constructor(){this.ppid1=null,this.ppid2=null,this.idfv=null,this.anId=null}processPPIDs(t,n){return e(this,void 0,void 0,function*(){var e,o,i,a,r,d,s,l,c,p,u;const g=v.get(D),h=yield this.getNewPPIDs(t,n);if(this.shouldHash(g,h)){const n=null!==(e=t.hasherUrl)&&void 0!==e?e:"https://hasher.schibsted.com/api/v1/hash",l=this.createHasherPayload(h),c=yield this.hashPPIDs(l,n);return c?(this.cachePPIDs(l,c,null===(o=h.idfv)||void 0===o?void 0:o.plain,null===(i=h.anId)||void 0===i?void 0:i.plain),void this.setPPIDs(null!==(a=c.userId)&&void 0!==a?a:"",null!==(r=c.environmentId)&&void 0!==r?r:"",null===(d=h.idfv)||void 0===d?void 0:d.plain,null===(s=h.anId)||void 0===s?void 0:s.plain)):void this.setPPIDs("","")}this.setPPIDs(null!==(l=null==g?void 0:g.userId.hashed)&&void 0!==l?l:"",null!==(c=null==g?void 0:g.environmentId.hashed)&&void 0!==c?c:"",null===(p=null==h?void 0:h.idfv)||void 0===p?void 0:p.plain,null===(u=null==h?void 0:h.anId)||void 0===u?void 0:u.plain)})}getPPIDs(){var e,t;return null!==this.ppid1&&null!==this.ppid2||p("PPIDv3s accessed before they have been initialized"),{ppid1:null!==(e=this.ppid1)&&void 0!==e?e:"",ppid2:null!==(t=this.ppid2)&&void 0!==t?t:"",idfv:this.idfv,anId:this.anId}}setPPIDs(e,t,n,o){this.ppid1=null!=e?e:"",this.ppid2=null!=t?t:"",this.idfv=null!=n?n:null,this.anId=null!=o?o:null}shouldHash(e,t){var n,o;if(!e)return!0;for(const i in e){if((null===(n=e[i])||void 0===n?void 0:n.plain)!==(null===(o=t[i])||void 0===o?void 0:o.plain))return!0}return!1}cachePPIDs(e,t,n,o){const i=Object.assign(Object.assign({clientId:{plain:e.clientId},userId:{plain:e.userId,hashed:t.userId},environmentId:{plain:e.environmentId,hashed:t.environmentId},trackerType:{plain:e.trackerType},trackerVersion:{plain:e.trackerVersion}},n?{idfv:{plain:n}}:{}),o?{anId:{plain:o}}:{});v.set(D,i)}hashPPIDs(t,n){return e(this,void 0,void 0,function*(){try{const e=new Headers({"Content-Type":"application/json"});return yield z.post(n,e,t)}catch(e){return p("Error with hashing PPIDs",e),null}})}getNewPPIDs(t,n){return e(this,arguments,void 0,function*({clientId:t,instance:n},o){const i=yield((t,n)=>e(void 0,void 0,void 0,function*(){const e=yield t.getUserId();return e?`${H[n]}:${e}`:null}))(n,o),a=yield(t=>e(void 0,void 0,void 0,function*(){const e=yield t.getEnvironmentId();return e?`sdrn:schibsted:environment:${e}`:null}))(n),r=window.advertory_idfv,d=window.advertory_anId;return Object.assign(Object.assign({clientId:{plain:t},userId:{plain:i},environmentId:{plain:a},trackerType:{plain:"Advertory"},trackerVersion:{plain:"1.0.0"}},r?{idfv:{plain:r}}:{}),d?{anId:{plain:d}}:{})})}createHasherPayload({clientId:e,trackerType:t,trackerVersion:n,userId:o,environmentId:i}){return{clientId:e.plain,trackerType:t.plain,trackerVersion:n.plain,userId:o.plain,environmentId:i.plain}}},J=t=>e(void 0,void 0,void 0,function*(){const{tracker:e,tcf:n,country:o,isMobileApp:i}=t;if(!(yield A(n,i,o,"setXandrPPIDs")))return;if(!e)return;(yield Promise.allSettled([K.processPPIDs(e,null==n?void 0:n.timeout),G.processPPIDs(e,o)])).forEach((e,t)=>{if("rejected"===e.status){p(`Cannot fetch PPIDs v${t+2}`,e.reason)}})}),Y=e=>{const{ppid1:t,ppid2:n}=K.getPPIDs(),{ppid1:o,ppid2:i,idfv:a,anId:r}=G.getPPIDs();return{userIds:[{type:"extendedIDs",eids:(new W).add(n,M[e]).add(t,B[e]).add(i,R[e]).add(o,F[e]).add(a,V[e]).add(r,U[e]).buildEids()}]}},Q=e=>{const{ppid1:t,ppid2:n}=K.getPPIDs(),{ppid1:o,ppid2:i,idfv:a,anId:r}=G.getPPIDs();if(!n)return{};return{userSync:{userIds:[{name:"pubProvidedId",params:{eids:(new W).add(n,M[e]).add(t,B[e]).add(i,R[e]).add(o,F[e]).add(a,V[e]).add(r,U[e]).buildRyEids()}}]}}},X=e=>{const t=encodeURIComponent(e).replace(/[-.+*]/g,"\\$&"),n=new RegExp(`(?:(?:^|.*;)\\s*${t}\\s*\\=\\s*([^;]*).*$)|^.*$`);return decodeURIComponent(document.cookie.replace(n,"$1"))||null},Z={MOBILE:"mobile",TABLET:"tablet",DESKTOP:"desktop"},ee=9826;class te{constructor(){this.getSupplyTypeKeywords=()=>{const{deviceType:e=Z.DESKTOP,isMobileApp:t}=l.get();if(t){return{"aa-sch-supply_type":`app_${e===Z.MOBILE?"phone":Z.TABLET}`}}return{"aa-sch-supply_type":`web_${this.getPageOptionsFormatDevice(e)}`}}}prepare(t){return e(this,void 0,void 0,function*(){return Object.assign(Object.assign({},t),{keywords:Object.assign(Object.assign(Object.assign(Object.assign({},t.keywords),this.getSupplyTypeKeywords()),yield this.getFormattedExternalIdKeywords()),this.getHasContextKeywords(t.keywords)),user:{externalUid:yield this.getExternalUid(),dnt:yield this.isTrackingForbidden()}})})}getFormattedExternalIdKeywords(){return e(this,void 0,void 0,function*(){const e=yield this.getExternalUid(),t=this.getUserId();return{"aa-sch-externalid_src":Number(!!e)+Number(!!t)}})}getUserId(){return(()=>{const e=X("_pulse2data");return e?e.split(",")[2]:void 0})()}getExternalUid(){return e(this,void 0,void 0,function*(){return yield(t=>e(void 0,void 0,void 0,function*(){const{tcf:e,isMobileApp:n,country:o}=t,{getConsentAsync:i}=I(e,0,o);if(!(yield i()))return;const a=X("_pulse2data");return a?a.split(",")[9]:void 0}))(l.get())})}isTrackingForbidden(){return e(this,void 0,void 0,function*(){return(null===navigator||void 0===navigator?void 0:navigator.globalPrivacyControl)||"1"===(null===navigator||void 0===navigator?void 0:navigator.doNotTrack)||"DO_NOT_TRACK"===(yield this.getExternalUid())})}getMember(){const{pageOptions:{member:e},testMember:t=ee}=l.get();return"true"===f("inventory_test")?t:e}getCMPValue(e){return localStorage.getItem(`CMP:${e}`)?"0"===localStorage.getItem(`CMP:${e}`)?"0":"1":"0"}getPublisherKeywords(){const{publisher:e}=l.get();return{"aa-sch-publisher":`${e}`}}getAnalyticsConsentKeywords(){return{"aa-sch-cmp_analytics":this.getCMPValue("analytics")}}getAdvertisingConsentKeywords(){return e(this,void 0,void 0,function*(){const{tcf:e,isMobileApp:t,country:n}=l.get(),{getConsentAsync:o}=I(e,0,n);return{"aa-sch-cmp_advertising":(yield o())?"1":"0"}})}getPageTypeKeywords(){const{pageType:e}=l.get();return{"aa-sch-page_type":e}}getCountryCodeKeywords(e){return{"aa-sch-country_code":e}}getInventoryTypeKeywords(){return{"aa-sch-inventory_type":"editorial"}}getHasContextKeywords(e){const t=e["aa-sch-context_keyword"];return{"aa-sch-has_context_keyword":Array.isArray(t)&&t.length?1:0}}getPageOptionsFormatDevice(e="desktop"){return"mobile"===e?"phone":e}getSponsorsKeywords(){var e;const{publisher:t,keywordsConfig:n}=l.get(),o=null===(e=null==n?void 0:n.sponsors)||void 0===e?void 0:e.split(":").map(e=>`${t}_${e}`);return o?{"no-sno-news-sponsors":o}:{}}}const ne=new te;ne.prepare.bind(ne);const oe=new class extends te{prepare(t){return e(this,void 0,void 0,function*(){const n=Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},this.getCountryCodeKeywords(x.NO)),this.getPublisherKeywords()),this.getPageTypeKeywords()),yield this.getFormattedExternalIdKeywords()),this.getSupplyTypeKeywords()),yield this.getAdvertisingConsentKeywords()),yield(o=l.get(),e(void 0,void 0,void 0,function*(){const{addPublisherToGeo:e}={},{glimr:t,country:n}=o,i=yield S(o);if(!(null==t?void 0:t.enabled)||!i)return p("No consent for getting glimr tags."),{};const a=$(n),r=_(o,Boolean(e));return{[`${a}-geo`]:r.geoTags,[`${a}-weather`]:r.weatherTags,[`${a}-geofence`]:r.geofenceTags}}))),(()=>{const{ppid1:e,ppid2:t}=K.getPPIDs();return{"aa-sch-schuserhash":e?"1":"0","aa-sch-schenvhash":t?"1":"0"}})()),t.keywords);var o;return Object.assign(Object.assign({},t),{keywords:n,user:Object.assign(Object.assign({},Y(x.NO)),{externalUid:yield this.getExternalUid()}),member:this.getMember()})})}};var ie=oe.prepare.bind(oe);let ae="";const re=new Map,de=e=>{const t=e.split("-"),n=t[t.length-1];return 6===n.length&&n.match(/^[a-zA-Z0-9]+$/)?t.slice(0,-1).join("-"):e},se="0123456789abcdefghijklmnopqrstuvwxyz",le=()=>Promise.resolve(),ce=e=>{window.apntag.anq.push(e)},pe=new Promise(e=>{"undefined"!=typeof document&&document.prerendering?document.addEventListener("prerenderingchange",()=>e()):e()}),ue=new Promise(e=>{if("undefined"==typeof document||!document.hidden)return void e();const t=()=>{document.hidden||(document.removeEventListener("visibilitychange",t),e())};document.addEventListener("visibilitychange",t,{once:!0})}),ve="advertory-wallpaper-background",ge="advertory-with-horseshoe",he=()=>{const e=document.querySelector(`.${ve}`);e&&e.remove()},me=e=>{const t=e.getBoundingClientRect().top;requestAnimationFrame(()=>(e=>{if(!document.body)return;const t=document.querySelector(`.${ve}`);t&&t.style.setProperty("top",`${e}px`)})(t+15))},fe=/^wallpaper:url:(http[s]?:\/\/)?[^\s(["<,>]*\.[^\s[",><]*/,ye=()=>null!==f("disable_prebid"),be=e=>{if("0"===f("collapse_ad"))return;const t=document.querySelector(`div[id^="${e}"]`);if(!t)return;const n=t.parentElement;n&&(t.style.setProperty("width","0","important"),t.style.setProperty("height","0","important"),t.style.setProperty("display","none","important"),n.style.setProperty("display","none","important"),e.includes("wallpaper")&&he())},we=e=>{const t=document.querySelector(`div[id^="${e}"]`);if(!t)return;const n=t.parentElement;n&&(t.style.removeProperty("width"),t.style.removeProperty("height"),t.style.removeProperty("display"),n.style.removeProperty("display"))};class xe{initialize(){this.DATA=Object.assign({},xe.INITIAL_DATA)}getData(e){if(!this.DATA)throw new Error("Storage was accessed with invalid data.");return this.DATA[e]}setData(e,t){if(!this.DATA)throw new Error("Storage was accessed before it had been initialized.");this.DATA[e]=Object.assign(Object.assign({},this.DATA[e]),t)}}xe.INITIAL_DATA={wallpaper:{isAvailable:!1},horseshoe:{isAvailable:!1},initialClassNames:{},alertoryConfigKeywords:{}};const Ee=new xe,ke=e=>{var t;const n=null===(t=document.querySelector(`#${e}`))||void 0===t?void 0:t.parentElement,o=(null==n?void 0:n.offsetHeight)||0;n&&(n.style.minHeight=`${o}px`)},Te=e=>{const t=e.parentElement;if(!e||!t)return;const{container:n,wrapper:o}=(e=>{const t=Ee.getData("initialClassNames")[e.id];return{wrapper:(null==t?void 0:t.wrapper)?t.wrapper.join(" "):"",container:(null==t?void 0:t.container)?t.container.join(" "):""}})(e);e.className=n,t.className=o},Ie=()=>{he();document.querySelectorAll('[data-advertory-ad-rendered="true"]').forEach(e=>{be(e.id),Te(e),(e=>{const t=document.querySelector(`#${e}`),n=null==t?void 0:t.getAttribute("data-probable-height"),o=null==t?void 0:t.getAttribute("data-probable-width");n&&o&&(null==t||t.style.setProperty("min-height",n+"px"),null==t||t.style.setProperty("min-probable-width",o+"px"))})(e.id),e.innerHTML="",e.id=de(e.id)}),ce(()=>window.apntag.clearRequest())},Ae="noGroupedPlacements",Se=e=>{const t=e.replace(/[0-9]/g,"");return"_"===t.slice(-1)?t.substring(0,t.length-1):t},Ce=e=>{if(!(null==e?void 0:e.minViewWidth))return!0;return window.innerWidth>=e.minViewWidth},Pe=e=>{var t;if(!(null===(t=null===window||void 0===window?void 0:window.advertory)||void 0===t?void 0:t.initialized))return[];const{placements:n,queryConfig:o,deviceType:i}=l.get(),a=n[i].filter(Ce)||[],r=e?document.querySelector(e):document;if(!r)return[];const d=a.reduce((e,t)=>{const n=Se(t.id);return!n||e.includes(n)||e.push(n),e},[]).flatMap(e=>{const t=new RegExp(`^${e}(_(\\d+))?$`),n=a.filter(({id:e})=>e.match(t)),d=(null==o?void 0:o.queryByDataDevice)?`div[id^="${e}"][data-device=${i}], div[id^="${e}"][data-device=all]`:`div[id^="${e}"]:not([data-disabled="true"])`,s=r.querySelectorAll(d),c=Array.from(s).filter(({id:e})=>e.match(t)).map((e,t)=>{var o;const i=Oe(e,t,n),a=i.finnBlink&&!i.finnBlink.renderOnlyWithAdBlock,r=a&&(null===(o=i.finnBlink)||void 0===o?void 0:o.loadOnlyFinnBlink),d=`${e.id}-${((e=6)=>{if(e<=0)return"";let t="";for(let n=0;n<e;n++)t+=se[Math.floor(36*Math.random())];return t})(6)}`;return e.id=d,e.setAttribute("data-advertory-ad-rendered","true"),a&&e.setAttribute("data-is-finn-blink-placement","true"),r&&e.setAttribute("data-is-finn-blink-only-placement","true"),(e=>{var t;const n=e.id;n&&Ee.setData("initialClassNames",{[n]:{wrapper:null===(t=e.parentElement)||void 0===t?void 0:t.className.split(" "),container:e.className.split(" ")}})})(e),Object.assign(Object.assign({},i),{id:d})});return(e=>{const{keywordsConfig:t}=l.get();return(null==t?void 0:t.includeCountingKeywordInTags)?(ae!==window.location.pathname&&(re.clear(),ae=window.location.pathname),e.map(e=>{var t;const n=e.invCode.replace(/_\d+$/,""),o=null!==(t=re.get(n))&&void 0!==t?t:0;return e.keywords=Object.assign({},e.keywords),e.keywords[`${N()}-count`]=o,re.set(n,o+1),e})):e})(c)});return(e=>{const t=Array.from(document.querySelectorAll('div[class^="advertory"]'));return e.sort((e,n)=>t.findIndex(t=>t.id===e.id)-t.findIndex(e=>e.id===n.id))})(d)},Oe=(e,t,n)=>{const o=n[t],i=n[n.length-1],a=n.filter(({id:t})=>t===e.id)[0];return(null==e?void 0:e.id)===(null==o?void 0:o.id)?o:(null==e?void 0:e.id)===(null==i?void 0:i.id)?i:a||i},Le=e=>{const{queryConfig:{placementBatches:t}={},deviceType:n}=l.get(),o=(null==t?void 0:t[n])||{},i=Object.values(o).flat(),a=(e=>{const t={};return e.forEach(e=>{const n=de(e.id);e.isBackfill&&(t[n]=[e])}),t})(e),r=((e,t)=>{const n={};for(const[o,i]of Object.entries(t))n[o]=e.filter(e=>i.includes(de(e.id)));return n})(e,o),d=Object.keys(a),s=((e,t)=>e.filter(e=>!t.has(de(e.id))))(e,new Set([...d,...i]));return Object.assign(Object.assign(Object.assign({},r),a),{[Ae]:s})},je="ABSOLUTE_FULLSCREEN",$e="ANY_FULLSCREEN",Ne="VERTICAL_FULLWIDTH",_e="FULLWIDTH",qe="TAKEOVER",ze="VELVET_TAKEOVER",De="WALLPAPER",Me="COLLAPSE",Be={ANY_FULLSCREEN:[{width:6,height:6},{width:1920,height:1080},{width:3,height:3}],ABSOLUTE_FULLSCREEN:[{width:6,height:6}],VERTICAL_FULLWIDTH:[{width:1080,height:1920}],FIXED_FULLSCREEN:[{width:1920,height:1080},{width:3,height:3}],FULLWIDTH:[{width:5},{width:400,height:400}],NATIVE_AD:[{width:1,height:1}],TAKEOVER:[{width:4,height:4}],VELVET_TAKEOVER:[{width:7,height:7}],WALLPAPER:[{width:2,height:2}],COLLAPSE:[{width:2,height:1}]},Re={wallpaper:1600,"l-format":1600},Fe=e=>{const{banner:t,targetId:n}=e;return!(!t||(null==n?void 0:n.includes("takeover")))&&nt(e,$e)},Ve=e=>{const{native:t}=e;return!!t},Ue=e=>nt(e,_e),He=e=>{const{targetId:t}=e;return t.includes("takeover")||nt(e,qe)},We=e=>nt(e,qe),Ke=e=>nt(e,De),Ge=e=>nt(e,Me),Je=e=>e.targetId.includes("sponsorstripe"),Ye=e=>{const t=document.querySelector(`#${e}`);return!!t&&"true"===t.dataset.isFinnBlinkPlacement},Qe=e=>e.targetId.startsWith("panorama")||e.targetId.startsWith("modul"),Xe=e=>e.targetId.startsWith("midboard"),Ze=e=>e.targetId.includes("widescreen"),et=e=>e.width>=1260&&e.width<=1280,tt=e=>e.width>=1600&&e.width<=1620,nt=(e,t)=>{const n=Be[t];if(!n)return!1;return!!n.find(t=>{var n,o;const i=(null===(n=e.banner)||void 0===n?void 0:n.width)||e.width,a=(null===(o=e.banner)||void 0===o?void 0:o.height)||e.height,r=t.width===i,d=!t.height||t.height===a;return r&&d})},ot="splash",it="welcomePage",at="topscroller",rt="velvet",dt=(e,t=(...e)=>{})=>{const n=t.toString();if(0===e.length)return n;const o=n.substring(0,n.indexOf("=>")).replace("(","").replace(")","").split(",").map(e=>e.trim()),i=n.substring(n.indexOf("{")+1,n.lastIndexOf("}")),a=o.map((t,n)=>`${t} = "${e[n]}"`);return new Function(...a,i).toString()},st="takeover-displayed",lt="takeover-visit-count",ct=14400,pt=()=>{const e=X(lt);return e?parseInt(e):0},ut=()=>{const{takeover:{enabled:e=!1,secondVisitEnabled:t=!1}={}}=l.get();return"0"!==f(y)&&("1"===f(y)||!(!e||(()=>{var e;const t=(null===(e=l.get().takeover)||void 0===e?void 0:e.cookieCapName)||st;return"true"===X(t)})())&&(!t||vt()))},vt=()=>{const e=pt();return 0===e?((()=>{const e=pt(),{takeover:{cookieCapTime:t=ct}={}}=l.get(),n=document.location.hostname;window.document.cookie=`${lt}=${e+1}; max-age=${t}; domain=${n}; path=/; SameSite=Lax`})(),!1):1===e},gt=(e,t)=>[[1,1],[1920,1080]].some(([n,o])=>n===e&&o===t),ht=()=>{const{takeover:e}=l.get();return Boolean(null==e?void 0:e.topscroller)},mt=()=>e(void 0,void 0,void 0,function*(){const e=document.location.hostname,{takeover:{cookieCapName:t=st,cookieCapTime:n=ct}={},isMobileApp:o,tcf:i,country:a}=l.get(),r=yield A(i,o,a,"ad-takeover-cookiecap");n&&r&&(window.document.cookie=`${t}=true; max-age=${n}; domain=${e}; path=/`)}),ft=e=>{var t;const n=!!(null===(t=l.get().takeover)||void 0===t?void 0:t.setCookieCapForNotShownAd);return He(e)&&n},yt=(e,t)=>{var n;if(t===at){const{topscroller:t}=e;return null!=t?t:{}}if(t===ot){const{splash:t}=e;return null!=t?t:{}}return null!==(n=e.welcomePage)&&void 0!==n?n:{}},bt=(e,t)=>{t!==ot?(e=>{var t,n,o;const i=null===(n=null===(t=l.get().takeover)||void 0===t?void 0:t.welcomePage)||void 0===n?void 0:n.headerElementSelector,a=null===(o=l.get().takeover)||void 0===o?void 0:o.topscroller;if(!i||a)return;const r=document.querySelector(i),d=document.querySelector(".welcome-page-wrapper"),s=document.querySelector(`#${e.targetId}`),c=document.querySelector(".advertory-welcome-page-scroll");if(!(r&&d&&c&&s))return;const p=null==r?void 0:r.offsetHeight,u=We(e)?"60svh":`calc(100svh - ${p}px)`,v=We(e)?"calc(40svh + 30px)":`calc(${p}px + 30px)`;d.style.setProperty("height",u,"important"),s.style.setProperty("height",u,"important"),c.style.setProperty("bottom",v,"important")})(e):(e=>{var t;if(!(null===(t=l.get().takeover)||void 0===t?void 0:t.splash))return;const n=document.querySelector(".advertory-splash-navbar-wrapper"),o=document.querySelector(`#${e.targetId}`);if(!n||!o)return;const i=`calc(100svh - ${n.offsetHeight}px)`;o.style.setProperty("height",i,"important")})(e)},wt=dt([],()=>{new MutationObserver((e,t)=>{document.querySelector("iframe")&&((()=>{const e=document.querySelector("iframe");e&&(e.onload=()=>{if(!e.contentDocument)return;document.body.style.height="100%",document.documentElement.style.height="100%",e.height="100%",e.width="100%";const t=e.contentDocument.createElement("style");t.textContent="\n .adform-adbox {\n height: 100% !important;\n width: 100% !important;\n }\n img {\n height: 100% !important;\n width: 100% !important;\n object-fit: cover !important;\n object-position: top !important;\n }\n ",e.contentDocument.head.appendChild(t)})})(),t.disconnect())}).observe(document.body,{childList:!0,subtree:!0})}),xt={nativeAd:e=>Ve(e)&&!Je(e),buyrecipe:e=>e.targetId.startsWith("buyrecipe"),fullwidthAd:Ue,fullscreenScroll:Fe,topscroller:e=>He(e)&&ht(),splash:e=>He(e)&&gt(e.width,e.height),welcomePage:He,wallpaper:Ke,skyscraper:e=>e.targetId.includes("skyscraper")&&!!e.banner,lFormat:et,hFormat:tt,toppanorama:e=>e.targetId.startsWith("toppanorama")&&!tt(e)&&!et(e),topboard:e=>e.targetId.startsWith("topboard")&&!He(e),widescreen:Ze,insider:e=>e.targetId.startsWith("insider"),sponsorstripe:Je,brandboard:e=>(e=>(980===e.width||1920===e.width&&e.targetId.includes("brandboard"))&&!e.targetId.includes("topboard")&&!e.targetId.includes("companion")&&!Qe(e))(e)&&!(e=>e.targetId.includes("backfill"))(e)&&!Xe(e),outstream:e=>"https://acdn.adnxs.com/video/outstream/ANOutstreamVideo.js"===e.renderer_url,netboard:e=>(e=>e.targetId.startsWith("netboard"))(e)||(e=>e.targetId.startsWith("board"))(e),panorama:Qe,midboard:Xe},Et=({adObj:e,preferredTestIdData:t})=>{var n,o;const i=null!==(n=null==t?void 0:t.targetId)&&void 0!==n?n:null==e?void 0:e.targetId;if(!i)return;const a=null===(o=document.querySelector(`#${i}`))||void 0===o?void 0:o.parentElement;if(!a)return;if(((e,t)=>{var n,o,i,a;const r=null===(a=null===(i=null===(o=null===(n=window.apntag)||void 0===n?void 0:n.requests)||void 0===o?void 0:o.tags)||void 0===i?void 0:i[e])||void 0===a?void 0:a.invCode;r&&(t.dataset.invCode=r)})(i,a),null==t?void 0:t.testId)return void(a.dataset.testid=t.testId);const r="DIV"===(null==a?void 0:a.tagName);e&&r&&((e,t)=>{var n,o;for(const[i,a]of Object.entries(xt))if(a(e)){if("nativeAd"===i){const a="default";t.dataset.testid=`${i}-${null!==(o=null===(n=null==e?void 0:e.native)||void 0===n?void 0:n.desc2)&&void 0!==o?o:a}`;break}t.dataset.testid=i;break}})(e,a)},kt=e=>{var t;return(null===(t=Object.entries(xt).find(([,t])=>t(e)))||void 0===t?void 0:t[0])||""},Tt=(e,t)=>{const n=e.width,o=(null!=t?t:window.screen.width)/n;return o<1?o:1},It=(e,t=window.screen.width,n,o)=>{const i=Tt(e,t),a=document.querySelector(`iframe[id^="utif_${e.targetId}"]`);a&&(a.style.transform=`scale(${i})`,a.style.transformOrigin="left top")},At=new Map;At.set("insider",{scale:.82,transformOrigin:"left center",cogwheelAdjust:!0}),At.set("panorama",{scale:.79,transformOrigin:"center center"}),At.set("outstream",{scale:.79,transformOrigin:"center center"}),At.set("integration",{scale:.79,transformOrigin:"center center"}),At.set("toppanorama",{scale:.8,transformOrigin:"left center"});const St=e=>{if(!((null===(t=null===document||void 0===document?void 0:document.body)||void 0===t?void 0:t.clientWidth)>767&&(null===(n=null===document||void 0===document?void 0:document.body)||void 0===n?void 0:n.clientWidth)<=853))return;var t,n;const o=kt(e),i=At.get(o),a=document.querySelector(`#${e.targetId}`);if(!a||!i)return;if(a.style.transformOrigin=i.transformOrigin,a.style.transform=`scale(${i.scale})`,!(null==i?void 0:i.cogwheelAdjust))return;const r=document.querySelector(`div[class*="gdpr-cogwheel-button"][id$="${e.targetId}"]`),d=null==a?void 0:a.offsetWidth;r&&"number"==typeof d&&!isNaN(d)&&r.style.setProperty("right",String(-1*d*.2)+"px")},Ct={adRequested:()=>{},adAvailable:e=>{},adLoaded:e=>{const t=window.screen.width||window.innerWidth;980===e.width&&t<980&&((e,t)=>{It(e,t);const n=document.querySelector(`#${e.targetId}`);n&&(n.style.minWidth="100vw")})(e,t)},adNoBid:e=>{},adError:(e,t)=>{},adCollapse:()=>{},adRequestFailure:e=>{},adBadRequest:e=>{},adLoadedMediated:e=>{},adNoBidMediated:e=>{}},Pt=()=>(window.apntag||(window.apntag={anq:[],defineTag:e=>({targetId:""}),showTag:e=>{},onEvent:(e,t,n)=>{},offEvent:(e,t)=>{},refresh:e=>{},modifyTag:(e,t)=>{},loadTags:e=>{},emitEvent:(e,t)=>{},setPageOpts:e=>{},resizeAd:(e,t,n)=>{},getAstVersion:()=>"",setEndpoint:(e,t)=>{},fireImpressionTrackers:e=>{},setKeywords:()=>{},clearRequest:()=>{}}),window.apntag),Ot=()=>(window.relevantDigital||(window.relevantDigital={cmd:[]}),window.relevantDigital),Lt=(e={},t)=>{const{prebid:{externalUidInAuctionEnabled:n,forwardGlimrTags:o=!1}={},country:i}=l.get(),a=[`${$(i)}-geo`],r=["aa-sch-context_keyword","aa-sch-publisher","se-aftonbladet-section","se-svd-section","se-generic-section","no-sno-news-section","no-sno-news-subsection","aa-sch-cmp_advertising",...o?a:[]],d=Object.fromEntries(Object.entries(e).filter(([e])=>r.includes(e))),s=t&&n?{id:t}:{};return{ortb2:Object.assign({site:{ext:{data:d}}},s)}},jt=(t,...n)=>e(void 0,[t,...n],void 0,function*(e,{timeout:t}={timeout:1e3}){document.querySelector(`script[src="${e}"]:not([type="module"])`)||(yield new Promise((n,o)=>{const i=document.createElement("script");i.async=!0,i.src=e;const a=()=>{d(),n()},r=()=>{d(),o(new Error(`Failed to load ${e}`))},d=()=>{i.removeEventListener("load",a),i.removeEventListener("error",r),clearTimeout(s)};i.addEventListener("load",a),i.addEventListener("error",r);const s=setTimeout(()=>{d(),o(new Error(`Loading script timed out: ${e}`))},t);document.head.appendChild(i)}).catch(e=>{console.error(e)}))}),$t="advertory-fullscreen-scroll",Nt="advertory-fullscreen-scroll-wrapper",_t="fullscreen-scroll-in-screen",qt="in-screen",zt=e=>e.includes("snoap.no"),Dt=e=>{var t,n,o,i,a;return!!(null===(a=null===(i=null===(o=null===(n=null===(t=window.apntag)||void 0===t?void 0:t.requests)||void 0===n?void 0:n.tags[e])||void 0===o?void 0:o.adResponse)||void 0===i?void 0:i.ads[1])||void 0===a?void 0:a.rtb)},Mt=dt([],()=>{const e=({width:e,height:t})=>{var n;const o=null===(n=document.querySelector("#sf_align"))||void 0===n?void 0:n.querySelector("div");if(!o)return;const{clientWidth:i,clientHeight:a}=o,r=e/i,d=t/a;o.style.transform=`scale(${r},${d})`,o.style.transformOrigin="left top"},t=()=>{const{innerWidth:t,innerHeight:n}=window;e({width:t,height:n})};window.addEventListener("resize",t=>{if(!t.currentTarget)return;const n={width:innerWidth,height:innerHeight};e(n)});const n=window.frameElement;(null==n?void 0:n.contentWindow)?n.contentWindow.document.body.onload=t:document.body.onload=t}),Bt=e=>{const t=dt([],()=>{new MutationObserver((e,t)=>{document.querySelector("iframe")&&((()=>{const e=document.querySelector("iframe");e&&(e.onload=()=>{if(!e.contentDocument)return;document.body.style.height="100%",document.documentElement.style.height="100%",e.height="100%",e.width="100%";const t=e.contentDocument.createElement("style");t.textContent="\n adfm-ad {\n height: 100% !important;\n width: 100% !important;\n }\n ",e.contentDocument.head.appendChild(t);const n=e.contentDocument.querySelector("iframe");if(!(null==n?void 0:n.contentDocument))return;const o=n.contentDocument.createElement("style");o.textContent="\n #image {\n background-size: cover !important;\n }\n ",new MutationObserver((e,t)=>{n.contentDocument&&(n.contentDocument.head.appendChild(o),t.disconnect())}).observe(e.contentDocument,{childList:!0,subtree:!0})})})(),t.disconnect())}).observe(document.body,{childList:!0,subtree:!0})}),n=document.createElement("script");n.textContent=`(${t})()`;return e+n.outerHTML},Rt=[],Ft={},Vt=(e,t)=>{e.forEach(({target:e,isIntersecting:n})=>{const o=Ht(e);n?(Ut(o,n),Wt(e,o,t)):(Ut(o,n),Kt(e,o,t))})},Ut=(e,t)=>{var n,o;const i=null===(n=document.getElementById(e))||void 0===n?void 0:n.querySelector("iframe");if(!i)return;const a=t?"showFullscreen":"hideFullscreen";null===(o=i.contentWindow)||void 0===o||o.postMessage(`advertory:${a}-${e}`,"*")},Ht=e=>{var t;return null===(t=e.children[0])||void 0===t?void 0:t.id},Wt=(e,t,n)=>{e.classList.add(qt),document.body.classList.add(_t),window.dispatchEvent(new CustomEvent("advertory:fullscreenScrollInView")),Rt.includes(t)||Rt.push(t),n&&window.addEventListener("scroll",Ft[t],{passive:!0})},Kt=(e,t,n)=>{Rt.includes(t)&&(n&&window.removeEventListener("scroll",Ft[t]),document.body.classList.remove(_t),e.classList.remove(qt),window.dispatchEvent(new CustomEvent("advertory:fullscreenScrollNotInView")))},Gt=(e,t={fadingHeaderEnabled:!1,headerSelectors:[".js-masthead"],skyscraperSelectors:[".skyscraper_r"],headerZIndex:3})=>{const{headerSelectors:n=[".js-masthead"],skyscraperSelectors:o=[".skyscraper_r"],headerZIndex:i=3}=t,a=[],r=[];return n.forEach(e=>{var t;const n=null!==(t=document.querySelector(e))&&void 0!==t?t:document.querySelector("header");n&&a.push(n)}),o.forEach(e=>{const t=document.querySelector(e);t&&r.push(t)}),()=>{a.length&&Jt(e,a,i,0),r.length&&Jt(e,r,i,40)}},Jt=(e,t,n,o)=>{const i=e.offsetHeight,a=window.scrollY,r=e.getBoundingClientRect().top+a;t.forEach(e=>{const t=e.offsetHeight;let d;d=r>a?(r-a)/t-o:(a+t-(r+i))/t;const s=d<=0;e.style.visibility=s?"hidden":"",e.style.zIndex=s?"":n.toString(),e.style.pointerEvents=s?"none":"all",e.style.opacity=d.toString()})};function Yt(e){if(!e||"undefined"==typeof window)return;const t=document.createElement("style");return t.setAttribute("type","text/css"),t.innerHTML=e,document.head.appendChild(t),e}Yt('body.fullscreen-scroll-in-screen{overflow-x:hidden}.advertory-fullscreen-scroll-wrapper{visibility:hidden;overflow:visible;width:100% !important;height:var(--advertory-fullscreen-scroll-vh, 100vh) !important;position:relative;margin:var(--advertory-fullscreen-scroll-wrapper-margin);z-index:1;display:block !important;min-height:250px;padding:0 !important;clip-path:polygon(0 0, 100vw 0, 100vw 100dvh, 0 100dvh);-webkit-clip-path:polygon(0 0, 100vw 0, 100vw 100dvh, 0 100dvh)}.advertory-fullscreen-scroll-wrapper>div{position:fixed;top:0;left:0;height:var(--advertory-fullscreen-scroll-vh, 100vh) !important;width:100vw !important;overflow:hidden}html[data-app-platform=iOS] .advertory-fullscreen-scroll-wrapper>div{height:calc(var(--advertory-fullscreen-scroll-vh, 100vh) - env(safe-area-inset-top) + var(--advertory-ios-safe-area-top-fix, 0px) - env(safe-area-inset-bottom)) !important;top:unset !important;bottom:env(safe-area-inset-bottom) !important}.advertory-fullscreen-scroll-wrapper>div>iframe{height:inherit !important;width:inherit !important;display:none !important}.advertory-fullscreen-scroll-wrapper.in-screen{visibility:visible;overflow:visible;width:100vw !important}.advertory-fullscreen-scroll-wrapper.in-screen>div>iframe{display:block !important}.advertory-fullscreen-scroll-wrapper.in-screen:before{content:"";width:100vw;height:150dvh;position:relative !important;display:block;transform:translateX(-50%);overflow:visible;z-index:1;left:50%;top:-150dvh;padding:0 !important}.advertory-fullscreen-scroll-wrapper.in-screen:after{content:"";width:100vw;height:150dvh;position:relative !important;display:block;transform:translateX(-50%);overflow:visible;z-index:1;left:50%;top:-50dvh}.advertory-fullscreen-scroll{position:fixed;top:var(--advertory-fullscreen-scroll-top, 0px);left:var(--advertory-fullscreen-scroll-left, 0px);width:var(--advertory-fullscreen-scroll-vw, 100vw);height:var(--advertory-fullscreen-scroll-vh, 100vh);overflow:hidden}.advertory-fullscreen-scroll::before{content:attr(data-ad-label);box-sizing:border-box;position:fixed;top:0}html[data-app-platform=iOS] .advertory-fullscreen-scroll::before{top:calc(env(safe-area-inset-top) - var(--advertory-ios-safe-area-top-fix, 0px)) !important}.advertory-fullscreen-scroll::before{left:calc(50vw - 628px);width:calc(100% - 36px);max-width:1250px;text-align:left;background-color:hsla(0,0%,100%,.6);color:#212121;font-family:Ester Blenda,Arial,sans-serif;font-size:11px;font-weight:400;font-style:normal;text-transform:lowercase;line-height:1;margin:16px 2px;padding:10px;z-index:1;visibility:inherit !important}@media screen and (max-width: 1290px){.advertory-fullscreen-scroll::before{left:16px}}.advertory-fullscreen-scroll[data-move-cogwheel-to-the-left=true]>div[role=button]{left:calc(50vw - 623px);right:unset}@media screen and (max-width: 1290px){.advertory-fullscreen-scroll[data-move-cogwheel-to-the-left=true]>div[role=button]{left:22px;right:unset}}.advertory-fullscreen-scroll[data-move-cogwheel-to-the-left=true]::before{padding-left:32px}.advertory-fullscreen-scroll>div[id*=utif]{display:block;width:var(--advertory-fullscreen-scroll-vw, 100vw) !important;height:var(--advertory-fullscreen-scroll-vh, 100vh) !important}html[data-app-platform=iOS] .advertory-fullscreen-scroll>div[id*=utif]{height:calc(var(--advertory-fullscreen-scroll-vh, 100vh) - env(safe-area-inset-top) + var(--advertory-ios-safe-area-top-fix, 0px) - env(safe-area-inset-bottom)) !important}.advertory-fullscreen-scroll>div[id*=utif]{overflow:hidden}.advertory-fullscreen-scroll>div[id*=utif]>iframe{display:block;height:inherit !important;width:inherit !important}.advertory-fullscreen-scroll>div[role=button]{z-index:2;opacity:1;background:rgba(0,0,0,0) !important;left:unset;position:fixed !important;right:calc(50vw - 623px);top:19px !important;width:26px !important;height:26px !important}html[data-app-platform=iOS] .advertory-fullscreen-scroll>div[role=button]{top:calc(env(safe-area-inset-top) - var(--advertory-ios-safe-area-top-fix) + 19px) !important}@media screen and (max-width: 1290px){.advertory-fullscreen-scroll>div[role=button]{right:22px}}');const Qt={no:{adText:"ANNONSE",adFrom:"ANNONSE FRA",adContent:"ANNONSØRINNHOLD",adContentFrom:"ANNONSØRINNHOLD FRA"},se:{adText:"ANNONS",adFrom:"ANNONS FRÅN",adContent:"EXTERN LÄNK",adContentFrom:"EXTERN LÄNK FRÅN"}};let Xt=null;const Zt=(e,t)=>{let n=e;return n=(e=>{const t=document.createElement("script");return t.textContent="\n window.addEventListener('message', function(event) {\n if (event.data === 'advertory:showFullscreen-'+document.body.id) {\n document.body.style.display = \"block\";\n } else if (event.data === 'advertory:hideFullscreen-'+document.body.id) {\n document.body.style.display = \"none\";\n }\n });\n ",e+t.outerHTML})(e),n=(e=>{const t=document.createElement("script");return t.textContent=`(${Mt})()`,e+t.outerHTML})(n),n=(e=>{if((e=>e.includes("google"))(e))return e;const t=document.createElement("div");t.innerHTML=e;const n=t.querySelector("img");return n?(n.style.width="100%",n.style.height="100%",n.style.objectFit="cover",n.style.position="fixed",t.innerHTML):e})(n),n=(e=>{if(zt(e))return e;const t=document.createElement("style");return t.textContent="\n .GoogleActiveViewClass, .GoogleActiveViewElement {\n transform: translate(calc(-50% + 50vw), 0);\n width: 100vw !important;\n height: 100vh !important;\n }\n .GoogleActiveViewClass img, .GoogleActiveViewElement img {\n width: 100vw;\n height: 100vh;\n object-fit: cover;\n }\n .GoogleActiveViewClass iframe {\n width: 100vw !important;\n height: 100vh !important;\n }\n ",e+t.outerHTML})(n),(e=>e.includes("adform"))(n)&&(n=(e=>{const t=document.createElement("script");t.textContent='\n var frame = window.frameElement;\n if (frame) {\n frame.style.removeProperty("width");\n frame.style.removeProperty("height");\n frame.contentWindow.document.body.onload = onLoad;\n } else {\n document.body.onload = onLoad;\n }\n \n function onLoad() {\n var iframe = document.querySelector("adfm-ad iframe");\n if (iframe) {\n var image = iframe.contentWindow.document.getElementById("image");\n if (!image) return;\n image.style.backgroundSize = "cover";\n } else {\n var iframe = document.querySelector(".adform-adbox iframe");\n if (iframe) {\n var style = document.createElement("style");\n style.textContent = "#banner {width: 100% !important; height: 100% !important;} #banner img {object-fit: cover;}";\n iframe.contentDocument.body.append(style);\n iframe.style = "width: 100vw; height: 100vh;";\n } else {\n var observer = new MutationObserver(function(mutations, obs) {\n for (var mutation of mutations) {\n var iframe = mutation.addedNodes[0];\n if (iframe && iframe.nodeName === "IFRAME") {\n iframe.style = "width: 100vw; height: 100vh;";\n iframe.dataset.contents += "<style>#banner {width: 100% !important; height: 100% !important;} #banner img {object-fit: cover;}</style>";\n obs.disconnect();\n }\n }\n });\n observer.observe(document.body, { childList: true, subtree: true });\n }\n }\n }\n ';const n=document.createElement("style");return n.textContent="\n html, body, adfm-ad, #sf_align, .adform-adbox, .adform-adbox img {\n width: 100% !important;\n height: 100% !important;\n object-fit: cover;\n max-width: 100vw;\n }\n ",e+n.outerHTML+t.outerHTML})(n)),(e=>e.includes("529299503"))(n)&&(n=Bt(n)),(e=>e.includes("de17a"))(n)&&(n=(e=>zt(e)?e:e.replace("<iframe ","<iframe onload=\"\n var f = document.querySelector('iframe');\n if (!f) return;\n var s = f.style;\n s.transform = 'scale(' + (window.innerHeight / Number(f.height)).toFixed(2) + ')';\n s.right = parseInt((Number(f.width) - window.innerWidth) / 2) + 'px';\n s.bottom = parseInt((Number(f.height) - window.innerHeight) / 2) + 'px';\n s.position = 'relative';\n \" "))(n)),zt(n)&&(n=(e=>{let t=e.replace("<html>",'<html style="height: 100%;">');return t=t.replace("</iframe>","</iframe><style>#sf_align {height: 100%;} #sf_align iframe {height: 100vh;}</style>"),t=t.replace('<body style="','<body style="height: 100%; '),t})(n)),(e=>e.includes("kreateam.io"))(n)&&(n=(e=>{let t=e.replace("<html>",'<html style="height: 100%;">');return t=t.replace("</div>","</div><style>#sf_align {height: 100%;} #sf_align iframe {height: 100vh;}</style>"),t=t.replace('<body style="','<body style="height: 100%; '),t})(n)),Dt(t)&&(n=(e=>{const t=document.createElement("script");t.textContent='var frame = window.frameElement;\n if (frame) {\n frame.style.width = "100vw";\n frame.style.height = "100vh";\n }';const n=document.createElement("div");return n.innerHTML=e,n.appendChild(t),n.innerHTML})(n)),n},en=()=>{Xt=null;const e=window.visualViewport,t=e?e.height:window.innerHeight,n=e?e.width:window.innerWidth,o=e?e.offsetLeft:0,i=document.documentElement;i.style.setProperty("--advertory-fullscreen-scroll-vh",`${t}px`),i.style.setProperty("--advertory-fullscreen-scroll-vw",`${n}px`),i.style.setProperty("--advertory-fullscreen-scroll-left",`${o}px`)},tn=()=>{Xt||(Xt=window.requestAnimationFrame(en))},nn=(e,t)=>{var n,o,i,a;const{country:r}=l.get(),{targetId:d}=e;document.documentElement.style.setProperty("--advertory-ios-safe-area-top-fix",null!==(n=null==t?void 0:t.iosSafeAreaTopFix)&&void 0!==n?n:"0px"),(e=>{const{articlesContainerWidth:t=1302,backgroundColor:n="#fff",foregroundColor:o="#fff",margin:i="16px 0",beforeContentValue:a=""}=e,r=t/2,d=document.createElement("style");d.innerHTML=`\n :root {\n --background: linear-gradient(\n to right,\n ${n} 0px,\n ${n} calc(50% - ${r}px),\n ${o} calc(50% - ${r}px),\n ${o} calc(50% + ${r}px),\n ${n} calc(50% + ${r}px),\n ${n} 100%\n ) !important;\n \n --advertory-fullscreen-scroll-wrapper-margin: ${i};\n }\n \n .advertory-fullscreen-scroll-wrapper {\n ${a&&"clip-path: polygon(0 -16px, 100vw -16px, 100vw 100dvh, 0 100dvh);\n -webkit-clip-path: polygon(0 -16px, 100vw -16px, 100vw 100dvh, 0 100dvh);"}\n }\n\n .advertory-fullscreen-scroll-wrapper:before, .advertory-fullscreen-scroll-wrapper:after {\n background: var(--background);\n content: '${a}' !important;\n }`,d.id="ad-fullscreen-scroll-wrapper-style",document.head.appendChild(d)})(null!==(o=null==t?void 0:t.overlayStyles)&&void 0!==o?o:{});const s=document.getElementById(d),c=null==s?void 0:s.parentElement;if(!s||!c)return;((e,t)=>{const n=(null==t?void 0:t.fadingHeaderEnabled)||!1,o=new IntersectionObserver(e=>Vt(e,n),{}),i=Ht(e);o.observe(e),n&&(Ft[i]=Gt(e,t))})(c,t),s.className=$t;const p=nt(e,je)?"absolute":"fixed";s.style.position=p,c.className=Nt,c.dataset.showTagSubscribeId=d,s.setAttribute("data-ad-label",Qt[r].adText),(null==t?void 0:t.moveCogwheelToTheLeft)&&(s.dataset.moveCogwheelToTheLeft="true"),tn(),window.addEventListener("resize",tn),null===(i=window.visualViewport)||void 0===i||i.addEventListener("resize",tn),null===(a=window.visualViewport)||void 0===a||a.addEventListener("scroll",tn)},on=({targetId:e})=>{const t=(e=>{var t;const{requests:n}=window.apntag,o=Dt(e)?1:0;return null===(t=null==n?void 0:n.tags[e].adResponse.ads[o].rtb)||void 0===t?void 0:t.banner.content})(e);if(!t)return;((e,t)=>{const{requests:n}=window.apntag,o=Dt(e)?1:0,i=null==n?void 0:n.tags[e].adResponse.ads[o].rtb;i&&(i.banner.content=t)})(e,Zt(t,e))},an=e=>{var t;!document.querySelector(`#gdprAdTransparencyCogWheelButton-${e}`)&&(null===(t=window.gdpr)||void 0===t?void 0:t.setupButton)&&window.gdpr.setupButton(e)},rn="ad-loaded",dn=()=>e(void 0,void 0,void 0,function*(){const{prebid:e,tcf:t,country:n,isMobileApp:o,fullscreenScroll:i}=l.get();if(!(null==e?void 0:e.enabled))return;const{initNativeAd:a}=l.getHandlers(),{getConsentAsync:r}=I(t,0,n),d=yield r(),s=(()=>{let e=!1,t=[];const n={relevantCb:{timeout:1e3},auctionCb:{timeout:2e3}};return{getCancel:()=>e,setCancel:t=>{e=t},events:n,failsafeOnTimeout:o=>{const i=Pt(),{prebid:{relevantCbTimeout:a}={}}=l.get(),r="relevantCb"===o&&a?a:n[o].timeout,d=setTimeout(()=>{!n[o].done&&!e&&(console.warn(`Doing failsafe loadTags() call after waiting too long for '${o}'`),e=!0,i.loadTags&&i.loadTags())},r);t.push(d)},cleanup:()=>{t.forEach(e=>clearTimeout(e)),t=[],e=!1,n.relevantCb.done=!1,n.auctionCb.done=!1}}})(),c=Pt(),u=(()=>{const{requests:{user:e={userIds:[]},keywords:t={}}={}}=Pt();return{user:e,keywords:t}})();s.failsafeOnTimeout("relevantCb");const{user:{externalUid:v=""}={},keywords:g}=u;(()=>{const e=Ot();return e.cmd||(e.cmd=[]),e.cmd})().push(()=>{if(s.getCancel()||!c.loadTags)return p("core loadTags() call was cancelled",{cancel:s.getCancel(),apnTagLoadTags:!c.loadTags,condition:"or"}),void s.cleanup();const t=Ot();s.events.relevantCb.done=!0,s.failsafeOnTimeout("auctionCb");const o=d?{gdpr:{cmpApi:"iab",timeout:8e3}}:{cmpApi:"none"};p("prebid consentManagement",o),t.addPrebidConfig(Object.assign(Object.assign({consentManagement:o,enableSendAllBids:!1},Q(n)),Lt(g,v))),p("core add prebid config",Object.assign(Object.assign({consentManagement:o,enableSendAllBids:!1},Q(n)),Lt(g,v))),t.loadPrebid({configId:e.id,manageAdserver:!1,collapseEmptyDivs:!1,collapseBeforeAdFetch:!1,noGpt:!0,noSlotReload:!0,loadUnknownSlots:!0,apntagCalls:{showTag:()=>{},loadTags:e=>{s.getCancel()||(s.events.auctionCb.done=!0,c.loadTags(e)),s.cleanup()}},customNativeRender:e=>{sn(e,a)},directRenderFn:e=>{var t;const{settings:n,renderFn:o}=e,{bid:a,adDiv:r}=n||{};if(!r)return;const d=o(n),s=Object.assign(Object.assign({},a),{targetId:r.id,banner:!0}),l=r.id,c=document.getElementById(l);c&&(Fe(s)?(nn(s,i),(e=>{const t=()=>{const t=e.contentDocument;if(!(null==t?void 0:t.body))return;const n=()=>{const e=t.querySelector("iframe");if(!e)return!1;const n=()=>{var t;const n=null===(t=e.contentDocument)||void 0===t?void 0:t.querySelector(".adn-ttpa-container");n&&(n.style.setProperty("bottom","10px","important"),n.style.setProperty("top","unset","important"))};return e.addEventListener("load",n),n(),!0};if(n())return;const o=new MutationObserver(()=>{n()&&o.disconnect()});o.observe(t.body,{childList:!0,subtree:!0})};e.addEventListener("load",t),t()})(d)):((e=>{if(!(null==e?void 0:e.classList.contains($t)))return;e.classList.remove($t),e.removeAttribute("style"),e.removeAttribute("data-ad-label");const t=e.parentElement;(null==t?void 0:t.classList.contains(Nt))&&(t.classList.remove(Nt),t.classList.remove(qt))})(c),null===(t=null==c?void 0:c.parentElement)||void 0===t||t.classList.add("advertory-direct-render")),c.classList.add(rn),((e,t,n)=>{var o,i,a,r;const d=document.createElement("div");d.id=`${e}-button`,t.appendChild(d),(null===(i=null===(o=window.apntag.requests)||void 0===o?void 0:o.tags[e])||void 0===i?void 0:i.adResponse)||(null!==(a=(r=window.apntag).requests)&&void 0!==a||(r.requests={tags:{}}),window.apntag.requests.tags[e]=Object.assign(Object.assign({},window.apntag.requests.tags[e]),{adResponse:{ads:[{creative_id:n}]}})),an(e);const s=d.firstElementChild;s&&t.insertBefore(s,d),d.remove()})(l,c,null==a?void 0:a.creativeId))}}),p("core load prebid",{configId:e.id,manageAdserver:!1,collapseEmptyDivs:!1,collapseBeforeAdFetch:!1,noGpt:!0,noSlotReload:!0,loadUnknownSlots:!0,apntagCalls:{showTag:()=>{},loadTags:e=>{s.getCancel()||(s.events.auctionCb.done=!0,c.loadTags(e))}},customNativeRender:e=>{sn(e,a)},directRenderFn:()=>{}})})}),sn=(e,t)=>{var n;const{divId:o,native:i,bid:a}=e,r=document.querySelectorAll(`[id^=${o}]`)[0],d=`RY-${r.id}`;((e,t)=>{e.childNodes.forEach(e=>e.style.cssText="position: absolute; z-index: -1;");const n=document.createElement("div");n.setAttribute("id",t),e.appendChild(n)})(r,d);const s=null===(n=r.getElementsByTagName("iframe")[0])||void 0===n?void 0:n.contentWindow;t({native:i,targetId:d},l.get()),null==s||s.postMessage(JSON.stringify({message:"Prebid Response",ad:"\x3c!-- nothing --\x3e",adId:a.adId}),"*")},ln=(e,t,n)=>{const o=document.getElementById(`div_utif_${e}`);if(!o)return;const{apntag:i}=window,[a,r]=t;if(!o.dataset.lockedsize&&r&&a)o.style.width=`${a}px`,o.style.height=`${r}px`,n&&(i.resizeAd(o.id,[a,r]),o.dataset.lockedsize="true",o.dataset.lockedwidth=a.toString(),o.dataset.lockedheight=r.toString());else if(null==o?void 0:o.dataset.lockedsize){const{lockedwidth:e,lockedheight:t}=o.dataset;e&&t&&i.resizeAd(o.id,[e,t])}},cn=["netboard","board"];class pn{constructor(e,t){this.identityFacade=e,this.tracker=t}buildUrl(e,t){var n,o;const{editionName:i}=e,a=(()=>{const e=window.location.href;return new URL(e).searchParams.get("dre_override_inv_code")||""})(),r=JSON.stringify(null!==(o=null===(n=window.advertory)||void 0===n?void 0:n.renderedDrEditionAds)&&void 0!==o?o:[]),d=new URL("https://dr-edition-teaser-server.inventory.schibsted.io/editions"),{envId:s,spid:l}=t;return d.searchParams.append("editionName",i),a&&d.searchParams.append("urlData",a),r&&d.searchParams.append("excludedItems",r),l&&d.searchParams.append("spid",l),s&&d.searchParams.append("envid",s),d.toString()}fetchData(t){return e(this,void 0,void 0,function*(){var e,n,o;const i=yield this.identityFacade.getIdentityUser(),a=null!==(o=yield null===(n=null===(e=this.tracker)||void 0===e?void 0:e.getEnvironmentId)||void 0===n?void 0:n.call(e))&&void 0!==o?o:"",r=(null==i?void 0:i.userId)?String(i.userId):"",d=this.buildUrl(t,{envId:a,spid:r});try{p("Starting fetching DrEdition ad from URL:",d);const e={method:"GET"},t=yield z.get(d,e);return p("Fetch operation completed successfully."),t}catch(e){p("Error during fetch operation:",e)}return null})}}let un=class{getDrEditionUTMParams(e,t){var n;const{title:o="",clientName:i,creativeId:a}=null!==(n=null==e?void 0:e.pulseData)&&void 0!==n?n:{},{editionName:r}=t,d=o.replace(/<[^>]*>/g,"");return Object.assign({utm_source:"vgfront",utm_content:r,utm_campaign:i,utm_medium:d},a&&{utm_id:`df-${a}`})}getUrlSearchParams(e,t,n){if(!e)return"";const o=this.getDrEditionUTMParams(t,n),i=new URLSearchParams(decodeURIComponent(e.search)),a=new URLSearchParams(e.search);return Object.entries(o).forEach(([e,t])=>{i.has(e)||a.set(e,null!=t?t:"")}),a.toString().replace(/\+/g,"%20")}getUrlWithParams(e,t){var n;const o=null===(n=null==e?void 0:e.pulseData)||void 0===n?void 0:n.url;if(!o)return"";const i=this.getDrEditionUTMParams(e,t),a=new URL(o);return Object.entries(i).forEach(([e,t])=>{a.searchParams.has(e)||a.searchParams.set(e,null!=t?t:"")}),a.toString()}handleVideo(t,n){return e(this,void 0,void 0,function*(){const{id:e,autoplay:o,mute:i,videoLoop:a,vendor:r}=n.videoConfiguration;t.classList.add("vgtv-video-container"),Object.assign(t.dataset,{vgtvVideoId:e,vgtvVendor:r,vgtvAutoplay:o,vgtvMuted:i,vgtvLoop:!!a,vgtvNa:!0,vgtvRecommended:!1,vgtvPulseProvider:"vg",vgtvPulseProductTag:"partnerstudio"})})}getPulseObjectId(){return"sdrn:vg:content:partnerstudio:element:partnerstudio:stats"}getPulsePageId(){return"sdrn:vg:frontpage:front"}getTags(e){var t;let n;if(n=e instanceof HTMLAnchorElement?e.href:null===(t=null==e?void 0:e.querySelector("a"))||void 0===t?void 0:t.href,!n)return[];const{host:o,pathname:i}=new URL(n);if(!o.includes("www.vg.no")&&!i.includes("annonsorinnhold"))return[n];const a=i.split("/");return a.length?[...a.filter(Boolean).slice(1).map(e=>e),n]:[n]}};const vn=e=>{const t=e.parentElement;t?t.classList.remove("dr-edition-lock-height"):p("Dr. Edition container does not have a parent element, cannot remove height lock.")};class gn{constructor(e,t,n,o){this.drEditionService=e,this.rendererManager=t,this.videoManager=n,this.pulseManager=o,this.drEditionAds=[]}fetchAndRenderAd(t,n){return e(this,void 0,void 0,function*(){var e,o;const{drEditionConfig:{containerSelector:i},renderAsBackfill:a=!1}=n,r=t.querySelector(i);if(!r)return void p(`Container with selector "${i}" not found.`);const d=yield this.drEditionService.fetchData(n);return(null==d?void 0:d.itemId)||a?!(null==d?void 0:d.itemId)&&a?(p("No Dr. Edition ads available to render. Collapsing whole placement."),be(t.id),void vn(r)):((null==d?void 0:d.itemId)&&a&&(p("Dr. Edition ad available to render as a Xandr backfill."),we(t.id)),void(d?(d.css&&((e,t)=>{const n=document.createElement("link");n.rel="preload",n.href=e,n.as=t,document.head.appendChild(n)})(d.css,"style"),yield this.rendererManager.render(r,d,n),yield null===(e=this.videoManager)||void 0===e?void 0:e.handle(d,n),vn(r),this.drEditionAds.push(d),window.advertory=window.advertory||{},window.advertory.renderedDrEditionAds=window.advertory.renderedDrEditionAds||[],window.advertory.renderedDrEditionAds.push(d.itemId),this.observeAdView(t,d,n),null===(o=t.querySelector("a"))||void 0===o||o.addEventListener("pointerup",()=>null)):vn(r))):(p("No Dr. Edition ads available to render. Hiding Dr. Edition and rendering Xandr backfill."),this.hideDrEdition(r),this.showBackfill(t),void vn(r))})}observeAdView(e,t,n){this.observeCarousel(e,t,n)||((e,t,n={threshold:.5})=>{new IntersectionObserver(([e],n)=>{e.isIntersecting&&(t(),n.disconnect())},n).observe(e)})(e,()=>this.pulseManager.trackContentView(e,t,n),{threshold:.5})}showBackfill(e){var t;const n=e.querySelector(".fallback");if(!n)return;n.style.display="block";const o=null!==(t=n.dataset.fallbackTargetId)&&void 0!==t?t:"";we(o)}hideDrEdition(e){e.style.display="none"}observeCarousel(e,t,n){const o=e.querySelector(".dr-edition-slider");if(!o)return!1;let i=null;const a=new IntersectionObserver(e=>{e.forEach(e=>{e.isIntersecting&&e.intersectionRatio>=.9&&(i&&clearTimeout(i),i=setTimeout(()=>{e.target.onclick=()=>this.pulseManager.trackContentClick(e.target,t,n),this.pulseManager.trackContentView(e.target,t,n)},500)),[...o.children].forEach(e=>{a.observe(e)})})},{threshold:[.9]});return[...o.children].forEach(e=>{a.observe(e)}),!0}}class hn{constructor(e,t){this.newsroomStrategy=e,this.pulseManager=t}render(t,n,o){return e(this,void 0,void 0,function*(){if(!(null==n?void 0:n.itemId))return;const{getConsentAsync:e}=I(o.tcf,o.isMobileApp,o.country),i=yield e(),a=o.device===Z.MOBILE?n.mobileHTML:n.desktopHTML;const r=i?a:a.replace(/<img [^>]*class="tracking-pixel"[^>]*>/g,"");t.innerHTML=r,t.querySelectorAll("a").forEach(e=>{var t,i,a;e.search=null!==(a=null===(i=(t=this.newsroomStrategy).getUrlSearchParams)||void 0===i?void 0:i.call(t,e,n,o))&&void 0!==a?a:"",e.onclick=()=>this.pulseManager.trackContentClick(e,n,o)})})}}class mn{constructor(e){this.strategy=e}handle(t,n){return e(this,void 0,void 0,function*(){const{videoConfiguration:{id:e,preview:o}={}}=t;(e||o)&&(yield this.importScript(n),yield this.createVideoElement(t,n))})}importScript(t){return e(this,void 0,void 0,function*(){const e=t.drEditionConfig.videoScriptUrl,n=document.querySelector(`script[src="${e}"]`);if(e&&!window.autoplayQueue&&!n)try{yield jt(e)}catch(e){p("Error! Failed to prepare SVP player script for Dr. Edition!",e)}})}createVideoElement(t,n){return e(this,void 0,void 0,function*(){const e=document.createElement("div"),{node:o}=t.videoConfiguration,i=[...document.querySelectorAll(`#${o}`)||[]].find(e=>0===e.children.length);if(this.handlePreviewVideo(t,n))return;this.strategy.handleVideo(e,t),null==i||i.appendChild(e),window.autoplayQueue=window.autoplayQueue||[],window.autoplayQueue.push(e=>{e.parse()});const a=null==i?void 0:i.parentNode;if(!a)return;const r=a.closest("a");a.addEventListener("click",e=>{const t=e.target.closest("a");r!==t&&t||(e.stopPropagation(),e.preventDefault())})})}handlePreviewVideo(e,t){var n,o,i;const{preview:{url:a,thumbnail:r}}=null!==(n=e.videoConfiguration)&&void 0!==n?n:{};if(!a)return!1;const d=document.querySelector(".dr-edition-preview .preview-video");return!!d&&(d.setAttribute("src",a),d.setAttribute("playsinline",""),!(!d||!r)&&(null===(i=(o=t.drEditionConfig).addPreviewVideo)||void 0===i||i.call(o,d),!0))}}let fn=class{constructor(e,t){this.pulse=e,this.newsroomStrategy=t}getEventInput(e,t,n,o){return{}}mapPageType(e){return{front:"Frontpage",article:"Article",section:"Article",collection:"Article",other:"Article"}[e||"front"]||"Frontpage"}getArticleId(){return location.pathname.split("/").slice(-2,-1).pop()||""}getTeaserElementText(e,t){if(!e)return"";const n=e.querySelector({title:".dr-edition-title",subtitle:".dr-edition-subtitle",image:"img.teaser-main-image"}[t]);if(!n)return"";if("image"===t)return n.src||"";const o=null==n?void 0:n.textContent;return o?o.trim():""}getEventTarget(e,t){const{itemId:n,pulseData:{url:o}={}}=t,i=this.getTeaserElementText(e,"title");return{id:n,name:this.normalizePlacementTitle(null!=i?i:""),type:"Page",url:o}}normalizePlacementTitle(e){return e.replace(/<[^>]+>/gi,"").replace(/[^a-z0-9æøå\s_-]/gi,"")}trackContentView(t,n,o){return e(this,void 0,void 0,function*(){var e,i,a,r,d,s,l,c;const p=new CustomEvent("advertory:partnerstudioAdImpression",{detail:{ad:o.editionName}});if(window.dispatchEvent(p),!this.pulse)return;const u=this.getEventInput(t,n,o,"view");(null===(e=this.pulse)||void 0===e?void 0:e.trackLegacyViewUIElement)?null===(a=null===(i=this.pulse)||void 0===i?void 0:i.trackLegacyViewUIElement)||void 0===a||a.call(i,u):(null===(r=this.pulse)||void 0===r?void 0:r.trackViewUIElement)?null===(s=null===(d=this.pulse)||void 0===d?void 0:d.trackViewUIElement)||void 0===s||s.call(d,u):null===(c=null===(l=this.pulse)||void 0===l?void 0:l.trackElementView)||void 0===c||c.call(l,u)})}trackContentClick(t,n,o){return e(this,void 0,void 0,function*(){var e,i,a,r,d,s;if(!this.pulse)return;const l=this.getEventInput(t,n,o,"click");this.pulse.trackLegacyClickUIElement?null===(i=(e=this.pulse).trackLegacyClickUIElement)||void 0===i||i.call(e,l):this.pulse.trackClickUIElement?null===(r=(a=this.pulse).trackClickUIElement)||void 0===r||r.call(a,l):null===(s=(d=this.pulse).trackElementClick)||void 0===s||s.call(d,l)})}};class yn extends fn{constructor(e,t,n){super(e,t),this.pulse=e,this.newsroomStrategy=t,this.pageType=n}getEventBaseData(e,t,n){const{pulseData:{title:o,clientName:i="",creativeId:a}={}}=t,{columnName:r,primaryPosition:d}=n;return{"@type":"UIElement",elementType:"Teaser",layout:{elementSize:"large",imageUrl:"",name:"large"},name:o,placement:{columnName:r,primaryPosition:d},"spt:custom":{is_sponsored:!0,sponsor:i,"spt:creativeId":a},url:location.origin}}getEventInput(e,t,n){return{object:this.getEventBaseData(e,t,n),target:this.getEventTarget(e,t)}}}let bn=class extends fn{constructor(e,t,n){super(e,t),this.pulse=e,this.newsroomStrategy=t,this.pageType=n}getEventBaseData(e,t,n){var o,i,a,r,d,s;const{itemId:l,pulseData:{clientName:c,creativeId:p}={}}=t,u=n.editionName,v=this.mapPageType(this.pageType),g=null===(o=this.newsroomStrategy)||void 0===o?void 0:o.getPulsePageId(this.pageType||"front",this.getArticleId());return{"@id":null!==(r=null===(a=null===(i=this.newsroomStrategy)||void 0===i?void 0:i.getPulseObjectId)||void 0===a?void 0:a.call(i))&&void 0!==r?r:u,"@type":"UIElement",position:u,elementType:"Article",custom:{customer:c,creativeId:null!=p?p:l},page:{"@id":null!=g?g:u,"@type":v,url:location.origin},tags:null===(s=null===(d=this.newsroomStrategy)||void 0===d?void 0:d.getTags)||void 0===s?void 0:s.call(d,e)}}getEventInput(e,t,n,o){return{object:this.getEventBaseData(e,t,n),partnerstudio:this.getEventPartnerstudioData(e,t,n,o),target:this.getEventTarget(e,t),provider:this.getProviderData()}}getEventPartnerstudioData(e,t,n,o){var i,a,r,d;const{pulseData:{algorithm:s="sov",clientName:l,creativeId:c,editionId:p,itemId:u,url:v,probability:g}={}}=t,h=Math.floor(Date.now()/1e3),m=this.getTeaserElementText(e,"title"),f=this.getTeaserElementText(e,"subtitle"),y=this.getTeaserElementText(e,"image"),b=null!==(d=null!==(r=null===(a=null===(i=this.newsroomStrategy)||void 0===i?void 0:i.getUrlWithParams)||void 0===a?void 0:a.call(i,t,n))&&void 0!==r?r:v)&&void 0!==d?d:"";return{algorithm:s,clientName:l,probability:g,creativeId:c,device:n.device,editionId:p,itemId:u,link:b,placement:n.editionName,subtitle:f,time:h,title:m,type:o,imageUrl:y,frontId:86,tracking_type:"ad",xandrAdLoaded:!1}}getProviderData(){return{productTag:"partnerstudio"}}};const wn={SVD:"svd",VG:"vg",GODARE:"godare",AFTENPOSTEN:"aftenposten",SA:"sa",BT:"bt",AFTONBLADET:"aftonbladet",E24:"e24",MINMOTE:"minmote",PENT:"pent",GODT:"godt",TEK:"tekno",KLART:"klart",TVNU:"tvnu",POLARIS:"polaris",KOKET:"koket",TV4:"tv4",FOTBOLLSKANALEN:"fotbollskanalen"},xn={FRONT:"front"},En=t=>e(void 0,void 0,void 0,function*(){var e,n;return(null===(e=null===window||void 0===window?void 0:window.SVP)||void 0===e?void 0:e.Player)?new window.SVP.Player(t):((()=>{const e="svp-player-sdk",t=document.querySelector(e),n=Array.from(document.querySelectorAll('script[src^="https://cdn.stream.schibsted.media/player"]'));if(t||n.length>0)return;const o=document.createElement("script");o.id=e,o.src="https://cdn.stream.schibsted.media/player/3.78.1/player.min.js",o.async=!0;try{o.src=o.src.replace("player.min","player.next.min")}catch(e){console.error("Failed to set player.next.min source:",e)}document.head.insertBefore(o,document.head.firstChild)})(),(null===(n=window.SVP)||void 0===n?void 0:n.isLoaded)?new window.SVP.Player(t):yield new Promise(e=>{window.addEventListener("onSvpPlayerReady",()=>e(new window.SVP.Player(t)))}))}),kn={ContentMutePlugin:e=>{window.SVP.Player.Plugins.register({getName:()=>"ContentMutePlugin",initialize(){},setup(){const t=this.player.config.get("mute");this.container=e||this.player.getContainer(),this.muted=t,t&&this.listenToOnce(this.player,"ready",this.renderButtonElement,this)},getButtonElement(){const e=document.createElement("button");e.className="player-plugin-content-mute";const t=document.createElement("span");return t.className="volume-button-icon",e.appendChild(t),e},renderButtonElement(){this.buttonElement=this.getButtonElement(),this.buttonElement.addEventListener("click",this.onButtonClick.bind(this)),this.container.appendChild(this.buttonElement),this.isVideo()||(this.buttonElement.style.display="none"),this.getJWPlayer()&&this.getJWPlayer().on("mute",this.onMuteChange,this)},onButtonClick(){this.getJWPlayer()&&(this.container.classList.add("has-interacted"),this.muted=!this.muted,this.getJWPlayer().setMute(this.muted))},onMuteChange(e){this.muted=e.mute,this.muted?this.buttonElement.classList.remove("content-video-volume-on"):this.buttonElement.classList.add("content-video-volume-on")},isVideo(){return"video"===this.player.getRawAsset().assetType},getJWPlayer(){return this.player.model.player}})},IntegrationMenu:()=>{window.SVP.Player.Plugins.register({getName:()=>"IntegrationMenu",setup(){return e(this,void 0,void 0,function*(){yield Promise.resolve().then(function(){return Gi})})}})}};class Tn{handleVideo(t,n){return e(this,arguments,void 0,function*(t,{videoConfiguration:{id:n,node:o,autoplay:i,mute:a,vendor:r}}){yield e(void 0,void 0,void 0,function*(){return yield new Promise(e=>{var t;Boolean(null===(t=window.SVP)||void 0===t?void 0:t.Player)?e(!0):window.addEventListener("onSvpPlayerReady",()=>e(!0))})});const d=["ContentMutePlugin"],s=this.createPlayerOverlay(t);var l,c;c=s,null==(l=d)||l.forEach(e=>{kn[e](c)});const p={id:n,node:o,autoplay:i,mute:a,vendor:r,autopause:"viewable",maxBitrate:600,pulse:{provider:"e24"},recommended:{autoplay:!1,next:{countdown:10}},skin:{name:"e24-default",url:""}},u=yield En(p);u.once("assetReady",()=>{((e,t)=>{null==t||t.forEach(t=>{const n=window.SVP.Player.Plugins.get(t);e.addPlugin(new n)})})(u,d)}),u.once("ready",()=>{const e=t;new MutationObserver(t=>{t.forEach(({type:t,attributeName:n})=>{"attributes"===t&&"class"===n&&(e.classList.contains("jw-state-playing")?s.classList.add("is-playing"):s.classList.remove("is-playing"),e.classList.contains("jw-flag-user-inactive")?s.classList.add("is-inactive"):s.classList.remove("is-inactive"))})}).observe(e,{attributes:!0,attributeFilter:["class"]})}),u.once("PulseStats:ready",()=>e(this,void 0,void 0,function*(){const e=yield u.getPlugin("PulseStats").getTracker();null==e||e.update({provider:{id:"e24",productTag:"partnerstudio"}})}))})}getPulseObjectId(){return"sdrn:e24:content:partnerstudio:element:partnerstudio:stats"}getPulsePageId(e,t){return e===xn.FRONT?"sdrn:e24:frontpage:front":`sdrn:e24:article:${t}`}getTags(e){var t;let n;if(n=e instanceof HTMLAnchorElement?e.href:null===(t=null==e?void 0:e.querySelector("a"))||void 0===t?void 0:t.href,!n)return[];if(!n.includes("https://e24.no/annonsorinnhold/"))return[n];const{pathname:o}=new URL(n),i=o.split("/").filter(Boolean);return i.length?[...i.slice(1),n]:[n]}createPlayerOverlay(e){const t=document.createElement("div");t.classList.add("cm-custom-video-overlay"),e.parentElement&&(t.innerHTML=e.parentElement.innerHTML,e.parentElement.replaceChild(t,e));return t.addEventListener("click",e=>{e.stopPropagation(),e.preventDefault(),t.classList.add("has-interacted")}),t}}const In="https://www.aftonbladet.se/video-player-extras/latest/";class An{handleVideo(t,n){return e(this,arguments,void 0,function*(e,{videoConfiguration:{id:t,node:n,autoplay:o,mute:i,vendor:a}}){const r={id:t,node:n,autoplay:o,mute:i,vendor:a,autopause:"viewable",maxBitrate:600,pulse:{provider:"aftonbladet"},recommended:{autoplay:!1,next:{countdown:10}},skin:{name:"",url:""},plugins:{[`${In}cta-button.js`]:{name:"CtaButton",options:{type:"unmute"}},[`${In}external-link.js`]:{name:"ExternalLink"}}};yield En(r),this.addEditionVideoClass(e)})}addEditionVideoClass(e){var t;(null===(t=null==e?void 0:e.parentElement)||void 0===t?void 0:t.parentElement)&&e.parentElement.parentElement.classList.add("dr-edition-video-player")}getPulseObjectId(){return""}getPulsePageId(){return""}}const Sn=e=>null!==e&&"object"==typeof e&&!Array.isArray(e);class Cn{handleVideo(t,n){return e(this,arguments,void 0,function*(t,{videoConfiguration:{id:n,node:o,autoplay:i,mute:a,vendor:r}}){const d={id:n,node:o,autoplay:i,mute:a,vendor:r,locale:"se",autopause:"viewable",maxBitrate:600,sharing:!1,recommended:!1,pulse:{provider:"svdse",decorator:(e,t)=>Object.assign(Object.assign({},Sn(e)?e:{}),{provider:Object.assign(Object.assign({},Sn(null==e?void 0:e.provider)?e.provider:{}),{productTag:"partnerstudio"})})},skin:{name:"svd-player",url:""},settings:{pulse:{host:"se-aftonbladet.videoplaza.tv",contentMetadata:{category:"SvD",tags:["standard-linears","pause",`video-${n}`]},requestSettings:{}}}},s=yield En(d);s.once("PulseStats:ready",()=>e(this,void 0,void 0,function*(){const e=yield s.getPlugin("PulseStats").getTracker();null==e||e.update({provider:{id:"svdse",productTag:"partnerstudio"}})}))})}getPulseObjectId(){return"sdrn:svdse:content:partnerstudio:element:partnerstudio:stats"}getPulsePageId(e,t){return e===xn.FRONT?"sdrn:svdse:frontpage:front":`sdrn:svdse:article:${t}`}}let Pn=class{handleVideo(e,t){}getPulseObjectId(){return""}getPulsePageId(e,t){return""}};const On=(e,t,n)=>{var o;const{publisher:i,pageType:a,country:r}=e,d={[wn.VG]:new un,[wn.E24]:new Tn,[wn.AFTONBLADET]:new An,[wn.SVD]:new Cn}[i]||new Pn,s=new(r===x.SE?yn:bn)(n,d,a),l=new pn(t,null!==(o=null==n?void 0:n.pulseTracker)&&void 0!==o?o:n),c=new hn(d,s),p=new mn(d);return new gn(l,c,p,s)},Ln=()=>e(void 0,void 0,void 0,function*(){return yield new Promise(e=>{if("undefined"!=typeof window)if(window.Identity)e(window.Identity);else{const t=()=>{e(window.Identity)};window.addEventListener("identity-initialized",t,{once:!0})}else e(void 0)})});class jn{constructor(e){this.identity=e,this.getIdentityUser=this.getIdentityUser.bind(this),this.isUserLoggedIn=this.isUserLoggedIn.bind(this),this.onIdentityLogout=this.onIdentityLogout.bind(this)}getIdentityUser(){return e(this,void 0,void 0,function*(){var e;try{const t=yield null===(e=this.identity)||void 0===e?void 0:e.getUser();return null!=t?t:null}catch(e){return p("[Privacy Broker] User is not logged in."),null}})}isUserLoggedIn(){return e(this,void 0,void 0,function*(){var e,t;return null!==(t=yield null===(e=this.identity)||void 0===e?void 0:e.isLoggedIn())&&void 0!==t&&t})}onIdentityLogout(e){var t;null===(t=this.identity)||void 0===t||t.on("logout",e)}}const $n=(e,t,n)=>{const{wrapperSelector:o}=null==e?void 0:e.drEditionConfig,i=document.querySelectorAll(o),a=new IntersectionObserver((o,i)=>((e,t,n,o,i)=>{const a=On(n,o,i);e.forEach(e=>{var o,i,r;if(!e.isIntersecting)return;const d=e.target,s=null!==(o=d.dataset.editionName)&&void 0!==o?o:"",l=null!==(i=d.dataset.pulseColumnname)&&void 0!==i?i:"",c=null!==(r=d.dataset.pulsePrimaryposition)&&void 0!==r?r:"";a.fetchAndRenderAd(d,Object.assign(Object.assign({},n),{editionName:s,columnName:l,primaryPosition:c})),t.unobserve(d)})})(o,i,e,t,n),{rootMargin:"400% 0px"});i.forEach(e=>a.observe(e))},Nn=()=>e(void 0,void 0,void 0,function*(){try{(()=>{const e=document.createElement("script");e.setAttribute("src","https://ads.inventory.schibsted.io/ad-service/ad-banner-sponsor-advertisement/ad.js"),e.setAttribute("type","text/javascript"),e.setAttribute("async","true"),document.head.appendChild(e)})(),(()=>{const e=document.createElement("div");e.setAttribute("id","ads-advertory-anchor"),e.classList.add("subscribe_box"),e.classList.add("ad-box"),e.classList.add("leftAd"),e.classList.add("netboard"),e.classList.add("advert"),e.classList.add("module"),e.classList.add("banner"),e.classList.add("leaderboard"),e.classList.add("adsbygoogle"),e.classList.add("ad-banner"),e.classList.add("ad-container"),e.classList.add("adsbox"),e.classList.add("sidebar-ads"),e.classList.add("banner-ads"),e.style.opacity="0",e.style.width="1px",e.style.height="1px",e.style.minWidth="0px",e.style.minHeight="0px",e.style.maxWidth="1px",e.style.maxHeight="1px",e.style.position="absolute",e.style.top="0",e.style.boxSizing="border-box",e.style.margin="0",e.style.padding="0",document.body.appendChild(e)})()}catch(e){console.error("Error running adblock scripts:",e)}}),_n=[],qn=(t,n)=>e(void 0,void 0,void 0,function*(){var e;const{pulse:o,tcf:i,deviceType:a,drEdition:r,publisher:d,pageType:s,country:l,isMobileApp:c}=t;if(!(yield A(i,c,l,"handleDrEditionBackfill")))return;const u=((e,t)=>{var n;const{deviceType:o,placements:i,drEdition:{fallbackGlobalEditionName:a}={}}=e,r=i[o]||i.desktop,d=de(t.targetId),s=r.find(e=>e.id===d),l=cn.some(e=>d.startsWith(e)),c=_n.includes(d),p=(null===(n=null==s?void 0:s.drEdition)||void 0===n?void 0:n.editionName)||a;return s&&l&&!c&&p?(_n.push(d),Object.assign(Object.assign({},s),{drEdition:Object.assign(Object.assign({},s.drEdition),{editionName:p})})):null})(t,n);if(!u)return;if(!(null==o?void 0:o.instance))return void p("Pulse has not been passed as a prop, aborting");const v=yield Ln(),g=new jn(v),h=On({publisher:d,pageType:s,country:l},g,null==o?void 0:o.instance),m=document.getElementById(n.targetId);if(!m||!r)return;m.classList.value="";const f=document.createElement("div");f.className=r.containerSelector.replace(/^[.#:[\]]+/,""),m.innerHTML=f.outerHTML;const y={editionName:(null===(e=null==u?void 0:u.drEdition)||void 0===e?void 0:e.editionName)||"",drEditionConfig:r,device:a,tcf:i,isMobileApp:c,country:l,renderAsBackfill:!0};yield h.fetchAndRenderAd(m,y)}),zn=(t,n)=>{var o,i,a,r;if(!(()=>{const e=document.getElementById("ads-advertory-anchor");return!(e&&"none"!==getComputedStyle(e).display&&window.advertoryFluepapir)})())return void p("Ad block not enabled, Dr. Edition backfills will not be rendered");p("Ad block is enabled, Dr. Edition backfills will be rendered");const d=null!==(r=null===(a=null===(i=null===(o=t.finnBlink)||void 0===o?void 0:o.replacementConfig)||void 0===i?void 0:i.adsToReplace)||void 0===a?void 0:a.map(([e])=>e))&&void 0!==r?r:[],s=new IntersectionObserver((n,o)=>e(void 0,void 0,void 0,function*(){for(const e of n){if(!e.isIntersecting)continue;const n=e.target;o.unobserve(n),yield qn(t,{targetId:n.id})}}),{rootMargin:"400% 0px"});n.filter(e=>!d.some(t=>e.id.startsWith(t))).forEach(e=>{const t=document.getElementById(e.id);t&&s.observe(t)})},Dn="collapseAd",Mn="hideAd",Bn="resizeAd",Rn="renderDrEditionFallback",Fn="wallpaperImageUrl",Vn="wallpaperColor",Un="velvet",Hn=[Bn,Fn,Vn,Dn,Mn,Rn,Un];let Wn;const Kn=e=>{if("object"==typeof e)return e;if(t=e,fe.test(t)){const t=e.replace(/^wallpaper:url:/,"");return{name:Fn,wallpaperImageUrl:t}}var t;if((e=>e.startsWith("wallpaper:color:"))(e)){const t=e.replace(/^wallpaper:color:/,"");return{name:Vn,wallpaperColor:t}}if(e.startsWith(Rn)){const t=e.split(":")[1];return{name:Rn,targetId:t}}if(e.startsWith(Dn)||e.startsWith(Mn)){const t=e.split(":")[1];return{name:Dn,targetId:t}}if(e.includes("name")&&Hn.some(t=>e.includes(t)))try{return JSON.parse(e)}catch(e){}},Gn=e=>{if(!["http://acdn.adnxs-simple.com","https://acdn.adnxs-simple.com","https://crcdn01.adnxs-simple.com","http://crcdn01.adnxs-simple.com","https://acdn.adnxs.com","http://acdn.adnxs.com","https://adsdk.microsoft.com","https://adsdk.bing.net","https://adsdkprod.azureedge.net"].includes(e.origin.trim()))return;const{data:t}=e;if(!t)return;const n=Kn(t);if(!n)return;if(!n.name||!Hn.some(e=>n.name===e))return;const{name:o,targetId:i,wallpaperImageUrl:a,wallpaperColor:r,cmd:d,size:s}=n;o===Un&&d&&(d.includes("noScroll")&&(Wn=(e=>{if(!e)return()=>{};const t=e.style.overflow;return e.style.setProperty("overflow","hidden"),()=>{e.style.setProperty("overflow",t)}})(document.querySelector("body"))),(d.includes("close")||d.includes("ended"))&&(null==Wn||Wn(),dispatchEvent(new CustomEvent("advertory:closeTakeover",{})))),o!==Dn&&o!==Mn||!i||be(i),o===Bn&&i&&d&&ln(i,d),o===Rn&&i&&(be(i),qn(l.get(),{targetId:i})),"resizeMediationAd"===o&&i&&s&&ln(i,s,!0),o===Fn&&a&&(e=>{const t=document.querySelector(`.${ve}`);t&&(t.style.backgroundImage=`url(${e})`)})(a),o===Vn&&r&&(e=>{const t=document.querySelector(`.${ve}`);t&&(t.style.backgroundColor=e)})(r)},Jn=e=>({rootMargin:`${e}px 0px ${e}px 0px`}),Yn=()=>{const{publisher:t,country:n,finnBlink:o}=l.get(),{loadFinnBlinkAd:i,wallpaperHandlers:{adjustAdToHorseshoe:a}}=l.getHandlers(),r=window.apntag,d={publisher:t,country:n,finnBlink:o},s=e=>{we(e),ce(()=>r.showTag(e))};return{withXandrAd:s,withFinnBlinkAd:t=>e(void 0,void 0,void 0,function*(){yield i(t,d,null)}),withFullAdsChain:t=>e(void 0,void 0,void 0,function*(){yield i(t,d,s,()=>{Ee.getData("horseshoe").isAvailable&&a(t)})})}},Qn=(e,t,n)=>{const o="true"===n.dataset.isFinnBlinkOnlyPlacement;return Ye(t)&&o?(p(`loading finn blink ad for blink only placement for ${t}`),void Yn().withFinnBlinkAd(t)):Ye(t)?(p(`loading finn blink ad with full ads chain for ${t}`),void Yn().withFullAdsChain(t)):void ce(()=>(p("core showTag",{id:t}),e.showTag(t)))},Xn=(t,n)=>e(void 0,void 0,void 0,function*(){yield pe,yield ue;const e=new IntersectionObserver((e,n)=>((e,t,n,o)=>{e.filter(({isIntersecting:e,target:{id:t}})=>e&&!t.includes("wallpaper")).forEach(e=>{const{target:i}=e,a=(e=>{const t=e.dataset.showTagSubscribeId;return!e.id.length&&t?t:e.id})(i),r=document.getElementById(a);p("core log from intersection observer handler",{targetId:a,element:r}),n(window.apntag,a,o),r&&(t.unobserve(r),t.disconnect())})})(e,n,Qn,t),Jn(n));e.observe(t)}),Zn=new Map,eo=["no-stavangeraftenblad","sa","no-aftenposten","aftenposten","no-bergenstidende","bt"],to=".brandstudio-premium-content-widget",no=({adWrapper:e,placementContainer:t})=>t.offsetHeight+(({adWrapper:e})=>{const{paddingTop:t,paddingBottom:n}=getComputedStyle(e);return parseFloat(t)+parseFloat(n)})({adWrapper:e}),oo=({adWrapper:e,placementContainer:t})=>{const n=no({adWrapper:e,placementContainer:t});var o;null==e||e.style.setProperty("height",`${n}px`),Te(o=t),o.innerHTML=""},io=e=>{e&&e.style.getPropertyValue("height")&&e.style.removeProperty("height")},ao=({adWrapper:e,placementContainer:t})=>{const{publisher:n}=l.get(),o=eo.includes(n)&&Boolean(t.closest(to));const i=o?t.closest(to):null,a=new MutationObserver(t=>{t.forEach(({addedNodes:t})=>{t.forEach(t=>{const n=t instanceof HTMLElement,r=n&&t.matches("iframe, article")&&e;if(!n||!o&&!r||o&&!i)return;if(r)return io(e),void a.disconnect();const d=t.closest('[style*="height"]'),s=i;d&&s.contains(d)?io(d):s.hasAttribute("style")&&io(s),a.disconnect()})})});try{a.observe(t,{childList:!0,subtree:!0})}catch(e){a.disconnect()}},ro=(e,t,n,o,i,a)=>{var r;const d=performance.now(),s=null!==(r=Zn.get(t))&&void 0!==r?r:0,c=((e,t)=>!!t&&e+t<(new Date).getTime())(o,i)&&n<0;d-s>=i&&c&&(Zn.set(t,d),((e,t,n)=>{const{country:o}=l.get(),i=null==n?void 0:n.parentElement;i&&n&&oo({adWrapper:i,placementContainer:n}),ce(()=>{e.setKeywords([t],{[`${$(o)}-adreload`]:"1"},{overrideKeyValue:!0}),e.refresh([t])})})(e,t,a))},so=(e,t,n)=>{const o=new IntersectionObserver((e,o)=>((e,t,n,o)=>{e.filter(({isIntersecting:e})=>e).forEach(e=>{const{target:i,boundingClientRect:a}=e;t(window.apntag,i.id,a.y,n,o,i)})})(e,ro,t,n),Jn(300));o.observe(e)},lo=(e,t=6)=>{const n=[];for(let o=0;o<e.length;o+=t){const i=e.slice(o,o+t);n.push(i)}return n},co=()=>navigator&&navigator.userAgent.match(/chrome/i)?null:navigator&&navigator.userAgent.match(/apple/i),po=(e,t=0)=>{const n=e.getBoundingClientRect(),o=window.innerHeight;return n.bottom>-t&&n.top<o+t},uo=e=>{const{refreshConfig:{visibilityStateRefreshEnabled:t=!1}={}}=l.get();if(!t)return;const n=()=>{"visible"===document.visibilityState&&document.removeEventListener("visibilitychange",n),fo(e)};"visible"!==document.visibilityState&&document.addEventListener("visibilitychange",n)},vo=(e,t,n)=>{const o=document.querySelectorAll('[data-bf-cache-refresh="true"]');for(const i of o){const o=e.find(e=>{var t;return e.id===(null===(t=i.firstElementChild)||void 0===t?void 0:t.id)&&e.bfCacheRefresh}),a=null==o?void 0:o.threshold;po(i,a)&&o&&(ke(o.id),n.length&&i.classList.remove(...n),fo([o],t))}},go=e=>{const{refreshConfig:{backForwardNavigationRefreshEnabled:t=!1}={},siteSpecificConfig:{classesToRemoveOnRefresh:n=[]}={},isMobileApp:o}=l.get();t&&(e.forEach(({id:e})=>{const t=ho(e);t&&(t.dataset.bfCacheRefresh="true")}),o?((e,t)=>{document.addEventListener("visibilitychange",()=>{"visible"===document.visibilityState&&vo(e,!0,t)})})(e,n):((e,t)=>{window.addEventListener("pageshow",n=>{const o=()=>{window.scrollY>0&&(window.removeEventListener("scroll",o),vo(e,!1,t))};n.persisted&&(co()?window.addEventListener("scroll",o,{passive:!0}):vo(e,!1,t))})})(e,n))},ho=e=>{var t,n;return null!==(n=null===(t=document.querySelector(`#${e}`))||void 0===t?void 0:t.parentElement)&&void 0!==n?n:null},mo=e=>{const{id:t,allowedFormats:n}=e,o=(e=>{if(!e)return[];try{return JSON.parse(e.dataset.adSizes||"[]")}catch(e){return[]}})(ho(t)),i=(e=>1===e[0]&&1===e[1])(o),a={sizes:[o],allowedFormats:i?n:n.filter(e=>"native"!==e),allowSmallerSizes:!1};return i||(a.native=void 0),a},fo=(e,t=!1)=>{const{requestSize:n=d}=l.get(),o=e.map(({id:e})=>e),i=lo(o,n);if(t)for(const t of e){const e=mo(t);window.apntag.modifyTag(t.id,e)}for(const e of i)ce(()=>window.apntag.refresh(e))};const yo="#fff",bo="#0098da",wo=(e,t=!0)=>{(e===it||e===at)&&(e=>{e?setTimeout(()=>window.scrollTo(0,0),100):window.scrollTo(0,10)})(t)},xo=()=>{const e=parseInt(document.body.dataset.scrollY||"0",10);document.body.style.top="",window.scrollTo(0,e),document.body.classList.remove("page-locked")},Eo=e=>{document.body.style.overflow=e?"initial":"hidden"},ko=e=>{const t=Io(e),n=To(e);(e=>{e.classList.toggle("takeover-ad-hidden",!0)})(e),Eo(!0),e.style.display="none",window.removeEventListener("keydown",t),window.removeEventListener("advertory:closeTakeover",n)},To=e=>{const t=()=>ko(e);return window.addEventListener("advertory:closeTakeover",t),xo(),t},Io=e=>{const t=t=>{["Enter","Escape"].includes(t.key)&&ko(e)};return xo(),window.addEventListener("keydown",t),t},Ao=e=>{const t=e.querySelector(".advertory-splash-navbar-wrapper");t&&(Io(e),To(e),xo(),t.addEventListener("click",()=>{ko(e)}),Eo(!1))},So=e=>{(e=>{window.addEventListener("scroll",()=>{e.getBoundingClientRect().bottom,(e=>{const t=e.getBoundingClientRect().bottom;e.style.opacity=""+t/e.offsetHeight})(e)},{passive:!0})})(e),To(e);const t=document.querySelector("header");document.querySelectorAll(".smooth-close-takeover").forEach(e=>e.addEventListener("click",()=>null==t?void 0:t.scrollIntoView({behavior:"smooth"})))},Co=e=>{(e=>{window.addEventListener("advertory:closeTakeover",()=>ko(e))})(e)},Po=e=>{const{takeover:{splash:{showAnnonsLabel:t=!1}={}}={}}=l.get(),n=e.querySelectorAll(".advertory-splash-navbar-wrapper"),o=document.querySelector(".advertory-takeover-label");Array.from(n).forEach(e=>e.style.display="flex"),t&&o&&(o.style.display="flex",o.innerText=Qt.se.adText),e.classList.toggle("advertory-splash-wrapper",!0)},Oo=e=>{const t=document.querySelectorAll(".advertory-topscroller-elements");Array.from(t).forEach(e=>e.style.display="flex");const n=document.querySelector(".advertory-takeover-label");n&&(n.style.display="flex",n.innerText=Qt.no.adText,n.classList.add("takeover-topscroller-label"),e.classList.toggle("topscroller-wrapper",!0))},Lo=e=>{const t=document.querySelectorAll(".advertory-welcome-page-elements");Array.from(t).forEach(e=>{e.style.display="flex",e.style.animation="elementsAnimation 1.5s ease-out forwards"});const n=document.querySelector(".advertory-takeover-label");n&&(n.style.display="flex",n.innerText=Qt.se.adText,e.classList.toggle("welcome-page-wrapper",!0))},jo=e=>{const t=document.querySelector(".advertory-takeover-label");t&&(t.style.display="flex",t.innerText=Qt.se.adText,e.classList.toggle("advertory-impact-wrapper",!0))},$o=()=>{const e=document.querySelector(".welcome-page-wrapper, .topscroller-wrapper, .advertory-splash-wrapper");if(!e)return;let t=0;new IntersectionObserver(e=>{e.forEach(e=>{var n;if(e.isIntersecting){window.dispatchEvent(new CustomEvent("advertory:takeoverInView"));(null!==(n=Array.from(e.target.classList))&&void 0!==n?n:[]).includes("advertory-splash-wrapper")&&(()=>{const e=window.scrollY||0;document.body.dataset.scrollY=e.toString(),document.body.style.top="0",document.body.classList.add("page-locked"),document.documentElement.scrollTop=0})(),t++}else t>0&&window.dispatchEvent(new CustomEvent("advertory:takeoverNotInView"))})},{root:null,rootMargin:"0px",threshold:0}).observe(e)},No=(e,t)=>{let n=e;return e.includes("529299503")&&(n=(e=>{const t=document.createElement("script");return t.textContent=`(${wt})()`,e+t.outerHTML})(e)),n},_o=e=>{const t=(e=>{var t;const{requests:n}=window.apntag,o=Dt(e)?1:0;return null===(t=null==n?void 0:n.tags[e].adResponse.ads[o].rtb)||void 0===t?void 0:t.banner.content})(e);if(!t)return;((e,t)=>{const{requests:n}=window.apntag,o=Dt(e)?1:0,i=null==n?void 0:n.tags[e].adResponse.ads[o].rtb;i&&(i.banner.content=t)})(e,No(t))},qo=t=>e(void 0,void 0,void 0,function*(){const{takeover:e}=l.get(),{targetId:n}=t,o=document.querySelector(`#${n}`),i=document.querySelector(".advertory-takeover-wrapper");if(!o||!i||!e)return;const a=(e=>{const{width:t,height:n}=e;return gt(t,n)?ot:nt(e,ze)?rt:ht()?at:it})(t),r=i.offsetHeight,d=window.scrollY>r;i.style.display="block",!d&&wo(a,!1),((e,t)=>{({[it]:Lo,[ot]:Po,[at]:Oo,[rt]:jo})[t](e)})(i,a),$o(),((e,t)=>{({[it]:So,[at]:So,[ot]:Ao,[rt]:Co})[t](e)})(i,a),((e,t,n)=>{if(!n)return;({[it]:()=>{const{buttonLabel:o}=yt(n,t);["#advertory-welcome-page-scroll-label","#advertory-welcome-page-scroll-image"].forEach(t=>{const n=e.querySelector(`${t}`);n&&(n.innerText=null!=o?o:"")})},[ot]:()=>{const{themeColors:o,logotype:i,buttonLabel:a,showArrowIcon:r}=yt(n,t);["#advertory-splash-close-label",".advertory-splash-close","#advertory-splash-logotype",".advertory-splash-navbar-wrapper"].forEach(t=>{const n=e.querySelector(`${t}`);if(n){if("#advertory-splash-close-label"===t&&(n.innerText=null!=a?a:""),".advertory-splash-close"===t&&r){const e=document.createElement("img");e.setAttribute("src","data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAAAfQAAAH0Bx0gPAAAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAAABzSURBVDiNtdPJCYBADEDRzzRmE3ZgEV6tRHHpzELiIQrBZRajA7lk4EE2RIQjgApYgdbmY8EJaADZo3sDBKAvQa4JRYZc5D6pyJiDPMuKTCkkXp8icwxJd1mRxSC1/Q94328luJroGqNrkdyrzAfHVHzOG+8CKlLk+LO+AAAAAElFTkSuQmCC"),e.setAttribute("alt","close ad"),n.appendChild(e)}if("#advertory-splash-logotype"===t&&i&&(n.setAttribute("src",i.url),n.setAttribute("alt",i.alt)),".advertory-splash-navbar-wrapper"===t&&o){const{backgroundColor:e,color:t}=o;n.style.setProperty("background-color",null!=e?e:yo,"important"),n.style.color=null!=t?t:bo}}})},[at]:()=>{const{buttonLabel:o,showArrowIcon:i,showCloseButton:a=!0}=yt(n,t);["#advertory-topscroller-scroll-label","#advertory-topscroller-scroll-image",".advertory-topscroller-close"].forEach(t=>{const n=e.querySelector(`${t}`);n&&(".advertory-topscroller-close"!==t||a||(n.style.display="none"),"#advertory-topscroller-scroll-image"!==t||i||(n.style.display="none"),"#advertory-topscroller-scroll-label"===t&&(n.innerText=null!=o?o:""))})},[rt]:()=>{}})[t]()})(i,a,e),yield mt(),!d&&wo(a,!0),bt(t,a)});Yt(".advertory-brandmetrics-survey{width:100%}");const zo="advertory-brandmetrics-survey",Do=()=>e(void 0,void 0,void 0,function*(){const{norstat:{enabled:t}={},country:n,isMobileApp:o,tcf:i}=l.get(),a=yield A(i,o,n,"norstat");if(!t||o||!a)return;const r=(e=>{const{ppid1:t,ppid2:n}=K.getPPIDs(),{ppid1:o,ppid2:i}=G.getPPIDs(),a=(new W).add(n,M[e]).add(t,B[e]).add(i,R[e]).add(o,F[e]);return`${a.buildNorstatPath()}?${a.buildNorstatQuery("alias").toString()}`})(n);((t,n,...o)=>{e(void 0,[t,n,...o],void 0,function*(e,t,n=!0){if(document.getElementById(t))return;const o=document.createElement("img");o.src=e,o.id=null!=t?t:"",n&&(o.style.display="none"),document.body.appendChild(o)})})(`https://sch-map.norstatsurveys.com/api/nids/${n===x.NO?"schibsted":"schibstedse"}/map/${r}`,"norstat")}),Mo=(e,t)=>t?Object.assign(Object.assign({},e),{"aa-sch-ssa-native-ad":"true","aa-sch-ssa-format":"NATIVE_CONTENT","aa-sch-ssa-market":"XNO","aa-sch-ssa-cat":["ssa_1","ssa_2","ssa_3","ssa_4","ssa_5","ssa_6","ssa_7","ssa_8","ssa_9","ssa_10","ssa_11","ssa_12","ssa_13","ssa_14","ssa_15","ssa_16","ssa_17","ssa_18","ssa_19","ssa_20","ssa_21","ssa_22","ssa_23","ssa_24","ssa_25","ssa_26","ssa_27","ssa_28","ssa_29","ssa_30"]}):e,Bo=e=>`externalImpId:'${e}'`,Ro=e=>{var t;const{forwardExternalImpId:n=!1,tracker:o}=l.get(),i=(e=>{var t;if(!e.positionConfig)return e;const n=e.keywords[`${N()}-count`],o=e.positionConfig.find(e=>e.adPositionIndex===n);if(!o)return e;const i=o.keywords?Object.assign(Object.assign({},e.keywords),o.keywords):e.keywords;return Object.assign(Object.assign({},e),{sizes:null!==(t=null==o?void 0:o.sizes)&&void 0!==t?t:e.sizes,keywords:i})})(e),{id:a,sizes:r,keywords:d,allowedFormats:s,invCode:c,ssa:u=!1,nativeCustomProperties:v,safeframeConfig:g,dynamicSizeWidthCheck:h=!1}=(e=>{var t;if(!e.takeoverCookieCapForSharedPlacement||ut())return e;const n=null===(t=e.keywords)||void 0===t?void 0:t["no-sno-adformat"],o=null==n?void 0:n.filter(e=>e!==at),i=Object.assign(Object.assign({},e.keywords),n&&{"no-sno-adformat":o}),a=e.sizes.filter(([e,t])=>4!==e||4!==t);return Object.assign(Object.assign({},e),{sizes:a,keywords:i})})(i),m=Object.assign({invCode:c,sizes:r,targetId:a,keywords:Mo(d,u),allowedFormats:s,dynamicSizeWidthCheck:h},g&&{safeframeConfig:g}),f=(e=>{var t,n,o,i,a,r,d;return e?(null===(t=null==e?void 0:e.instance)||void 0===t?void 0:t.state)?(null===(o=null===(n=null==e?void 0:e.instance)||void 0===n?void 0:n.state)||void 0===o?void 0:o.pageViewId)?(p("Tracker state pageViewId is:",null===(a=null===(i=null==e?void 0:e.instance)||void 0===i?void 0:i.state)||void 0===a?void 0:a.pageViewId),null===(d=null===(r=null==e?void 0:e.instance)||void 0===r?void 0:r.state)||void 0===d?void 0:d.pageViewId):(p("Tracker state does not contain field pageViewId or it is empty"),""):(p("Tracker state is empty"),""):(p("Tracker is not configured in initAdvertory function"),"")})(o);n&&f&&(p("External Impression ID assigned to defineTag:",Bo(f)),m.externalImpId=Bo(f));const y=(e=>Object.entries({video:{required:!1},address:{required:!1},saleprice:{required:!1},rating:{required:!1},price:{required:!1},phone:{required:!1},likes:{required:!1},downloads:{required:!1},customIcon1:{required:!1},customIcon2:{required:!1},customDisplayUrl1:{required:!1}}).reduce((t,[n,o])=>((null==e?void 0:e.includes(n))&&(t[n]=o),t),{customTitle1:{required:!1},customTitle2:{required:!1},customTitle3:{required:!1},customTitle4:{required:!1},title:{required:!1},body:{required:!1},image:{required:!1},icon:{required:!1},sponsoredBy:{required:!1},cta:{required:!1},clickUrl:{required:!1},desc2:{required:!1},displayUrl:{required:!1},description:{required:!1}}))(v);return(null===(t=e.allowedFormats)||void 0===t?void 0:t.includes("native"))&&(m.native=y),m},Fo=e=>!e.includes("takeover")||ut(),Vo=e=>{const{source:t}=e;return"csm"===t},Uo="native-ad",Ho=e=>{if(!e)return e;const{country:t}=l.get(),n=$(t),o=e[`${n}-targetid`],i=o?de(o[0]):"";return Object.assign(Object.assign({},e),o&&{[`${n}-targetid`]:[i]})},Wo=e=>{const{country:t}=l.get(),n=$(t);return Object.assign(Object.assign(Object.assign(Object.assign({},e),e[`${n}-geo`]&&{[`${n}-geo`]:["geo-test-value"]}),e[`${n}-geofence`]&&{[`${n}-geofence`]:["geofence-test-value"]}),e[`${n}-weather`]&&{[`${n}-weather`]:["weather-test-value"]})},Ko=e=>{(e=>{const t=new URLSearchParams(window.location.search);if("true"!==t.get("scrollToFirstInvCode"))return;const n=t.get("ast_override_inv_code");if(!n)return;const o=n.split(",")[0].split(":")[0],i=e.find(e=>e.invCode===o),a=document.querySelector(`[id^=${null==i?void 0:i.id}]`);a&&a.scrollIntoView({behavior:"smooth",block:"start"})})(e),(()=>{var e;const t=new URLSearchParams(window.location.search).get("scrollToDrEditionPlacement");if(!t)return;const n=null!==(e=document.querySelector(`[id*="${t}}"]`))&&void 0!==e?e:document.querySelector(`a[aria-label*="${t}"]`);n&&n.scrollIntoView({behavior:"smooth",block:"start"})})()},Go=(t,n)=>e(void 0,void 0,void 0,function*(){return yield new Promise(e=>{t().then(t=>{e(null!=t?t:null)}).catch(t=>{e(null)})})}),Jo={arrayMerge:(e,t)=>t},Yo=t=>e(void 0,void 0,void 0,function*(){if(!(e=>{const{editableConfiguration:{useS3Config:t=!1,pageTypeToFetch:n}={},siteSpecificConfig:o}=e;return Boolean(t&&n&&(null==o?void 0:o.publisherClassName))})(t))return t;try{const n=yield(t=>e(void 0,void 0,void 0,function*(){const e=(e=>{const{siteSpecificConfig:t,editableConfiguration:{pageTypeToFetch:n}={}}=e;return(null==t?void 0:t.publisherClassName)&&n?`https://alertory-cdn.staging.inventory.schibsted.io/editable-configurations/${t.publisherClassName}/${n.toUpperCase()}.json`:null})(t);if(!e)return null;const n=new AbortController,o=setTimeout(()=>n.abort(),5e3);try{return yield z.get(e,{method:"GET",signal:n.signal})}catch(t){throw p("Failed to fetch S3 config",{error:t,url:e}),t}finally{clearTimeout(o)}}))(t);return n?(({siteConfig:e,configOverrides:t})=>{var n;const{keywords:o,refresh:a,placements:r,threshold:d,batchSize:s}=t,l=i.all([e.placements,r],Jo),c=i(e.pageOptions,{keywords:o},Jo),p=i(e.appearanceConfig,{defaultThreshold:d},Jo),u=i(null!==(n=e.refreshConfig)&&void 0!==n?n:{},{scrollRefreshEnabled:a},Jo);return Object.assign(Object.assign({},e),{placements:l,requestSize:null!=s?s:e.requestSize,pageOptions:c,appearanceConfig:p,refreshConfig:u})})({siteConfig:t,configOverrides:n}):t}catch(e){return p("Error fetching S3 config, using site config",{error:e}),t}}),Qo=".advertory-right-column-track",Xo="--advertory-right-column-track-height",Zo=e=>e.getBoundingClientRect().top+window.scrollY,ei=e=>{const{marginTop:t,marginBottom:n}=getComputedStyle(e);return e.getBoundingClientRect().height+parseFloat(t||"0")+parseFloat(n||"0")},ti=(e,t)=>{const n=(o=t,`${Math.max(0,Math.round(o))}px`);var o;document.body.style.setProperty(e,n)},ni=(e,t)=>`${e}-${t}`,oi=(e,t,n)=>{var o;const i=Array.from(null!==(o=e.querySelectorAll(t))&&void 0!==o?o:[]),a=(e=>e.map(e=>{var t;return null===(t=document.querySelector(`[id^="${e}"]`))||void 0===t?void 0:t.parentElement}).map((e,t)=>({point:e,originalIndex:t})).filter(e=>Boolean(e.point)))(n);if(0===a.length)return;const r=Zo(e);(()=>{const e=document.querySelector("header");if(!e)return;const t=ei(e);ti("--advertory-newsroom-header-height",t)})(),a.forEach(({point:e,originalIndex:t})=>{((e,t,n)=>{const o=Zo(e),i=ni(Xo,t),a=o-n,r=ni("--advertory-right-column-split-point-height",t),d=ei(e);ti(i,a),ti(r,d)})(e,t+1,r),(e=>{const t=null==e?void 0:e.id;if(!t)return;const n=ni("--advertory-right-column-ad-height",t),o=ei(e);ti(n,o)})(i[t])});((e,t)=>{const n=Zo(e);ti(Xo,n-t)})(a[Math.min(i.length,a.length-1)].point,r)};let ii=!1;class ai{getPulseObjectId(){return"sdrn:vg:content:partnerstudio:element:partnerstudio:stats"}getPulsePageId(){return"sdrn:vg:frontpage:front"}getTags(e){var t;let n;if(n=e instanceof HTMLAnchorElement?e.href:null===(t=null==e?void 0:e.querySelector("a"))||void 0===t?void 0:t.href,!n)return[];const{host:o,pathname:i}=new URL(n);if(!o.includes("www.vg.no")&&!i.includes("annonsorinnhold"))return[n];const a=i.split("/");return a.length?[...a.filter(Boolean).slice(1).map(e=>e),n]:[n]}}class ri{getPulseObjectId(){return""}getPulsePageId(e,t){return""}}class di{constructor(e,t){this.pulse=e,this.newsroomStrategy=t}getEventInput(e,t){return{}}parseKilkayaData(e){const t=e.querySelector("article");if(!t)return{};const n=t.dataset.k5aTeaserAnalytics;try{return n?JSON.parse(n):{}}catch(e){return{}}}mapPageType(e){return{front:"Frontpage",article:"Article",section:"Article",collection:"Article",other:"Article"}[e||"front"]||"Frontpage"}getArticleId(){return location.pathname.split("/").slice(-2,-1).pop()||""}getEventTarget(e){const{url:t,title:n,itemId:o}=this.parseKilkayaData(e);return{id:o,name:this.normalizePlacementTitle(null!=n?n:""),type:"Page",url:t}}normalizePlacementTitle(e){return e.replace(/<[^>]+>/gi,"").replace(/[^a-z0-9æøå\s_-]/gi,"")}trackContentView(t){return e(this,void 0,void 0,function*(){var e,n,o,i,a,r,d,s,l;const c=new CustomEvent("advertory:partnerstudioAdImpression",{detail:{ad:null===(e=this.parseKilkayaData(t))||void 0===e?void 0:e.placement}});if(window.dispatchEvent(c),!this.pulse)return;const p=this.getEventInput(t,"view");(null===(n=this.pulse)||void 0===n?void 0:n.trackLegacyViewUIElement)?null===(i=null===(o=this.pulse)||void 0===o?void 0:o.trackLegacyViewUIElement)||void 0===i||i.call(o,p):(null===(a=this.pulse)||void 0===a?void 0:a.trackViewUIElement)?null===(d=null===(r=this.pulse)||void 0===r?void 0:r.trackViewUIElement)||void 0===d||d.call(r,p):null===(l=null===(s=this.pulse)||void 0===s?void 0:s.trackElementView)||void 0===l||l.call(s,p)})}trackContentClick(t){return e(this,void 0,void 0,function*(){var e,n,o,i,a,r;if(!this.pulse)return;const d=this.getEventInput(t,"click");this.pulse.trackLegacyClickUIElement?null===(n=(e=this.pulse).trackLegacyClickUIElement)||void 0===n||n.call(e,d):this.pulse.trackClickUIElement?null===(i=(o=this.pulse).trackClickUIElement)||void 0===i||i.call(o,d):null===(r=(a=this.pulse).trackElementClick)||void 0===r||r.call(a,d)})}}class si extends di{constructor(e,t,n){super(e,t),this.pulse=e,this.newsroomStrategy=t,this.pageType=n}getEventBaseData(e){var t,n,o,i,a,r;const{clientName:d,creativeId:s,itemId:l,placement:c}=this.parseKilkayaData(e),p=this.mapPageType(this.pageType),u=null===(t=this.newsroomStrategy)||void 0===t?void 0:t.getPulsePageId(this.pageType||"front",this.getArticleId());return{"@id":null!==(i=null===(o=null===(n=this.newsroomStrategy)||void 0===n?void 0:n.getPulseObjectId)||void 0===o?void 0:o.call(n))&&void 0!==i?i:c,"@type":"UIElement",position:c,elementType:"Article",custom:{customer:d,creativeId:null!=s?s:l},page:{"@id":null!=u?u:c,"@type":p,url:location.origin},tags:null===(r=null===(a=this.newsroomStrategy)||void 0===a?void 0:a.getTags)||void 0===r?void 0:r.call(a,e)}}getEventTarget(e){const{link:t,itemId:n,title:o}=this.parseKilkayaData(e);return{id:n,name:this.normalizePlacementTitle(null!=o?o:""),type:"Page",url:t}}getEventInput(e,t){return{object:this.getEventBaseData(e),partnerstudio:this.getEventPartnerstudioData(e,t),target:this.getEventTarget(e),provider:this.getProviderData()}}getEventPartnerstudioData(e,t){const n=this.parseKilkayaData(e);return Object.assign(Object.assign({},n),{type:t,tracking_type:"ad",xandrAdLoaded:!1})}getProviderData(){return{productTag:"partnerstudio"}}}const li="[data-k5a-teaser-analytics]",ci=(e,t,n)=>{const o=document.querySelectorAll("k5a-stream");if(!o.length)return;const i=new si(e,t,n),a=new WeakMap,r=e=>{const t=a.get(e);t&&(t.disconnect(),a.delete(e))},d=new IntersectionObserver((e,t)=>{e.forEach(e=>{if(!e.isIntersecting)return;const n=e.target,o=n.querySelector(li);Boolean(null==o?void 0:o.dataset.k5aTeaserAnalytics)?(i.trackContentView(n),t.unobserve(e.target),r(n)):((e,t)=>{if(a.has(e))return;const n=new MutationObserver(()=>{const n=e.querySelector(li);Boolean(null==n?void 0:n.dataset.k5aTeaserAnalytics)&&(i.trackContentView(e),t.unobserve(e),r(e))});n.observe(e,{attributes:!0,childList:!0,subtree:!0,attributeFilter:["data-k5a-teaser-analytics"]}),a.set(e,n)})(n,t)})},{threshold:.5});o.forEach(e=>{d.observe(e),e.addEventListener("click",()=>i.trackContentClick(e))})};class pi{handleKilkayaStreamTracking({pulse:e,pageType:t,publisher:n}){if(!(null==e?void 0:e.instance))return;const o={[wn.VG]:new ai}[n]||new ri;ci(e.instance,o,t)}injectKilkayaMeta(e){const t=document.createElement("script");t.textContent=`var k5aMeta = { consent: ${e} };`,document.head.appendChild(t)}observeForKilkayaBackfills(){document.addEventListener("K5A:EmptyStreamSlot",e=>{var t;const n=null===(t=null==e?void 0:e.detail)||void 0===t?void 0:t.streamSlot;if(!n)return;const o=n.parentElement;o&&(p(`Kilkaya placement ${n.getAttribute("name")} has not been loaded, loading Xandr backfill`),this.showBackfill(o))})}showBackfill(e){var t;const n=e.querySelector(".fallback");if(!n)return;n.style.display="block";const o=null!==(t=n.dataset.fallbackTargetId)&&void 0!==t?t:"";we(o)}loadKilkayaScript(t){return e(this,void 0,void 0,function*(){yield jt(t)})}run(t){return e(this,void 0,void 0,function*(){const{tcf:e,isMobileApp:n,country:o,kilkaya:i}=t;if(!(null==i?void 0:i.enabled))return;const a=yield A(e,n,o,"kilkaya");a&&(this.observeForKilkayaBackfills(),this.injectKilkayaMeta(a),yield this.loadKilkayaScript(i.url),this.handleKilkayaStreamTracking(t))})}}const ui=1e4,vi=e=>e.some(e=>e.some(e=>!!e&&po(e,0)));let gi;const hi=()=>{const{widescreenSwitching:e}=l.get(),{enabled:t,rotationInterval:n=ui,widescreenIdPrefix:o}=null!=e?e:{};if(!t)return;const i=((e="widescreen")=>{const{pageSectionsSelectors:{right:t}={}}=l.get();return t?Array.from(document.querySelectorAll(t)).map(t=>Array.from(t.querySelectorAll(`div[id^="${e}"]`))):[]})(o);let a=0,r=Date.now(),d=vi(i);if(!i.length)return;gi&&window.removeEventListener("scroll",gi);const s=(e,t,n)=>{e.forEach(e=>{e&&e.style.setProperty(t,n)})},c=e=>1===e?0:1;(e=>{e.forEach(e=>{e[0]&&(e[0].style.display="block",e[0].style.opacity="1"),e[1]&&(e[1].style.display="none",e[1].style.opacity="")})})(i);const p=((e,t)=>{let n=null;return(...o)=>{null===n&&(e(...o),n=setTimeout(()=>{n=null},t))}})(()=>{d||(d=vi(i)||d,r=Date.now());Date.now()-r>=n&&((()=>{const e=c(a),t=i.map(e=>e[a]),n=i.map(t=>t[e]);s(t,"opacity","0"),setTimeout(()=>{s(t,"display","none"),s(n,"opacity","0"),s(n,"display","block"),setTimeout(()=>{s(n,"opacity","1")},450)},450)})(),a=c(a),r=Date.now())},1e3);gi=p,window.addEventListener("scroll",p)};Yt('.advertory-finn-blink-wrapper{height:100%;display:flex !important;align-items:center;justify-content:center}.advertory-finn-blink-wrapper:not(.brandboard-container){width:100%;margin-inline:auto}.advertory-finn-blink{width:100%;height:500px;max-width:580px;display:flex !important;align-items:center;justify-content:center}.advertory-finn-blink::before{content:"" !important}.advertory-finn-blink iframe{max-width:100%}');const mi=e=>document.querySelector(`#${e}`);let fi,yi=[];const bi=["takeover","wallpaper"],wi=e=>{const t=(e=>{const t=Ee.getData("alertoryConfigKeywords"),{queryConfig:n,placements:o,tcf:i,glimr:a,appearanceConfig:r,requestSize:s=d,publisher:l,country:c,pageType:p,deviceType:u,isMobileApp:v=!1,pageOptions:{member:g},takeover:h,fullscreenScroll:m,useAppTabletInvCode:f}=e;return{xandr:{member:g,keywords:t,tags:[]},advertory:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({publisher:l,country:c,pageType:p,deviceType:u,placements:o,tcf:i,requestSize:s,isMobileApp:v,useAppTabletInvCode:f},a&&{glimr:a}),n&&{queryConfig:n}),r&&{appearanceConfig:r}),h&&{takeover:h}),m&&{fullscreenScroll:m})}})(e);window.advertory={initialized:!0,siteConfig:e,alertoryConfig:t}},xi=()=>e(void 0,void 0,void 0,function*(){const{pageOptions:t}=l.get(),{preparePageOptions:n}=l.getHandlers(),o=(()=>{const{sandboxAdIframeEnabled:e=!0}=l.get();return{sandboxAdIframe:e,sandboxAttributes:["allow-same-origin","allow-scripts","allow-top-navigation-by-user-activation","allow-popups","allow-popups-to-escape-sandbox","allow-forms"]}})(),i=yield e(void 0,void 0,void 0,function*(){const{tcf:e,isMobileApp:t,country:n}=l.get();return(yield A(e,t,n,"page-options"))?{}:{userSync:{disabled:!0}}}),a=yield n(Object.assign(Object.assign(Object.assign({disablePsa:!0,enableSafeFrame:!0},t),{renderingManagement:Object.assign({},o)}),i));(e=>{const t=Ee.getData("alertoryConfigKeywords");if(Object.keys(t).length)return;const n=Wo(e);Ee.setData("alertoryConfigKeywords",n)})(a.keywords),ce(()=>fi.setPageOpts(a))}),Ei=t=>e(void 0,void 0,void 0,function*(){const{prebid:e,tcf:n,isMobileApp:o,country:i}=l.get(),a=yield A(n,o,i,"loadPlacements"),r=((e,t)=>t?e:(e.filter(e=>!e.supportsNonRTB).forEach(e=>be(e.id)),e.filter(e=>e.supportsNonRTB).map(e=>{return Object.assign(Object.assign({},e),{invCode:(t=e.invCode,`${t}_non_rtb`)});var t})))(t,a);ki(r);(null==e?void 0:e.enabled)&&a&&!ye()?(p("core loadPlacements prebid enabled"),yield dn()):(p("core load tags invoked without prebid enabled"),Ti(r))}),ki=e=>{const{prepareTag:t}=l.getHandlers(),n=[];(e=>{const t=["skyscraperright_1","topboard","wallpaper","skyscraperleft_1"];return e.sort((e,n)=>{const o=t.findIndex(t=>e.id.includes(t)),i=t.findIndex(e=>n.id.includes(e));return-1!==o&&-1===i?-1:-1===o&&-1!==i?1:o-i})})(e).forEach(e=>{p("core defineTags",{placement:e});const o=Ro(e);if(Fo(e.id)){const i=t(o),a=(e=>{const{allowedFormats:t,invCode:n,keywords:o,sizes:i}=e;return{adTypes:t,invCode:n,keywords:Ho(o),sizes:i}})(i);n.push(a),ce(()=>(p("core defineTag - add to the queue",{placement:e,preparedTag:i}),fi.defineTag(i)))}}),(e=>{var t,n,o;(null===(o=null===(n=null===(t=window.advertory)||void 0===t?void 0:t.alertoryConfig)||void 0===n?void 0:n.xandr)||void 0===o?void 0:o.tags)&&e.length&&window.advertory.alertoryConfig.xandr.tags.push(e)})(n)},Ti=e=>{const t=e.filter(({id:e})=>Fo(e)).map(({id:e})=>e);t.length&&ce(()=>(p("core loadTags",{placementsIdsToLoad:t}),fi.loadTags([...t])))},Ii=(t,n)=>e(void 0,void 0,void 0,function*(){const{appearanceConfig:e,deviceType:o}=l.get(),{threshold:i,refresh:a}=t,r=(e=>{const t=document.querySelector(`[data-show-tag-subscribe-id=${e.targetId}]`),n=document.querySelector(`#${e.targetId}`);return t||n})(n),d=null==e?void 0:e.defaultThreshold[o];r&&(p("core showAd - subscribe for show tag with thresholds",{placement:t,adObj:n,threshold:i,deviceDefaultThreshold:d}),yield Xn(r,null!=i?i:d)),r&&a&&(p("core showAd - setup refreshing",{placement:t,adObj:n}),r.dataset.refresh=a.toString())}),Ai=e=>e.some(({id:e})=>bi.some(t=>e.includes(t))),Si=t=>e(void 0,void 0,void 0,function*(){var n;if(!(null===(n=null===window||void 0===window?void 0:window.advertory)||void 0===n?void 0:n.initialized))return;const[o,i]=(e=>e.reduce(([e,t],n)=>{var o;return(null===(o=null==n?void 0:n.finnBlink)||void 0===o?void 0:o.loadOnlyFinnBlink)?[[...e,n],t]:[e,[...t,n]]},[[],[]]))(t),a=(e=>{const{requestSize:t=d,queryConfig:{placementBatches:n}={},deviceType:o}=l.get(),i=Le(e),a=Object.keys((null==n?void 0:n[o])||{}).map(e=>i[e]||[]).filter(e=>e.length>0),r=new Set(a.flat().map(({id:e})=>e)),s=e.filter(({id:e})=>!r.has(e));return[...a,...lo(s,t)]})(i);for(const e of a)Ai(e)?(p("core loadAds without lazy loading",{placementsToLoad:e}),yield Ei(e)):e.length&&(p("core loadAds with lazy loading",{placementsToLoad:e}),yield Ci(e));yield(t=>e(void 0,void 0,void 0,function*(){if(!t.length)return;const{appearanceConfig:e,deviceType:n}=l.get(),o=null==e?void 0:e.defaultThreshold[n];for(const e of t){const{threshold:t,id:n}=e,i=mi(n);i&&(yield Xn(i,null!=t?t:o))}}))(o)}),Ci=t=>e(void 0,void 0,void 0,function*(){const{queryConfig:{lazyLoadingV3:{enabled:e=!1,rootMargin:n="200% 0px"}={}}={}}=l.get(),o=[];if(!e)return p("lazy load is not enabled",{placements:t}),void(yield Ei(t));const i=new IntersectionObserver((e,n)=>{e.filter(({isIntersecting:e,target:{id:t}})=>e&&!t.includes("wallpaper")).forEach(e=>{p("lazy load is enabled - handler start",{loadedPlacementIds:o,placements:t});const i=t.every(e=>o.includes(e.id)),a=t.map(e=>e.id);!i&&o.push(...a),!i&&Ei(t),p("lazy load is enabled - handler stop",{loadedPlacementIds:o,placements:t,arePlacementsLoaded:i,placementIds:a}),n.disconnect()})},{rootMargin:n});t.forEach(e=>{const t=document.getElementById(e.id);t&&(p("lazy loading - observe element",{placementId:e.id,element:t}),i.observe(t))})}),Pi=()=>e(void 0,void 0,void 0,function*(){const{siteEvents:t,initNativeAd:n,wallpaperHandlers:{initWallpaperAd:o,adjustAdToHorseshoe:i}}=l.getHandlers(),{wallpaper:a,fullscreenScroll:r}=l.get(),d=[];ce(()=>{fi.onEvent("adRequested",()=>{t.adRequested()}),fi.onEvent("adAvailable",i=>e(void 0,void 0,void 0,function*(){var e,d,s,c,u,v;p("core adAvailable start",{placementsAvailable:yi,adObj:i,isFullscreenScrollAd:Fe(i),isFinnBlink:Ye(i.targetId),isNativeAd:Ve(i),isMediation:Vo(i),isTakeoverAd:He(i),isCollapseAd:Ge(i),isWallpaperAd:Ke(i)});const g=null===(s=null===(d=null===(e=null===window||void 0===window?void 0:window.apntag)||void 0===e?void 0:e.requests)||void 0===d?void 0:d.tags[i.targetId])||void 0===s?void 0:s.adResponse.ads;Vo(i)&&g&&(null===(c=g[1])||void 0===c?void 0:c.rtb)&&(i.banner=null===(v=null===(u=g[1])||void 0===u?void 0:u.rtb)||void 0===v?void 0:v.banner),Fe(i)&&on(i),Ze(i)&&hi(),Fe(i)&&!Ye(i.targetId)&&nn(i,r),!Ve(i)||Vo(i)||Ye(i.targetId)||n(i,l.get()),He(i)&&!Ge(i)&&(_o(i.targetId),yield qo(i)),Ke(i)&&(o(()=>ce(()=>window.apntag.showTag(i.targetId)),a),Ee.setData("wallpaper",{isAvailable:!0})),(e=>e.targetId.includes("skyscraperleft")&&!!e.banner)(i)&&Ee.setData("horseshoe",{isAvailable:!0}),Et({adObj:i}),(e=>{var t;const n=null==e?void 0:e.targetId;if(!n)return;const o=null===(t=document.querySelector(`#${n}`))||void 0===t?void 0:t.parentElement;o&&((e,t)=>{const{height:n,width:o,native:i}=e;i?t.dataset.adSizes="[1,1]":n&&o&&(t.dataset.adSizes=`[${o},${n}]`)})(e,o)})(i),t.adAvailable(i);const h=yi.find(({id:e})=>e===i.targetId);h&&(yield Ii(h,i),yi=yi.filter(e=>e.id!==h.id)),p("core adAvailable stop",{placementsAvailable:yi,adObj:i,isFullscreenScrollAd:Fe(i),isFinnBlink:Ye(i.targetId),isNativeAd:Ve(i),isMediation:Vo(i),isTakeoverAd:He(i),isCollapseAd:Ge(i),isWallpaperAd:Ke(i)})})),fi.onEvent("adLoaded",e=>{const{refreshConfig:o,appearanceConfig:a}=l.get(),r=document.getElementById(e.targetId);Ye(e.targetId)&&(e=>{const{fullscreenScroll:t}=l.get(),{initNativeAd:n}=l.getHandlers();Fe(e)&&nn(e,t),Ve(e)&&n(e,l.get())})(e);d.includes(e.targetId)&&Ve(e)&&(n(e,l.get()),Et({adObj:e})),!d.includes(e.targetId)&&Vo(e)&&d.push(e.targetId),Ge(e)&&be(e.targetId),He(e)&&((e,t)=>{var n;const o="100%",i="100%";e.resizeAd(t,[o,i]);const a=null===(n=document.querySelector(`#div_utif_${t}`))||void 0===n?void 0:n.querySelector("iframe");if(!a)return;new MutationObserver(e=>{for(const t of e)if("attributes"===t.type&&"style"===t.attributeName){const e=window.getComputedStyle(a),t=e.width,n=e.height;t===o&&n===i||(a.style.width=o,a.style.height=i)}}).observe(a,{attributes:!0,attributeFilter:["style"]})})(fi,e.targetId),Ue(e)&&(e=>{const t=document.querySelector(`#${e.targetId}`),{siteSpecificConfig:{publisherClassName:n,fullWidthFormatClassName:o}={}}=l.get();if(!t||!n||!o)return;const i=t.parentElement;i&&(t.classList.add(`advertory-${n}-${o}__full-width-ad`),i.classList.add(`advertory-${n}-${o}-wrapper__full-width-ad`))})(e),(e=>nt(e,Ne))(e)&&(e=>{var t;const n=document.querySelector(`#${e.targetId}`),o=null===(t=document.querySelector(`#${e.targetId}`))||void 0===t?void 0:t.parentElement,i=null==n?void 0:n.querySelector("iframe"),a=null==i?void 0:i.parentElement,{siteSpecificConfig:{publisherClassName:r,fullWidthFormatClassName:d}={}}=l.get();if(!(n&&i&&a&&o))return;o.classList.add(`advertory-${r}-${d}__vertical-full-width-ad-wrapper`);const s=window.innerWidth,c=Math.round(s/1080*1920);n.style.width="100%",n.style.height=`${c}px`,n.classList.add(`advertory-${r}-${d}__vertical-full-width-ad`);const p=Tt(e,n.offsetWidth);a.style.transform=`scale(${p})`,a.style.transformOrigin="left top"})(e),((e,t)=>{if(!(null==t?void 0:t.scrollRefreshEnabled))return;const{targetId:n}=e,o=document.querySelector(`#${n}`),i=null==o?void 0:o.parentElement;if(!i||!o)return;ao({adWrapper:i,placementContainer:o});const{delayTime:a=1e3}=t,r=(new Date).getTime();o&&"true"!==o.dataset.subscribedForRefresh&&(o.dataset.subscribedForRefresh="true",o.dataset.refresh&&so(o,r,a))})(e,o),(null==a?void 0:a.clearProbableDimensionsEnabled)&&(e=>{const t=document.querySelector(`#${e}`);t&&(t.style.minWidth="",t.style.minHeight="")})(e.targetId);Ee.getData("horseshoe").isAvailable&&i(e.targetId),(e=>{var t,n,o,i,a,r;const{adScaleConfig:d,deviceType:s}=l.get();if(!(null==d?void 0:d.enabled))return;if(nt(e,$e))return;const c=null!==(t=d.adsToBeScaled[s])&&void 0!==t?t:[],p=Se(e.targetId.split("-")[0]);if(!c.includes(p))return;const u=null!==(o=null===(n=d.offset)||void 0===n?void 0:n[p])&&void 0!==o?o:0,v=document.getElementById(e.targetId),g=null!==(i=null==v?void 0:v.offsetWidth)&&void 0!==i?i:window.screen.width,h=null!==(r=null===(a=null==v?void 0:v.parentElement)||void 0===a?void 0:a.offsetWidth)&&void 0!==r?r:window.screen.width;It(e,(g<h?g:h)-u)})(e),t.adLoaded(e),an(e.targetId),r&&(r.classList.add(rn),(e=>{var t,n;const{siteSpecificConfig:o}=l.get(),i=null!==(t=null==o?void 0:o.mainColumnWidth)&&void 0!==t?t:1/0;e.clientWidth>i&&(null===(n=e.parentElement)||void 0===n||n.setAttribute("data-two-column-ad-layout","true"))})(r)),St(e),window.dispatchEvent(new CustomEvent("advertory:adLoaded",{detail:{targetId:e.targetId,adFormat:kt(e)}}))}),fi.onEvent("adNoBid",n=>e(void 0,void 0,void 0,function*(){be(n.targetId),yield qn(l.get(),n),ft(n)&&(yield mt()),t.adNoBid(n)})),fi.onEvent("adError",(n,o)=>e(void 0,void 0,void 0,function*(){ft(o)&&(yield mt()),t.adError(n,o)})),fi.onEvent("adCollapse",()=>{t.adCollapse()}),fi.onEvent("adRequestFailure",n=>e(void 0,void 0,void 0,function*(){be(n.targetId),yield qn(l.get(),n),t.adRequestFailure(n)})),fi.onEvent("adBadRequest",n=>e(void 0,void 0,void 0,function*(){be(n.targetId),yield qn(l.get(),n),t.adBadRequest(n)})),fi.onEvent("adLoadedMediated",e=>t.adLoadedMediated(e)),fi.onEvent("adNoBidMediated",n=>e(void 0,void 0,void 0,function*(){yield qn(l.get(),n),t.adNoBidMediated(n)}))})}),Oi=(t,n)=>e(void 0,void 0,void 0,function*(){var o;l.set(t),l.setHandlers(n),Ee.initialize(),window.addEventListener("message",Gn,!1),fi=window.apntag||{anq:[],defineTag:e=>({targetId:""}),showTag:e=>{},onEvent:(e,t,n)=>{},offEvent:(e,t)=>{},refresh:e=>{},modifyTag:(e,t)=>{},loadTags:e=>{},emitEvent:(e,t)=>{},setPageOpts:e=>{},resizeAd:(e,t,n)=>{},getAstVersion:()=>"",setEndpoint:(e,t)=>{},fireImpressionTrackers:e=>{},setKeywords:()=>{},clearRequest:()=>{}},window.apntag=fi,p("Apn tag is set up on window"),yield Promise.allSettled([e(void 0,void 0,void 0,function*(){const{tcf:e,isMobileApp:t,country:n}=l.get();(yield A(e,t,n,"xandr-endpoint"))||fi.setEndpoint("ib.adnxs-simple.com",!0)}),e(void 0,void 0,void 0,function*(){if(ye())return;const{prebid:e,tcf:t,isMobileApp:n,country:o}=l.get(),i=yield A(t,n,o,"prebid");(null==e?void 0:e.enabled)&&i&&(yield jt(null==e?void 0:e.url))}),J(t),e(void 0,void 0,void 0,function*(){const{astUrl:e}=l.get();yield jt(null!=e?e:"https://adsdk.microsoft.com/ast/ast.js")}),e(void 0,void 0,void 0,function*(){const{gptUrl:e,tcf:t,isMobileApp:n,country:o}=l.get();(yield A(t,n,o,"gpt-endpoint"))&&(yield jt(null!=e?e:"https://securepubads.g.doubleclick.net/tag/js/gpt.js"))}),e(void 0,void 0,void 0,function*(){const{brandmetrics:{enabled:e,url:t}={},tcf:n,isMobileApp:o,country:i}=l.get(),{getConsentAsync:a}=I(n,0,i),r=yield a();if(e&&t&&r){if(yield jt(t),document.querySelector(`.${zo}`))return window._brandmetrics=window._brandmetrics||[],void window._brandmetrics.push({cmd:"_loadsurvey"});new MutationObserver((e,t)=>{for(const n of e){if("childList"!==n.type)return;Array.from(n.addedNodes).some(e=>{var t;return null===(t=e.outerHTML)||void 0===t?void 0:t.includes(zo)})&&(t.disconnect(),window._brandmetrics=window._brandmetrics||[],window._brandmetrics.push({cmd:"_loadsurvey"}))}}).observe(document,{childList:!0,subtree:!0,attributes:!0})}}),C(),e(void 0,void 0,void 0,function*(){const{gdpr:{url:e,allowHidingAds:t=!0}={}}=l.get();t&&(window.gdpr=window.gdpr||{},window.gdpr.allowHidingAds=!0),yield jt(null!=e?e:"https://cogwheel.inventory.schibsted.io/prod/latest/gdpr-bundle.js")})]),yield Do(),p("Libraries have been loaded and trackers have been set"),yield(o=n.librariesToLoad,e(void 0,void 0,void 0,function*(){const e=o.map(e=>jt(e));yield Promise.all(e)})),yield Pi(),yield xi(),p("Page options have been set"),wi(t),p("Advertory is setup on window"),yi=Pe(),uo(yi),go(yi),yield Si(yi),p("Ads has been loaded",yi),zn(t,yi),Ko(yi),yield n.replaceAdsWithFinnBlink(t.finnBlink),yield(t=>e(void 0,void 0,void 0,function*(){var e;if(!t.drEdition)return;if(!(yield A(t.tcf,t.isMobileApp,t.country,"handleDrEdition")))return;const n=yield Ln(),o=new jn(n);$n({publisher:t.publisher,drEditionConfig:t.drEdition,device:t.deviceType,pageType:t.pageType,country:t.country},o,null===(e=t.pulse)||void 0===e?void 0:e.instance)}))(t),(e=>{if(!(null==e?void 0:e.enabled)||ii)return;const{splitPointIDs:t,adSelector:n,trackSelector:o=Qo}=e,i=document.querySelector(o);if(!i)return;ii=!0;const a=()=>{oi(i,n,t)};a(),window.addEventListener("resize",a),window.addEventListener("orientationchange",a),window.addEventListener("load",a),window.addEventListener("advertory:adLoaded",()=>{requestAnimationFrame(a)}),new ResizeObserver(a).observe(i)})(t.rightColumnSplit),yield(t=>e(void 0,void 0,void 0,function*(){const e=new pi;yield e.run(t)}))(t)}),Li=(t,n)=>e(void 0,void 0,void 0,function*(){yield((t,n)=>e(void 0,void 0,void 0,function*(){const{initConsentManager:e,getConsentAsync:o}=I(t.tcf,t.isMobileApp,t.country),i=yield Yo(t);yield Nn(),yield Go(e),yield Go(o),p("TCF resolved successfully"),yield Oi(i,n),p("Run function resolved successfully")}))(t,n)}),ji=()=>{if(!window.location.search.includes("kv_"))return{};const e={},t=(()=>{const e=new URLSearchParams(window.location.search);return Object.fromEntries(e)})();return Object.keys(t).forEach(n=>{n.startsWith("kv_")&&(e[n.slice(3)]=t[n])}),e},$i=e=>{const{siteSpecificConfig:t}=l.get(),n=(null==t?void 0:t.dynamicOutstreamFormats)||[];return 0!==n.length&&n.some(t=>e.includes(t))},Ni={publisherClassName:wn.PENT,fullWidthFormatClassName:"netboard"},_i=(e,t,n,o)=>{var i;const{image:a,icon:r,sponsoredBy:d,title:s,clickUrl:l,cta:c,body:p,desc2:u,video:v,description:g,customTitle1:h,customTitle2:m,customTitle3:f,customTitle4:y,customIcon1:b,customIcon2:w,customDisplayUrl1:x}=e,E=(e,t="")=>{var n;return e?null!==(n=e.url)&&void 0!==n?n:e:t};return Object.assign({containerId:n,img:E(a),imgWidth:null==a?void 0:a.width,imgHeight:null==a?void 0:a.height,imgAltText:null!=s?s:"",logo:(()=>{var e;const t=(null==u?void 0:u.includes("sponsor"))&&"dark"===(null===(e=o.appearanceConfig)||void 0===e?void 0:e.theme)&&b;return E(t?b:r)})(),sponsoredBy:null!=d?d:"",title:null!=s?s:"",url:null!=l?l:"",cta:null!=c?c:"",description:null!==(i=null!=p?p:g)&&void 0!==i?i:"",desc2:null!=u?u:"",video:v,customTitle1:null!=h?h:"",customTitle2:null!=m?m:"",customTitle3:null!=f?f:"",customTitle4:null!=y?y:"",logo2:E(w),previewVideoSrc:null!=x?x:""},t)},qi=(e,t)=>{const n=(o=b,window.location.href.includes(o));var o;const i=new URLSearchParams(window.location.search).get(b),a=t.includes("native_recirc");return n&&i?i:(null==e?void 0:e.includes("recirc"))?a?"native_recirc":"recirc":(null==e?void 0:e.includes("sponsor"))?"sponsorstripe":null},zi=(e,t,n,o)=>{const i=document.querySelector(`#${e}`);i&&t&&(i.innerHTML=t,((e,t)=>{const n=e.parentElement,{publisher:o,pageType:i}=t,a=o&&Object.values(wn).includes(o);n&&a&&((e,t,n,o)=>{const i=t.parentElement;if(!i)return;const a=e?`-${e}`:"",r=o?`__${o}`:"",d=`advertory${a}-${n}${r}`,s=`advertory${a}-${n}-wrapper${r}`;t.classList.remove(...t.classList),i.classList.remove(...i.classList),t.classList.add(d),i.classList.add(s),t.dataset.adType=n})(o,e,Uo,i)})(i,n),o())},Di=e=>{var t;const n=document.querySelector(`#${e.targetId}`);if(!n||!(null===(t=e.native)||void 0===t?void 0:t.clickTrackers))return;(null==n?void 0:n.querySelectorAll("a.ad-link")).forEach(t=>{"true"!==t.dataset.tracked&&(t.addEventListener("click",()=>{var t,n;for(const o of null!==(n=null===(t=e.native)||void 0===t?void 0:t.clickTrackers)&&void 0!==n?n:[])Fi(o)}),t.dataset.tracked="true")})},Mi=e=>{const{native:{impressionTrackers:t}={}}=e;(null==t?void 0:t.some(e=>e.includes("googleads")))?null==t||t.forEach(Ri):window.apntag.fireImpressionTrackers(e);const n=new CustomEvent("advertory:nativeImpression",{detail:{ad:e}});window.dispatchEvent(n)},Bi=(e,t)=>{var n;let o=!1;const i=document.querySelector(`#${e.targetId}`);if(!i||!e.native)return;const{deviceType:a,appearanceConfig:r,nativeTrackingConfig:{fireImpressionsBasedOnAppearanceThreshold:d=!1}={}}=t,s=d?{rootMargin:`${l=null!==(n=null==r?void 0:r.defaultThreshold[null!=a?a:Z.DESKTOP])&&void 0!==n?n:0}px 0px ${l}px 0px`}:{};var l;const c=new IntersectionObserver(t=>{if(!o)for(const n of t)if(n.isIntersecting){o=!0,Mi(e),c.disconnect();break}},s);c.observe(i)},Ri=e=>{const t=e.includes("googleads");"function"!=typeof window.navigator.sendBeacon||t?Fi(e):window.navigator.sendBeacon(e)},Fi=e=>{fetch(e,{method:"GET",mode:"no-cors"}).catch(t=>console.warn(`Tracker ${e} failed. Error: ${t||"Unknown"}`))},Vi=(e,t,n)=>{const o=((e,t,n)=>{var o;const{displayTemplates:i,videoTemplates:a}=n,r="default";if(!e.native)return null;const{native:d,targetId:s}=e,{desc2:l=r}=e.native,c=l.toLowerCase(),p=null!==(o=qi(e.targetId,l))&&void 0!==o?o:c,u=Qt[t.language||x.NO],v=_i(d,u,s,t);return(d.video?a[p]:i[p]||i.default)(v,t)})(e,t,n);zi(e.targetId,o,t,()=>{const{nativeTrackingConfig:{nativeTrackingEnabled:n=!0}={}}=t;n&&((e,t)=>{Di(e),Bi(e,t)})(e,t)})};Yt('@import"https://fonts.googleapis.com/css?family=Roboto:400,500&display=swap";.advertory-shared-ad-native-content-display-basic{width:100%;font-family:Roboto,sans-serif;color:#6d747e;text-align:left;background:#fff;position:relative;margin:0 auto;display:flex;flex-direction:column}.advertory-shared-ad-native-content-display-basic *{line-height:normal}.advertory-shared-ad-native-content-display-basic .ad-info{top:0;right:8px;position:absolute}.advertory-shared-ad-native-content-display-basic .ad-info>div{position:initial !important}.advertory-shared-ad-native-content-display-basic .ad-link{text-decoration:none}.advertory-shared-ad-native-content-display-basic .ad-link:hover{text-decoration:none}.advertory-shared-ad-native-content-display-basic .ad-header{padding:5px 16px;background-color:#ffcd00;font-size:12px;text-transform:uppercase;color:#495057;font-weight:600}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper{display:flex;flex-direction:column}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-large-image-container{position:relative;padding-bottom:40%}@media screen and (min-width: 768px){.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-large-image-container{display:none}}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-large-image-container .ad-large-image-wrapper{position:absolute;height:100%;width:100%}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-large-image-container .ad-large-image-wrapper .ad-large-image{object-fit:cover;min-width:100%;height:100%}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-content{box-sizing:border-box;display:flex;background-color:#fffae6}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-content .ad-text-container{flex-grow:1;padding:16px}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-content .ad-text-container .ad-title{font-size:20px;color:#212529;font-weight:600;margin-bottom:16px}@media screen and (min-width: 768px){.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-content .ad-text-container .ad-title{font-size:22px}}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-content .ad-text-container .ad-sponsor{font-size:11px;color:gray;font-weight:600;text-transform:uppercase}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-content .ad-small-image-container{display:none;max-width:175px}@media screen and (min-width: 768px){.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-content .ad-small-image-container{display:block}}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-content .ad-small-image-container .ad-small-image{object-fit:cover;max-width:100%}.advertory-shared-ad-native-content-display-basic.article .ad-info{top:0;right:0;position:absolute;border-bottom-left-radius:50%;background:hsla(0,0%,100%,.6)}.advertory-shared-ad-native-content-display-basic.article .ad-info>div{position:initial !important}.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-small-image-container{display:block}.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-text-container{padding:8px 16px;border-left:4px solid #ffcd00}.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-text-container .ad-header-wrapper{display:flex;margin-bottom:8px}@media screen and (min-width: 768px){.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-text-container .ad-header-wrapper{margin-bottom:16px}}.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-text-container .ad-header-wrapper .ad-header{padding:2px 4px;font-size:11px}.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-text-container .ad-title{font-size:15px;margin-bottom:8px}@media screen and (min-width: 768px){.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-text-container .ad-title{font-size:18px;margin-bottom:16px}}.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-small-image-container{padding:16px 8px 16px 0}@media screen and (min-width: 768px){.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-small-image-container{padding:0}}.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-small-image-container .ad-small-image{object-fit:contain}@media screen and (min-width: 768px){.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-small-image-container .ad-small-image{object-fit:cover}}'),Yt(".advertory-shared-ad-native-video{width:100%;min-height:250px;height:auto;margin:auto;text-align:left;position:relative;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;text-decoration:none;display:table;table-layout:fixed}@media screen and (min-width: 768px){.advertory-shared-ad-native-video{width:580px}}.advertory-shared-ad-native-video .ad-info{position:absolute;top:2px;right:24px}.advertory-shared-ad-native-video .ad-info .gdprAdTransparencyCogWheelButton{background-color:rgba(0,0,0,0);border-bottom-right-radius:13px;z-index:10}.advertory-shared-ad-native-video a.ad-link{display:block;text-decoration:none;color:#2b2b2b}.advertory-shared-ad-native-video a.ad-link:hover{text-decoration:none}.advertory-shared-ad-native-video .ad-content .ad-header{font-size:12px;padding:5px 8px;color:#4c3d00;background:rgba(255,205,0,.8);font-weight:bold}.advertory-shared-ad-native-video .ad-content .ad-image-container{position:relative;line-height:0}@media screen and (min-width: 768px){.advertory-shared-ad-native-video .ad-content .ad-image-container{min-height:300px}}.advertory-shared-ad-native-video .ad-content .ad-image-container .ad-player-wrapper{height:56.4971751412vw;width:100%}@media screen and (min-width: 768px){.advertory-shared-ad-native-video .ad-content .ad-image-container .ad-player-wrapper{height:326px}}.advertory-shared-ad-native-video .ad-content .ad-text-container{background:#fff6d1;overflow:auto;padding-bottom:15px;padding-left:8px}@media screen and (min-width: 768px){.advertory-shared-ad-native-video .ad-content .ad-text-container{background:#fff6d1;padding-left:16px;overflow:auto}}.advertory-shared-ad-native-video .ad-content .ad-text-container .sponsored-by{margin:8px 16px 8px 0;color:#64625a;font-size:10px;text-transform:uppercase;display:block;font-weight:600}@media screen and (min-width: 768px){.advertory-shared-ad-native-video .ad-content .ad-text-container .sponsored-by{font-size:12px}}.advertory-shared-ad-native-video .ad-content .ad-text-container .title{line-height:1;margin:8px 0;font-weight:bold;font-size:20px;font-family:Arial,sans-serif}@media screen and (min-width: 768px){.advertory-shared-ad-native-video .ad-content .ad-text-container .title{font-size:22px}}"),Yt(".advertory-abo-ad-native-video{width:100%;min-height:250px;margin:auto;color:#000;font-family:-apple-system,BlinkMacSystemFont,sans-serif;font-weight:600;text-align:left;position:relative;box-sizing:border-box;text-decoration:none;display:table;table-layout:fixed}.advertory-abo-ad-native-video *{box-sizing:border-box;line-height:normal;text-transform:none}@media screen and (min-width: 768px){.advertory-abo-ad-native-video{width:580px;height:400px}}.advertory-abo-ad-native-video .ad-info{position:absolute;height:26px;width:26px;top:20px;left:0;z-index:1000;background-color:hsla(0,0%,100%,.4509803922);border-bottom-right-radius:13px;transform:none;transform-origin:center}@media screen and (min-width: 768px){.advertory-abo-ad-native-video .ad-info{top:30px}}.advertory-abo-ad-native-video .ad-info .gdprAdTransparencyCogWheelButton{background-color:rgba(0,0,0,0);border-bottom-right-radius:13px;z-index:10}.advertory-abo-ad-native-video .ad-content .ad-image-container{position:relative;line-height:0}.advertory-abo-ad-native-video .ad-content .ad-image-container .ad-header{position:absolute;height:20px;width:100%;font-size:13px;line-height:20px;color:#4c3d00;background:rgba(255,205,0,.8);z-index:100}.advertory-abo-ad-native-video .ad-content .ad-image-container .ad-header span{margin-left:8px}@media screen and (min-width: 768px){.advertory-abo-ad-native-video .ad-content .ad-image-container .ad-header{height:30px;line-height:30px;padding-left:16px}.advertory-abo-ad-native-video .ad-content .ad-image-container .ad-header span{margin:0}}.advertory-abo-ad-native-video .ad-content .ad-image-container .ad-player-wrapper{height:56.4971751412vw;width:100%}@media screen and (min-width: 768px){.advertory-abo-ad-native-video .ad-content .ad-image-container .ad-player-wrapper{height:326px}}.advertory-abo-ad-native-video .ad-content .ad-text-container{background:#fff6d1;overflow:auto}.advertory-abo-ad-native-video .ad-content .ad-text-container .sponsored-by{color:#64625a;font-size:10px;margin:8px 8px 3px 8px;text-transform:uppercase;display:block}@media screen and (min-width: 768px){.advertory-abo-ad-native-video .ad-content .ad-text-container .sponsored-by{font-size:13px;margin:8px 16px}}.advertory-abo-ad-native-video .ad-content .ad-text-container .ad-link{text-decoration:none;display:flex;flex-direction:column}.advertory-abo-ad-native-video .ad-content .ad-text-container .ad-link,.advertory-abo-ad-native-video .ad-content .ad-text-container .ad-link:focus,.advertory-abo-ad-native-video .ad-content .ad-text-container .ad-link:hover,.advertory-abo-ad-native-video .ad-content .ad-text-container .ad-link:visited{color:#000}.advertory-abo-ad-native-video .ad-content .ad-text-container .ad-link .ad-title{margin:0 8px 7px 8px;min-height:52px;line-height:24px;color:#000;font-size:20px;font-weight:700;display:flex;flex-direction:column}@media screen and (min-width: 768px){.advertory-abo-ad-native-video .ad-content .ad-text-container .ad-link .ad-title{font-size:22px;margin:0 16px 9px 16px;height:35px;min-height:auto;line-height:35px;overflow:hidden;-ms-text-overflow:ellipsis;text-overflow:ellipsis;white-space:nowrap;display:block}}.advertory-abo-ad-native-video .ad-content .ad-text-container .ad-link .ad-description{display:none;border-top:1px solid rgba(128,128,128,.5019607843);margin:0 8px 12px 8px;padding-top:8px;color:#6a6a6a;font-style:normal;font-weight:normal;font-size:12px;line-height:14px}@media screen and (min-width: 768px){.advertory-abo-ad-native-video .ad-content .ad-text-container .ad-link .ad-description{font-size:13px;margin:8px 16px;line-height:16px}}"),Yt('@import"https://fonts.googleapis.com/css?family=Inter:400,600&display=swap";.advertory-abo-ad-native-podme-section{height:130px;background:linear-gradient(90deg, #23375e 0%, #041426 104.93%);border-radius:11px}@media screen and (min-width: 768px){.advertory-abo-ad-native-podme-section{height:202px}}.advertory-abo-ad-native-podme-section .ad-link{text-decoration:none;color:initial;background-color:rgba(0,0,0,0);cursor:pointer}.advertory-abo-ad-native-podme-section .ad-content-wrapper{display:flex;height:100%;font-family:"Inter",sans-serif;font-style:normal;font-weight:normal}.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-text-container{display:flex;flex-direction:column;width:428px;margin:18px 3px 8px 18px;font-family:"Inter",sans-serif;font-style:normal;font-weight:normal}@media screen and (min-width: 768px){.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-text-container{margin:41px 28px 41px 41px}}.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-text-container .ad-title{font-weight:600;color:#fff;font-size:calc(12px + 11*(100vw - 300px)/468);line-height:16px;margin-bottom:7px}@media screen and (min-width: 768px){.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-text-container .ad-title{font-size:23px;line-height:28px;margin-bottom:15px}}.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-text-container .ad-description{color:#17e1e3;font-size:calc(10px + 8*(100vw - 300px)/468);font-weight:normal;line-height:14px}@media screen and (min-width: 768px){.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-text-container .ad-description{font-size:18px;font-weight:500;line-height:22px}}.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-small-image-container{display:flex;-webkit-box-pack:center;justify-content:center;-webkit-box-align:center;align-items:center;max-width:253px;min-width:100px;height:100%;margin:0 auto}@media screen and (min-width: 768px){.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-small-image-container{min-width:250px}}.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-small-image-container .ad-small-image{max-width:100%;max-height:100%;object-fit:fill}.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-logo{display:none}@media screen and (min-width: 768px){.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-logo{display:flex;-webkit-box-pack:center;justify-content:center;-webkit-box-align:center;align-items:center;max-width:162px;height:100%;margin:0 16px}}.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-logo .logo{max-width:100%;max-height:100%;object-fit:fill}'),Yt('.advertory-abo-ad-native-default{width:calc(100% - 32px);min-height:250px;margin:auto;color:#000;font-family:-apple-system,BlinkMacSystemFont,sans-serif;font-weight:600;text-align:left;position:relative;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;text-decoration:none;display:table;table-layout:fixed}.advertory-abo-ad-native-default *{box-sizing:border-box;line-height:normal;text-transform:none}@media screen and (min-width: 768px){.advertory-abo-ad-native-default{width:580px;height:400px}}.advertory-abo-ad-native-default .ad-info{position:absolute;top:20px;height:26px;width:26px;left:0;z-index:1000;background-color:hsla(0,0%,100%,.4509803922);border-bottom-right-radius:13px;transform:none;transform-origin:center}@media screen and (min-width: 768px){.advertory-abo-ad-native-default .ad-info{top:30px}}.advertory-abo-ad-native-default .ad-link{display:block;text-decoration:none;color:#000;background-color:rgba(0,0,0,0)}.advertory-abo-ad-native-default .ad-content{display:block}.advertory-abo-ad-native-default .ad-image-container{position:relative;line-height:0}.advertory-abo-ad-native-default .ad-image-container .ad-header{position:absolute;height:20px;width:100%;font-size:13px;line-height:20px;color:#4c3d00;background:rgba(255,205,0,.8)}@media screen and (min-width: 768px){.advertory-abo-ad-native-default .ad-image-container .ad-header{height:30px;line-height:30px;padding-left:16px}}.advertory-abo-ad-native-default .ad-image-container .ad-header span{margin-left:8px}@media screen and (min-width: 768px){.advertory-abo-ad-native-default .ad-image-container .ad-header span{margin:0}}.advertory-abo-ad-native-default .ad-image-container .ad-image{position:static;width:100%;height:52.3560209424vw}@media screen and (min-width: 768px){.advertory-abo-ad-native-default .ad-image-container .ad-image{height:301px}}.advertory-abo-ad-native-default .ad-image-container .ad-logo{position:absolute;height:30px;width:auto;top:auto;bottom:8px;left:8px;right:auto}@media screen and (min-width: 768px){.advertory-abo-ad-native-default .ad-image-container .ad-logo{left:16px;bottom:16px}}.advertory-abo-ad-native-default .ad-text-container{background:#fff6d1;overflow:auto}.advertory-abo-ad-native-default .ad-text-container .ad-sponsored-by{color:#64625a;font-size:10px;margin:8px 8px 3px 8px;text-transform:uppercase;display:block}@media screen and (min-width: 768px){.advertory-abo-ad-native-default .ad-text-container .ad-sponsored-by{font-size:13px;margin:8px 16px}}.advertory-abo-ad-native-default .ad-text-container .ad-title{margin:0 8px 7px 8px;min-height:52px;line-height:24px;color:#000;font-size:20px;font-weight:700;display:flex;flex-direction:column;justify-content:center}@media screen and (min-width: 768px){.advertory-abo-ad-native-default .ad-text-container .ad-title{font-size:24px;margin:0 16px 8px 16px;height:59px;min-height:auto;line-height:normal;overflow:hidden}}.advertory-abo-ad-native-default.bt .ad-text-container .ad-title{font-family:"TabacG2",serif;font-weight:500}'),Yt('.advertory-abo-ad-native-sponsorstripe{position:absolute;top:0;left:0;width:100%;height:1px;background:inherit;padding:0;margin:0;border:none;text-align:left}.advertory-abo-ad-native-sponsorstripe .ad-wrapper{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:center;max-width:980px;height:30px;padding:5px 15px;margin:auto;font-family:"Helvetica Neue",Arial,Roboto,sans-serif}.advertory-abo-ad-native-sponsorstripe .ad-logo{flex:0;height:20px;max-width:35%;max-height:inherit}.advertory-abo-ad-native-sponsorstripe .ad-title{margin-right:10px;padding-left:34px;font-size:13px;color:#fff}.advertory-abo-ad-native-sponsorstripe .info-button-wrapper{display:grid;position:absolute;place-content:center;height:30px;min-width:30px}.advertory-abo-ad-native-sponsorstripe .info-button-wrapper .info-button{display:inline-block;height:20px;width:20px;position:relative;border:solid 1px #fff;border-radius:50%;cursor:pointer}.advertory-abo-ad-native-sponsorstripe .info-button-wrapper .info-button:before{content:"i";color:#fff;position:absolute;left:50%;top:50%;transform:translate(-50%, -50%);font-size:13px}.advertory-abo-ad-native-sponsorstripe .ad-description{font-size:13px;color:#fff;position:absolute;top:0;max-width:980px;min-height:30px;padding:15px 35px 15px 15px;margin-left:-15px;background-color:rgba(0,0,0,.9)}.advertory-abo-ad-native-sponsorstripe .ad-description .close-button-wrapper{position:absolute;top:15px;right:15px;place-content:center;height:16px;min-width:16px}.advertory-abo-ad-native-sponsorstripe .ad-description .close-button-wrapper .close-button{display:inline-block;height:16px;width:16px;position:relative;border:1px solid #fff;border-radius:50%;cursor:pointer}.advertory-abo-ad-native-sponsorstripe .ad-description .close-button-wrapper .close-button:before{content:"✕";color:#fff;position:absolute;left:50%;top:50%;transform:translate(-50%, -50%);font-size:10px;font-weight:bold}.advertory-abo-ad-native-sponsorstripe .ad-description .ad-description-readmore{color:#c7ecff}.advertory-abo-ad-native-sponsorstripe .ad-description.hide{display:none}@media screen and (min-width: 768px){.advertory-abo-ad-native-sponsorstripe .ad-wrapper{height:50px}.advertory-abo-ad-native-sponsorstripe .ad-wrapper .ad-description{min-height:50px}.advertory-abo-ad-native-sponsorstripe .ad-logo{height:40px}.advertory-abo-ad-native-sponsorstripe .ad-title{font-size:20px;padding-left:40px}.advertory-abo-ad-native-sponsorstripe .info-button-wrapper .info-button{height:30px;width:30px;border-width:2px}.advertory-abo-ad-native-sponsorstripe .info-button-wrapper .info-button:before{font-size:20px}}'),Yt(".advertory-abo-ad-native-recirc{width:100%;min-height:250px;margin:auto;color:#000;text-align:left;position:relative;box-sizing:border-box;text-decoration:none;display:table;table-layout:fixed}@media screen and (min-width: 768px){.advertory-abo-ad-native-recirc{max-width:283px;height:400px}}.advertory-abo-ad-native-recirc .ad-info{position:absolute;top:0;height:26px;width:26px;left:0;z-index:1000;background-color:hsla(0,0%,100%,.4509803922);border-bottom-right-radius:13px;transform:none;transform-origin:center}.advertory-abo-ad-native-recirc .ad-link{display:block;text-decoration:none;color:#000;background-color:rgba(0,0,0,0)}.advertory-abo-ad-native-recirc .ad-content{display:block}.advertory-abo-ad-native-recirc .ad-image-container{position:relative;line-height:0}.advertory-abo-ad-native-recirc .ad-image-container .ad-header{height:30px;font-size:13px;line-height:30px;font-weight:600;color:#4c3d00;background:rgba(255,205,0,.8);padding-left:32px;font-family:-apple-system,BlinkMacSystemFont,sans-serif;border-top-right-radius:10px;border-top-left-radius:10px}.advertory-abo-ad-native-recirc .ad-image-container .ad-image{width:100%}.advertory-abo-ad-native-recirc .ad-image-container .ad-logo{position:absolute;height:30px;width:auto;top:auto;bottom:8px;left:8px;right:auto}@media screen and (min-width: 768px){.advertory-abo-ad-native-recirc .ad-image-container .ad-logo{left:16px;bottom:16px}}.advertory-abo-ad-native-recirc .ad-text-container{background:#fff6d1;overflow:auto;border-bottom-right-radius:10px;border-bottom-left-radius:10px}.advertory-abo-ad-native-recirc .ad-text-container .ad-sponsored-by{display:block;color:#64625a;font-size:13px;padding:5px 8px;text-transform:uppercase;font-family:Roboto,sans-serif}.advertory-abo-ad-native-recirc .ad-text-container .ad-title{padding:6px 8px;margin-bottom:12px;color:#000;font-size:17px;font-weight:700;font-family:Arial,sans-serif}"),Yt('.advertory-abo-ad-native-content-video{position:relative;display:table;table-layout:fixed;width:100%;margin:0 auto;background:#fff;font-family:"Inter",sans-serif;font-weight:700;text-align:left;color:#000}.advertory-abo-ad-native-content-video *{line-height:1}.advertory-abo-ad-native-content-video a.ad-link{display:block;text-decoration:none;color:inherit}.advertory-abo-ad-native-content-video a.ad-link:hover{text-decoration:none}.advertory-abo-ad-native-content-video .ad-info{z-index:10;top:44px}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-info{top:50px}}.advertory-abo-ad-native-content-video .ad-info div[role=button]{top:44px !important;border-bottom-right-radius:13px;background-color:hsla(0,0%,100%,.45);z-index:10}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-info div[role=button]{top:51px !important}}.advertory-abo-ad-native-content-video .ad-content{display:flex;flex-direction:column}.advertory-abo-ad-native-content-video .ad-content .ad-header{position:relative;height:44px;display:flex;align-items:center;text-transform:uppercase;padding:0 8px}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-content .ad-header{height:51px;min-height:0}}.advertory-abo-ad-native-content-video .ad-content .ad-header span{font-weight:700;font-size:13px;position:absolute;top:50%;transform:translateY(-50%)}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-content .ad-header span{font-size:20px;padding-left:12px}}.advertory-abo-ad-native-content-video .ad-content .ad-header .ad-logo{position:absolute;right:0;width:auto;height:40px;margin-right:8px}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-content .ad-header .ad-logo{width:auto;height:35px}}.advertory-abo-ad-native-content-video .ad-content .ad-image-container{display:flex;position:relative}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-content .ad-image-container{min-height:0}}.advertory-abo-ad-native-content-video .ad-content .ad-image-container .ad-image{width:100%;height:auto;object-fit:cover;object-position:center 0}.advertory-abo-ad-native-content-video .ad-content .ad-image-container .ad-player-wrapper{height:56.4971751412vw;width:100%}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-content .ad-image-container .ad-player-wrapper{height:407px}}.advertory-abo-ad-native-content-video .ad-content .ad-text-container{display:flex;flex-direction:column;color:#2b2b2b;padding-bottom:10px}.advertory-abo-ad-native-content-video .ad-content .ad-text-container .sponsored-by{display:block;padding:8px;font-size:12px;font-weight:normal;text-transform:uppercase}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-content .ad-text-container .sponsored-by{padding:8px 10px}}.advertory-abo-ad-native-content-video .ad-content .ad-text-container .ad-title{display:block;padding:0 8px;margin-left:0;margin-bottom:0;font-size:var(--mobileTitleSize);font-weight:bold;line-height:1}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-content .ad-text-container .ad-title{padding:4px 12px 8px 12px;font-size:var(--desktopTitleSize)}}.advertory-abo-ad-native-content-video .ad-content .ad-text-container .ad-description{margin:4px 0;padding:0 8px;font-size:16px;line-height:calc(15px);color:#000}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-content .ad-text-container .ad-description{padding:0 12px}}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video.bt .ad-content .ad-image-container .ad-player-wrapper,.advertory-abo-ad-native-content-video.sa .ad-content .ad-image-container .ad-player-wrapper{height:302px}}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video.bt .ad-content .ad-text-container .ad-title,.advertory-abo-ad-native-content-video.sa .ad-content .ad-text-container .ad-title{font-size:23px}}'),Yt('.advertory-no-ad-native-default{width:calc(100% - 32px);min-height:250px;margin:auto;color:#dfdfdf;font-family:"Inter",sans-serif;font-weight:600;text-align:left;position:relative;box-sizing:border-box;text-decoration:none;display:table;table-layout:fixed;font-size:14px}@media screen and (min-width: 768px){.advertory-no-ad-native-default{width:580px;height:400px}}.advertory-no-ad-native-default *{box-sizing:border-box;line-height:normal;text-transform:none}.advertory-no-ad-native-default .ad-info{position:absolute;top:0;left:0;height:26px;width:26px;z-index:1000;background-color:#dfdfdf;border-bottom-right-radius:13px;transform:none;transform-origin:center}.advertory-no-ad-native-default .ad-link{display:block;text-decoration:none;color:#000;background-color:rgba(0,0,0,0);border:1px solid #dfdfdf}.advertory-no-ad-native-default .ad-content{display:block}.advertory-no-ad-native-default .ad-image-container{background-color:#dfdfdf;display:flex;position:relative;line-height:0}.advertory-no-ad-native-default .ad-image-container .ad-image{position:static;width:100%;aspect-ratio:1.91;height:auto}.advertory-no-ad-native-default .ad-text-container{background:#f5faff;overflow:auto;padding:8px}@media screen and (min-width: 768px){.advertory-no-ad-native-default .ad-text-container{padding:12px 16px}}.advertory-no-ad-native-default .ad-text-container .ad-sponsor{font-size:12px;margin:0;text-transform:uppercase;display:block}@media screen and (min-width: 768px){.advertory-no-ad-native-default .ad-text-container .ad-sponsor{font-size:14px;margin-right:8px}}.advertory-no-ad-native-default .ad-text-container .ad-sponsor .ad-label{font-weight:600;color:#fff;background-color:#467aae;display:inline-block;padding:4px 6px;border-radius:4px;border:none;margin-right:4px}.advertory-no-ad-native-default .ad-text-container .ad-title{margin:4px 0 0 0;line-height:normal;color:#000;font-size:18px;display:flex;flex-direction:column;justify-content:center}@media screen and (min-width: 768px){.advertory-no-ad-native-default .ad-text-container .ad-title{margin:12px 0 0 0;font-size:28px}}.advertory-vg-native-ad__front .advertory-no-ad-native-default{width:100%;height:auto}.advertory-aftenposten-native-ad-wrapper__front{justify-content:center}.advertory-e24-native-ad-wrapper__article{margin-bottom:calc(-40px + 4rem)}@media screen and (min-width: 768px){.advertory-e24-native-ad-wrapper__article{margin-bottom:calc(12px + .75rem)}}');Yt('.advertory-no-ad-native-recirc{width:100%;min-height:250px;margin:0 auto;color:#000;text-align:left;position:relative;box-sizing:border-box;text-decoration:none;display:table;table-layout:fixed;background-color:#fff;font-family:"Inter",sans-serif;font-weight:600;text-align:left;font-size:14px;container-type:inline-size}.advertory-no-ad-native-recirc *{box-sizing:border-box;line-height:normal;text-transform:none}.advertory-no-ad-native-recirc .ad-info{position:absolute;top:0;left:0;height:26px;width:26px;z-index:1000;background-color:#dfdfdf;border-bottom-right-radius:13px;transform:none;transform-origin:center}.advertory-no-ad-native-recirc .ad-link{display:block;text-decoration:none;color:#000;background-color:rgba(0,0,0,0);border:1px solid #dfdfdf}.advertory-no-ad-native-recirc .ad-content{display:flex;flex-direction:column}.advertory-no-ad-native-recirc .ad-image-container{background-color:#dfdfdf;display:flex;position:relative;line-height:0}@container (min-width: dna.$md){.advertory-no-ad-native-recirc .ad-image-container{min-height:0}}.advertory-no-ad-native-recirc .ad-image-container .ad-image{position:static;width:100%;aspect-ratio:1.91;height:auto}.advertory-no-ad-native-recirc .ad-text-container{background:#f5faff;overflow:auto;padding:8px;container-type:inline-size}@container (min-width: dna.$md){.advertory-no-ad-native-recirc .ad-text-container{padding:12px 16px}}.advertory-no-ad-native-recirc .ad-text-container .ad-sponsor{font-size:12px;margin:0;text-transform:uppercase;display:block}@container (min-width: dna.$md){.advertory-no-ad-native-recirc .ad-text-container .ad-sponsor{font-size:14px;margin-right:8px}}.advertory-no-ad-native-recirc .ad-text-container .ad-sponsor .ad-label{font-weight:600;color:#fff;background-color:#467aae;display:inline-block;padding:4px 6px;border-radius:4px;border:none;margin-right:4px}.advertory-no-ad-native-recirc .ad-text-container .ad-title{margin:4px 0 0 0;line-height:normal;color:#000;font-size:18px;display:flex;flex-direction:column;justify-content:center}@container (min-width: 420px){.advertory-no-ad-native-recirc .ad-text-container .ad-title{margin:12px 0 0 0;font-size:28px}}'),Yt('.advertory-no-ad-native-seamless .ad-info div[role=button]{left:100%;transform:translateX(-100%);background-color:hsla(0,0%,100%,.45);border-bottom-left-radius:13px}.advertory-no-ad-native-seamless .ad-link{text-decoration:none;color:inherit}.advertory-no-ad-native-seamless .ad-link .ad-content{min-width:320px;height:100%;margin:0 auto;padding:8px 8px 0;font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;border-radius:10px;background-color:var(--color-background-secondary, #ffffff);color:var(--color-text-primary, #333)}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-header{padding:8px 10px 10px 10px}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-header .ad-brand{display:flex;align-items:center;gap:12px;margin-bottom:11px}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-header .ad-brand .ad-logo{max-height:44px;border-radius:50%}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-header .ad-brand .ad-brand-text{display:flex;flex-direction:column;gap:3px;align-items:start}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-header .ad-brand .ad-brand-text .sponsored-by{font-size:16px;font-weight:500;line-height:1}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-header .ad-brand .ad-brand-text .ad-annons{font-size:14px;font-weight:400;line-height:1.1;color:var(--color-text-primary, #333);text-transform:lowercase}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-header .ad-brand .ad-brand-text .ad-annons::first-letter{text-transform:uppercase}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-header .ad-headline{margin:0;font-size:16px;font-weight:400;line-height:1.2;word-spacing:-1px;text-align:left}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-image-container{width:100%;aspect-ratio:1/1;overflow:hidden;display:flex;justify-content:center;align-items:center}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-image-container .ad-image{height:100%;width:auto;object-fit:cover}@media screen and (min-width: 768px){.advertory-no-ad-native-seamless .ad-link .ad-content .ad-image-container{aspect-ratio:1.91/1}}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-footer{display:flex;flex-direction:column;justify-content:center;padding:13px 10px}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-footer .ad-row{display:flex;align-items:center;justify-content:space-between}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-footer .ad-row .ad-text-wrapper{display:flex;flex-direction:column;gap:5px;flex-grow:1;padding-right:8px;align-items:start}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-footer .ad-row .ad-text-wrapper .ad-domain{font-size:11px;line-height:1;color:#666;text-transform:uppercase;text-align:left;font-weight:500}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-footer .ad-row .ad-text-wrapper .ad-description{font-size:15.5px;font-weight:500;text-align:left;word-spacing:-1px;color:var(--color-text-primary, #111111)}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-footer .ad-row .ad-action{flex-shrink:0;padding:10px 14px;font-size:12px;line-height:1;color:var(--color-text-primary, #111111);white-space:nowrap;background-color:var(--color-background-tertiary, #d9d9d9);border-radius:12px;font-weight:500}.advertory-aftenposten-native-ad-wrapper__front:has(.advertory-no-ad-native-seamless),.advertory-aftenposten-native-ad__front:has(.advertory-no-ad-native-seamless),.advertory-bt-native-ad-wrapper__front:has(.advertory-no-ad-native-seamless),.advertory-bt-native-ad__front:has(.advertory-no-ad-native-seamless),.advertory-sa-native-ad-wrapper__front:has(.advertory-no-ad-native-seamless){max-width:100%}');const Ui={NATIVE_TEMPLATE:({containerId:e,url:t,sponsoredBy:n,title:o,img:i,adText:a})=>`<article class="advertory-no-ad-native-default">\n <div class="ad-info" id="${e}-button"></div>\n <a class="ad-link" href="${t}" target="_self">\n <div class="ad-content">\n <div class="ad-image-container">\n <img alt="${o}" class="ad-image" src="${i}" />\n </div>\n <div class="ad-text-container">\n <div class="ad-sponsor">\n <span class="ad-label">${a}</span> ${n}\n </div>\n <div class="ad-title">${o}</div>\n </div>\n </div>\n </a>\n </article>`},Hi={displayTemplates:{default:Ui.NATIVE_TEMPLATE},videoTemplates:{}},Wi=((e,t)=>n=>Li(Object.assign(Object.assign({},n),{siteSpecificConfig:t}),e))({initNativeAd:(e,t)=>{const{targetId:n}=e;if(!document.querySelector(`#${n}`))return;const{pageType:o=xn.FRONT,nativeTrackingConfig:i,appearanceConfig:a,deviceType:r}=null!=t?t:{},d={language:x.NO,publisher:wn.PENT,deviceType:r,pageType:o,nativeTrackingConfig:i,appearanceConfig:a};Vi(e,d,Hi)},wallpaperHandlers:{initWallpaperAd:(e,t)=>{if(!t)return;const{options:{appMainContainerSelector:n,wallpaperAnchorSelector:o}={}}=t;(e=>{const t=document.querySelector(e||"#application");if(!t)return;he();const n=document.createElement("div");n.classList.add(ve),document.body.insertBefore(n,t.nextSibling),n.style.setProperty("position","fixed"),n.style.setProperty("width","100%"),n.style.setProperty("height","calc(100% - var(--header-height, 0px) - 15px)"),n.style.setProperty("background-position","center top"),n.style.setProperty("background-repeat","no-repeat")})(n),(e=>{const t=e||".advertory-wrapper-common-skyscraperleft_1",n=document.querySelector(t);n&&(me(n),window.addEventListener("scroll",()=>me(n)))})(o),e()},adjustAdToHorseshoe:e=>{var t;const n=document.querySelector(`#${e}`);n&&(null===(t=n.parentElement)||void 0===t||t.classList.add(ge),n.classList.add(ge))}},loadFinnBlinkAd:le,replaceAdsWithFinnBlink:le,preparePageOptions:ie,prepareTag:e=>{const{keywords:t,targetId:n,invCode:o}=e,{useAppTabletInvCode:i=!0}=l.get(),a=((e,t)=>{const{isMobileApp:n}=l.get();return n?((e,t)=>e.replace(/wtb|wde|wph/g,e=>"wph"===e?"aph":t?"atb":e))(e,t):e})(o,i),r=(e=>{const{country:t}=l.get(),{keywords:n,dynamicSizeWidthCheck:o}=e,i=`${$(t)}-adformat`,a=n?n[i]:[];if(!a)return{};const r=(Array.isArray(a)?a:[a]).filter(e=>!(e in Re)||window.innerWidth>=Re[e]);return{[i]:o?r:a}})(e),d=(e=>{const{country:t}=l.get(),n=`${$(t)}-targetid`;return e?{[n]:[e]}:{}})(n),s=ji(),c=(e=>$i(e)?{"aa-sch-dynamic-outstream":["true"]}:{})(o),p=((e,t)=>$i(e)?Object.assign(Object.assign({},t),{playerSkin:{videoBackgroundColor:"#e6e7e8"}}):{})(o);return Object.assign(Object.assign({},e),{invCode:a,keywords:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},t),r),d),c),s),rendererOptions:p})},siteEvents:Ct,librariesToLoad:[]},Ni),Ki=Yt("[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-slider-time,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-slider-time{display:none}[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container{padding:0 6px;height:36px}[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-icon-fullscreen,[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-settings-sharing,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-icon-fullscreen,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-settings-sharing{display:none}[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-icon,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-icon{margin-right:3px;height:unset;width:unset;bottom:0}[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-icon-volume,[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-icon-playback,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-icon-volume,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-icon-playback{display:flex}");var Gi=Object.freeze({__proto__:null,default:Ki});exports.initAdvertoryPackage=Wi,exports.updateAdvertory=(t,n)=>e(void 0,void 0,void 0,function*(){var e;if(!(null===(e=null===window||void 0===window?void 0:window.advertory)||void 0===e?void 0:e.initialized))return[];const{clearAds:o,reloadExistingAds:i,renderFinnBlinkPlacements:a,contextSelector:r}=null!=n?n:{};if(o)return Ie(),[];i&&(Ie(),document.querySelectorAll('[data-advertory-ad-rendered="true"]').forEach(e=>{we(e.id)})),c(null!=t?t:{}),yield xi();let d=Pe(r);return a&&(d=d.filter(e=>Ye(e.id))),d.length>0&&(yi=[...yi,...d.map(e=>Object.assign({},e))],uo(d),go(d),yield Si(d)),yi});
1
+ "use strict";function e(e,t,n,i){return new(n||(n=Promise))(function(o,r){function a(e){try{s(i.next(e))}catch(e){r(e)}}function d(e){try{s(i.throw(e))}catch(e){r(e)}}function s(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(a,d)}s((i=i.apply(e,t||[])).next())})}function t(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var n,i;require("react/jsx-runtime"),"function"==typeof SuppressedError&&SuppressedError;var o=t(function(){if(i)return n;i=1;var e=function(e){return function(e){return!!e&&"object"==typeof e}(e)&&!function(e){var n=Object.prototype.toString.call(e);return"[object RegExp]"===n||"[object Date]"===n||function(e){return e.$$typeof===t}(e)}(e)},t="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function o(e,t){return!1!==t.clone&&t.isMergeableObject(e)?l((n=e,Array.isArray(n)?[]:{}),e,t):e;var n}function r(e,t,n){return e.concat(t).map(function(e){return o(e,n)})}function a(e){return Object.keys(e).concat(function(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[]}(e))}function d(e,t){try{return t in e}catch(e){return!1}}function s(e,t,n){var i={};return n.isMergeableObject(e)&&a(e).forEach(function(t){i[t]=o(e[t],n)}),a(t).forEach(function(r){(function(e,t){return d(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))})(e,r)||(d(e,r)&&n.isMergeableObject(t[r])?i[r]=function(e,t){if(!t.customMerge)return l;var n=t.customMerge(e);return"function"==typeof n?n:l}(r,n)(e[r],t[r],n):i[r]=o(t[r],n))}),i}function l(t,n,i){(i=i||{}).arrayMerge=i.arrayMerge||r,i.isMergeableObject=i.isMergeableObject||e,i.cloneUnlessOtherwiseSpecified=o;var a=Array.isArray(n);return a===Array.isArray(t)?a?i.arrayMerge(t,n,i):s(t,n,i):o(n,i)}return l.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(e,n){return l(e,n,t)},{})},n=l}());const r=["deviceType","pageType","placements","takeover","refreshConfig","editableConfiguration"],a={adRequested:()=>{},adAvailable:e=>{},adLoaded:e=>{},adNoBid:e=>{},adError:(e,t)=>{},adCollapse:()=>{},adRequestFailure:e=>{},adBadRequest:e=>{},adLoadedMediated:e=>{},adNoBidMediated:e=>{}},d=6;class s{set(e){this.config=e}modifyConfigProperties(e){if(!this.config)throw new Error("Config was accessed before it had been initialized.");const t={};for(const n of r){const i=e[n];void 0!==i&&(t[n]=i)}Object.assign(this.config,t),Object.prototype.hasOwnProperty.call(e,"pageOptions")&&void 0!==e.pageOptions&&(this.config.pageOptions=Object.assign(Object.assign({},this.config.pageOptions),e.pageOptions)),Object.prototype.hasOwnProperty.call(e,"tcf")&&void 0!==e.tcf&&(this.config.tcf=Object.assign(Object.assign({},this.config.tcf),e.tcf))}get(){if(!this.config)throw new Error("Config was accessed before it had been initialized.");return this.config}getHandlers(){if(!this.siteHandlers)throw new Error("Handlers were accessed before it had been initialized.");return this.siteHandlers}setHandlers(e){this.siteHandlers=o(s.DEFAULT_SITE_HANDLERS,e)}}s.DEFAULT_SITE_HANDLERS={siteEvents:a,initNativeAd:function(){}};const l=new s,c=l.modifyConfigProperties.bind(l),p=(e,t)=>{const n="[Advertory LOG]: ";location.search.includes("ast_debug=true")&&(t?console.log(n,e,t):console.log(n,e))},u=864e5,v=(()=>{const e=e=>{const t=window.localStorage.getItem(e);if(!t)return null;try{return JSON.parse(t)}catch(e){return p("Error with parsing localStorage data"),null}},t=(e,t)=>{window.localStorage.setItem(e,JSON.stringify(t))};return{get:e,set:t,setWithTimestamp:(e,n,i=u)=>{const o={data:n,expirationTime:(new Date).getTime()+i};t(e,JSON.stringify(o))},getByTimestamp:(t,n=u)=>{const i=e(t);if(!i)return null;if(!n)return i;try{const{expirationTime:e,data:t}=JSON.parse(i);return(new Date).getTime()<=e?t:null}catch(e){return p("Error with parsing localStorage data"),null}}}})(),g="glimrTags",h=["glwe_","glwet_"],m={geofenceTags:[],geoTags:[],weatherTags:[]},f=e=>new URLSearchParams(window.location.search).get(e),y="takeover",b="native_override_desc2",w=e=>new Promise(t=>{if(!window._tcf_||!(null==e?void 0:e.enabled))return void t(!1);const n=(()=>{if(!window._tcf_)return null;const e=window._tcf_.getPermissionSync("CMP:advertising");if(null===e)return null;const t=Number(e);return p("Advertising permission value obtained synchronously: ",e),Boolean(t)})();if(null!==n)return void t(n);let i=!1;const o=e=>{i||(p("Resolving advertising permission value obtained"),i=!0,t(e))},r=setTimeout(()=>{p("Advertising permission timed out, resolving with false"),o(!1)},3e3);window._tcf_.onTcfReady(()=>{p("On Tcf Ready called, waiting for permission"),clearTimeout(r)}),window._tcf_.getPermission("CMP:advertising",e=>{clearTimeout(r);const t=Number(e);p("Advertising permission value obtained asynchronously: ",e),o(Boolean(t))})}),x={NO:"no",SE:"se"},k="cmp:loaded";let E="undefined"!=typeof window?window._tcf_:void 0,T=!1;const I=(t,n,i)=>{const o=!!(null==t?void 0:t.enabled),r=(null==t?void 0:t.timeout)||3e3,a=f("bypass_tcf"),d=()=>{if(!(null==t?void 0:t.enabled))return!0;if(((e,t)=>e?!!t&&(p("TCF bypass param detected, returning consent: true"),!0):(p("TCF is not enabled, returning consent: true"),!0))(o,a))return!0;if(T)return null;if(!E)throw new Error("[Advertory]: getConsentSync method was called before the tcfManager was available.");const e=E.getConsentedToAllSync();return p(`TCF consented to all is: ${e}`),E.getConsentedToAllSync()};return{initConsentManager:()=>(null==t?void 0:t.enabled)?new Promise((e,t)=>{if(p("Getting TCF consent manager..."),window._tcf_)return p("TCF consent manager is already available"),E=window._tcf_,void e(E);p("TCF consent manager is not available");const n=()=>{p("CMP loaded, resolving consent manager..."),i&&clearTimeout(i),window._tcf_?(E=window._tcf_,e(E)):t(new Error("CMP loaded but window._tcf_ is not defined"))},i=setTimeout(()=>{document.removeEventListener(k,n),T=!0,t(new Error("Timeout waiting for CMP to load"))},r);p("Listening for CMP loaded event..."),document.addEventListener(k,n,{once:!0})}):Promise.resolve(null),getConsentSync:d,getConsentAsync:()=>e(void 0,void 0,void 0,function*(){if(null==t?void 0:t.schibstedAdChoicesOverrideValue)return p(`Schibsted Ad Choices override value is set, returning override value: ${t.schibstedAdChoicesOverrideValue}`),Boolean(Number(t.schibstedAdChoicesOverrideValue));const e=(null==t?void 0:t.schibstedAdChoicesEnabled)&&i===x.SE,n=(null==t?void 0:t.schibstedAdChoicesEnabled)&&i===x.NO;if(e||n)return p("Schibsted Ad Choices is enabled, getting advertising permissions..."),yield w(t);if(!(null==t?void 0:t.enabled))return!0;const o=d();return null!==o?o:yield new Promise((e,t)=>{try{if(!E)throw new Error("[Advertory]: getConsentAsync method was called before the tcfManager was available.");let t=!1;const n=n=>{t||(t=!0,e(n))},i=setTimeout(()=>{p("TCF isConsentedToAll timed out, resolving with false"),n(!1)},r);E.onTcfReady(()=>{p("On Tcf Ready called, waiting for consent"),clearTimeout(i)}),E.isConsentedToAll(t=>{clearTimeout(i),e(t)})}catch(e){t(e)}})})}},A=(t,n,i,...o)=>e(void 0,[t,n,i,...o],void 0,function*(e,t,n,i="NOT SPECIFIED FEATURE"){if(!(null==e?void 0:e.schibstedConsentToPayEnabled))return p(`Schibsted Consent to Pay is not enabled, returning true for ${i}`),!0;if(null==e?void 0:e.schibstedAdChoicesOverrideValue)return p(`Schibsted Ad Choices override value is set, returning override value: ${null==e?void 0:e.schibstedAdChoicesOverrideValue} for ${i}`),Boolean(Number(null==e?void 0:e.schibstedAdChoicesOverrideValue));const{getConsentAsync:o}=I(e,0,n);return(yield o())?(p(`Schibsted Ad Choices consent given according to TCF consent manager for ${i}`),!0):(p(`Schibsted Ad Choices consent not given according to TCF consent manager for ${i}`),!1)}),S=(...t)=>e(void 0,[...t],void 0,function*(e=l.get()){const{tcf:t,isMobileApp:n,country:i}=e;if(null==t?void 0:t.schibstedConsentToPayEnabled){return yield A(t,n,i,"glimr")}const{getConsentAsync:o}=I(t,0,i);return yield o()}),C=()=>e(void 0,void 0,void 0,function*(){const{glimr:t}=l.get();if(!(yield S())||!(null==t?void 0:t.enabled))return void p("No consent for glimr data fetching.");const n=yield(i=500,e(void 0,void 0,void 0,function*(){return yield Promise.race([e(void 0,void 0,void 0,function*(){const e=yield import("glimr-sdk");return e.default||e}),new Promise(e=>setTimeout(()=>e(!1),i))])}));var i;if(n)try{n.setTagCacheTimeInSeconds(300),yield new Promise(e=>{n.getTags(t.clientId,(t,n)=>{v.setWithTimestamp(g,{tags:t,tagMappings:n}),e(!0)})})}catch(e){p(`Error during getting glimr data: ${e}`)}else p("Timeout (500ms) while loading glimr package. Skipping glimr data fetching.",{glimr:n})}),P={svd:"svd",vg:"vg",godare:"godare",aftenposten:"no-aftenposten",sa:"no-stavangeraftenblad",bt:"no-bergenstidende",aftonbladet:"aftonbladet",e24:"e24",minmote:"minmote",pent:"pent",godt:"godt",tek:"no-tek"},O=e=>h.some(t=>e.startsWith(t)),L=e=>e.startsWith("glgc_"),j=e=>!O(e)&&!L(e),$=e=>e===x.NO?"no-sno":"se-generic",N=()=>{const{country:e,publisher:t}=l.get();return`${e}-${t}`},_=(e,t)=>{const n=q();if(!n)return m;const i=((e=[])=>e.filter(O))(n),o=((e=[])=>e.filter(L))(n),r=((e=[],t,n)=>{const i=e.filter(j);if(n&&t){const{publisher:e}=t,n=P[e]||e;i.push(n)}return i})(n,e,t);return{geoTags:r,geofenceTags:o,weatherTags:i}},q=()=>{const e=v.getByTimestamp(g);return e&&"string"!=typeof e?null==e?void 0:e.tags:null},z={get:(t,n)=>e(void 0,void 0,void 0,function*(){const e=yield fetch(t,n);if(!e.ok)throw new Error(e.statusText);return yield e.json()}),post:(t,n,i)=>e(void 0,void 0,void 0,function*(){const e=JSON.stringify(i),o=yield fetch(t,{method:"POST",headers:n,body:e});if(!o.ok)throw new Error(o.statusText);return yield o.json()})},D="advertory:ppids-cache",M={[x.SE]:`SCH${x.SE.toUpperCase()}-EnvHash`,[x.NO]:`SCH${x.NO.toUpperCase()}-EnvHash`},B={[x.SE]:`SCH${x.SE.toUpperCase()}-UserHash`,[x.NO]:`SCH${x.NO.toUpperCase()}-UserHash`},R={[x.SE]:`sch${x.SE}-envhash-v3`,[x.NO]:`sch${x.NO}-envhash-v3`},F={[x.SE]:`sch${x.SE}-userhash-v3`,[x.NO]:`sch${x.NO}-userhash-v3`},V={[x.SE]:`'sch${x.SE}-iosid-v3'`,[x.NO]:`'sch${x.NO}-iosid-v3'`},U={[x.SE]:`sch${x.SE}-androidid-v3`,[x.NO]:`sch${x.NO}-androidid-v3`},H={[x.SE]:"sdrn:schibsted.com:user",[x.NO]:"sdrn:spid.no:user"};class W{constructor(){this.eids=[]}add(e,t){return e&&this.eids.push({id:e,source:t}),this}buildRyEids(){return this.eids.map(({id:e,source:t})=>({source:t,uids:[{id:e,atype:1,ext:{stype:"ppuid"}}]}))}buildEids(){return[...this.eids]}buildVideoEids(){return this.eids.map(({id:e,source:t})=>`${t},${e}`).join("|")}buildNorstatPath(){const e=this.eids[0];return e?`${e.source}-${e.id}`:""}buildNorstatQuery(e){const t=new URLSearchParams;return this.eids.slice(1).forEach(({id:n,source:i})=>{t.append(e,`${i}-${n}`)}),t}}const K=new class{constructor(){this.ppid1=null,this.ppid2=null}processPPIDs(t){return e(this,arguments,void 0,function*(e,t=1e4){var n,i;const o=yield Promise.race([new Promise(e=>{setTimeout(()=>e({xandr:{ppId1:"",ppId2:""}}),t)}),e.instance.getAdvertisingIdentifiers()]);this.setPPIDs(null===(n=o.xandr)||void 0===n?void 0:n.ppId1,null===(i=o.xandr)||void 0===i?void 0:i.ppId2)})}getPPIDs(){var e,t;return null!==this.ppid1&&null!==this.ppid2||p("PPIDv2s accessed before they have been initialized"),{ppid1:null!==(e=this.ppid1)&&void 0!==e?e:"",ppid2:null!==(t=this.ppid2)&&void 0!==t?t:""}}setPPIDs(e,t){this.ppid1=null!=e?e:"",this.ppid2=null!=t?t:""}},G=new class{constructor(){this.ppid1=null,this.ppid2=null,this.idfv=null,this.anId=null}processPPIDs(t,n){return e(this,void 0,void 0,function*(){var e,i,o,r,a,d,s,l,c,p,u;const g=v.get(D),h=yield this.getNewPPIDs(t,n);if(this.shouldHash(g,h)){const n=null!==(e=t.hasherUrl)&&void 0!==e?e:"https://hasher.schibsted.com/api/v1/hash",l=this.createHasherPayload(h),c=yield this.hashPPIDs(l,n);return c?(this.cachePPIDs(l,c,null===(i=h.idfv)||void 0===i?void 0:i.plain,null===(o=h.anId)||void 0===o?void 0:o.plain),void this.setPPIDs(null!==(r=c.userId)&&void 0!==r?r:"",null!==(a=c.environmentId)&&void 0!==a?a:"",null===(d=h.idfv)||void 0===d?void 0:d.plain,null===(s=h.anId)||void 0===s?void 0:s.plain)):void this.setPPIDs("","")}this.setPPIDs(null!==(l=null==g?void 0:g.userId.hashed)&&void 0!==l?l:"",null!==(c=null==g?void 0:g.environmentId.hashed)&&void 0!==c?c:"",null===(p=null==h?void 0:h.idfv)||void 0===p?void 0:p.plain,null===(u=null==h?void 0:h.anId)||void 0===u?void 0:u.plain)})}getPPIDs(){var e,t;return null!==this.ppid1&&null!==this.ppid2||p("PPIDv3s accessed before they have been initialized"),{ppid1:null!==(e=this.ppid1)&&void 0!==e?e:"",ppid2:null!==(t=this.ppid2)&&void 0!==t?t:"",idfv:this.idfv,anId:this.anId}}setPPIDs(e,t,n,i){this.ppid1=null!=e?e:"",this.ppid2=null!=t?t:"",this.idfv=null!=n?n:null,this.anId=null!=i?i:null}shouldHash(e,t){var n,i;if(!e)return!0;for(const o in e){if((null===(n=e[o])||void 0===n?void 0:n.plain)!==(null===(i=t[o])||void 0===i?void 0:i.plain))return!0}return!1}cachePPIDs(e,t,n,i){const o=Object.assign(Object.assign({clientId:{plain:e.clientId},userId:{plain:e.userId,hashed:t.userId},environmentId:{plain:e.environmentId,hashed:t.environmentId},trackerType:{plain:e.trackerType},trackerVersion:{plain:e.trackerVersion}},n?{idfv:{plain:n}}:{}),i?{anId:{plain:i}}:{});v.set(D,o)}hashPPIDs(t,n){return e(this,void 0,void 0,function*(){try{const e=new Headers({"Content-Type":"application/json"});return yield z.post(n,e,t)}catch(e){return p("Error with hashing PPIDs",e),null}})}getNewPPIDs(t,n){return e(this,arguments,void 0,function*({clientId:t,instance:n},i){const o=yield((t,n)=>e(void 0,void 0,void 0,function*(){const e=yield t.getUserId();return e?`${H[n]}:${e}`:null}))(n,i),r=yield(t=>e(void 0,void 0,void 0,function*(){const e=yield t.getEnvironmentId();return e?`sdrn:schibsted:environment:${e}`:null}))(n),a=window.advertory_idfv,d=window.advertory_anId;return Object.assign(Object.assign({clientId:{plain:t},userId:{plain:o},environmentId:{plain:r},trackerType:{plain:"Advertory"},trackerVersion:{plain:"1.0.0"}},a?{idfv:{plain:a}}:{}),d?{anId:{plain:d}}:{})})}createHasherPayload({clientId:e,trackerType:t,trackerVersion:n,userId:i,environmentId:o}){return{clientId:e.plain,trackerType:t.plain,trackerVersion:n.plain,userId:i.plain,environmentId:o.plain}}},J=t=>e(void 0,void 0,void 0,function*(){const{tracker:e,tcf:n,country:i,isMobileApp:o}=t;if(!(yield A(n,o,i,"setXandrPPIDs")))return;if(!e)return;(yield Promise.allSettled([K.processPPIDs(e,null==n?void 0:n.timeout),G.processPPIDs(e,i)])).forEach((e,t)=>{if("rejected"===e.status){p(`Cannot fetch PPIDs v${t+2}`,e.reason)}})}),Y=e=>{const{ppid1:t,ppid2:n}=K.getPPIDs(),{ppid1:i,ppid2:o,idfv:r,anId:a}=G.getPPIDs();return{userIds:[{type:"extendedIDs",eids:(new W).add(n,M[e]).add(t,B[e]).add(o,R[e]).add(i,F[e]).add(r,V[e]).add(a,U[e]).buildEids()}]}},X=e=>{const{ppid1:t,ppid2:n}=K.getPPIDs(),{ppid1:i,ppid2:o,idfv:r,anId:a}=G.getPPIDs();if(!n)return{};return{userSync:{userIds:[{name:"pubProvidedId",params:{eids:(new W).add(n,M[e]).add(t,B[e]).add(o,R[e]).add(i,F[e]).add(r,V[e]).add(a,U[e]).buildRyEids()}}]}}},Q=e=>{const{ppid1:t,ppid2:n}=K.getPPIDs(),{ppid1:i,ppid2:o}=G.getPPIDs();return(new W).add(n,M[e]).add(t,B[e]).add(o,R[e]).add(i,F[e]).buildRyEids()},Z=e=>{const t=encodeURIComponent(e).replace(/[-.+*]/g,"\\$&"),n=new RegExp(`(?:(?:^|.*;)\\s*${t}\\s*\\=\\s*([^;]*).*$)|^.*$`);return decodeURIComponent(document.cookie.replace(n,"$1"))||null},ee=t=>e(void 0,void 0,void 0,function*(){const{tcf:e,isMobileApp:n,country:i}=t,{getConsentAsync:o}=I(e,0,i);if(!(yield o()))return;const r=Z("_pulse2data");return r?r.split(",")[9]:void 0}),te={MOBILE:"mobile",TABLET:"tablet",DESKTOP:"desktop"},ne=9826;class ie{constructor(){this.getSupplyTypeKeywords=()=>{const{deviceType:e=te.DESKTOP,isMobileApp:t}=l.get();if(t){return{"aa-sch-supply_type":`app_${e===te.MOBILE?"phone":te.TABLET}`}}return{"aa-sch-supply_type":`web_${this.getPageOptionsFormatDevice(e)}`}}}prepare(t){return e(this,void 0,void 0,function*(){return Object.assign(Object.assign({},t),{keywords:Object.assign(Object.assign(Object.assign(Object.assign({},t.keywords),this.getSupplyTypeKeywords()),yield this.getFormattedExternalIdKeywords()),this.getHasContextKeywords(t.keywords)),user:{externalUid:yield this.getExternalUid(),dnt:yield this.isTrackingForbidden()}})})}getFormattedExternalIdKeywords(){return e(this,void 0,void 0,function*(){const e=yield this.getExternalUid(),t=this.getUserId();return{"aa-sch-externalid_src":Number(!!e)+Number(!!t)}})}getUserId(){return(()=>{const e=Z("_pulse2data");return e?e.split(",")[2]:void 0})()}getExternalUid(){return e(this,void 0,void 0,function*(){return yield ee(l.get())})}isTrackingForbidden(){return e(this,void 0,void 0,function*(){return(null===navigator||void 0===navigator?void 0:navigator.globalPrivacyControl)||"1"===(null===navigator||void 0===navigator?void 0:navigator.doNotTrack)||"DO_NOT_TRACK"===(yield this.getExternalUid())})}getMember(){const{pageOptions:{member:e},testMember:t=ne}=l.get();return"true"===f("inventory_test")?t:e}getCMPValue(e){return localStorage.getItem(`CMP:${e}`)?"0"===localStorage.getItem(`CMP:${e}`)?"0":"1":"0"}getPublisherKeywords(){const{publisher:e}=l.get();return{"aa-sch-publisher":`${e}`}}getAnalyticsConsentKeywords(){return{"aa-sch-cmp_analytics":this.getCMPValue("analytics")}}getAdvertisingConsentKeywords(){return e(this,void 0,void 0,function*(){const{tcf:e,isMobileApp:t,country:n}=l.get(),{getConsentAsync:i}=I(e,0,n);return{"aa-sch-cmp_advertising":(yield i())?"1":"0"}})}getPageTypeKeywords(){const{pageType:e}=l.get();return{"aa-sch-page_type":e}}getCountryCodeKeywords(e){return{"aa-sch-country_code":e}}getInventoryTypeKeywords(){return{"aa-sch-inventory_type":"editorial"}}getHasContextKeywords(e){const t=e["aa-sch-context_keyword"];return{"aa-sch-has_context_keyword":Array.isArray(t)&&t.length?1:0}}getPageOptionsFormatDevice(e="desktop"){return"mobile"===e?"phone":e}getSponsorsKeywords(){var e;const{publisher:t,keywordsConfig:n}=l.get(),i=null===(e=null==n?void 0:n.sponsors)||void 0===e?void 0:e.split(":").map(e=>`${t}_${e}`);return i?{"no-sno-news-sponsors":i}:{}}}const oe=new ie;oe.prepare.bind(oe);const re=new class extends ie{prepare(t){return e(this,void 0,void 0,function*(){const n=Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},this.getCountryCodeKeywords(x.NO)),this.getPublisherKeywords()),this.getPageTypeKeywords()),yield this.getFormattedExternalIdKeywords()),this.getSupplyTypeKeywords()),yield this.getAdvertisingConsentKeywords()),yield(i=l.get(),e(void 0,void 0,void 0,function*(){const{addPublisherToGeo:e}={},{glimr:t,country:n}=i,o=yield S(i);if(!(null==t?void 0:t.enabled)||!o)return p("No consent for getting glimr tags."),{};const r=$(n),a=_(i,Boolean(e));return{[`${r}-geo`]:a.geoTags,[`${r}-weather`]:a.weatherTags,[`${r}-geofence`]:a.geofenceTags}}))),(()=>{const{ppid1:e,ppid2:t}=K.getPPIDs();return{"aa-sch-schuserhash":e?"1":"0","aa-sch-schenvhash":t?"1":"0"}})()),t.keywords);var i;return Object.assign(Object.assign({},t),{keywords:n,user:Object.assign(Object.assign({},Y(x.NO)),{externalUid:yield this.getExternalUid()}),member:this.getMember()})})}};var ae=re.prepare.bind(re);let de="";const se=new Map,le=e=>{const t=e.split("-"),n=t[t.length-1];return 6===n.length&&n.match(/^[a-zA-Z0-9]+$/)?t.slice(0,-1).join("-"):e},ce="0123456789abcdefghijklmnopqrstuvwxyz",pe=(e=6)=>{if(e<=0)return"";let t="";for(let n=0;n<e;n++){t+=ce[Math.floor(36*Math.random())]}return t},ue=()=>Promise.resolve(),ve=e=>{window.apntag.anq.push(e)},ge=new Promise(e=>{"undefined"!=typeof document&&document.prerendering?document.addEventListener("prerenderingchange",()=>e()):e()}),he=new Promise(e=>{if("undefined"==typeof document||!document.hidden)return void e();const t=()=>{document.hidden||(document.removeEventListener("visibilitychange",t),e())};document.addEventListener("visibilitychange",t,{once:!0})}),me="advertory-wallpaper-background",fe="advertory-with-horseshoe",ye=()=>{const e=document.querySelector(`.${me}`);e&&e.remove()},be=e=>{const t=e.getBoundingClientRect().top;requestAnimationFrame(()=>(e=>{if(!document.body)return;const t=document.querySelector(`.${me}`);t&&t.style.setProperty("top",`${e}px`)})(t+15))},we=/^wallpaper:url:(http[s]?:\/\/)?[^\s(["<,>]*\.[^\s[",><]*/,xe=()=>null!==f("disable_prebid"),ke=e=>{if("0"===f("collapse_ad"))return;const t=document.querySelector(`div[id^="${e}"]`);if(!t)return;const n=t.parentElement;n&&(t.style.setProperty("width","0","important"),t.style.setProperty("height","0","important"),t.style.setProperty("display","none","important"),n.style.setProperty("display","none","important"),e.includes("wallpaper")&&ye())},Ee=e=>{const t=document.querySelector(`div[id^="${e}"]`);if(!t)return;const n=t.parentElement;n&&(t.style.removeProperty("width"),t.style.removeProperty("height"),t.style.removeProperty("display"),n.style.removeProperty("display"))};class Te{initialize(){this.DATA=Object.assign({},Te.INITIAL_DATA)}getData(e){if(!this.DATA)throw new Error("Storage was accessed with invalid data.");return this.DATA[e]}setData(e,t){if(!this.DATA)throw new Error("Storage was accessed before it had been initialized.");this.DATA[e]=Object.assign(Object.assign({},this.DATA[e]),t)}}Te.INITIAL_DATA={wallpaper:{isAvailable:!1},horseshoe:{isAvailable:!1},initialClassNames:{},alertoryConfigKeywords:{}};const Ie=new Te,Ae=e=>{var t;const n=null===(t=document.querySelector(`#${e}`))||void 0===t?void 0:t.parentElement,i=(null==n?void 0:n.offsetHeight)||0;n&&(n.style.minHeight=`${i}px`)},Se=e=>{const t=e.parentElement;if(!e||!t)return;const{container:n,wrapper:i}=(e=>{const t=Ie.getData("initialClassNames")[e.id];return{wrapper:(null==t?void 0:t.wrapper)?t.wrapper.join(" "):"",container:(null==t?void 0:t.container)?t.container.join(" "):""}})(e);e.className=n,t.className=i},Ce=()=>{ye();document.querySelectorAll('[data-advertory-ad-rendered="true"]').forEach(e=>{ke(e.id),Se(e),(e=>{const t=document.querySelector(`#${e}`),n=null==t?void 0:t.getAttribute("data-probable-height"),i=null==t?void 0:t.getAttribute("data-probable-width");n&&i&&(null==t||t.style.setProperty("min-height",n+"px"),null==t||t.style.setProperty("min-probable-width",i+"px"))})(e.id),e.innerHTML="",e.id=le(e.id)}),ve(()=>window.apntag.clearRequest())},Pe="noGroupedPlacements",Oe=e=>{const t=e.replace(/[0-9]/g,"");return"_"===t.slice(-1)?t.substring(0,t.length-1):t},Le=e=>{if(!(null==e?void 0:e.minViewWidth))return!0;return window.innerWidth>=e.minViewWidth},je=e=>{var t;if(!(null===(t=null===window||void 0===window?void 0:window.advertory)||void 0===t?void 0:t.initialized))return[];const{placements:n,queryConfig:i,deviceType:o}=l.get(),r=n[o].filter(Le)||[],a=e?document.querySelector(e):document;if(!a)return[];const d=r.reduce((e,t)=>{const n=Oe(t.id);return!n||e.includes(n)||e.push(n),e},[]).flatMap(e=>{const t=new RegExp(`^${e}(_(\\d+))?$`),n=r.filter(({id:e})=>e.match(t)),d=(null==i?void 0:i.queryByDataDevice)?`div[id^="${e}"][data-device=${o}], div[id^="${e}"][data-device=all]`:`div[id^="${e}"]:not([data-disabled="true"])`,s=a.querySelectorAll(d),c=Array.from(s).filter(({id:e})=>e.match(t)).map((e,t)=>{var i;const o=$e(e,t,n),r=o.finnBlink&&!o.finnBlink.renderOnlyWithAdBlock,a=r&&(null===(i=o.finnBlink)||void 0===i?void 0:i.loadOnlyFinnBlink),d=`${e.id}-${pe(6)}`;return e.id=d,e.setAttribute("data-advertory-ad-rendered","true"),r&&e.setAttribute("data-is-finn-blink-placement","true"),a&&e.setAttribute("data-is-finn-blink-only-placement","true"),(e=>{var t;const n=e.id;n&&Ie.setData("initialClassNames",{[n]:{wrapper:null===(t=e.parentElement)||void 0===t?void 0:t.className.split(" "),container:e.className.split(" ")}})})(e),Object.assign(Object.assign({},o),{id:d})});return(e=>{const{keywordsConfig:t}=l.get();return(null==t?void 0:t.includeCountingKeywordInTags)?(de!==window.location.pathname&&(se.clear(),de=window.location.pathname),e.map(e=>{var t;const n=e.invCode.replace(/_\d+$/,""),i=null!==(t=se.get(n))&&void 0!==t?t:0;return e.keywords=Object.assign({},e.keywords),e.keywords[`${N()}-count`]=i,se.set(n,i+1),e})):e})(c)});return(e=>{const t=Array.from(document.querySelectorAll('div[class^="advertory"]'));return e.sort((e,n)=>t.findIndex(t=>t.id===e.id)-t.findIndex(e=>e.id===n.id))})(d)},$e=(e,t,n)=>{const i=n[t],o=n[n.length-1],r=n.filter(({id:t})=>t===e.id)[0];return(null==e?void 0:e.id)===(null==i?void 0:i.id)?i:(null==e?void 0:e.id)===(null==o?void 0:o.id)?o:r||o},Ne=e=>{const{queryConfig:{placementBatches:t}={},deviceType:n}=l.get(),i=(null==t?void 0:t[n])||{},o=Object.values(i).flat(),r=(e=>{const t={};return e.forEach(e=>{const n=le(e.id);e.isBackfill&&(t[n]=[e])}),t})(e),a=((e,t)=>{const n={};for(const[i,o]of Object.entries(t))n[i]=e.filter(e=>o.includes(le(e.id)));return n})(e,i),d=Object.keys(r),s=((e,t)=>e.filter(e=>!t.has(le(e.id))))(e,new Set([...d,...o]));return Object.assign(Object.assign(Object.assign({},a),r),{[Pe]:s})},_e="ABSOLUTE_FULLSCREEN",qe="ANY_FULLSCREEN",ze="VERTICAL_FULLWIDTH",De="FULLWIDTH",Me="TAKEOVER",Be="VELVET_TAKEOVER",Re="WALLPAPER",Fe="COLLAPSE",Ve={ANY_FULLSCREEN:[{width:6,height:6},{width:1920,height:1080},{width:3,height:3}],ABSOLUTE_FULLSCREEN:[{width:6,height:6}],VERTICAL_FULLWIDTH:[{width:1080,height:1920}],FIXED_FULLSCREEN:[{width:1920,height:1080},{width:3,height:3}],FULLWIDTH:[{width:5},{width:400,height:400}],NATIVE_AD:[{width:1,height:1}],TAKEOVER:[{width:4,height:4}],VELVET_TAKEOVER:[{width:7,height:7}],WALLPAPER:[{width:2,height:2}],COLLAPSE:[{width:2,height:1}]},Ue={wallpaper:1600,"l-format":1600},He=e=>{const{banner:t,targetId:n}=e;return!(!t||(null==n?void 0:n.includes("takeover")))&&rt(e,qe)},We=e=>{const{native:t}=e;return!!t},Ke=e=>rt(e,De),Ge=e=>{const{targetId:t}=e;return t.includes("takeover")||rt(e,Me)},Je=e=>rt(e,Me),Ye=e=>rt(e,Re),Xe=e=>rt(e,Fe),Qe=e=>e.targetId.includes("sponsorstripe"),Ze=e=>{const t=document.querySelector(`#${e}`);return!!t&&"true"===t.dataset.isFinnBlinkPlacement},et=e=>e.targetId.startsWith("panorama")||e.targetId.startsWith("modul"),tt=e=>e.targetId.startsWith("midboard"),nt=e=>e.targetId.includes("widescreen"),it=e=>e.width>=1260&&e.width<=1280,ot=e=>e.width>=1600&&e.width<=1620,rt=(e,t)=>{const n=Ve[t];if(!n)return!1;return!!n.find(t=>{var n,i;const o=(null===(n=e.banner)||void 0===n?void 0:n.width)||e.width,r=(null===(i=e.banner)||void 0===i?void 0:i.height)||e.height,a=t.width===o,d=!t.height||t.height===r;return a&&d})},at="splash",dt="welcomePage",st="topscroller",lt="velvet",ct=(e,t=(...e)=>{})=>{const n=t.toString();if(0===e.length)return n;const i=n.substring(0,n.indexOf("=>")).replace("(","").replace(")","").split(",").map(e=>e.trim()),o=n.substring(n.indexOf("{")+1,n.lastIndexOf("}")),r=i.map((t,n)=>`${t} = "${e[n]}"`);return new Function(...r,o).toString()},pt="takeover-displayed",ut="takeover-visit-count",vt=14400,gt=()=>{const e=Z(ut);return e?parseInt(e):0},ht=()=>{const{takeover:{enabled:e=!1,secondVisitEnabled:t=!1}={}}=l.get();return"0"!==f(y)&&("1"===f(y)||!(!e||(()=>{var e;const t=(null===(e=l.get().takeover)||void 0===e?void 0:e.cookieCapName)||pt;return"true"===Z(t)})())&&(!t||mt()))},mt=()=>{const e=gt();return 0===e?((()=>{const e=gt(),{takeover:{cookieCapTime:t=vt}={}}=l.get(),n=document.location.hostname;window.document.cookie=`${ut}=${e+1}; max-age=${t}; domain=${n}; path=/; SameSite=Lax`})(),!1):1===e},ft=(e,t)=>[[1,1],[1920,1080]].some(([n,i])=>n===e&&i===t),yt=()=>{const{takeover:e}=l.get();return Boolean(null==e?void 0:e.topscroller)},bt=()=>e(void 0,void 0,void 0,function*(){const e=document.location.hostname,{takeover:{cookieCapName:t=pt,cookieCapTime:n=vt}={},isMobileApp:i,tcf:o,country:r}=l.get(),a=yield A(o,i,r,"ad-takeover-cookiecap");n&&a&&(window.document.cookie=`${t}=true; max-age=${n}; domain=${e}; path=/`)}),wt=e=>{var t;const n=!!(null===(t=l.get().takeover)||void 0===t?void 0:t.setCookieCapForNotShownAd);return Ge(e)&&n},xt=(e,t)=>{var n;if(t===st){const{topscroller:t}=e;return null!=t?t:{}}if(t===at){const{splash:t}=e;return null!=t?t:{}}return null!==(n=e.welcomePage)&&void 0!==n?n:{}},kt=(e,t)=>{t!==at?(e=>{var t,n,i;const o=null===(n=null===(t=l.get().takeover)||void 0===t?void 0:t.welcomePage)||void 0===n?void 0:n.headerElementSelector,r=null===(i=l.get().takeover)||void 0===i?void 0:i.topscroller;if(!o||r)return;const a=document.querySelector(o),d=document.querySelector(".welcome-page-wrapper"),s=document.querySelector(`#${e.targetId}`),c=document.querySelector(".advertory-welcome-page-scroll");if(!(a&&d&&c&&s))return;const p=null==a?void 0:a.offsetHeight,u=Je(e)?"60svh":`calc(100svh - ${p}px)`,v=Je(e)?"calc(40svh + 30px)":`calc(${p}px + 30px)`;d.style.setProperty("height",u,"important"),s.style.setProperty("height",u,"important"),c.style.setProperty("bottom",v,"important")})(e):(e=>{var t;if(!(null===(t=l.get().takeover)||void 0===t?void 0:t.splash))return;const n=document.querySelector(".advertory-splash-navbar-wrapper"),i=document.querySelector(`#${e.targetId}`);if(!n||!i)return;const o=`calc(100svh - ${n.offsetHeight}px)`;i.style.setProperty("height",o,"important")})(e)},Et=ct([],()=>{new MutationObserver((e,t)=>{document.querySelector("iframe")&&((()=>{const e=document.querySelector("iframe");e&&(e.onload=()=>{if(!e.contentDocument)return;document.body.style.height="100%",document.documentElement.style.height="100%",e.height="100%",e.width="100%";const t=e.contentDocument.createElement("style");t.textContent="\n .adform-adbox {\n height: 100% !important;\n width: 100% !important;\n }\n img {\n height: 100% !important;\n width: 100% !important;\n object-fit: cover !important;\n object-position: top !important;\n }\n ",e.contentDocument.head.appendChild(t)})})(),t.disconnect())}).observe(document.body,{childList:!0,subtree:!0})}),Tt={nativeAd:e=>We(e)&&!Qe(e),buyrecipe:e=>e.targetId.startsWith("buyrecipe"),fullwidthAd:Ke,fullscreenScroll:He,topscroller:e=>Ge(e)&&yt(),splash:e=>Ge(e)&&ft(e.width,e.height),welcomePage:Ge,wallpaper:Ye,skyscraper:e=>e.targetId.includes("skyscraper")&&!!e.banner,lFormat:it,hFormat:ot,toppanorama:e=>e.targetId.startsWith("toppanorama")&&!ot(e)&&!it(e),topboard:e=>e.targetId.startsWith("topboard")&&!Ge(e),widescreen:nt,insider:e=>e.targetId.startsWith("insider"),sponsorstripe:Qe,brandboard:e=>(e=>(980===e.width||1920===e.width&&e.targetId.includes("brandboard"))&&!e.targetId.includes("topboard")&&!e.targetId.includes("companion")&&!et(e))(e)&&!(e=>e.targetId.includes("backfill"))(e)&&!tt(e),outstream:e=>"https://acdn.adnxs.com/video/outstream/ANOutstreamVideo.js"===e.renderer_url,netboard:e=>(e=>e.targetId.startsWith("netboard"))(e)||(e=>e.targetId.startsWith("board"))(e),panorama:et,midboard:tt},It=({adObj:e,preferredTestIdData:t})=>{var n,i;const o=null!==(n=null==t?void 0:t.targetId)&&void 0!==n?n:null==e?void 0:e.targetId;if(!o)return;const r=null===(i=document.querySelector(`#${o}`))||void 0===i?void 0:i.parentElement;if(!r)return;if(((e,t)=>{var n,i,o,r;const a=null===(r=null===(o=null===(i=null===(n=window.apntag)||void 0===n?void 0:n.requests)||void 0===i?void 0:i.tags)||void 0===o?void 0:o[e])||void 0===r?void 0:r.invCode;a&&(t.dataset.invCode=a)})(o,r),null==t?void 0:t.testId)return void(r.dataset.testid=t.testId);const a="DIV"===(null==r?void 0:r.tagName);e&&a&&((e,t)=>{var n,i;for(const[o,r]of Object.entries(Tt))if(r(e)){if("nativeAd"===o){const r="default";t.dataset.testid=`${o}-${null!==(i=null===(n=null==e?void 0:e.native)||void 0===n?void 0:n.desc2)&&void 0!==i?i:r}`;break}t.dataset.testid=o;break}})(e,r)},At=e=>{var t;return(null===(t=Object.entries(Tt).find(([,t])=>t(e)))||void 0===t?void 0:t[0])||""},St=(e,t)=>{const n=e.width,i=(null!=t?t:window.screen.width)/n;return i<1?i:1},Ct=(e,t=window.screen.width,n,i)=>{const o=St(e,t),r=document.querySelector(`iframe[id^="utif_${e.targetId}"]`);r&&(r.style.transform=`scale(${o})`,r.style.transformOrigin="left top")},Pt=new Map;Pt.set("insider",{scale:.82,transformOrigin:"left center",cogwheelAdjust:!0}),Pt.set("panorama",{scale:.79,transformOrigin:"center center"}),Pt.set("outstream",{scale:.79,transformOrigin:"center center"}),Pt.set("integration",{scale:.79,transformOrigin:"center center"}),Pt.set("toppanorama",{scale:.8,transformOrigin:"left center"});const Ot=e=>{if(!((null===(t=null===document||void 0===document?void 0:document.body)||void 0===t?void 0:t.clientWidth)>767&&(null===(n=null===document||void 0===document?void 0:document.body)||void 0===n?void 0:n.clientWidth)<=853))return;var t,n;const i=At(e),o=Pt.get(i),r=document.querySelector(`#${e.targetId}`);if(!r||!o)return;if(r.style.transformOrigin=o.transformOrigin,r.style.transform=`scale(${o.scale})`,!(null==o?void 0:o.cogwheelAdjust))return;const a=document.querySelector(`div[class*="gdpr-cogwheel-button"][id$="${e.targetId}"]`),d=null==r?void 0:r.offsetWidth;a&&"number"==typeof d&&!isNaN(d)&&a.style.setProperty("right",String(-1*d*.2)+"px")},Lt={adRequested:()=>{},adAvailable:e=>{},adLoaded:e=>{const t=window.screen.width||window.innerWidth;980===e.width&&t<980&&((e,t)=>{Ct(e,t);const n=document.querySelector(`#${e.targetId}`);n&&(n.style.minWidth="100vw")})(e,t)},adNoBid:e=>{},adError:(e,t)=>{},adCollapse:()=>{},adRequestFailure:e=>{},adBadRequest:e=>{},adLoadedMediated:e=>{},adNoBidMediated:e=>{}},jt=()=>(window.apntag||(window.apntag={anq:[],defineTag:e=>({targetId:""}),showTag:e=>{},onEvent:(e,t,n)=>{},offEvent:(e,t)=>{},refresh:e=>{},modifyTag:(e,t)=>{},loadTags:e=>{},emitEvent:(e,t)=>{},setPageOpts:e=>{},resizeAd:(e,t,n)=>{},getAstVersion:()=>"",setEndpoint:(e,t)=>{},fireImpressionTrackers:e=>{},setKeywords:()=>{},clearRequest:()=>{}}),window.apntag),$t=()=>(window.relevantDigital||(window.relevantDigital={cmd:[]}),window.relevantDigital),Nt=(e={},t)=>{const{prebid:{externalUidInAuctionEnabled:n,forwardGlimrTags:i=!1}={},country:o}=l.get(),r=[`${$(o)}-geo`],a=["aa-sch-context_keyword","aa-sch-publisher","se-aftonbladet-section","se-svd-section","se-generic-section","no-sno-news-section","no-sno-news-subsection","aa-sch-cmp_advertising",...i?r:[]],d=Object.fromEntries(Object.entries(e).filter(([e])=>a.includes(e))),s=t&&n?{id:t}:{};return{ortb2:Object.assign({site:{ext:{data:d}}},s)}},_t=(t,...n)=>e(void 0,[t,...n],void 0,function*(e,{timeout:t}={timeout:1e3}){document.querySelector(`script[src="${e}"]:not([type="module"])`)||(yield new Promise((n,i)=>{const o=document.createElement("script");o.async=!0,o.src=e;const r=()=>{d(),n()},a=()=>{d(),i(new Error(`Failed to load ${e}`))},d=()=>{o.removeEventListener("load",r),o.removeEventListener("error",a),clearTimeout(s)};o.addEventListener("load",r),o.addEventListener("error",a);const s=setTimeout(()=>{d(),i(new Error(`Loading script timed out: ${e}`))},t);document.head.appendChild(o)}).catch(e=>{console.error(e)}))}),qt="advertory-fullscreen-scroll",zt="advertory-fullscreen-scroll-wrapper",Dt="fullscreen-scroll-in-screen",Mt="in-screen",Bt=e=>e.includes("snoap.no"),Rt=e=>{var t,n,i,o,r;return!!(null===(r=null===(o=null===(i=null===(n=null===(t=window.apntag)||void 0===t?void 0:t.requests)||void 0===n?void 0:n.tags[e])||void 0===i?void 0:i.adResponse)||void 0===o?void 0:o.ads[1])||void 0===r?void 0:r.rtb)},Ft=ct([],()=>{const e=({width:e,height:t})=>{var n;const i=null===(n=document.querySelector("#sf_align"))||void 0===n?void 0:n.querySelector("div");if(!i)return;const{clientWidth:o,clientHeight:r}=i,a=e/o,d=t/r;i.style.transform=`scale(${a},${d})`,i.style.transformOrigin="left top"},t=()=>{const{innerWidth:t,innerHeight:n}=window;e({width:t,height:n})};window.addEventListener("resize",t=>{if(!t.currentTarget)return;const n={width:innerWidth,height:innerHeight};e(n)});const n=window.frameElement;(null==n?void 0:n.contentWindow)?n.contentWindow.document.body.onload=t:document.body.onload=t}),Vt=e=>{const t=ct([],()=>{new MutationObserver((e,t)=>{document.querySelector("iframe")&&((()=>{const e=document.querySelector("iframe");e&&(e.onload=()=>{if(!e.contentDocument)return;document.body.style.height="100%",document.documentElement.style.height="100%",e.height="100%",e.width="100%";const t=e.contentDocument.createElement("style");t.textContent="\n adfm-ad {\n height: 100% !important;\n width: 100% !important;\n }\n ",e.contentDocument.head.appendChild(t);const n=e.contentDocument.querySelector("iframe");if(!(null==n?void 0:n.contentDocument))return;const i=n.contentDocument.createElement("style");i.textContent="\n #image {\n background-size: cover !important;\n }\n ",new MutationObserver((e,t)=>{n.contentDocument&&(n.contentDocument.head.appendChild(i),t.disconnect())}).observe(e.contentDocument,{childList:!0,subtree:!0})})})(),t.disconnect())}).observe(document.body,{childList:!0,subtree:!0})}),n=document.createElement("script");n.textContent=`(${t})()`;return e+n.outerHTML},Ut=[],Ht={},Wt=(e,t)=>{e.forEach(({target:e,isIntersecting:n})=>{const i=Gt(e);n?(Kt(i,n),Jt(e,i,t)):(Kt(i,n),Yt(e,i,t))})},Kt=(e,t)=>{var n,i;const o=null===(n=document.getElementById(e))||void 0===n?void 0:n.querySelector("iframe");if(!o)return;const r=t?"showFullscreen":"hideFullscreen";null===(i=o.contentWindow)||void 0===i||i.postMessage(`advertory:${r}-${e}`,"*")},Gt=e=>{var t;return null===(t=e.children[0])||void 0===t?void 0:t.id},Jt=(e,t,n)=>{e.classList.add(Mt),document.body.classList.add(Dt),window.dispatchEvent(new CustomEvent("advertory:fullscreenScrollInView")),Ut.includes(t)||Ut.push(t),n&&window.addEventListener("scroll",Ht[t],{passive:!0})},Yt=(e,t,n)=>{Ut.includes(t)&&(n&&window.removeEventListener("scroll",Ht[t]),document.body.classList.remove(Dt),e.classList.remove(Mt),window.dispatchEvent(new CustomEvent("advertory:fullscreenScrollNotInView")))},Xt=(e,t={fadingHeaderEnabled:!1,headerSelectors:[".js-masthead"],skyscraperSelectors:[".skyscraper_r"],headerZIndex:3})=>{const{headerSelectors:n=[".js-masthead"],skyscraperSelectors:i=[".skyscraper_r"],headerZIndex:o=3}=t,r=[],a=[];return n.forEach(e=>{var t;const n=null!==(t=document.querySelector(e))&&void 0!==t?t:document.querySelector("header");n&&r.push(n)}),i.forEach(e=>{const t=document.querySelector(e);t&&a.push(t)}),()=>{r.length&&Qt(e,r,o,0),a.length&&Qt(e,a,o,40)}},Qt=(e,t,n,i)=>{const o=e.offsetHeight,r=window.scrollY,a=e.getBoundingClientRect().top+r;t.forEach(e=>{const t=e.offsetHeight;let d;d=a>r?(a-r)/t-i:(r+t-(a+o))/t;const s=d<=0;e.style.visibility=s?"hidden":"",e.style.zIndex=s?"":n.toString(),e.style.pointerEvents=s?"none":"all",e.style.opacity=d.toString()})};function Zt(e){if(!e||"undefined"==typeof window)return;const t=document.createElement("style");return t.setAttribute("type","text/css"),t.innerHTML=e,document.head.appendChild(t),e}Zt('body.fullscreen-scroll-in-screen{overflow-x:hidden}.advertory-fullscreen-scroll-wrapper{visibility:hidden;overflow:visible;width:100% !important;height:var(--advertory-fullscreen-scroll-vh, 100vh) !important;position:relative;margin:var(--advertory-fullscreen-scroll-wrapper-margin);z-index:1;display:block !important;min-height:250px;padding:0 !important;clip-path:polygon(0 0, 100vw 0, 100vw 100dvh, 0 100dvh);-webkit-clip-path:polygon(0 0, 100vw 0, 100vw 100dvh, 0 100dvh)}.advertory-fullscreen-scroll-wrapper>div{position:fixed;top:0;left:0;height:var(--advertory-fullscreen-scroll-vh, 100vh) !important;width:100vw !important;overflow:hidden}html[data-app-platform=iOS] .advertory-fullscreen-scroll-wrapper>div{height:calc(var(--advertory-fullscreen-scroll-vh, 100vh) - env(safe-area-inset-top) + var(--advertory-ios-safe-area-top-fix, 0px) - env(safe-area-inset-bottom)) !important;top:unset !important;bottom:env(safe-area-inset-bottom) !important}.advertory-fullscreen-scroll-wrapper>div>iframe{height:inherit !important;width:inherit !important;display:none !important}.advertory-fullscreen-scroll-wrapper.in-screen{visibility:visible;overflow:visible;width:100vw !important}.advertory-fullscreen-scroll-wrapper.in-screen>div>iframe{display:block !important}.advertory-fullscreen-scroll-wrapper.in-screen:before{content:"";width:100vw;height:150dvh;position:relative !important;display:block;transform:translateX(-50%);overflow:visible;z-index:1;left:50%;top:-150dvh;padding:0 !important}.advertory-fullscreen-scroll-wrapper.in-screen:after{content:"";width:100vw;height:150dvh;position:relative !important;display:block;transform:translateX(-50%);overflow:visible;z-index:1;left:50%;top:-50dvh}.advertory-fullscreen-scroll{position:fixed;top:var(--advertory-fullscreen-scroll-top, 0px);left:var(--advertory-fullscreen-scroll-left, 0px);width:var(--advertory-fullscreen-scroll-vw, 100vw);height:var(--advertory-fullscreen-scroll-vh, 100vh);overflow:hidden}.advertory-fullscreen-scroll::before{content:attr(data-ad-label);box-sizing:border-box;position:fixed;top:0}html[data-app-platform=iOS] .advertory-fullscreen-scroll::before{top:calc(env(safe-area-inset-top) - var(--advertory-ios-safe-area-top-fix, 0px)) !important}.advertory-fullscreen-scroll::before{left:calc(50vw - 628px);width:calc(100% - 36px);max-width:1250px;text-align:left;background-color:hsla(0,0%,100%,.6);color:#212121;font-family:Ester Blenda,Arial,sans-serif;font-size:11px;font-weight:400;font-style:normal;text-transform:lowercase;line-height:1;margin:16px 2px;padding:10px;z-index:1;visibility:inherit !important}@media screen and (max-width: 1290px){.advertory-fullscreen-scroll::before{left:16px}}.advertory-fullscreen-scroll[data-move-cogwheel-to-the-left=true]>div[role=button]{left:calc(50vw - 623px);right:unset}@media screen and (max-width: 1290px){.advertory-fullscreen-scroll[data-move-cogwheel-to-the-left=true]>div[role=button]{left:22px;right:unset}}.advertory-fullscreen-scroll[data-move-cogwheel-to-the-left=true]::before{padding-left:32px}.advertory-fullscreen-scroll>div[id*=utif]{display:block;width:var(--advertory-fullscreen-scroll-vw, 100vw) !important;height:var(--advertory-fullscreen-scroll-vh, 100vh) !important}html[data-app-platform=iOS] .advertory-fullscreen-scroll>div[id*=utif]{height:calc(var(--advertory-fullscreen-scroll-vh, 100vh) - env(safe-area-inset-top) + var(--advertory-ios-safe-area-top-fix, 0px) - env(safe-area-inset-bottom)) !important}.advertory-fullscreen-scroll>div[id*=utif]{overflow:hidden}.advertory-fullscreen-scroll>div[id*=utif]>iframe{display:block;height:inherit !important;width:inherit !important}.advertory-fullscreen-scroll>div[role=button]{z-index:2;opacity:1;background:rgba(0,0,0,0) !important;left:unset;position:fixed !important;right:calc(50vw - 623px);top:19px !important;width:26px !important;height:26px !important}html[data-app-platform=iOS] .advertory-fullscreen-scroll>div[role=button]{top:calc(env(safe-area-inset-top) - var(--advertory-ios-safe-area-top-fix) + 19px) !important}@media screen and (max-width: 1290px){.advertory-fullscreen-scroll>div[role=button]{right:22px}}');const en={no:{adText:"ANNONSE",adFrom:"ANNONSE FRA",adContent:"ANNONSØRINNHOLD",adContentFrom:"ANNONSØRINNHOLD FRA"},se:{adText:"ANNONS",adFrom:"ANNONS FRÅN",adContent:"EXTERN LÄNK",adContentFrom:"EXTERN LÄNK FRÅN"}};let tn=null;const nn=(e,t)=>{let n=e;return n=(e=>{const t=document.createElement("script");return t.textContent="\n window.addEventListener('message', function(event) {\n if (event.data === 'advertory:showFullscreen-'+document.body.id) {\n document.body.style.display = \"block\";\n } else if (event.data === 'advertory:hideFullscreen-'+document.body.id) {\n document.body.style.display = \"none\";\n }\n });\n ",e+t.outerHTML})(e),n=(e=>{const t=document.createElement("script");return t.textContent=`(${Ft})()`,e+t.outerHTML})(n),n=(e=>{if((e=>e.includes("google"))(e))return e;const t=document.createElement("div");t.innerHTML=e;const n=t.querySelector("img");return n?(n.style.width="100%",n.style.height="100%",n.style.objectFit="cover",n.style.position="fixed",t.innerHTML):e})(n),n=(e=>{if(Bt(e))return e;const t=document.createElement("style");return t.textContent="\n .GoogleActiveViewClass, .GoogleActiveViewElement {\n transform: translate(calc(-50% + 50vw), 0);\n width: 100vw !important;\n height: 100vh !important;\n }\n .GoogleActiveViewClass img, .GoogleActiveViewElement img {\n width: 100vw;\n height: 100vh;\n object-fit: cover;\n }\n .GoogleActiveViewClass iframe {\n width: 100vw !important;\n height: 100vh !important;\n }\n ",e+t.outerHTML})(n),(e=>e.includes("adform"))(n)&&(n=(e=>{const t=document.createElement("script");t.textContent='\n var frame = window.frameElement;\n if (frame) {\n frame.style.removeProperty("width");\n frame.style.removeProperty("height");\n frame.contentWindow.document.body.onload = onLoad;\n } else {\n document.body.onload = onLoad;\n }\n \n function onLoad() {\n var iframe = document.querySelector("adfm-ad iframe");\n if (iframe) {\n var image = iframe.contentWindow.document.getElementById("image");\n if (!image) return;\n image.style.backgroundSize = "cover";\n } else {\n var iframe = document.querySelector(".adform-adbox iframe");\n if (iframe) {\n var style = document.createElement("style");\n style.textContent = "#banner {width: 100% !important; height: 100% !important;} #banner img {object-fit: cover;}";\n iframe.contentDocument.body.append(style);\n iframe.style = "width: 100vw; height: 100vh;";\n } else {\n var observer = new MutationObserver(function(mutations, obs) {\n for (var mutation of mutations) {\n var iframe = mutation.addedNodes[0];\n if (iframe && iframe.nodeName === "IFRAME") {\n iframe.style = "width: 100vw; height: 100vh;";\n iframe.dataset.contents += "<style>#banner {width: 100% !important; height: 100% !important;} #banner img {object-fit: cover;}</style>";\n obs.disconnect();\n }\n }\n });\n observer.observe(document.body, { childList: true, subtree: true });\n }\n }\n }\n ';const n=document.createElement("style");return n.textContent="\n html, body, adfm-ad, #sf_align, .adform-adbox, .adform-adbox img {\n width: 100% !important;\n height: 100% !important;\n object-fit: cover;\n max-width: 100vw;\n }\n ",e+n.outerHTML+t.outerHTML})(n)),(e=>e.includes("529299503"))(n)&&(n=Vt(n)),(e=>e.includes("de17a"))(n)&&(n=(e=>Bt(e)?e:e.replace("<iframe ","<iframe onload=\"\n var f = document.querySelector('iframe');\n if (!f) return;\n var s = f.style;\n s.transform = 'scale(' + (window.innerHeight / Number(f.height)).toFixed(2) + ')';\n s.right = parseInt((Number(f.width) - window.innerWidth) / 2) + 'px';\n s.bottom = parseInt((Number(f.height) - window.innerHeight) / 2) + 'px';\n s.position = 'relative';\n \" "))(n)),Bt(n)&&(n=(e=>{let t=e.replace("<html>",'<html style="height: 100%;">');return t=t.replace("</iframe>","</iframe><style>#sf_align {height: 100%;} #sf_align iframe {height: 100vh;}</style>"),t=t.replace('<body style="','<body style="height: 100%; '),t})(n)),(e=>e.includes("kreateam.io"))(n)&&(n=(e=>{let t=e.replace("<html>",'<html style="height: 100%;">');return t=t.replace("</div>","</div><style>#sf_align {height: 100%;} #sf_align iframe {height: 100vh;}</style>"),t=t.replace('<body style="','<body style="height: 100%; '),t})(n)),Rt(t)&&(n=(e=>{const t=document.createElement("script");t.textContent='var frame = window.frameElement;\n if (frame) {\n frame.style.width = "100vw";\n frame.style.height = "100vh";\n }';const n=document.createElement("div");return n.innerHTML=e,n.appendChild(t),n.innerHTML})(n)),n},on=()=>{tn=null;const e=window.visualViewport,t=e?e.height:window.innerHeight,n=e?e.width:window.innerWidth,i=e?e.offsetLeft:0,o=document.documentElement;o.style.setProperty("--advertory-fullscreen-scroll-vh",`${t}px`),o.style.setProperty("--advertory-fullscreen-scroll-vw",`${n}px`),o.style.setProperty("--advertory-fullscreen-scroll-left",`${i}px`)},rn=()=>{tn||(tn=window.requestAnimationFrame(on))},an=(e,t)=>{var n,i,o,r;const{country:a}=l.get(),{targetId:d}=e;document.documentElement.style.setProperty("--advertory-ios-safe-area-top-fix",null!==(n=null==t?void 0:t.iosSafeAreaTopFix)&&void 0!==n?n:"0px"),(e=>{const{articlesContainerWidth:t=1302,backgroundColor:n="#fff",foregroundColor:i="#fff",margin:o="16px 0",beforeContentValue:r=""}=e,a=t/2,d=document.createElement("style");d.innerHTML=`\n :root {\n --background: linear-gradient(\n to right,\n ${n} 0px,\n ${n} calc(50% - ${a}px),\n ${i} calc(50% - ${a}px),\n ${i} calc(50% + ${a}px),\n ${n} calc(50% + ${a}px),\n ${n} 100%\n ) !important;\n \n --advertory-fullscreen-scroll-wrapper-margin: ${o};\n }\n \n .advertory-fullscreen-scroll-wrapper {\n ${r&&"clip-path: polygon(0 -16px, 100vw -16px, 100vw 100dvh, 0 100dvh);\n -webkit-clip-path: polygon(0 -16px, 100vw -16px, 100vw 100dvh, 0 100dvh);"}\n }\n\n .advertory-fullscreen-scroll-wrapper:before, .advertory-fullscreen-scroll-wrapper:after {\n background: var(--background);\n content: '${r}' !important;\n }`,d.id="ad-fullscreen-scroll-wrapper-style",document.head.appendChild(d)})(null!==(i=null==t?void 0:t.overlayStyles)&&void 0!==i?i:{});const s=document.getElementById(d),c=null==s?void 0:s.parentElement;if(!s||!c)return;((e,t)=>{const n=(null==t?void 0:t.fadingHeaderEnabled)||!1,i=new IntersectionObserver(e=>Wt(e,n),{}),o=Gt(e);i.observe(e),n&&(Ht[o]=Xt(e,t))})(c,t),s.className=qt;const p=rt(e,_e)?"absolute":"fixed";s.style.position=p,c.className=zt,c.dataset.showTagSubscribeId=d,s.setAttribute("data-ad-label",en[a].adText),(null==t?void 0:t.moveCogwheelToTheLeft)&&(s.dataset.moveCogwheelToTheLeft="true"),rn(),window.addEventListener("resize",rn),null===(o=window.visualViewport)||void 0===o||o.addEventListener("resize",rn),null===(r=window.visualViewport)||void 0===r||r.addEventListener("scroll",rn)},dn=({targetId:e})=>{const t=(e=>{var t;const{requests:n}=window.apntag,i=Rt(e)?1:0;return null===(t=null==n?void 0:n.tags[e].adResponse.ads[i].rtb)||void 0===t?void 0:t.banner.content})(e);if(!t)return;((e,t)=>{const{requests:n}=window.apntag,i=Rt(e)?1:0,o=null==n?void 0:n.tags[e].adResponse.ads[i].rtb;o&&(o.banner.content=t)})(e,nn(t,e))},sn=e=>{var t;!document.querySelector(`#gdprAdTransparencyCogWheelButton-${e}`)&&(null===(t=window.gdpr)||void 0===t?void 0:t.setupButton)&&window.gdpr.setupButton(e)},ln=(e,t,n)=>{var i,o,r,a;const d=document.createElement("div");d.id=`${e}-button`,t.appendChild(d);(null===(o=null===(i=window.apntag.requests)||void 0===i?void 0:i.tags[e])||void 0===o?void 0:o.adResponse)||(null!==(r=(a=window.apntag).requests)&&void 0!==r||(a.requests={tags:{}}),window.apntag.requests.tags[e]=Object.assign(Object.assign({},window.apntag.requests.tags[e]),{adResponse:{ads:[{creative_id:n}]}})),sn(e);const s=d.firstElementChild;s&&t.insertBefore(s,d),d.remove()},cn="ad-loaded",pn=()=>e(void 0,void 0,void 0,function*(){const{prebid:e,tcf:t,country:n,isMobileApp:i,fullscreenScroll:o}=l.get();if(!(null==e?void 0:e.enabled))return;const{initNativeAd:r}=l.getHandlers(),{getConsentAsync:a}=I(t,0,n),d=yield a(),s=(()=>{let e=!1,t=[];const n={relevantCb:{timeout:1e3},auctionCb:{timeout:2e3}};return{getCancel:()=>e,setCancel:t=>{e=t},events:n,failsafeOnTimeout:i=>{const o=jt(),{prebid:{relevantCbTimeout:r}={}}=l.get(),a="relevantCb"===i&&r?r:n[i].timeout,d=setTimeout(()=>{!n[i].done&&!e&&(console.warn(`Doing failsafe loadTags() call after waiting too long for '${i}'`),e=!0,o.loadTags&&o.loadTags())},a);t.push(d)},cleanup:()=>{t.forEach(e=>clearTimeout(e)),t=[],e=!1,n.relevantCb.done=!1,n.auctionCb.done=!1}}})(),c=jt(),u=(()=>{const{requests:{user:e={userIds:[]},keywords:t={}}={}}=jt();return{user:e,keywords:t}})();s.failsafeOnTimeout("relevantCb");const{user:{externalUid:v=""}={},keywords:g}=u;(()=>{const e=$t();return e.cmd||(e.cmd=[]),e.cmd})().push(()=>{if(s.getCancel()||!c.loadTags)return p("core loadTags() call was cancelled",{cancel:s.getCancel(),apnTagLoadTags:!c.loadTags,condition:"or"}),void s.cleanup();const t=$t();s.events.relevantCb.done=!0,s.failsafeOnTimeout("auctionCb");const i=d?{gdpr:{cmpApi:"iab",timeout:8e3}}:{cmpApi:"none"};p("prebid consentManagement",i),t.addPrebidConfig(Object.assign(Object.assign({consentManagement:i,enableSendAllBids:!1},X(n)),Nt(g,v))),p("core add prebid config",Object.assign(Object.assign({consentManagement:i,enableSendAllBids:!1},X(n)),Nt(g,v))),t.loadPrebid({configId:e.id,manageAdserver:!1,collapseEmptyDivs:!1,collapseBeforeAdFetch:!1,noGpt:!0,noSlotReload:!0,loadUnknownSlots:!0,apntagCalls:{showTag:()=>{},loadTags:e=>{s.getCancel()||(s.events.auctionCb.done=!0,c.loadTags(e)),s.cleanup()}},customNativeRender:e=>{un(e,r)},directRenderFn:e=>{var t;const{settings:n,renderFn:i}=e,{bid:r,adDiv:a}=n||{};if(!a)return;const d=i(n),s=Object.assign(Object.assign({},r),{targetId:a.id,banner:!0}),l=a.id,c=document.getElementById(l);c&&(He(s)?(an(s,o),(e=>{const t=()=>{const t=e.contentDocument;if(!(null==t?void 0:t.body))return;const n=()=>{const e=t.querySelector("iframe");if(!e)return!1;const n=()=>{var t;const n=null===(t=e.contentDocument)||void 0===t?void 0:t.querySelector(".adn-ttpa-container");n&&(n.style.setProperty("bottom","10px","important"),n.style.setProperty("top","unset","important"))};return e.addEventListener("load",n),n(),!0};if(n())return;const i=new MutationObserver(()=>{n()&&i.disconnect()});i.observe(t.body,{childList:!0,subtree:!0})};e.addEventListener("load",t),t()})(d)):((e=>{if(!(null==e?void 0:e.classList.contains(qt)))return;e.classList.remove(qt),e.removeAttribute("style"),e.removeAttribute("data-ad-label");const t=e.parentElement;(null==t?void 0:t.classList.contains(zt))&&(t.classList.remove(zt),t.classList.remove(Mt))})(c),null===(t=null==c?void 0:c.parentElement)||void 0===t||t.classList.add("advertory-direct-render")),c.classList.add(cn),(null==r?void 0:r.creativeId)&&ln(l,c,Number(null==r?void 0:r.creativeId)))}}),p("core load prebid",{configId:e.id,manageAdserver:!1,collapseEmptyDivs:!1,collapseBeforeAdFetch:!1,noGpt:!0,noSlotReload:!0,loadUnknownSlots:!0,apntagCalls:{showTag:()=>{},loadTags:e=>{s.getCancel()||(s.events.auctionCb.done=!0,c.loadTags(e))}},customNativeRender:e=>{un(e,r)},directRenderFn:()=>{}})})}),un=(e,t)=>{var n;const{divId:i,native:o,bid:r}=e,a=document.querySelectorAll(`[id^=${i}]`)[0],d=`RY-${a.id}`;((e,t)=>{e.childNodes.forEach(e=>e.style.cssText="position: absolute; z-index: -1;");const n=document.createElement("div");n.setAttribute("id",t),e.appendChild(n)})(a,d);const s=null===(n=a.getElementsByTagName("iframe")[0])||void 0===n?void 0:n.contentWindow;t({native:o,targetId:d},l.get()),null==s||s.postMessage(JSON.stringify({message:"Prebid Response",ad:"\x3c!-- nothing --\x3e",adId:r.adId}),"*")},vn=(e,t,n)=>{const i=document.getElementById(`div_utif_${e}`);if(!i)return;const{apntag:o}=window,[r,a]=t;if(!i.dataset.lockedsize&&a&&r)i.style.width=`${r}px`,i.style.height=`${a}px`,n&&(o.resizeAd(i.id,[r,a]),i.dataset.lockedsize="true",i.dataset.lockedwidth=r.toString(),i.dataset.lockedheight=a.toString());else if(null==i?void 0:i.dataset.lockedsize){const{lockedwidth:e,lockedheight:t}=i.dataset;e&&t&&o.resizeAd(i.id,[e,t])}},gn=["netboard","board"];class hn{constructor(e,t){this.identityFacade=e,this.tracker=t}buildUrl(e,t){var n,i;const{editionName:o}=e,r=(()=>{const e=window.location.href;return new URL(e).searchParams.get("dre_override_inv_code")||""})(),a=JSON.stringify(null!==(i=null===(n=window.advertory)||void 0===n?void 0:n.renderedDrEditionAds)&&void 0!==i?i:[]),d=new URL("https://dr-edition-teaser-server.inventory.schibsted.io/editions"),{envId:s,spid:l}=t;return d.searchParams.append("editionName",o),r&&d.searchParams.append("urlData",r),a&&d.searchParams.append("excludedItems",a),l&&d.searchParams.append("spid",l),s&&d.searchParams.append("envid",s),d.toString()}fetchData(t){return e(this,void 0,void 0,function*(){var e,n,i;const o=yield this.identityFacade.getIdentityUser(),r=null!==(i=yield null===(n=null===(e=this.tracker)||void 0===e?void 0:e.getEnvironmentId)||void 0===n?void 0:n.call(e))&&void 0!==i?i:"",a=(null==o?void 0:o.userId)?String(o.userId):"",d=this.buildUrl(t,{envId:r,spid:a});try{p("Starting fetching DrEdition ad from URL:",d);const e={method:"GET"},t=yield z.get(d,e);return p("Fetch operation completed successfully."),t}catch(e){p("Error during fetch operation:",e)}return null})}}let mn=class{getDrEditionUTMParams(e,t){var n;const{title:i="",clientName:o,creativeId:r}=null!==(n=null==e?void 0:e.pulseData)&&void 0!==n?n:{},{editionName:a}=t,d=i.replace(/<[^>]*>/g,"");return Object.assign({utm_source:"vgfront",utm_content:a,utm_campaign:o,utm_medium:d},r&&{utm_id:`df-${r}`})}getUrlSearchParams(e,t,n){if(!e)return"";const i=this.getDrEditionUTMParams(t,n),o=new URLSearchParams(decodeURIComponent(e.search)),r=new URLSearchParams(e.search);return Object.entries(i).forEach(([e,t])=>{o.has(e)||r.set(e,null!=t?t:"")}),r.toString().replace(/\+/g,"%20")}getUrlWithParams(e,t){var n;const i=null===(n=null==e?void 0:e.pulseData)||void 0===n?void 0:n.url;if(!i)return"";const o=this.getDrEditionUTMParams(e,t),r=new URL(i);return Object.entries(o).forEach(([e,t])=>{r.searchParams.has(e)||r.searchParams.set(e,null!=t?t:"")}),r.toString()}handleVideo(t,n){return e(this,void 0,void 0,function*(){const{id:e,autoplay:i,mute:o,videoLoop:r,vendor:a}=n.videoConfiguration;t.classList.add("vgtv-video-container"),Object.assign(t.dataset,{vgtvVideoId:e,vgtvVendor:a,vgtvAutoplay:i,vgtvMuted:o,vgtvLoop:!!r,vgtvNa:!0,vgtvRecommended:!1,vgtvPulseProvider:"vg",vgtvPulseProductTag:"partnerstudio"})})}getPulseObjectId(){return"sdrn:vg:content:partnerstudio:element:partnerstudio:stats"}getPulsePageId(){return"sdrn:vg:frontpage:front"}getTags(e){var t;let n;if(n=e instanceof HTMLAnchorElement?e.href:null===(t=null==e?void 0:e.querySelector("a"))||void 0===t?void 0:t.href,!n)return[];const{host:i,pathname:o}=new URL(n);if(!i.includes("www.vg.no")&&!o.includes("annonsorinnhold"))return[n];const r=o.split("/");return r.length?[...r.filter(Boolean).slice(1).map(e=>e),n]:[n]}};const fn=e=>{const t=e.parentElement;t?t.classList.remove("dr-edition-lock-height"):p("Dr. Edition container does not have a parent element, cannot remove height lock.")};class yn{constructor(e,t,n,i){this.drEditionService=e,this.rendererManager=t,this.videoManager=n,this.pulseManager=i,this.drEditionAds=[]}fetchAndRenderAd(t,n){return e(this,void 0,void 0,function*(){var e,i;const{drEditionConfig:{containerSelector:o},renderAsBackfill:r=!1}=n,a=t.querySelector(o);if(!a)return void p(`Container with selector "${o}" not found.`);const d=yield this.drEditionService.fetchData(n);return(null==d?void 0:d.itemId)||r?!(null==d?void 0:d.itemId)&&r?(p("No Dr. Edition ads available to render. Collapsing whole placement."),ke(t.id),void fn(a)):((null==d?void 0:d.itemId)&&r&&(p("Dr. Edition ad available to render as a Xandr backfill."),Ee(t.id)),void(d?(d.css&&((e,t)=>{const n=document.createElement("link");n.rel="preload",n.href=e,n.as=t,document.head.appendChild(n)})(d.css,"style"),yield this.rendererManager.render(a,d,n),yield null===(e=this.videoManager)||void 0===e?void 0:e.handle(d,n),fn(a),this.drEditionAds.push(d),window.advertory=window.advertory||{},window.advertory.renderedDrEditionAds=window.advertory.renderedDrEditionAds||[],window.advertory.renderedDrEditionAds.push(d.itemId),this.observeAdView(t,d,n),null===(i=t.querySelector("a"))||void 0===i||i.addEventListener("pointerup",()=>null)):fn(a))):(p("No Dr. Edition ads available to render. Hiding Dr. Edition and rendering Xandr backfill."),this.hideDrEdition(a),this.showBackfill(t),void fn(a))})}observeAdView(e,t,n){this.observeCarousel(e,t,n)||((e,t,n={threshold:.5})=>{new IntersectionObserver(([e],n)=>{e.isIntersecting&&(t(),n.disconnect())},n).observe(e)})(e,()=>this.pulseManager.trackContentView(e,t,n),{threshold:.5})}showBackfill(e){var t;const n=e.querySelector(".fallback");if(!n)return;n.style.display="block";const i=null!==(t=n.dataset.fallbackTargetId)&&void 0!==t?t:"";Ee(i)}hideDrEdition(e){e.style.display="none"}observeCarousel(e,t,n){const i=e.querySelector(".dr-edition-slider");if(!i)return!1;let o=null;const r=new IntersectionObserver(e=>{e.forEach(e=>{e.isIntersecting&&e.intersectionRatio>=.9&&(o&&clearTimeout(o),o=setTimeout(()=>{e.target.onclick=()=>this.pulseManager.trackContentClick(e.target,t,n),this.pulseManager.trackContentView(e.target,t,n)},500)),[...i.children].forEach(e=>{r.observe(e)})})},{threshold:[.9]});return[...i.children].forEach(e=>{r.observe(e)}),!0}}class bn{constructor(e,t){this.newsroomStrategy=e,this.pulseManager=t}render(t,n,i){return e(this,void 0,void 0,function*(){if(!(null==n?void 0:n.itemId))return;const{getConsentAsync:e}=I(i.tcf,i.isMobileApp,i.country),o=yield e(),r=i.device===te.MOBILE?n.mobileHTML:n.desktopHTML;const a=o?r:r.replace(/<img [^>]*class="tracking-pixel"[^>]*>/g,"");t.innerHTML=a,t.querySelectorAll("a").forEach(e=>{var t,o,r;e.search=null!==(r=null===(o=(t=this.newsroomStrategy).getUrlSearchParams)||void 0===o?void 0:o.call(t,e,n,i))&&void 0!==r?r:"",e.onclick=()=>this.pulseManager.trackContentClick(e,n,i)})})}}class wn{constructor(e){this.strategy=e}handle(t,n){return e(this,void 0,void 0,function*(){const{videoConfiguration:{id:e,preview:i}={}}=t;(e||i)&&(yield this.importScript(n),yield this.createVideoElement(t,n))})}importScript(t){return e(this,void 0,void 0,function*(){const e=t.drEditionConfig.videoScriptUrl,n=document.querySelector(`script[src="${e}"]`);if(e&&!window.autoplayQueue&&!n)try{yield _t(e)}catch(e){p("Error! Failed to prepare SVP player script for Dr. Edition!",e)}})}createVideoElement(t,n){return e(this,void 0,void 0,function*(){const e=document.createElement("div"),{node:i}=t.videoConfiguration,o=[...document.querySelectorAll(`#${i}`)||[]].find(e=>0===e.children.length);if(this.handlePreviewVideo(t,n))return;this.strategy.handleVideo(e,t),null==o||o.appendChild(e),window.autoplayQueue=window.autoplayQueue||[],window.autoplayQueue.push(e=>{e.parse()});const r=null==o?void 0:o.parentNode;if(!r)return;const a=r.closest("a");r.addEventListener("click",e=>{const t=e.target.closest("a");a!==t&&t||(e.stopPropagation(),e.preventDefault())})})}handlePreviewVideo(e,t){var n,i,o;const{preview:{url:r,thumbnail:a}}=null!==(n=e.videoConfiguration)&&void 0!==n?n:{};if(!r)return!1;const d=document.querySelector(".dr-edition-preview .preview-video");return!!d&&(d.setAttribute("src",r),d.setAttribute("playsinline",""),!(!d||!a)&&(null===(o=(i=t.drEditionConfig).addPreviewVideo)||void 0===o||o.call(i,d),!0))}}let xn=class{constructor(e,t){this.pulse=e,this.newsroomStrategy=t}getEventInput(e,t,n,i){return{}}mapPageType(e){return{front:"Frontpage",article:"Article",section:"Article",collection:"Article",other:"Article"}[e||"front"]||"Frontpage"}getArticleId(){return location.pathname.split("/").slice(-2,-1).pop()||""}getTeaserElementText(e,t){if(!e)return"";const n=e.querySelector({title:".dr-edition-title",subtitle:".dr-edition-subtitle",image:"img.teaser-main-image"}[t]);if(!n)return"";if("image"===t)return n.src||"";const i=null==n?void 0:n.textContent;return i?i.trim():""}getEventTarget(e,t){const{itemId:n,pulseData:{url:i}={}}=t,o=this.getTeaserElementText(e,"title");return{id:n,name:this.normalizePlacementTitle(null!=o?o:""),type:"Page",url:i}}normalizePlacementTitle(e){return e.replace(/<[^>]+>/gi,"").replace(/[^a-z0-9æøå\s_-]/gi,"")}trackContentView(t,n,i){return e(this,void 0,void 0,function*(){var e,o,r,a,d,s,l,c;const p=new CustomEvent("advertory:partnerstudioAdImpression",{detail:{ad:i.editionName}});if(window.dispatchEvent(p),!this.pulse)return;const u=this.getEventInput(t,n,i,"view");(null===(e=this.pulse)||void 0===e?void 0:e.trackLegacyViewUIElement)?null===(r=null===(o=this.pulse)||void 0===o?void 0:o.trackLegacyViewUIElement)||void 0===r||r.call(o,u):(null===(a=this.pulse)||void 0===a?void 0:a.trackViewUIElement)?null===(s=null===(d=this.pulse)||void 0===d?void 0:d.trackViewUIElement)||void 0===s||s.call(d,u):null===(c=null===(l=this.pulse)||void 0===l?void 0:l.trackElementView)||void 0===c||c.call(l,u)})}trackContentClick(t,n,i){return e(this,void 0,void 0,function*(){var e,o,r,a,d,s;if(!this.pulse)return;const l=this.getEventInput(t,n,i,"click");this.pulse.trackLegacyClickUIElement?null===(o=(e=this.pulse).trackLegacyClickUIElement)||void 0===o||o.call(e,l):this.pulse.trackClickUIElement?null===(a=(r=this.pulse).trackClickUIElement)||void 0===a||a.call(r,l):null===(s=(d=this.pulse).trackElementClick)||void 0===s||s.call(d,l)})}};class kn extends xn{constructor(e,t,n){super(e,t),this.pulse=e,this.newsroomStrategy=t,this.pageType=n}getEventBaseData(e,t,n){const{pulseData:{title:i,clientName:o="",creativeId:r}={}}=t,{columnName:a,primaryPosition:d}=n;return{"@type":"UIElement",elementType:"Teaser",layout:{elementSize:"large",imageUrl:"",name:"large"},name:i,placement:{columnName:a,primaryPosition:d},"spt:custom":{is_sponsored:!0,sponsor:o,"spt:creativeId":r},url:location.origin}}getEventInput(e,t,n){return{object:this.getEventBaseData(e,t,n),target:this.getEventTarget(e,t)}}}let En=class extends xn{constructor(e,t,n){super(e,t),this.pulse=e,this.newsroomStrategy=t,this.pageType=n}getEventBaseData(e,t,n){var i,o,r,a,d,s;const{itemId:l,pulseData:{clientName:c,creativeId:p}={}}=t,u=n.editionName,v=this.mapPageType(this.pageType),g=null===(i=this.newsroomStrategy)||void 0===i?void 0:i.getPulsePageId(this.pageType||"front",this.getArticleId());return{"@id":null!==(a=null===(r=null===(o=this.newsroomStrategy)||void 0===o?void 0:o.getPulseObjectId)||void 0===r?void 0:r.call(o))&&void 0!==a?a:u,"@type":"UIElement",position:u,elementType:"Article",custom:{customer:c,creativeId:null!=p?p:l},page:{"@id":null!=g?g:u,"@type":v,url:location.origin},tags:null===(s=null===(d=this.newsroomStrategy)||void 0===d?void 0:d.getTags)||void 0===s?void 0:s.call(d,e)}}getEventInput(e,t,n,i){return{object:this.getEventBaseData(e,t,n),partnerstudio:this.getEventPartnerstudioData(e,t,n,i),target:this.getEventTarget(e,t),provider:this.getProviderData()}}getEventPartnerstudioData(e,t,n,i){var o,r,a,d;const{pulseData:{algorithm:s="sov",clientName:l,creativeId:c,editionId:p,itemId:u,url:v,probability:g}={}}=t,h=Math.floor(Date.now()/1e3),m=this.getTeaserElementText(e,"title"),f=this.getTeaserElementText(e,"subtitle"),y=this.getTeaserElementText(e,"image"),b=null!==(d=null!==(a=null===(r=null===(o=this.newsroomStrategy)||void 0===o?void 0:o.getUrlWithParams)||void 0===r?void 0:r.call(o,t,n))&&void 0!==a?a:v)&&void 0!==d?d:"";return{algorithm:s,clientName:l,probability:g,creativeId:c,device:n.device,editionId:p,itemId:u,link:b,placement:n.editionName,subtitle:f,time:h,title:m,type:i,imageUrl:y,frontId:86,tracking_type:"ad",xandrAdLoaded:!1}}getProviderData(){return{productTag:"partnerstudio"}}};const Tn={SVD:"svd",VG:"vg",GODARE:"godare",AFTENPOSTEN:"aftenposten",SA:"sa",BT:"bt",AFTONBLADET:"aftonbladet",E24:"e24",MINMOTE:"minmote",PENT:"pent",GODT:"godt",TEK:"tekno",KLART:"klart",TVNU:"tvnu",POLARIS:"polaris",KOKET:"koket",TV4:"tv4",FOTBOLLSKANALEN:"fotbollskanalen"},In={FRONT:"front"},An=t=>e(void 0,void 0,void 0,function*(){var e,n;return(null===(e=null===window||void 0===window?void 0:window.SVP)||void 0===e?void 0:e.Player)?new window.SVP.Player(t):((()=>{const e="svp-player-sdk",t=document.querySelector(e),n=Array.from(document.querySelectorAll('script[src^="https://cdn.stream.schibsted.media/player"]'));if(t||n.length>0)return;const i=document.createElement("script");i.id=e,i.src="https://cdn.stream.schibsted.media/player/3.78.1/player.min.js",i.async=!0;try{i.src=i.src.replace("player.min","player.next.min")}catch(e){console.error("Failed to set player.next.min source:",e)}document.head.insertBefore(i,document.head.firstChild)})(),(null===(n=window.SVP)||void 0===n?void 0:n.isLoaded)?new window.SVP.Player(t):yield new Promise(e=>{window.addEventListener("onSvpPlayerReady",()=>e(new window.SVP.Player(t)))}))}),Sn={ContentMutePlugin:e=>{window.SVP.Player.Plugins.register({getName:()=>"ContentMutePlugin",initialize(){},setup(){const t=this.player.config.get("mute");this.container=e||this.player.getContainer(),this.muted=t,t&&this.listenToOnce(this.player,"ready",this.renderButtonElement,this)},getButtonElement(){const e=document.createElement("button");e.className="player-plugin-content-mute";const t=document.createElement("span");return t.className="volume-button-icon",e.appendChild(t),e},renderButtonElement(){this.buttonElement=this.getButtonElement(),this.buttonElement.addEventListener("click",this.onButtonClick.bind(this)),this.container.appendChild(this.buttonElement),this.isVideo()||(this.buttonElement.style.display="none"),this.getJWPlayer()&&this.getJWPlayer().on("mute",this.onMuteChange,this)},onButtonClick(){this.getJWPlayer()&&(this.container.classList.add("has-interacted"),this.muted=!this.muted,this.getJWPlayer().setMute(this.muted))},onMuteChange(e){this.muted=e.mute,this.muted?this.buttonElement.classList.remove("content-video-volume-on"):this.buttonElement.classList.add("content-video-volume-on")},isVideo(){return"video"===this.player.getRawAsset().assetType},getJWPlayer(){return this.player.model.player}})},IntegrationMenu:()=>{window.SVP.Player.Plugins.register({getName:()=>"IntegrationMenu",setup(){return e(this,void 0,void 0,function*(){yield Promise.resolve().then(function(){return cr})})}})}};class Cn{handleVideo(t,n){return e(this,arguments,void 0,function*(t,{videoConfiguration:{id:n,node:i,autoplay:o,mute:r,vendor:a}}){yield e(void 0,void 0,void 0,function*(){return yield new Promise(e=>{var t;Boolean(null===(t=window.SVP)||void 0===t?void 0:t.Player)?e(!0):window.addEventListener("onSvpPlayerReady",()=>e(!0))})});const d=["ContentMutePlugin"],s=this.createPlayerOverlay(t);var l,c;c=s,null==(l=d)||l.forEach(e=>{Sn[e](c)});const p={id:n,node:i,autoplay:o,mute:r,vendor:a,autopause:"viewable",maxBitrate:600,pulse:{provider:"e24"},recommended:{autoplay:!1,next:{countdown:10}},skin:{name:"e24-default",url:""}},u=yield An(p);u.once("assetReady",()=>{((e,t)=>{null==t||t.forEach(t=>{const n=window.SVP.Player.Plugins.get(t);e.addPlugin(new n)})})(u,d)}),u.once("ready",()=>{const e=t;new MutationObserver(t=>{t.forEach(({type:t,attributeName:n})=>{"attributes"===t&&"class"===n&&(e.classList.contains("jw-state-playing")?s.classList.add("is-playing"):s.classList.remove("is-playing"),e.classList.contains("jw-flag-user-inactive")?s.classList.add("is-inactive"):s.classList.remove("is-inactive"))})}).observe(e,{attributes:!0,attributeFilter:["class"]})}),u.once("PulseStats:ready",()=>e(this,void 0,void 0,function*(){const e=yield u.getPlugin("PulseStats").getTracker();null==e||e.update({provider:{id:"e24",productTag:"partnerstudio"}})}))})}getPulseObjectId(){return"sdrn:e24:content:partnerstudio:element:partnerstudio:stats"}getPulsePageId(e,t){return e===In.FRONT?"sdrn:e24:frontpage:front":`sdrn:e24:article:${t}`}getTags(e){var t;let n;if(n=e instanceof HTMLAnchorElement?e.href:null===(t=null==e?void 0:e.querySelector("a"))||void 0===t?void 0:t.href,!n)return[];if(!n.includes("https://e24.no/annonsorinnhold/"))return[n];const{pathname:i}=new URL(n),o=i.split("/").filter(Boolean);return o.length?[...o.slice(1),n]:[n]}createPlayerOverlay(e){const t=document.createElement("div");t.classList.add("cm-custom-video-overlay"),e.parentElement&&(t.innerHTML=e.parentElement.innerHTML,e.parentElement.replaceChild(t,e));return t.addEventListener("click",e=>{e.stopPropagation(),e.preventDefault(),t.classList.add("has-interacted")}),t}}const Pn="https://www.aftonbladet.se/video-player-extras/latest/";class On{handleVideo(t,n){return e(this,arguments,void 0,function*(e,{videoConfiguration:{id:t,node:n,autoplay:i,mute:o,vendor:r}}){const a={id:t,node:n,autoplay:i,mute:o,vendor:r,autopause:"viewable",maxBitrate:600,pulse:{provider:"aftonbladet"},recommended:{autoplay:!1,next:{countdown:10}},skin:{name:"",url:""},plugins:{[`${Pn}cta-button.js`]:{name:"CtaButton",options:{type:"unmute"}},[`${Pn}external-link.js`]:{name:"ExternalLink"}}};yield An(a),this.addEditionVideoClass(e)})}addEditionVideoClass(e){var t;(null===(t=null==e?void 0:e.parentElement)||void 0===t?void 0:t.parentElement)&&e.parentElement.parentElement.classList.add("dr-edition-video-player")}getPulseObjectId(){return""}getPulsePageId(){return""}}const Ln=e=>null!==e&&"object"==typeof e&&!Array.isArray(e);class jn{handleVideo(t,n){return e(this,arguments,void 0,function*(t,{videoConfiguration:{id:n,node:i,autoplay:o,mute:r,vendor:a}}){const d={id:n,node:i,autoplay:o,mute:r,vendor:a,locale:"se",autopause:"viewable",maxBitrate:600,sharing:!1,recommended:!1,pulse:{provider:"svdse",decorator:(e,t)=>Object.assign(Object.assign({},Ln(e)?e:{}),{provider:Object.assign(Object.assign({},Ln(null==e?void 0:e.provider)?e.provider:{}),{productTag:"partnerstudio"})})},skin:{name:"svd-player",url:""},settings:{pulse:{host:"se-aftonbladet.videoplaza.tv",contentMetadata:{category:"SvD",tags:["standard-linears","pause",`video-${n}`]},requestSettings:{}}}},s=yield An(d);s.once("PulseStats:ready",()=>e(this,void 0,void 0,function*(){const e=yield s.getPlugin("PulseStats").getTracker();null==e||e.update({provider:{id:"svdse",productTag:"partnerstudio"}})}))})}getPulseObjectId(){return"sdrn:svdse:content:partnerstudio:element:partnerstudio:stats"}getPulsePageId(e,t){return e===In.FRONT?"sdrn:svdse:frontpage:front":`sdrn:svdse:article:${t}`}}let $n=class{handleVideo(e,t){}getPulseObjectId(){return""}getPulsePageId(e,t){return""}};const Nn=(e,t,n)=>{var i;const{publisher:o,pageType:r,country:a}=e,d={[Tn.VG]:new mn,[Tn.E24]:new Cn,[Tn.AFTONBLADET]:new On,[Tn.SVD]:new jn}[o]||new $n,s=new(a===x.SE?kn:En)(n,d,r),l=new hn(t,null!==(i=null==n?void 0:n.pulseTracker)&&void 0!==i?i:n),c=new bn(d,s),p=new wn(d);return new yn(l,c,p,s)},_n=()=>e(void 0,void 0,void 0,function*(){return yield new Promise(e=>{if("undefined"!=typeof window)if(window.Identity)e(window.Identity);else{const t=()=>{e(window.Identity)};window.addEventListener("identity-initialized",t,{once:!0})}else e(void 0)})});class qn{constructor(e){this.identity=e,this.getIdentityUser=this.getIdentityUser.bind(this),this.isUserLoggedIn=this.isUserLoggedIn.bind(this),this.onIdentityLogout=this.onIdentityLogout.bind(this)}getIdentityUser(){return e(this,void 0,void 0,function*(){var e;try{const t=yield null===(e=this.identity)||void 0===e?void 0:e.getUser();return null!=t?t:null}catch(e){return p("[Privacy Broker] User is not logged in."),null}})}isUserLoggedIn(){return e(this,void 0,void 0,function*(){var e,t;return null!==(t=yield null===(e=this.identity)||void 0===e?void 0:e.isLoggedIn())&&void 0!==t&&t})}onIdentityLogout(e){var t;null===(t=this.identity)||void 0===t||t.on("logout",e)}}const zn=(e,t,n)=>{const{wrapperSelector:i}=null==e?void 0:e.drEditionConfig,o=document.querySelectorAll(i),r=new IntersectionObserver((i,o)=>((e,t,n,i,o)=>{const r=Nn(n,i,o);e.forEach(e=>{var i,o,a;if(!e.isIntersecting)return;const d=e.target,s=null!==(i=d.dataset.editionName)&&void 0!==i?i:"",l=null!==(o=d.dataset.pulseColumnname)&&void 0!==o?o:"",c=null!==(a=d.dataset.pulsePrimaryposition)&&void 0!==a?a:"";r.fetchAndRenderAd(d,Object.assign(Object.assign({},n),{editionName:s,columnName:l,primaryPosition:c})),t.unobserve(d)})})(i,o,e,t,n),{rootMargin:"400% 0px"});o.forEach(e=>r.observe(e))},Dn=()=>e(void 0,void 0,void 0,function*(){try{(()=>{const e=document.createElement("script");e.setAttribute("src","https://ads.inventory.schibsted.io/ad-service/ad-banner-sponsor-advertisement/ad.js"),e.setAttribute("type","text/javascript"),e.setAttribute("async","true"),document.head.appendChild(e)})(),(()=>{const e=document.createElement("div");e.setAttribute("id","ads-advertory-anchor"),e.classList.add("subscribe_box"),e.classList.add("ad-box"),e.classList.add("leftAd"),e.classList.add("netboard"),e.classList.add("advert"),e.classList.add("module"),e.classList.add("banner"),e.classList.add("leaderboard"),e.classList.add("adsbygoogle"),e.classList.add("ad-banner"),e.classList.add("ad-container"),e.classList.add("adsbox"),e.classList.add("sidebar-ads"),e.classList.add("banner-ads"),e.style.opacity="0",e.style.width="1px",e.style.height="1px",e.style.minWidth="0px",e.style.minHeight="0px",e.style.maxWidth="1px",e.style.maxHeight="1px",e.style.position="absolute",e.style.top="0",e.style.boxSizing="border-box",e.style.margin="0",e.style.padding="0",document.body.appendChild(e)})()}catch(e){console.error("Error running adblock scripts:",e)}}),Mn=[],Bn=(t,n)=>e(void 0,void 0,void 0,function*(){var e;const{pulse:i,tcf:o,deviceType:r,drEdition:a,publisher:d,pageType:s,country:l,isMobileApp:c}=t;if(!(yield A(o,c,l,"handleDrEditionBackfill")))return;const u=((e,t)=>{var n;const{deviceType:i,placements:o,drEdition:{fallbackGlobalEditionName:r}={}}=e,a=o[i]||o.desktop,d=le(t.targetId),s=a.find(e=>e.id===d),l=gn.some(e=>d.startsWith(e)),c=Mn.includes(d),p=(null===(n=null==s?void 0:s.drEdition)||void 0===n?void 0:n.editionName)||r;return s&&l&&!c&&p?(Mn.push(d),Object.assign(Object.assign({},s),{drEdition:Object.assign(Object.assign({},s.drEdition),{editionName:p})})):null})(t,n);if(!u)return;if(!(null==i?void 0:i.instance))return void p("Pulse has not been passed as a prop, aborting");const v=yield _n(),g=new qn(v),h=Nn({publisher:d,pageType:s,country:l},g,null==i?void 0:i.instance),m=document.getElementById(n.targetId);if(!m||!a)return;m.classList.value="";const f=document.createElement("div");f.className=a.containerSelector.replace(/^[.#:[\]]+/,""),m.innerHTML=f.outerHTML;const y={editionName:(null===(e=null==u?void 0:u.drEdition)||void 0===e?void 0:e.editionName)||"",drEditionConfig:a,device:r,tcf:o,isMobileApp:c,country:l,renderAsBackfill:!0};yield h.fetchAndRenderAd(m,y)}),Rn=(t,n)=>{var i,o,r,a;if(!(()=>{const e=document.getElementById("ads-advertory-anchor");return!(e&&"none"!==getComputedStyle(e).display&&window.advertoryFluepapir)})())return void p("Ad block not enabled, Dr. Edition backfills will not be rendered");p("Ad block is enabled, Dr. Edition backfills will be rendered");const d=null!==(a=null===(r=null===(o=null===(i=t.finnBlink)||void 0===i?void 0:i.replacementConfig)||void 0===o?void 0:o.adsToReplace)||void 0===r?void 0:r.map(([e])=>e))&&void 0!==a?a:[],s=new IntersectionObserver((n,i)=>e(void 0,void 0,void 0,function*(){for(const e of n){if(!e.isIntersecting)continue;const n=e.target;i.unobserve(n),yield Bn(t,{targetId:n.id})}}),{rootMargin:"400% 0px"});n.filter(e=>!d.some(t=>e.id.startsWith(t))).forEach(e=>{const t=document.getElementById(e.id);t&&s.observe(t)})},Fn="collapseAd",Vn="hideAd",Un="resizeAd",Hn="renderDrEditionFallback",Wn="wallpaperImageUrl",Kn="wallpaperColor",Gn="velvet",Jn=[Un,Wn,Kn,Fn,Vn,Hn,Gn];let Yn;const Xn=e=>{if("object"==typeof e)return e;if(t=e,we.test(t)){const t=e.replace(/^wallpaper:url:/,"");return{name:Wn,wallpaperImageUrl:t}}var t;if((e=>e.startsWith("wallpaper:color:"))(e)){const t=e.replace(/^wallpaper:color:/,"");return{name:Kn,wallpaperColor:t}}if(e.startsWith(Hn)){const t=e.split(":")[1];return{name:Hn,targetId:t}}if(e.startsWith(Fn)||e.startsWith(Vn)){const t=e.split(":")[1];return{name:Fn,targetId:t}}if(e.includes("name")&&Jn.some(t=>e.includes(t)))try{return JSON.parse(e)}catch(e){}},Qn=e=>{if(!["http://acdn.adnxs-simple.com","https://acdn.adnxs-simple.com","https://crcdn01.adnxs-simple.com","http://crcdn01.adnxs-simple.com","https://acdn.adnxs.com","http://acdn.adnxs.com","https://adsdk.microsoft.com","https://adsdk.bing.net","https://adsdkprod.azureedge.net"].includes(e.origin.trim()))return;const{data:t}=e;if(!t)return;const n=Xn(t);if(!n)return;if(!n.name||!Jn.some(e=>n.name===e))return;const{name:i,targetId:o,wallpaperImageUrl:r,wallpaperColor:a,cmd:d,size:s}=n;i===Gn&&d&&(d.includes("noScroll")&&(Yn=(e=>{if(!e)return()=>{};const t=e.style.overflow;return e.style.setProperty("overflow","hidden"),()=>{e.style.setProperty("overflow",t)}})(document.querySelector("body"))),(d.includes("close")||d.includes("ended"))&&(null==Yn||Yn(),dispatchEvent(new CustomEvent("advertory:closeTakeover",{})))),i!==Fn&&i!==Vn||!o||ke(o),i===Un&&o&&d&&vn(o,d),i===Hn&&o&&(ke(o),Bn(l.get(),{targetId:o})),"resizeMediationAd"===i&&o&&s&&vn(o,s,!0),i===Wn&&r&&(e=>{const t=document.querySelector(`.${me}`);t&&(t.style.backgroundImage=`url(${e})`)})(r),i===Kn&&a&&(e=>{const t=document.querySelector(`.${me}`);t&&(t.style.backgroundColor=e)})(a)},Zn=e=>({rootMargin:`${e}px 0px ${e}px 0px`}),ei=()=>{const{publisher:t,country:n,finnBlink:i}=l.get(),{loadFinnBlinkAd:o,wallpaperHandlers:{adjustAdToHorseshoe:r}}=l.getHandlers(),a=window.apntag,d={publisher:t,country:n,finnBlink:i},s=e=>{Ee(e),ve(()=>a.showTag(e))};return{withXandrAd:s,withFinnBlinkAd:t=>e(void 0,void 0,void 0,function*(){yield o(t,d,null)}),withFullAdsChain:t=>e(void 0,void 0,void 0,function*(){yield o(t,d,s,()=>{Ie.getData("horseshoe").isAvailable&&r(t)})})}},ti=(e,t,n)=>{const i="true"===n.dataset.isFinnBlinkOnlyPlacement;return Ze(t)&&i?(p(`loading finn blink ad for blink only placement for ${t}`),void ei().withFinnBlinkAd(t)):Ze(t)?(p(`loading finn blink ad with full ads chain for ${t}`),void ei().withFullAdsChain(t)):void ve(()=>(p("core showTag",{id:t}),e.showTag(t)))},ni=(t,n)=>e(void 0,void 0,void 0,function*(){yield ge,yield he;const e=new IntersectionObserver((e,n)=>((e,t,n,i)=>{e.filter(({isIntersecting:e,target:{id:t}})=>e&&!t.includes("wallpaper")).forEach(e=>{const{target:o}=e,r=(e=>{const t=e.dataset.showTagSubscribeId;return!e.id.length&&t?t:e.id})(o),a=document.getElementById(r);p("core log from intersection observer handler",{targetId:r,element:a}),n(window.apntag,r,i),a&&(t.unobserve(a),t.disconnect())})})(e,n,ti,t),Zn(n));e.observe(t)}),ii=new Map,oi=["no-stavangeraftenblad","sa","no-aftenposten","aftenposten","no-bergenstidende","bt"],ri=".brandstudio-premium-content-widget",ai=({adWrapper:e,placementContainer:t})=>t.offsetHeight+(({adWrapper:e})=>{const{paddingTop:t,paddingBottom:n}=getComputedStyle(e);return parseFloat(t)+parseFloat(n)})({adWrapper:e}),di=({adWrapper:e,placementContainer:t})=>{const n=ai({adWrapper:e,placementContainer:t});var i;null==e||e.style.setProperty("height",`${n}px`),Se(i=t),i.innerHTML=""},si=e=>{e&&e.style.getPropertyValue("height")&&e.style.removeProperty("height")},li=({adWrapper:e,placementContainer:t})=>{const{publisher:n}=l.get(),i=oi.includes(n)&&Boolean(t.closest(ri));const o=i?t.closest(ri):null,r=new MutationObserver(t=>{t.forEach(({addedNodes:t})=>{t.forEach(t=>{const n=t instanceof HTMLElement,a=n&&t.matches("iframe, article")&&e;if(!n||!i&&!a||i&&!o)return;if(a)return si(e),void r.disconnect();const d=t.closest('[style*="height"]'),s=o;d&&s.contains(d)?si(d):s.hasAttribute("style")&&si(s),r.disconnect()})})});try{r.observe(t,{childList:!0,subtree:!0})}catch(e){r.disconnect()}},ci=(e,t,n,i,o,r)=>{var a;const d=performance.now(),s=null!==(a=ii.get(t))&&void 0!==a?a:0,c=((e,t)=>!!t&&e+t<(new Date).getTime())(i,o)&&n<0;d-s>=o&&c&&(ii.set(t,d),((e,t,n)=>{const{country:i}=l.get(),o=null==n?void 0:n.parentElement;o&&n&&di({adWrapper:o,placementContainer:n}),ve(()=>{e.setKeywords([t],{[`${$(i)}-adreload`]:"1"},{overrideKeyValue:!0}),e.refresh([t])})})(e,t,r))},pi=(e,t,n)=>{const i=new IntersectionObserver((e,i)=>((e,t,n,i)=>{e.filter(({isIntersecting:e})=>e).forEach(e=>{const{target:o,boundingClientRect:r}=e;t(window.apntag,o.id,r.y,n,i,o)})})(e,ci,t,n),Zn(300));i.observe(e)},ui=(e,t=6)=>{const n=[];for(let i=0;i<e.length;i+=t){const o=e.slice(i,i+t);n.push(o)}return n},vi=()=>navigator&&navigator.userAgent.match(/chrome/i)?null:navigator&&navigator.userAgent.match(/apple/i),gi=(e,t=0)=>{const n=e.getBoundingClientRect(),i=window.innerHeight;return n.bottom>-t&&n.top<i+t},hi=e=>{const{refreshConfig:{visibilityStateRefreshEnabled:t=!1}={}}=l.get();if(!t)return;const n=()=>{"visible"===document.visibilityState&&document.removeEventListener("visibilitychange",n),wi(e)};"visible"!==document.visibilityState&&document.addEventListener("visibilitychange",n)},mi=(e,t,n)=>{const i=document.querySelectorAll('[data-bf-cache-refresh="true"]');for(const o of i){const i=e.find(e=>{var t;return e.id===(null===(t=o.firstElementChild)||void 0===t?void 0:t.id)&&e.bfCacheRefresh}),r=null==i?void 0:i.threshold;gi(o,r)&&i&&(Ae(i.id),n.length&&o.classList.remove(...n),wi([i],t))}},fi=e=>{const{refreshConfig:{backForwardNavigationRefreshEnabled:t=!1}={},siteSpecificConfig:{classesToRemoveOnRefresh:n=[]}={},isMobileApp:i}=l.get();t&&(e.forEach(({id:e})=>{const t=yi(e);t&&(t.dataset.bfCacheRefresh="true")}),i?((e,t)=>{document.addEventListener("visibilitychange",()=>{"visible"===document.visibilityState&&mi(e,!0,t)})})(e,n):((e,t)=>{window.addEventListener("pageshow",n=>{const i=()=>{window.scrollY>0&&(window.removeEventListener("scroll",i),mi(e,!1,t))};n.persisted&&(vi()?window.addEventListener("scroll",i,{passive:!0}):mi(e,!1,t))})})(e,n))},yi=e=>{var t,n;return null!==(n=null===(t=document.querySelector(`#${e}`))||void 0===t?void 0:t.parentElement)&&void 0!==n?n:null},bi=e=>{const{id:t,allowedFormats:n}=e,i=(e=>{if(!e)return[];try{return JSON.parse(e.dataset.adSizes||"[]")}catch(e){return[]}})(yi(t)),o=(e=>1===e[0]&&1===e[1])(i),r={sizes:[i],allowedFormats:o?n:n.filter(e=>"native"!==e),allowSmallerSizes:!1};return o||(r.native=void 0),r},wi=(e,t=!1)=>{const{requestSize:n=d}=l.get(),i=e.map(({id:e})=>e),o=ui(i,n);if(t)for(const t of e){const e=bi(t);window.apntag.modifyTag(t.id,e)}for(const e of o)ve(()=>window.apntag.refresh(e))};const xi="#fff",ki="#0098da",Ei=(e,t=!0)=>{(e===dt||e===st)&&(e=>{e?setTimeout(()=>window.scrollTo(0,0),100):window.scrollTo(0,10)})(t)},Ti=()=>{const e=parseInt(document.body.dataset.scrollY||"0",10);document.body.style.top="",window.scrollTo(0,e),document.body.classList.remove("page-locked")},Ii=e=>{document.body.style.overflow=e?"initial":"hidden"},Ai=e=>{const t=Ci(e),n=Si(e);(e=>{e.classList.toggle("takeover-ad-hidden",!0)})(e),Ii(!0),e.style.display="none",window.removeEventListener("keydown",t),window.removeEventListener("advertory:closeTakeover",n)},Si=e=>{const t=()=>Ai(e);return window.addEventListener("advertory:closeTakeover",t),Ti(),t},Ci=e=>{const t=t=>{["Enter","Escape"].includes(t.key)&&Ai(e)};return Ti(),window.addEventListener("keydown",t),t},Pi=e=>{const t=e.querySelector(".advertory-splash-navbar-wrapper");t&&(Ci(e),Si(e),Ti(),t.addEventListener("click",()=>{Ai(e)}),Ii(!1))},Oi=e=>{(e=>{window.addEventListener("scroll",()=>{e.getBoundingClientRect().bottom,(e=>{const t=e.getBoundingClientRect().bottom;e.style.opacity=""+t/e.offsetHeight})(e)},{passive:!0})})(e),Si(e);const t=document.querySelector("header");document.querySelectorAll(".smooth-close-takeover").forEach(e=>e.addEventListener("click",()=>null==t?void 0:t.scrollIntoView({behavior:"smooth"})))},Li=e=>{(e=>{window.addEventListener("advertory:closeTakeover",()=>Ai(e))})(e)},ji=e=>{const{takeover:{splash:{showAnnonsLabel:t=!1}={}}={}}=l.get(),n=e.querySelectorAll(".advertory-splash-navbar-wrapper"),i=document.querySelector(".advertory-takeover-label");Array.from(n).forEach(e=>e.style.display="flex"),t&&i&&(i.style.display="flex",i.innerText=en.se.adText),e.classList.toggle("advertory-splash-wrapper",!0)},$i=e=>{const t=document.querySelectorAll(".advertory-topscroller-elements");Array.from(t).forEach(e=>e.style.display="flex");const n=document.querySelector(".advertory-takeover-label");n&&(n.style.display="flex",n.innerText=en.no.adText,n.classList.add("takeover-topscroller-label"),e.classList.toggle("topscroller-wrapper",!0))},Ni=e=>{const t=document.querySelectorAll(".advertory-welcome-page-elements");Array.from(t).forEach(e=>{e.style.display="flex",e.style.animation="elementsAnimation 1.5s ease-out forwards"});const n=document.querySelector(".advertory-takeover-label");n&&(n.style.display="flex",n.innerText=en.se.adText,e.classList.toggle("welcome-page-wrapper",!0))},_i=e=>{const t=document.querySelector(".advertory-takeover-label");t&&(t.style.display="flex",t.innerText=en.se.adText,e.classList.toggle("advertory-impact-wrapper",!0))},qi=()=>{const e=document.querySelector(".welcome-page-wrapper, .topscroller-wrapper, .advertory-splash-wrapper");if(!e)return;let t=0;new IntersectionObserver(e=>{e.forEach(e=>{var n;if(e.isIntersecting){window.dispatchEvent(new CustomEvent("advertory:takeoverInView"));(null!==(n=Array.from(e.target.classList))&&void 0!==n?n:[]).includes("advertory-splash-wrapper")&&(()=>{const e=window.scrollY||0;document.body.dataset.scrollY=e.toString(),document.body.style.top="0",document.body.classList.add("page-locked"),document.documentElement.scrollTop=0})(),t++}else t>0&&window.dispatchEvent(new CustomEvent("advertory:takeoverNotInView"))})},{root:null,rootMargin:"0px",threshold:0}).observe(e)},zi=(e,t)=>{let n=e;return e.includes("529299503")&&(n=(e=>{const t=document.createElement("script");return t.textContent=`(${Et})()`,e+t.outerHTML})(e)),n},Di=e=>{const t=(e=>{var t;const{requests:n}=window.apntag,i=Rt(e)?1:0;return null===(t=null==n?void 0:n.tags[e].adResponse.ads[i].rtb)||void 0===t?void 0:t.banner.content})(e);if(!t)return;((e,t)=>{const{requests:n}=window.apntag,i=Rt(e)?1:0,o=null==n?void 0:n.tags[e].adResponse.ads[i].rtb;o&&(o.banner.content=t)})(e,zi(t))},Mi=t=>e(void 0,void 0,void 0,function*(){const{takeover:e}=l.get(),{targetId:n}=t,i=document.querySelector(`#${n}`),o=document.querySelector(".advertory-takeover-wrapper");if(!i||!o||!e)return;const r=(e=>{const{width:t,height:n}=e;return ft(t,n)?at:rt(e,Be)?lt:yt()?st:dt})(t),a=o.offsetHeight,d=window.scrollY>a;o.style.display="block",!d&&Ei(r,!1),((e,t)=>{({[dt]:Ni,[at]:ji,[st]:$i,[lt]:_i})[t](e)})(o,r),qi(),((e,t)=>{({[dt]:Oi,[st]:Oi,[at]:Pi,[lt]:Li})[t](e)})(o,r),((e,t,n)=>{if(!n)return;({[dt]:()=>{const{buttonLabel:i}=xt(n,t);["#advertory-welcome-page-scroll-label","#advertory-welcome-page-scroll-image"].forEach(t=>{const n=e.querySelector(`${t}`);n&&(n.innerText=null!=i?i:"")})},[at]:()=>{const{themeColors:i,logotype:o,buttonLabel:r,showArrowIcon:a}=xt(n,t);["#advertory-splash-close-label",".advertory-splash-close","#advertory-splash-logotype",".advertory-splash-navbar-wrapper"].forEach(t=>{const n=e.querySelector(`${t}`);if(n){if("#advertory-splash-close-label"===t&&(n.innerText=null!=r?r:""),".advertory-splash-close"===t&&a){const e=document.createElement("img");e.setAttribute("src","data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAAAfQAAAH0Bx0gPAAAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAAABzSURBVDiNtdPJCYBADEDRzzRmE3ZgEV6tRHHpzELiIQrBZRajA7lk4EE2RIQjgApYgdbmY8EJaADZo3sDBKAvQa4JRYZc5D6pyJiDPMuKTCkkXp8icwxJd1mRxSC1/Q94328luJroGqNrkdyrzAfHVHzOG+8CKlLk+LO+AAAAAElFTkSuQmCC"),e.setAttribute("alt","close ad"),n.appendChild(e)}if("#advertory-splash-logotype"===t&&o&&(n.setAttribute("src",o.url),n.setAttribute("alt",o.alt)),".advertory-splash-navbar-wrapper"===t&&i){const{backgroundColor:e,color:t}=i;n.style.setProperty("background-color",null!=e?e:xi,"important"),n.style.color=null!=t?t:ki}}})},[st]:()=>{const{buttonLabel:i,showArrowIcon:o,showCloseButton:r=!0}=xt(n,t);["#advertory-topscroller-scroll-label","#advertory-topscroller-scroll-image",".advertory-topscroller-close"].forEach(t=>{const n=e.querySelector(`${t}`);n&&(".advertory-topscroller-close"!==t||r||(n.style.display="none"),"#advertory-topscroller-scroll-image"!==t||o||(n.style.display="none"),"#advertory-topscroller-scroll-label"===t&&(n.innerText=null!=i?i:""))})},[lt]:()=>{}})[t]()})(o,r,e),yield bt(),!d&&Ei(r,!0),kt(t,r)});Zt(".advertory-brandmetrics-survey{width:100%}");const Bi="advertory-brandmetrics-survey",Ri=()=>e(void 0,void 0,void 0,function*(){const{norstat:{enabled:t}={},country:n,isMobileApp:i,tcf:o}=l.get(),r=yield A(o,i,n,"norstat");if(!t||i||!r)return;const a=(e=>{const{ppid1:t,ppid2:n}=K.getPPIDs(),{ppid1:i,ppid2:o}=G.getPPIDs(),r=(new W).add(n,M[e]).add(t,B[e]).add(o,R[e]).add(i,F[e]);return`${r.buildNorstatPath()}?${r.buildNorstatQuery("alias").toString()}`})(n);((t,n,...i)=>{e(void 0,[t,n,...i],void 0,function*(e,t,n=!0){if(document.getElementById(t))return;const i=document.createElement("img");i.src=e,i.id=null!=t?t:"",n&&(i.style.display="none"),document.body.appendChild(i)})})(`https://sch-map.norstatsurveys.com/api/nids/${n===x.NO?"schibsted":"schibstedse"}/map/${a}`,"norstat")}),Fi=(e,t)=>t?Object.assign(Object.assign({},e),{"aa-sch-ssa-native-ad":"true","aa-sch-ssa-format":"NATIVE_CONTENT","aa-sch-ssa-market":"XNO","aa-sch-ssa-cat":["ssa_1","ssa_2","ssa_3","ssa_4","ssa_5","ssa_6","ssa_7","ssa_8","ssa_9","ssa_10","ssa_11","ssa_12","ssa_13","ssa_14","ssa_15","ssa_16","ssa_17","ssa_18","ssa_19","ssa_20","ssa_21","ssa_22","ssa_23","ssa_24","ssa_25","ssa_26","ssa_27","ssa_28","ssa_29","ssa_30"]}):e,Vi=e=>`externalImpId:'${e}'`,Ui=e=>{var t;const{forwardExternalImpId:n=!1,tracker:i}=l.get(),o=(e=>{var t;if(!e.positionConfig)return e;const n=e.keywords[`${N()}-count`],i=e.positionConfig.find(e=>e.adPositionIndex===n);if(!i)return e;const o=i.keywords?Object.assign(Object.assign({},e.keywords),i.keywords):e.keywords;return Object.assign(Object.assign({},e),{sizes:null!==(t=null==i?void 0:i.sizes)&&void 0!==t?t:e.sizes,keywords:o})})(e),{id:r,sizes:a,keywords:d,allowedFormats:s,invCode:c,ssa:u=!1,nativeCustomProperties:v,safeframeConfig:g,dynamicSizeWidthCheck:h=!1}=(e=>{var t;if(!e.takeoverCookieCapForSharedPlacement||ht())return e;const n=null===(t=e.keywords)||void 0===t?void 0:t["no-sno-adformat"],i=null==n?void 0:n.filter(e=>e!==st),o=Object.assign(Object.assign({},e.keywords),n&&{"no-sno-adformat":i}),r=e.sizes.filter(([e,t])=>4!==e||4!==t);return Object.assign(Object.assign({},e),{sizes:r,keywords:o})})(o),m=Object.assign({invCode:c,sizes:a,targetId:r,keywords:Fi(d,u),allowedFormats:s,dynamicSizeWidthCheck:h},g&&{safeframeConfig:g}),f=(e=>{var t,n,i,o,r,a,d;return e?(null===(t=null==e?void 0:e.instance)||void 0===t?void 0:t.state)?(null===(i=null===(n=null==e?void 0:e.instance)||void 0===n?void 0:n.state)||void 0===i?void 0:i.pageViewId)?(p("Tracker state pageViewId is:",null===(r=null===(o=null==e?void 0:e.instance)||void 0===o?void 0:o.state)||void 0===r?void 0:r.pageViewId),null===(d=null===(a=null==e?void 0:e.instance)||void 0===a?void 0:a.state)||void 0===d?void 0:d.pageViewId):(p("Tracker state does not contain field pageViewId or it is empty"),""):(p("Tracker state is empty"),""):(p("Tracker is not configured in initAdvertory function"),"")})(i);n&&f&&(p("External Impression ID assigned to defineTag:",Vi(f)),m.externalImpId=Vi(f));const y=(e=>Object.entries({video:{required:!1},address:{required:!1},saleprice:{required:!1},rating:{required:!1},price:{required:!1},phone:{required:!1},likes:{required:!1},downloads:{required:!1},customIcon1:{required:!1},customIcon2:{required:!1},customDisplayUrl1:{required:!1}}).reduce((t,[n,i])=>((null==e?void 0:e.includes(n))&&(t[n]=i),t),{customTitle1:{required:!1},customTitle2:{required:!1},customTitle3:{required:!1},customTitle4:{required:!1},title:{required:!1},body:{required:!1},image:{required:!1},icon:{required:!1},sponsoredBy:{required:!1},cta:{required:!1},clickUrl:{required:!1},desc2:{required:!1},displayUrl:{required:!1},description:{required:!1}}))(v);return(null===(t=e.allowedFormats)||void 0===t?void 0:t.includes("native"))&&(m.native=y),m},Hi=e=>!e.includes("takeover")||ht(),Wi=e=>{const{source:t}=e;return"csm"===t},Ki=(e,t,n,i)=>{const o=t.parentElement;if(!o)return;const r=e?`-${e}`:"",a=i?`__${i}`:"",d=`advertory${r}-${n}${a}`,s=`advertory${r}-${n}-wrapper${a}`;t.classList.remove(...t.classList),o.classList.remove(...o.classList),t.classList.add(d),o.classList.add(s),t.dataset.adType=n},Gi="native-ad",Ji=e=>{if(!e)return e;const{country:t}=l.get(),n=$(t),i=e[`${n}-targetid`],o=i?le(i[0]):"";return Object.assign(Object.assign({},e),i&&{[`${n}-targetid`]:[o]})},Yi=e=>{const{country:t}=l.get(),n=$(t);return Object.assign(Object.assign(Object.assign(Object.assign({},e),e[`${n}-geo`]&&{[`${n}-geo`]:["geo-test-value"]}),e[`${n}-geofence`]&&{[`${n}-geofence`]:["geofence-test-value"]}),e[`${n}-weather`]&&{[`${n}-weather`]:["weather-test-value"]})},Xi=e=>{(e=>{const t=new URLSearchParams(window.location.search);if("true"!==t.get("scrollToFirstInvCode"))return;const n=t.get("ast_override_inv_code");if(!n)return;const i=n.split(",")[0].split(":")[0],o=e.find(e=>e.invCode===i),r=document.querySelector(`[id^=${null==o?void 0:o.id}]`);r&&r.scrollIntoView({behavior:"smooth",block:"start"})})(e),(()=>{var e;const t=new URLSearchParams(window.location.search).get("scrollToDrEditionPlacement");if(!t)return;const n=null!==(e=document.querySelector(`[id*="${t}}"]`))&&void 0!==e?e:document.querySelector(`a[aria-label*="${t}"]`);n&&n.scrollIntoView({behavior:"smooth",block:"start"})})()},Qi=(t,n)=>e(void 0,void 0,void 0,function*(){return yield new Promise(e=>{t().then(t=>{e(null!=t?t:null)}).catch(t=>{e(null)})})}),Zi="https://dr-edition-teaser-server.inventory.schibsted.io/xandr";new Set(Object.values({PREROLL:"preroll",BUMPER:"bumper",MIDROLL:"midroll"}));const eo={plcmtcnt:1,context:1,contextsubtype:10,plcmttype:1,assets:[{id:1,title:{len:100},required:0},{id:2,img:{type:1,hmin:10,wmin:10},required:0},{id:3,img:{type:3,hmin:10,wmin:10},required:0},{id:4,data:{type:2},required:0},{id:5,data:{type:12},required:0}],ver:"1.2",eventtrackers:[{event:1,methods:[1,2]}]},to={no:"NOK",se:"SEK"},no={no:"no",se:"sv"};class io{buildFetchObject(t,n,i,o){return e(this,void 0,void 0,function*(){const{country:r,pageOptions:a}=o,{invCode:d,xandrPlacementId:s}=t,l=yield e(void 0,void 0,void 0,function*(){return window.__tcfapi?{gdpr:1,gdpr_consent:yield(e=window.__tcfapi,new Promise((t,n)=>{e("addEventListener",2,(n,i)=>{var o;i||t(""),"tcloaded"!==n.eventStatus&&"useractioncomplete"!==n.eventStatus||(t(null!==(o=n.tcString)&&void 0!==o?o:""),e("removeEventListener",2,()=>{},n.listenerId))})}))}:{};var e}),c=(p=Object.assign(Object.assign({},n),i),Object.entries(p).flatMap(([e,t])=>void 0===t?[]:Array.isArray(t)?t.map(t=>`${e}=${t}`):[`${e}=${t}`]).join(","));var p;const u=new URL(window.location.href),v=(e=>{const{allowedFormats:t}=e;if(!t||t.includes("native"))return{request:JSON.stringify(eo),ver:"1.1"}})(t),g=(e=>{const{sizes:t,allowedFormats:n}=e;if((null==n?void 0:n.includes("banner"))&&t&&0!==t.length)return{format:t.map(([e,t])=>({w:e,h:t})),w:t[0][0],h:t[0][1]}})(t);return{id:pe(36),imp:[Object.assign(Object.assign(Object.assign({id:d},v&&{native:v}),g&&{banner:g}),{secure:1,tagid:d,ext:{appnexus:Object.assign(Object.assign({},s&&{placement_id:s}),{code:d,keywords:c,use_pmt_rule:!1})}})],site:{domain:u.hostname,page:u.href,publisher:{id:String(a.publisherId),domain:u.hostname},ext:{amp:0}},device:{dnt:Number((null===navigator||void 0===navigator?void 0:navigator.globalPrivacyControl)||"1"===(null===navigator||void 0===navigator?void 0:navigator.doNotTrack)),ua:window.navigator.userAgent,h:screen.height,w:screen.width,language:(navigator.language||no[r]||"no").split("-")[0]},regs:{ext:{gdpr:l.gdpr||0}},user:{id:yield ee(o),ext:{consent:l.gdpr_consent||"",eids:Q(r)}},at:1,cur:[to[r]],source:{tid:pe(36)},ext:{prebid:{bidder:{appnexus:{member:a.member}}}}}})}fetchData(t,n,i,o){return e(this,void 0,void 0,function*(){try{p("Starting fetching Studio ad from Xandr:",Zi);const e=new Headers({"Content-Type":"application/json"}),r=new URLSearchParams(window.location.search),a=new URLSearchParams(["openRTBDebugMemberOverride","openRTBNewsroomOverride","openRTBForceNativeDesc2Override"].flatMap(e=>{const t=r.get(e);return t?[[e,t]]:[]})),d=a.size>0?`${Zi}?${a.toString()}`:Zi,s=yield this.buildFetchObject(t,n,i,o),l=yield z.post(d,e,s);return p("Fetch operation completed successfully.",l),l}catch(e){p("Error during fetch operation:",e)}return null})}}const oo=0,ro=3,ao=(e,t)=>{so(e,t),co(e,t)},so=(e,t)=>{var n,i;const o=document.querySelector(`#${e.targetId}`);if(!o||!(null===(n=e.native)||void 0===n?void 0:n.clickTrackers))return;const r=null!==(i=null==t?void 0:t.clickLinkSelector)&&void 0!==i?i:"a.ad-link";(null==o?void 0:o.querySelectorAll(r)).forEach(t=>{"true"!==t.dataset.tracked&&(t.addEventListener("click",()=>{var t,n;for(const i of null!==(n=null===(t=e.native)||void 0===t?void 0:t.clickTrackers)&&void 0!==n?n:[])uo(i)}),t.dataset.tracked="true")})},lo=e=>{var t;const{native:{impressionTrackers:n}={}}=e,i=null==n?void 0:n.some(e=>e.includes("googleads")),o="function"==typeof(null===(t=window.apntag)||void 0===t?void 0:t.fireImpressionTrackers)&&!!e.tagId;i||!o?null==n||n.forEach(po):window.apntag.fireImpressionTrackers(e);const r=new CustomEvent("advertory:nativeImpression",{detail:{ad:e}});window.dispatchEvent(r)},co=(e,t)=>{var n;let i=!1;const o=document.querySelector(`#${e.targetId}`);if(!o||!e.native)return;const{deviceType:r,appearanceConfig:a,nativeTrackingConfig:{fireImpressionsBasedOnAppearanceThreshold:d=!1}={}}=t,s=d?{rootMargin:`${l=null!==(n=null==a?void 0:a.defaultThreshold[null!=r?r:te.DESKTOP])&&void 0!==n?n:0}px 0px ${l}px 0px`}:{};var l;const c=new IntersectionObserver(t=>{if(!i)for(const n of t)if(n.isIntersecting){i=!0,lo(e),c.disconnect();break}},s);c.observe(o)},po=e=>{const t=e.includes("googleads");"function"!=typeof window.navigator.sendBeacon||t?uo(e):window.navigator.sendBeacon(e)},uo=e=>{fetch(e,{method:"GET",mode:"no-cors"}).catch(t=>console.warn(`Tracker ${e} failed. Error: ${t||"Unknown"}`))},vo=e=>e.reduce((e,t)=>{if(!t.serverSidePlacement)return e.clientSidePlacements.push(t),e;const n=Math.random()<.5;return t.keywords=Object.assign(Object.assign({},t.keywords),{"aa-sch-prerenderer":n?"true":"false"}),n?e.serverSidePlacements.push(t):e.clientSidePlacements.push(t),e},{clientSidePlacements:[],serverSidePlacements:[]}),go=(t,n)=>e(void 0,void 0,void 0,function*(){var e,i;const{deviceType:o,appearanceConfig:r}=n,a=null==r?void 0:r.defaultThreshold[o],d=null!==(e=t.threshold)&&void 0!==e?e:a,s=document.getElementById(t.id);if(!s)return void p(`Server-side ad container not found: ${t.id}`);yield new Promise(e=>{new IntersectionObserver((t,n)=>{t.some(e=>e.isIntersecting)&&(n.disconnect(),e())},Zn(d)).observe(s)});const{prepareTag:c}=l.getHandlers(),u=Ie.getData("alertoryConfigKeywords"),v=null!==(i=c(Ui(t)).keywords)&&void 0!==i?i:{},g=new io,h=yield g.fetchData(t,u,v,n);h&&(((e,t,n)=>{const i=n===te.MOBILE?t.mobileHTML:t.desktopHTML;if(i){if(t.adType===oo){const n=document.createElement("iframe");n.width=String(t.bid.w),n.height=String(t.bid.h),n.style.overflow="hidden",n.style.border="none",n.srcdoc=`<style>html,body{margin:0;overflow:hidden;}</style>${i}`,e.appendChild(n)}else e.innerHTML=i;e.classList.add("ad-loaded")}})(s,h,o),h.adType===ro&&(Ki(n.publisher,s,Gi,n.pageType),ao({targetId:t.id,native:{clickTrackers:h.clickTrackers,impressionTrackers:h.impTrackers}},{deviceType:o,appearanceConfig:r,nativeTrackingConfig:n.nativeTrackingConfig,clickLinkSelector:"a"})),((e,t,n,i)=>{var o,r,a;let d;(null===(o=window.apntag.requests)||void 0===o?void 0:o.tags[e])||(null!==(r=(a=window.apntag).requests)&&void 0!==r||(a.requests={tags:{}}),window.apntag.requests.tags[e]={invCode:t,adResponse:{ads:[{creative_id:Number(null==i?void 0:i.adid)}]}}),!!n.querySelector("iframe")||(d=document.createElement("iframe"),n.appendChild(d)),ln(e,n,Number(null==i?void 0:i.adid)),null==d||d.remove()})(t.id,t.invCode,s,h.bid))}),ho=(e,t)=>{e.forEach(e=>go(e,t).catch(e=>{p("Failed to handle server-side ad:",e)}))},mo={arrayMerge:(e,t)=>t},fo=t=>e(void 0,void 0,void 0,function*(){if(!(e=>{const{editableConfiguration:{useS3Config:t=!1,pageTypeToFetch:n}={},siteSpecificConfig:i}=e;return Boolean(t&&n&&(null==i?void 0:i.publisherClassName))})(t))return t;try{const n=yield(t=>e(void 0,void 0,void 0,function*(){const e=(e=>{const{siteSpecificConfig:t,editableConfiguration:{pageTypeToFetch:n}={}}=e;return(null==t?void 0:t.publisherClassName)&&n?`https://alertory-cdn.staging.inventory.schibsted.io/editable-configurations/${t.publisherClassName}/${n.toUpperCase()}.json`:null})(t);if(!e)return null;const n=new AbortController,i=setTimeout(()=>n.abort(),5e3);try{return yield z.get(e,{method:"GET",signal:n.signal})}catch(t){throw p("Failed to fetch S3 config",{error:t,url:e}),t}finally{clearTimeout(i)}}))(t);return n?(({siteConfig:e,configOverrides:t})=>{var n;const{keywords:i,refresh:r,placements:a,threshold:d,batchSize:s}=t,l=o.all([e.placements,a],mo),c=o(e.pageOptions,{keywords:i},mo),p=o(e.appearanceConfig,{defaultThreshold:d},mo),u=o(null!==(n=e.refreshConfig)&&void 0!==n?n:{},{scrollRefreshEnabled:r},mo);return Object.assign(Object.assign({},e),{placements:l,requestSize:null!=s?s:e.requestSize,pageOptions:c,appearanceConfig:p,refreshConfig:u})})({siteConfig:t,configOverrides:n}):t}catch(e){return p("Error fetching S3 config, using site config",{error:e}),t}}),yo=".advertory-right-column-track",bo="--advertory-right-column-track-height",wo=e=>e.getBoundingClientRect().top+window.scrollY,xo=e=>{const{marginTop:t,marginBottom:n}=getComputedStyle(e);return e.getBoundingClientRect().height+parseFloat(t||"0")+parseFloat(n||"0")},ko=(e,t)=>{const n=(i=t,`${Math.max(0,Math.round(i))}px`);var i;document.body.style.setProperty(e,n)},Eo=(e,t)=>`${e}-${t}`,To=(e,t,n)=>{var i;const o=Array.from(null!==(i=e.querySelectorAll(t))&&void 0!==i?i:[]),r=(e=>e.map(e=>{var t;return null===(t=document.querySelector(`[id^="${e}"]`))||void 0===t?void 0:t.parentElement}).map((e,t)=>({point:e,originalIndex:t})).filter(e=>Boolean(e.point)))(n);if(0===r.length)return;const a=wo(e);(()=>{const e=document.querySelector("header");if(!e)return;const t=xo(e);ko("--advertory-newsroom-header-height",t)})(),r.forEach(({point:e,originalIndex:t})=>{((e,t,n)=>{const i=wo(e),o=Eo(bo,t),r=i-n,a=Eo("--advertory-right-column-split-point-height",t),d=xo(e);ko(o,r),ko(a,d)})(e,t+1,a),(e=>{const t=null==e?void 0:e.id;if(!t)return;const n=Eo("--advertory-right-column-ad-height",t),i=xo(e);ko(n,i)})(o[t])});((e,t)=>{const n=wo(e);ko(bo,n-t)})(r[Math.min(o.length,r.length-1)].point,a)};let Io=!1;class Ao{getPulseObjectId(){return"sdrn:vg:content:partnerstudio:element:partnerstudio:stats"}getPulsePageId(){return"sdrn:vg:frontpage:front"}getTags(e){var t;let n;if(n=e instanceof HTMLAnchorElement?e.href:null===(t=null==e?void 0:e.querySelector("a"))||void 0===t?void 0:t.href,!n)return[];const{host:i,pathname:o}=new URL(n);if(!i.includes("www.vg.no")&&!o.includes("annonsorinnhold"))return[n];const r=o.split("/");return r.length?[...r.filter(Boolean).slice(1).map(e=>e),n]:[n]}}class So{getPulseObjectId(){return""}getPulsePageId(e,t){return""}}class Co{constructor(e,t){this.pulse=e,this.newsroomStrategy=t}getEventInput(e,t){return{}}parseKilkayaData(e){const t=e.querySelector("article");if(!t)return{};const n=t.dataset.k5aTeaserAnalytics;try{return n?JSON.parse(n):{}}catch(e){return{}}}mapPageType(e){return{front:"Frontpage",article:"Article",section:"Article",collection:"Article",other:"Article"}[e||"front"]||"Frontpage"}getArticleId(){return location.pathname.split("/").slice(-2,-1).pop()||""}getEventTarget(e){const{url:t,title:n,itemId:i}=this.parseKilkayaData(e);return{id:i,name:this.normalizePlacementTitle(null!=n?n:""),type:"Page",url:t}}normalizePlacementTitle(e){return e.replace(/<[^>]+>/gi,"").replace(/[^a-z0-9æøå\s_-]/gi,"")}trackContentView(t){return e(this,void 0,void 0,function*(){var e,n,i,o,r,a,d,s,l;const c=new CustomEvent("advertory:partnerstudioAdImpression",{detail:{ad:null===(e=this.parseKilkayaData(t))||void 0===e?void 0:e.placement}});if(window.dispatchEvent(c),!this.pulse)return;const p=this.getEventInput(t,"view");(null===(n=this.pulse)||void 0===n?void 0:n.trackLegacyViewUIElement)?null===(o=null===(i=this.pulse)||void 0===i?void 0:i.trackLegacyViewUIElement)||void 0===o||o.call(i,p):(null===(r=this.pulse)||void 0===r?void 0:r.trackViewUIElement)?null===(d=null===(a=this.pulse)||void 0===a?void 0:a.trackViewUIElement)||void 0===d||d.call(a,p):null===(l=null===(s=this.pulse)||void 0===s?void 0:s.trackElementView)||void 0===l||l.call(s,p)})}trackContentClick(t){return e(this,void 0,void 0,function*(){var e,n,i,o,r,a;if(!this.pulse)return;const d=this.getEventInput(t,"click");this.pulse.trackLegacyClickUIElement?null===(n=(e=this.pulse).trackLegacyClickUIElement)||void 0===n||n.call(e,d):this.pulse.trackClickUIElement?null===(o=(i=this.pulse).trackClickUIElement)||void 0===o||o.call(i,d):null===(a=(r=this.pulse).trackElementClick)||void 0===a||a.call(r,d)})}}class Po extends Co{constructor(e,t,n){super(e,t),this.pulse=e,this.newsroomStrategy=t,this.pageType=n}getEventBaseData(e){var t,n,i,o,r,a;const{clientName:d,creativeId:s,itemId:l,placement:c}=this.parseKilkayaData(e),p=this.mapPageType(this.pageType),u=null===(t=this.newsroomStrategy)||void 0===t?void 0:t.getPulsePageId(this.pageType||"front",this.getArticleId());return{"@id":null!==(o=null===(i=null===(n=this.newsroomStrategy)||void 0===n?void 0:n.getPulseObjectId)||void 0===i?void 0:i.call(n))&&void 0!==o?o:c,"@type":"UIElement",position:c,elementType:"Article",custom:{customer:d,creativeId:null!=s?s:l},page:{"@id":null!=u?u:c,"@type":p,url:location.origin},tags:null===(a=null===(r=this.newsroomStrategy)||void 0===r?void 0:r.getTags)||void 0===a?void 0:a.call(r,e)}}getEventTarget(e){const{link:t,itemId:n,title:i}=this.parseKilkayaData(e);return{id:n,name:this.normalizePlacementTitle(null!=i?i:""),type:"Page",url:t}}getEventInput(e,t){return{object:this.getEventBaseData(e),partnerstudio:this.getEventPartnerstudioData(e,t),target:this.getEventTarget(e),provider:this.getProviderData()}}getEventPartnerstudioData(e,t){const n=this.parseKilkayaData(e);return Object.assign(Object.assign({},n),{type:t,tracking_type:"ad",xandrAdLoaded:!1})}getProviderData(){return{productTag:"partnerstudio"}}}const Oo="[data-k5a-teaser-analytics]",Lo=(e,t,n)=>{const i=document.querySelectorAll("k5a-stream");if(!i.length)return;const o=new Po(e,t,n),r=new WeakMap,a=e=>{const t=r.get(e);t&&(t.disconnect(),r.delete(e))},d=new IntersectionObserver((e,t)=>{e.forEach(e=>{if(!e.isIntersecting)return;const n=e.target,i=n.querySelector(Oo);Boolean(null==i?void 0:i.dataset.k5aTeaserAnalytics)?(o.trackContentView(n),t.unobserve(e.target),a(n)):((e,t)=>{if(r.has(e))return;const n=new MutationObserver(()=>{const n=e.querySelector(Oo);Boolean(null==n?void 0:n.dataset.k5aTeaserAnalytics)&&(o.trackContentView(e),t.unobserve(e),a(e))});n.observe(e,{attributes:!0,childList:!0,subtree:!0,attributeFilter:["data-k5a-teaser-analytics"]}),r.set(e,n)})(n,t)})},{threshold:.5});i.forEach(e=>{d.observe(e),e.addEventListener("click",()=>o.trackContentClick(e))})};class jo{handleKilkayaStreamTracking({pulse:e,pageType:t,publisher:n}){if(!(null==e?void 0:e.instance))return;const i={[Tn.VG]:new Ao}[n]||new So;Lo(e.instance,i,t)}injectKilkayaMeta(e){const t=document.createElement("script");t.textContent=`var k5aMeta = { consent: ${e} };`,document.head.appendChild(t)}observeForKilkayaBackfills(){document.addEventListener("K5A:EmptyStreamSlot",e=>{var t;const n=null===(t=null==e?void 0:e.detail)||void 0===t?void 0:t.streamSlot;if(!n)return;const i=n.parentElement;i&&(p(`Kilkaya placement ${n.getAttribute("name")} has not been loaded, loading Xandr backfill`),this.showBackfill(i))})}showBackfill(e){var t;const n=e.querySelector(".fallback");if(!n)return;n.style.display="block";const i=null!==(t=n.dataset.fallbackTargetId)&&void 0!==t?t:"";Ee(i)}loadKilkayaScript(t){return e(this,void 0,void 0,function*(){yield _t(t)})}run(t){return e(this,void 0,void 0,function*(){const{tcf:e,isMobileApp:n,country:i,kilkaya:o}=t;if(!(null==o?void 0:o.enabled))return;const r=yield A(e,n,i,"kilkaya");r&&(this.observeForKilkayaBackfills(),this.injectKilkayaMeta(r),yield this.loadKilkayaScript(o.url),this.handleKilkayaStreamTracking(t))})}}const $o=1e4,No=e=>e.some(e=>e.some(e=>!!e&&gi(e,0)));let _o;const qo=()=>{const{widescreenSwitching:e}=l.get(),{enabled:t,rotationInterval:n=$o,widescreenIdPrefix:i}=null!=e?e:{};if(!t)return;const o=((e="widescreen")=>{const{pageSectionsSelectors:{right:t}={}}=l.get();return t?Array.from(document.querySelectorAll(t)).map(t=>Array.from(t.querySelectorAll(`div[id^="${e}"]`))):[]})(i);let r=0,a=Date.now(),d=No(o);if(!o.length)return;_o&&window.removeEventListener("scroll",_o);const s=(e,t,n)=>{e.forEach(e=>{e&&e.style.setProperty(t,n)})},c=e=>1===e?0:1;(e=>{e.forEach(e=>{e[0]&&(e[0].style.display="block",e[0].style.opacity="1"),e[1]&&(e[1].style.display="none",e[1].style.opacity="")})})(o);const p=((e,t)=>{let n=null;return(...i)=>{null===n&&(e(...i),n=setTimeout(()=>{n=null},t))}})(()=>{d||(d=No(o)||d,a=Date.now());Date.now()-a>=n&&((()=>{const e=c(r),t=o.map(e=>e[r]),n=o.map(t=>t[e]);s(t,"opacity","0"),setTimeout(()=>{s(t,"display","none"),s(n,"opacity","0"),s(n,"display","block"),setTimeout(()=>{s(n,"opacity","1")},450)},450)})(),r=c(r),a=Date.now())},1e3);_o=p,window.addEventListener("scroll",p)};Zt('.advertory-finn-blink-wrapper{height:100%;display:flex !important;align-items:center;justify-content:center}.advertory-finn-blink-wrapper:not(.brandboard-container){width:100%;margin-inline:auto}.advertory-finn-blink{width:100%;height:500px;max-width:580px;display:flex !important;align-items:center;justify-content:center}.advertory-finn-blink::before{content:"" !important}.advertory-finn-blink iframe{max-width:100%}');const zo=e=>document.querySelector(`#${e}`);let Do,Mo=[];const Bo=["takeover","wallpaper"],Ro=e=>{const t=(e=>{const t=Ie.getData("alertoryConfigKeywords"),{queryConfig:n,placements:i,tcf:o,glimr:r,appearanceConfig:a,requestSize:s=d,publisher:l,country:c,pageType:p,deviceType:u,isMobileApp:v=!1,pageOptions:{member:g},takeover:h,fullscreenScroll:m,useAppTabletInvCode:f}=e;return{xandr:{member:g,keywords:t,tags:[]},advertory:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({publisher:l,country:c,pageType:p,deviceType:u,placements:i,tcf:o,requestSize:s,isMobileApp:v,useAppTabletInvCode:f},r&&{glimr:r}),n&&{queryConfig:n}),a&&{appearanceConfig:a}),h&&{takeover:h}),m&&{fullscreenScroll:m})}})(e);window.advertory={initialized:!0,siteConfig:e,alertoryConfig:t}},Fo=()=>e(void 0,void 0,void 0,function*(){const{pageOptions:t}=l.get(),{preparePageOptions:n}=l.getHandlers(),i=(()=>{const{sandboxAdIframeEnabled:e=!0}=l.get();return{sandboxAdIframe:e,sandboxAttributes:["allow-same-origin","allow-scripts","allow-top-navigation-by-user-activation","allow-popups","allow-popups-to-escape-sandbox","allow-forms"]}})(),o=yield e(void 0,void 0,void 0,function*(){const{tcf:e,isMobileApp:t,country:n}=l.get();return(yield A(e,t,n,"page-options"))?{}:{userSync:{disabled:!0}}}),r=yield n(Object.assign(Object.assign(Object.assign({disablePsa:!0,enableSafeFrame:!0},t),{renderingManagement:Object.assign({},i)}),o));(e=>{const t=Ie.getData("alertoryConfigKeywords");if(Object.keys(t).length)return;const n=Yi(e);Ie.setData("alertoryConfigKeywords",n)})(r.keywords),ve(()=>Do.setPageOpts(r))}),Vo=t=>e(void 0,void 0,void 0,function*(){const{prebid:e,tcf:n,isMobileApp:i,country:o}=l.get(),r=yield A(n,i,o,"loadPlacements"),a=((e,t)=>t?e:(e.filter(e=>!e.supportsNonRTB).forEach(e=>ke(e.id)),e.filter(e=>e.supportsNonRTB).map(e=>{return Object.assign(Object.assign({},e),{invCode:(t=e.invCode,`${t}_non_rtb`)});var t})))(t,r);Uo(a);(null==e?void 0:e.enabled)&&r&&!xe()?(p("core loadPlacements prebid enabled"),yield pn()):(p("core load tags invoked without prebid enabled"),Ho(a))}),Uo=e=>{const{prepareTag:t}=l.getHandlers(),n=[];(e=>{const t=["skyscraperright_1","topboard","wallpaper","skyscraperleft_1"];return e.sort((e,n)=>{const i=t.findIndex(t=>e.id.includes(t)),o=t.findIndex(e=>n.id.includes(e));return-1!==i&&-1===o?-1:-1===i&&-1!==o?1:i-o})})(e).forEach(e=>{p("core defineTags",{placement:e});const i=Ui(e);if(Hi(e.id)){const o=t(i),r=(e=>{const{allowedFormats:t,invCode:n,keywords:i,sizes:o}=e;return{adTypes:t,invCode:n,keywords:Ji(i),sizes:o}})(o);n.push(r),ve(()=>(p("core defineTag - add to the queue",{placement:e,preparedTag:o}),Do.defineTag(o)))}}),(e=>{var t,n,i;(null===(i=null===(n=null===(t=window.advertory)||void 0===t?void 0:t.alertoryConfig)||void 0===n?void 0:n.xandr)||void 0===i?void 0:i.tags)&&e.length&&window.advertory.alertoryConfig.xandr.tags.push(e)})(n)},Ho=e=>{const t=e.filter(({id:e})=>Hi(e)).map(({id:e})=>e);t.length&&ve(()=>(p("core loadTags",{placementsIdsToLoad:t}),Do.loadTags([...t])))},Wo=(t,n)=>e(void 0,void 0,void 0,function*(){const{appearanceConfig:e,deviceType:i}=l.get(),{threshold:o,refresh:r}=t,a=(e=>{const t=document.querySelector(`[data-show-tag-subscribe-id=${e.targetId}]`),n=document.querySelector(`#${e.targetId}`);return t||n})(n),d=null==e?void 0:e.defaultThreshold[i];a&&(p("core showAd - subscribe for show tag with thresholds",{placement:t,adObj:n,threshold:o,deviceDefaultThreshold:d}),yield ni(a,null!=o?o:d)),a&&r&&(p("core showAd - setup refreshing",{placement:t,adObj:n}),a.dataset.refresh=r.toString())}),Ko=e=>e.some(({id:e})=>Bo.some(t=>e.includes(t))),Go=t=>e(void 0,void 0,void 0,function*(){var n;if(!(null===(n=null===window||void 0===window?void 0:window.advertory)||void 0===n?void 0:n.initialized))return;const[i,o]=(e=>e.reduce(([e,t],n)=>{var i;return(null===(i=null==n?void 0:n.finnBlink)||void 0===i?void 0:i.loadOnlyFinnBlink)?[[...e,n],t]:[e,[...t,n]]},[[],[]]))(t),r=(e=>{const{requestSize:t=d,queryConfig:{placementBatches:n}={},deviceType:i}=l.get(),o=Ne(e),r=Object.keys((null==n?void 0:n[i])||{}).map(e=>o[e]||[]).filter(e=>e.length>0),a=new Set(r.flat().map(({id:e})=>e)),s=e.filter(({id:e})=>!a.has(e));return[...r,...ui(s,t)]})(o);for(const e of r)Ko(e)?(p("core loadAds without lazy loading",{placementsToLoad:e}),yield Vo(e)):e.length&&(p("core loadAds with lazy loading",{placementsToLoad:e}),yield Jo(e));yield(t=>e(void 0,void 0,void 0,function*(){if(!t.length)return;const{appearanceConfig:e,deviceType:n}=l.get(),i=null==e?void 0:e.defaultThreshold[n];for(const e of t){const{threshold:t,id:n}=e,o=zo(n);o&&(yield ni(o,null!=t?t:i))}}))(i)}),Jo=t=>e(void 0,void 0,void 0,function*(){const{queryConfig:{lazyLoadingV3:{enabled:e=!1,rootMargin:n="200% 0px"}={}}={}}=l.get(),i=[];if(!e)return p("lazy load is not enabled",{placements:t}),void(yield Vo(t));const o=new IntersectionObserver((e,n)=>{e.filter(({isIntersecting:e,target:{id:t}})=>e&&!t.includes("wallpaper")).forEach(e=>{p("lazy load is enabled - handler start",{loadedPlacementIds:i,placements:t});const o=t.every(e=>i.includes(e.id)),r=t.map(e=>e.id);!o&&i.push(...r),!o&&Vo(t),p("lazy load is enabled - handler stop",{loadedPlacementIds:i,placements:t,arePlacementsLoaded:o,placementIds:r}),n.disconnect()})},{rootMargin:n});t.forEach(e=>{const t=document.getElementById(e.id);t&&(p("lazy loading - observe element",{placementId:e.id,element:t}),o.observe(t))})}),Yo=()=>e(void 0,void 0,void 0,function*(){const{siteEvents:t,initNativeAd:n,wallpaperHandlers:{initWallpaperAd:i,adjustAdToHorseshoe:o}}=l.getHandlers(),{wallpaper:r,fullscreenScroll:a}=l.get(),d=[];ve(()=>{Do.onEvent("adRequested",()=>{t.adRequested()}),Do.onEvent("adAvailable",o=>e(void 0,void 0,void 0,function*(){var e,d,s,c,u,v;p("core adAvailable start",{placementsAvailable:Mo,adObj:o,isFullscreenScrollAd:He(o),isFinnBlink:Ze(o.targetId),isNativeAd:We(o),isMediation:Wi(o),isTakeoverAd:Ge(o),isCollapseAd:Xe(o),isWallpaperAd:Ye(o)});const g=null===(s=null===(d=null===(e=null===window||void 0===window?void 0:window.apntag)||void 0===e?void 0:e.requests)||void 0===d?void 0:d.tags[o.targetId])||void 0===s?void 0:s.adResponse.ads;Wi(o)&&g&&(null===(c=g[1])||void 0===c?void 0:c.rtb)&&(o.banner=null===(v=null===(u=g[1])||void 0===u?void 0:u.rtb)||void 0===v?void 0:v.banner),He(o)&&dn(o),nt(o)&&qo(),He(o)&&!Ze(o.targetId)&&an(o,a),!We(o)||Wi(o)||Ze(o.targetId)||n(o,l.get()),Ge(o)&&!Xe(o)&&(Di(o.targetId),yield Mi(o)),Ye(o)&&(i(()=>ve(()=>window.apntag.showTag(o.targetId)),r),Ie.setData("wallpaper",{isAvailable:!0})),(e=>e.targetId.includes("skyscraperleft")&&!!e.banner)(o)&&Ie.setData("horseshoe",{isAvailable:!0}),It({adObj:o}),(e=>{var t;const n=null==e?void 0:e.targetId;if(!n)return;const i=null===(t=document.querySelector(`#${n}`))||void 0===t?void 0:t.parentElement;i&&((e,t)=>{const{height:n,width:i,native:o}=e;o?t.dataset.adSizes="[1,1]":n&&i&&(t.dataset.adSizes=`[${i},${n}]`)})(e,i)})(o),t.adAvailable(o);const h=Mo.find(({id:e})=>e===o.targetId);h&&(yield Wo(h,o),Mo=Mo.filter(e=>e.id!==h.id)),p("core adAvailable stop",{placementsAvailable:Mo,adObj:o,isFullscreenScrollAd:He(o),isFinnBlink:Ze(o.targetId),isNativeAd:We(o),isMediation:Wi(o),isTakeoverAd:Ge(o),isCollapseAd:Xe(o),isWallpaperAd:Ye(o)})})),Do.onEvent("adLoaded",e=>{const{refreshConfig:i,appearanceConfig:r}=l.get(),a=document.getElementById(e.targetId);Ze(e.targetId)&&(e=>{const{fullscreenScroll:t}=l.get(),{initNativeAd:n}=l.getHandlers();He(e)&&an(e,t),We(e)&&n(e,l.get())})(e);d.includes(e.targetId)&&We(e)&&(n(e,l.get()),It({adObj:e})),!d.includes(e.targetId)&&Wi(e)&&d.push(e.targetId),Xe(e)&&ke(e.targetId),Ge(e)&&((e,t)=>{var n;const i="100%",o="100%";e.resizeAd(t,[i,o]);const r=null===(n=document.querySelector(`#div_utif_${t}`))||void 0===n?void 0:n.querySelector("iframe");if(!r)return;new MutationObserver(e=>{for(const t of e)if("attributes"===t.type&&"style"===t.attributeName){const e=window.getComputedStyle(r),t=e.width,n=e.height;t===i&&n===o||(r.style.width=i,r.style.height=o)}}).observe(r,{attributes:!0,attributeFilter:["style"]})})(Do,e.targetId),Ke(e)&&(e=>{const t=document.querySelector(`#${e.targetId}`),{siteSpecificConfig:{publisherClassName:n,fullWidthFormatClassName:i}={}}=l.get();if(!t||!n||!i)return;const o=t.parentElement;o&&(t.classList.add(`advertory-${n}-${i}__full-width-ad`),o.classList.add(`advertory-${n}-${i}-wrapper__full-width-ad`))})(e),(e=>rt(e,ze))(e)&&(e=>{var t;const n=document.querySelector(`#${e.targetId}`),i=null===(t=document.querySelector(`#${e.targetId}`))||void 0===t?void 0:t.parentElement,o=null==n?void 0:n.querySelector("iframe"),r=null==o?void 0:o.parentElement,{siteSpecificConfig:{publisherClassName:a,fullWidthFormatClassName:d}={}}=l.get();if(!(n&&o&&r&&i))return;i.classList.add(`advertory-${a}-${d}__vertical-full-width-ad-wrapper`);const s=window.innerWidth,c=Math.round(s/1080*1920);n.style.width="100%",n.style.height=`${c}px`,n.classList.add(`advertory-${a}-${d}__vertical-full-width-ad`);const p=St(e,n.offsetWidth);r.style.transform=`scale(${p})`,r.style.transformOrigin="left top"})(e),((e,t)=>{if(!(null==t?void 0:t.scrollRefreshEnabled))return;const{targetId:n}=e,i=document.querySelector(`#${n}`),o=null==i?void 0:i.parentElement;if(!o||!i)return;li({adWrapper:o,placementContainer:i});const{delayTime:r=1e3}=t,a=(new Date).getTime();i&&"true"!==i.dataset.subscribedForRefresh&&(i.dataset.subscribedForRefresh="true",i.dataset.refresh&&pi(i,a,r))})(e,i),(null==r?void 0:r.clearProbableDimensionsEnabled)&&(e=>{const t=document.querySelector(`#${e}`);t&&(t.style.minWidth="",t.style.minHeight="")})(e.targetId);Ie.getData("horseshoe").isAvailable&&o(e.targetId),(e=>{var t,n,i,o,r,a;const{adScaleConfig:d,deviceType:s}=l.get();if(!(null==d?void 0:d.enabled))return;if(rt(e,qe))return;const c=null!==(t=d.adsToBeScaled[s])&&void 0!==t?t:[],p=Oe(e.targetId.split("-")[0]);if(!c.includes(p))return;const u=null!==(i=null===(n=d.offset)||void 0===n?void 0:n[p])&&void 0!==i?i:0,v=document.getElementById(e.targetId),g=null!==(o=null==v?void 0:v.offsetWidth)&&void 0!==o?o:window.screen.width,h=null!==(a=null===(r=null==v?void 0:v.parentElement)||void 0===r?void 0:r.offsetWidth)&&void 0!==a?a:window.screen.width;Ct(e,(g<h?g:h)-u)})(e),t.adLoaded(e),sn(e.targetId),a&&(a.classList.add(cn),(e=>{var t,n;const{siteSpecificConfig:i}=l.get(),o=null!==(t=null==i?void 0:i.mainColumnWidth)&&void 0!==t?t:1/0;e.clientWidth>o&&(null===(n=e.parentElement)||void 0===n||n.setAttribute("data-two-column-ad-layout","true"))})(a)),Ot(e),window.dispatchEvent(new CustomEvent("advertory:adLoaded",{detail:{targetId:e.targetId,adFormat:At(e)}}))}),Do.onEvent("adNoBid",n=>e(void 0,void 0,void 0,function*(){ke(n.targetId),yield Bn(l.get(),n),wt(n)&&(yield bt()),t.adNoBid(n)})),Do.onEvent("adError",(n,i)=>e(void 0,void 0,void 0,function*(){wt(i)&&(yield bt()),t.adError(n,i)})),Do.onEvent("adCollapse",()=>{t.adCollapse()}),Do.onEvent("adRequestFailure",n=>e(void 0,void 0,void 0,function*(){ke(n.targetId),yield Bn(l.get(),n),t.adRequestFailure(n)})),Do.onEvent("adBadRequest",n=>e(void 0,void 0,void 0,function*(){ke(n.targetId),yield Bn(l.get(),n),t.adBadRequest(n)})),Do.onEvent("adLoadedMediated",e=>t.adLoadedMediated(e)),Do.onEvent("adNoBidMediated",n=>e(void 0,void 0,void 0,function*(){yield Bn(l.get(),n),t.adNoBidMediated(n)}))})}),Xo=(t,n)=>e(void 0,void 0,void 0,function*(){var i;l.set(t),l.setHandlers(n),Ie.initialize(),window.addEventListener("message",Qn,!1),Do=window.apntag||{anq:[],defineTag:e=>({targetId:""}),showTag:e=>{},onEvent:(e,t,n)=>{},offEvent:(e,t)=>{},refresh:e=>{},modifyTag:(e,t)=>{},loadTags:e=>{},emitEvent:(e,t)=>{},setPageOpts:e=>{},resizeAd:(e,t,n)=>{},getAstVersion:()=>"",setEndpoint:(e,t)=>{},fireImpressionTrackers:e=>{},setKeywords:()=>{},clearRequest:()=>{}},window.apntag=Do,p("Apn tag is set up on window"),yield Promise.allSettled([e(void 0,void 0,void 0,function*(){const{tcf:e,isMobileApp:t,country:n}=l.get();(yield A(e,t,n,"xandr-endpoint"))||Do.setEndpoint("ib.adnxs-simple.com",!0)}),e(void 0,void 0,void 0,function*(){if(xe())return;const{prebid:e,tcf:t,isMobileApp:n,country:i}=l.get(),o=yield A(t,n,i,"prebid");(null==e?void 0:e.enabled)&&o&&(yield _t(null==e?void 0:e.url))}),J(t),e(void 0,void 0,void 0,function*(){const{astUrl:e}=l.get();yield _t(null!=e?e:"https://adsdk.microsoft.com/ast/ast.js")}),e(void 0,void 0,void 0,function*(){const{gptUrl:e,tcf:t,isMobileApp:n,country:i}=l.get();(yield A(t,n,i,"gpt-endpoint"))&&(yield _t(null!=e?e:"https://securepubads.g.doubleclick.net/tag/js/gpt.js"))}),e(void 0,void 0,void 0,function*(){const{brandmetrics:{enabled:e,url:t}={},tcf:n,isMobileApp:i,country:o}=l.get(),{getConsentAsync:r}=I(n,0,o),a=yield r();if(e&&t&&a){if(yield _t(t),document.querySelector(`.${Bi}`))return window._brandmetrics=window._brandmetrics||[],void window._brandmetrics.push({cmd:"_loadsurvey"});new MutationObserver((e,t)=>{for(const n of e){if("childList"!==n.type)return;Array.from(n.addedNodes).some(e=>{var t;return null===(t=e.outerHTML)||void 0===t?void 0:t.includes(Bi)})&&(t.disconnect(),window._brandmetrics=window._brandmetrics||[],window._brandmetrics.push({cmd:"_loadsurvey"}))}}).observe(document,{childList:!0,subtree:!0,attributes:!0})}}),C(),e(void 0,void 0,void 0,function*(){const{gdpr:{url:e,allowHidingAds:t=!0}={}}=l.get();t&&(window.gdpr=window.gdpr||{},window.gdpr.allowHidingAds=!0),yield _t(null!=e?e:"https://cogwheel.inventory.schibsted.io/prod/latest/gdpr-bundle.js")})]),yield Ri(),p("Libraries have been loaded and trackers have been set"),yield(i=n.librariesToLoad,e(void 0,void 0,void 0,function*(){const e=i.map(e=>_t(e));yield Promise.all(e)})),yield Yo(),yield Fo(),p("Page options have been set"),Ro(t),p("Advertory is setup on window");const{clientSidePlacements:o,serverSidePlacements:r}=vo(je());Mo=o,ho(r,t),hi(Mo),fi(Mo),yield Go(Mo),p("Ads has been loaded",Mo),Rn(t,Mo),Xi(Mo),yield n.replaceAdsWithFinnBlink(t.finnBlink),yield(t=>e(void 0,void 0,void 0,function*(){var e;if(!t.drEdition)return;if(!(yield A(t.tcf,t.isMobileApp,t.country,"handleDrEdition")))return;const n=yield _n(),i=new qn(n);zn({publisher:t.publisher,drEditionConfig:t.drEdition,device:t.deviceType,pageType:t.pageType,country:t.country},i,null===(e=t.pulse)||void 0===e?void 0:e.instance)}))(t),(e=>{if(!(null==e?void 0:e.enabled)||Io)return;const{splitPointIDs:t,adSelector:n,trackSelector:i=yo}=e,o=document.querySelector(i);if(!o)return;Io=!0;const r=()=>{To(o,n,t)};r(),window.addEventListener("resize",r),window.addEventListener("orientationchange",r),window.addEventListener("load",r),window.addEventListener("advertory:adLoaded",()=>{requestAnimationFrame(r)}),new ResizeObserver(r).observe(o)})(t.rightColumnSplit),yield(t=>e(void 0,void 0,void 0,function*(){const e=new jo;yield e.run(t)}))(t)}),Qo=(t,n)=>e(void 0,void 0,void 0,function*(){yield((t,n)=>e(void 0,void 0,void 0,function*(){const{initConsentManager:e,getConsentAsync:i}=I(t.tcf,t.isMobileApp,t.country),o=yield fo(t);yield Dn(),yield Qi(e),yield Qi(i),p("TCF resolved successfully"),yield Xo(o,n),p("Run function resolved successfully")}))(t,n)}),Zo=()=>{if(!window.location.search.includes("kv_"))return{};const e={},t=(()=>{const e=new URLSearchParams(window.location.search);return Object.fromEntries(e)})();return Object.keys(t).forEach(n=>{n.startsWith("kv_")&&(e[n.slice(3)]=t[n])}),e},er=e=>{const{siteSpecificConfig:t}=l.get(),n=(null==t?void 0:t.dynamicOutstreamFormats)||[];return 0!==n.length&&n.some(t=>e.includes(t))},tr={publisherClassName:Tn.PENT,fullWidthFormatClassName:"netboard"},nr=(e,t,n,i)=>{var o;const{image:r,icon:a,sponsoredBy:d,title:s,clickUrl:l,cta:c,body:p,desc2:u,video:v,description:g,customTitle1:h,customTitle2:m,customTitle3:f,customTitle4:y,customIcon1:b,customIcon2:w,customDisplayUrl1:x}=e,k=(e,t="")=>{var n;return e?null!==(n=e.url)&&void 0!==n?n:e:t};return Object.assign({containerId:n,img:k(r),imgWidth:null==r?void 0:r.width,imgHeight:null==r?void 0:r.height,imgAltText:null!=s?s:"",logo:(()=>{var e;const t=(null==u?void 0:u.includes("sponsor"))&&"dark"===(null===(e=i.appearanceConfig)||void 0===e?void 0:e.theme)&&b;return k(t?b:a)})(),sponsoredBy:null!=d?d:"",title:null!=s?s:"",url:null!=l?l:"",cta:null!=c?c:"",description:null!==(o=null!=p?p:g)&&void 0!==o?o:"",desc2:null!=u?u:"",video:v,customTitle1:null!=h?h:"",customTitle2:null!=m?m:"",customTitle3:null!=f?f:"",customTitle4:null!=y?y:"",logo2:k(w),previewVideoSrc:null!=x?x:""},t)},ir=(e,t)=>{const n=(i=b,window.location.href.includes(i));var i;const o=new URLSearchParams(window.location.search).get(b),r=t.includes("native_recirc");return n&&o?o:(null==e?void 0:e.includes("recirc"))?r?"native_recirc":"recirc":(null==e?void 0:e.includes("sponsor"))?"sponsorstripe":null},or=(e,t,n,i)=>{const o=document.querySelector(`#${e}`);o&&t&&(o.innerHTML=t,((e,t)=>{const n=e.parentElement,{publisher:i,pageType:o}=t,r=i&&Object.values(Tn).includes(i);n&&r&&Ki(i,e,Gi,o)})(o,n),i())},rr=(e,t,n)=>{const i=((e,t,n)=>{var i;const{displayTemplates:o,videoTemplates:r}=n,a="default";if(!e.native)return null;const{native:d,targetId:s}=e,{desc2:l=a}=e.native,c=l.toLowerCase(),p=null!==(i=ir(e.targetId,l))&&void 0!==i?i:c,u=en[t.language||x.NO],v=nr(d,u,s,t);return(d.video?r[p]:o[p]||o.default)(v,t)})(e,t,n);or(e.targetId,i,t,()=>{const{nativeTrackingConfig:{nativeTrackingEnabled:n=!0}={}}=t;n&&ao(e,t)})};Zt('@import"https://fonts.googleapis.com/css?family=Roboto:400,500&display=swap";.advertory-shared-ad-native-content-display-basic{width:100%;font-family:Roboto,sans-serif;color:#6d747e;text-align:left;background:#fff;position:relative;margin:0 auto;display:flex;flex-direction:column}.advertory-shared-ad-native-content-display-basic *{line-height:normal}.advertory-shared-ad-native-content-display-basic .ad-info{top:0;right:8px;position:absolute}.advertory-shared-ad-native-content-display-basic .ad-info>div{position:initial !important}.advertory-shared-ad-native-content-display-basic .ad-link{text-decoration:none}.advertory-shared-ad-native-content-display-basic .ad-link:hover{text-decoration:none}.advertory-shared-ad-native-content-display-basic .ad-header{padding:5px 16px;background-color:#ffcd00;font-size:12px;text-transform:uppercase;color:#495057;font-weight:600}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper{display:flex;flex-direction:column}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-large-image-container{position:relative;padding-bottom:40%}@media screen and (min-width: 768px){.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-large-image-container{display:none}}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-large-image-container .ad-large-image-wrapper{position:absolute;height:100%;width:100%}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-large-image-container .ad-large-image-wrapper .ad-large-image{object-fit:cover;min-width:100%;height:100%}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-content{box-sizing:border-box;display:flex;background-color:#fffae6}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-content .ad-text-container{flex-grow:1;padding:16px}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-content .ad-text-container .ad-title{font-size:20px;color:#212529;font-weight:600;margin-bottom:16px}@media screen and (min-width: 768px){.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-content .ad-text-container .ad-title{font-size:22px}}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-content .ad-text-container .ad-sponsor{font-size:11px;color:gray;font-weight:600;text-transform:uppercase}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-content .ad-small-image-container{display:none;max-width:175px}@media screen and (min-width: 768px){.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-content .ad-small-image-container{display:block}}.advertory-shared-ad-native-content-display-basic .ad-content-wrapper .ad-content .ad-small-image-container .ad-small-image{object-fit:cover;max-width:100%}.advertory-shared-ad-native-content-display-basic.article .ad-info{top:0;right:0;position:absolute;border-bottom-left-radius:50%;background:hsla(0,0%,100%,.6)}.advertory-shared-ad-native-content-display-basic.article .ad-info>div{position:initial !important}.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-small-image-container{display:block}.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-text-container{padding:8px 16px;border-left:4px solid #ffcd00}.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-text-container .ad-header-wrapper{display:flex;margin-bottom:8px}@media screen and (min-width: 768px){.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-text-container .ad-header-wrapper{margin-bottom:16px}}.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-text-container .ad-header-wrapper .ad-header{padding:2px 4px;font-size:11px}.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-text-container .ad-title{font-size:15px;margin-bottom:8px}@media screen and (min-width: 768px){.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-text-container .ad-title{font-size:18px;margin-bottom:16px}}.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-small-image-container{padding:16px 8px 16px 0}@media screen and (min-width: 768px){.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-small-image-container{padding:0}}.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-small-image-container .ad-small-image{object-fit:contain}@media screen and (min-width: 768px){.advertory-shared-ad-native-content-display-basic.article .ad-content-wrapper .ad-content .ad-small-image-container .ad-small-image{object-fit:cover}}'),Zt(".advertory-shared-ad-native-video{width:100%;min-height:250px;height:auto;margin:auto;text-align:left;position:relative;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;text-decoration:none;display:table;table-layout:fixed}@media screen and (min-width: 768px){.advertory-shared-ad-native-video{width:580px}}.advertory-shared-ad-native-video .ad-info{position:absolute;top:2px;right:24px}.advertory-shared-ad-native-video .ad-info .gdprAdTransparencyCogWheelButton{background-color:rgba(0,0,0,0);border-bottom-right-radius:13px;z-index:10}.advertory-shared-ad-native-video a.ad-link{display:block;text-decoration:none;color:#2b2b2b}.advertory-shared-ad-native-video a.ad-link:hover{text-decoration:none}.advertory-shared-ad-native-video .ad-content .ad-header{font-size:12px;padding:5px 8px;color:#4c3d00;background:rgba(255,205,0,.8);font-weight:bold}.advertory-shared-ad-native-video .ad-content .ad-image-container{position:relative;line-height:0}@media screen and (min-width: 768px){.advertory-shared-ad-native-video .ad-content .ad-image-container{min-height:300px}}.advertory-shared-ad-native-video .ad-content .ad-image-container .ad-player-wrapper{height:56.4971751412vw;width:100%}@media screen and (min-width: 768px){.advertory-shared-ad-native-video .ad-content .ad-image-container .ad-player-wrapper{height:326px}}.advertory-shared-ad-native-video .ad-content .ad-text-container{background:#fff6d1;overflow:auto;padding-bottom:15px;padding-left:8px}@media screen and (min-width: 768px){.advertory-shared-ad-native-video .ad-content .ad-text-container{background:#fff6d1;padding-left:16px;overflow:auto}}.advertory-shared-ad-native-video .ad-content .ad-text-container .sponsored-by{margin:8px 16px 8px 0;color:#64625a;font-size:10px;text-transform:uppercase;display:block;font-weight:600}@media screen and (min-width: 768px){.advertory-shared-ad-native-video .ad-content .ad-text-container .sponsored-by{font-size:12px}}.advertory-shared-ad-native-video .ad-content .ad-text-container .title{line-height:1;margin:8px 0;font-weight:bold;font-size:20px;font-family:Arial,sans-serif}@media screen and (min-width: 768px){.advertory-shared-ad-native-video .ad-content .ad-text-container .title{font-size:22px}}"),Zt(".advertory-abo-ad-native-video{width:100%;min-height:250px;margin:auto;color:#000;font-family:-apple-system,BlinkMacSystemFont,sans-serif;font-weight:600;text-align:left;position:relative;box-sizing:border-box;text-decoration:none;display:table;table-layout:fixed}.advertory-abo-ad-native-video *{box-sizing:border-box;line-height:normal;text-transform:none}@media screen and (min-width: 768px){.advertory-abo-ad-native-video{width:580px;height:400px}}.advertory-abo-ad-native-video .ad-info{position:absolute;height:26px;width:26px;top:20px;left:0;z-index:1000;background-color:hsla(0,0%,100%,.4509803922);border-bottom-right-radius:13px;transform:none;transform-origin:center}@media screen and (min-width: 768px){.advertory-abo-ad-native-video .ad-info{top:30px}}.advertory-abo-ad-native-video .ad-info .gdprAdTransparencyCogWheelButton{background-color:rgba(0,0,0,0);border-bottom-right-radius:13px;z-index:10}.advertory-abo-ad-native-video .ad-content .ad-image-container{position:relative;line-height:0}.advertory-abo-ad-native-video .ad-content .ad-image-container .ad-header{position:absolute;height:20px;width:100%;font-size:13px;line-height:20px;color:#4c3d00;background:rgba(255,205,0,.8);z-index:100}.advertory-abo-ad-native-video .ad-content .ad-image-container .ad-header span{margin-left:8px}@media screen and (min-width: 768px){.advertory-abo-ad-native-video .ad-content .ad-image-container .ad-header{height:30px;line-height:30px;padding-left:16px}.advertory-abo-ad-native-video .ad-content .ad-image-container .ad-header span{margin:0}}.advertory-abo-ad-native-video .ad-content .ad-image-container .ad-player-wrapper{height:56.4971751412vw;width:100%}@media screen and (min-width: 768px){.advertory-abo-ad-native-video .ad-content .ad-image-container .ad-player-wrapper{height:326px}}.advertory-abo-ad-native-video .ad-content .ad-text-container{background:#fff6d1;overflow:auto}.advertory-abo-ad-native-video .ad-content .ad-text-container .sponsored-by{color:#64625a;font-size:10px;margin:8px 8px 3px 8px;text-transform:uppercase;display:block}@media screen and (min-width: 768px){.advertory-abo-ad-native-video .ad-content .ad-text-container .sponsored-by{font-size:13px;margin:8px 16px}}.advertory-abo-ad-native-video .ad-content .ad-text-container .ad-link{text-decoration:none;display:flex;flex-direction:column}.advertory-abo-ad-native-video .ad-content .ad-text-container .ad-link,.advertory-abo-ad-native-video .ad-content .ad-text-container .ad-link:focus,.advertory-abo-ad-native-video .ad-content .ad-text-container .ad-link:hover,.advertory-abo-ad-native-video .ad-content .ad-text-container .ad-link:visited{color:#000}.advertory-abo-ad-native-video .ad-content .ad-text-container .ad-link .ad-title{margin:0 8px 7px 8px;min-height:52px;line-height:24px;color:#000;font-size:20px;font-weight:700;display:flex;flex-direction:column}@media screen and (min-width: 768px){.advertory-abo-ad-native-video .ad-content .ad-text-container .ad-link .ad-title{font-size:22px;margin:0 16px 9px 16px;height:35px;min-height:auto;line-height:35px;overflow:hidden;-ms-text-overflow:ellipsis;text-overflow:ellipsis;white-space:nowrap;display:block}}.advertory-abo-ad-native-video .ad-content .ad-text-container .ad-link .ad-description{display:none;border-top:1px solid rgba(128,128,128,.5019607843);margin:0 8px 12px 8px;padding-top:8px;color:#6a6a6a;font-style:normal;font-weight:normal;font-size:12px;line-height:14px}@media screen and (min-width: 768px){.advertory-abo-ad-native-video .ad-content .ad-text-container .ad-link .ad-description{font-size:13px;margin:8px 16px;line-height:16px}}"),Zt('@import"https://fonts.googleapis.com/css?family=Inter:400,600&display=swap";.advertory-abo-ad-native-podme-section{height:130px;background:linear-gradient(90deg, #23375e 0%, #041426 104.93%);border-radius:11px}@media screen and (min-width: 768px){.advertory-abo-ad-native-podme-section{height:202px}}.advertory-abo-ad-native-podme-section .ad-link{text-decoration:none;color:initial;background-color:rgba(0,0,0,0);cursor:pointer}.advertory-abo-ad-native-podme-section .ad-content-wrapper{display:flex;height:100%;font-family:"Inter",sans-serif;font-style:normal;font-weight:normal}.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-text-container{display:flex;flex-direction:column;width:428px;margin:18px 3px 8px 18px;font-family:"Inter",sans-serif;font-style:normal;font-weight:normal}@media screen and (min-width: 768px){.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-text-container{margin:41px 28px 41px 41px}}.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-text-container .ad-title{font-weight:600;color:#fff;font-size:calc(12px + 11*(100vw - 300px)/468);line-height:16px;margin-bottom:7px}@media screen and (min-width: 768px){.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-text-container .ad-title{font-size:23px;line-height:28px;margin-bottom:15px}}.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-text-container .ad-description{color:#17e1e3;font-size:calc(10px + 8*(100vw - 300px)/468);font-weight:normal;line-height:14px}@media screen and (min-width: 768px){.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-text-container .ad-description{font-size:18px;font-weight:500;line-height:22px}}.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-small-image-container{display:flex;-webkit-box-pack:center;justify-content:center;-webkit-box-align:center;align-items:center;max-width:253px;min-width:100px;height:100%;margin:0 auto}@media screen and (min-width: 768px){.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-small-image-container{min-width:250px}}.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-small-image-container .ad-small-image{max-width:100%;max-height:100%;object-fit:fill}.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-logo{display:none}@media screen and (min-width: 768px){.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-logo{display:flex;-webkit-box-pack:center;justify-content:center;-webkit-box-align:center;align-items:center;max-width:162px;height:100%;margin:0 16px}}.advertory-abo-ad-native-podme-section .ad-content-wrapper .ad-logo .logo{max-width:100%;max-height:100%;object-fit:fill}'),Zt('.advertory-abo-ad-native-default{width:calc(100% - 32px);min-height:250px;margin:auto;color:#000;font-family:-apple-system,BlinkMacSystemFont,sans-serif;font-weight:600;text-align:left;position:relative;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;text-decoration:none;display:table;table-layout:fixed}.advertory-abo-ad-native-default *{box-sizing:border-box;line-height:normal;text-transform:none}@media screen and (min-width: 768px){.advertory-abo-ad-native-default{width:580px;height:400px}}.advertory-abo-ad-native-default .ad-info{position:absolute;top:20px;height:26px;width:26px;left:0;z-index:1000;background-color:hsla(0,0%,100%,.4509803922);border-bottom-right-radius:13px;transform:none;transform-origin:center}@media screen and (min-width: 768px){.advertory-abo-ad-native-default .ad-info{top:30px}}.advertory-abo-ad-native-default .ad-link{display:block;text-decoration:none;color:#000;background-color:rgba(0,0,0,0)}.advertory-abo-ad-native-default .ad-content{display:block}.advertory-abo-ad-native-default .ad-image-container{position:relative;line-height:0}.advertory-abo-ad-native-default .ad-image-container .ad-header{position:absolute;height:20px;width:100%;font-size:13px;line-height:20px;color:#4c3d00;background:rgba(255,205,0,.8)}@media screen and (min-width: 768px){.advertory-abo-ad-native-default .ad-image-container .ad-header{height:30px;line-height:30px;padding-left:16px}}.advertory-abo-ad-native-default .ad-image-container .ad-header span{margin-left:8px}@media screen and (min-width: 768px){.advertory-abo-ad-native-default .ad-image-container .ad-header span{margin:0}}.advertory-abo-ad-native-default .ad-image-container .ad-image{position:static;width:100%;height:52.3560209424vw}@media screen and (min-width: 768px){.advertory-abo-ad-native-default .ad-image-container .ad-image{height:301px}}.advertory-abo-ad-native-default .ad-image-container .ad-logo{position:absolute;height:30px;width:auto;top:auto;bottom:8px;left:8px;right:auto}@media screen and (min-width: 768px){.advertory-abo-ad-native-default .ad-image-container .ad-logo{left:16px;bottom:16px}}.advertory-abo-ad-native-default .ad-text-container{background:#fff6d1;overflow:auto}.advertory-abo-ad-native-default .ad-text-container .ad-sponsored-by{color:#64625a;font-size:10px;margin:8px 8px 3px 8px;text-transform:uppercase;display:block}@media screen and (min-width: 768px){.advertory-abo-ad-native-default .ad-text-container .ad-sponsored-by{font-size:13px;margin:8px 16px}}.advertory-abo-ad-native-default .ad-text-container .ad-title{margin:0 8px 7px 8px;min-height:52px;line-height:24px;color:#000;font-size:20px;font-weight:700;display:flex;flex-direction:column;justify-content:center}@media screen and (min-width: 768px){.advertory-abo-ad-native-default .ad-text-container .ad-title{font-size:24px;margin:0 16px 8px 16px;height:59px;min-height:auto;line-height:normal;overflow:hidden}}.advertory-abo-ad-native-default.bt .ad-text-container .ad-title{font-family:"TabacG2",serif;font-weight:500}'),Zt('.advertory-abo-ad-native-sponsorstripe{position:absolute;top:0;left:0;width:100%;height:1px;background:inherit;padding:0;margin:0;border:none;text-align:left}.advertory-abo-ad-native-sponsorstripe .ad-wrapper{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:center;max-width:980px;height:30px;padding:5px 15px;margin:auto;font-family:"Helvetica Neue",Arial,Roboto,sans-serif}.advertory-abo-ad-native-sponsorstripe .ad-logo{flex:0;height:20px;max-width:35%;max-height:inherit}.advertory-abo-ad-native-sponsorstripe .ad-title{margin-right:10px;padding-left:34px;font-size:13px;color:#fff}.advertory-abo-ad-native-sponsorstripe .info-button-wrapper{display:grid;position:absolute;place-content:center;height:30px;min-width:30px}.advertory-abo-ad-native-sponsorstripe .info-button-wrapper .info-button{display:inline-block;height:20px;width:20px;position:relative;border:solid 1px #fff;border-radius:50%;cursor:pointer}.advertory-abo-ad-native-sponsorstripe .info-button-wrapper .info-button:before{content:"i";color:#fff;position:absolute;left:50%;top:50%;transform:translate(-50%, -50%);font-size:13px}.advertory-abo-ad-native-sponsorstripe .ad-description{font-size:13px;color:#fff;position:absolute;top:0;max-width:980px;min-height:30px;padding:15px 35px 15px 15px;margin-left:-15px;background-color:rgba(0,0,0,.9)}.advertory-abo-ad-native-sponsorstripe .ad-description .close-button-wrapper{position:absolute;top:15px;right:15px;place-content:center;height:16px;min-width:16px}.advertory-abo-ad-native-sponsorstripe .ad-description .close-button-wrapper .close-button{display:inline-block;height:16px;width:16px;position:relative;border:1px solid #fff;border-radius:50%;cursor:pointer}.advertory-abo-ad-native-sponsorstripe .ad-description .close-button-wrapper .close-button:before{content:"✕";color:#fff;position:absolute;left:50%;top:50%;transform:translate(-50%, -50%);font-size:10px;font-weight:bold}.advertory-abo-ad-native-sponsorstripe .ad-description .ad-description-readmore{color:#c7ecff}.advertory-abo-ad-native-sponsorstripe .ad-description.hide{display:none}@media screen and (min-width: 768px){.advertory-abo-ad-native-sponsorstripe .ad-wrapper{height:50px}.advertory-abo-ad-native-sponsorstripe .ad-wrapper .ad-description{min-height:50px}.advertory-abo-ad-native-sponsorstripe .ad-logo{height:40px}.advertory-abo-ad-native-sponsorstripe .ad-title{font-size:20px;padding-left:40px}.advertory-abo-ad-native-sponsorstripe .info-button-wrapper .info-button{height:30px;width:30px;border-width:2px}.advertory-abo-ad-native-sponsorstripe .info-button-wrapper .info-button:before{font-size:20px}}'),Zt(".advertory-abo-ad-native-recirc{width:100%;min-height:250px;margin:auto;color:#000;text-align:left;position:relative;box-sizing:border-box;text-decoration:none;display:table;table-layout:fixed}@media screen and (min-width: 768px){.advertory-abo-ad-native-recirc{max-width:283px;height:400px}}.advertory-abo-ad-native-recirc .ad-info{position:absolute;top:0;height:26px;width:26px;left:0;z-index:1000;background-color:hsla(0,0%,100%,.4509803922);border-bottom-right-radius:13px;transform:none;transform-origin:center}.advertory-abo-ad-native-recirc .ad-link{display:block;text-decoration:none;color:#000;background-color:rgba(0,0,0,0)}.advertory-abo-ad-native-recirc .ad-content{display:block}.advertory-abo-ad-native-recirc .ad-image-container{position:relative;line-height:0}.advertory-abo-ad-native-recirc .ad-image-container .ad-header{height:30px;font-size:13px;line-height:30px;font-weight:600;color:#4c3d00;background:rgba(255,205,0,.8);padding-left:32px;font-family:-apple-system,BlinkMacSystemFont,sans-serif;border-top-right-radius:10px;border-top-left-radius:10px}.advertory-abo-ad-native-recirc .ad-image-container .ad-image{width:100%}.advertory-abo-ad-native-recirc .ad-image-container .ad-logo{position:absolute;height:30px;width:auto;top:auto;bottom:8px;left:8px;right:auto}@media screen and (min-width: 768px){.advertory-abo-ad-native-recirc .ad-image-container .ad-logo{left:16px;bottom:16px}}.advertory-abo-ad-native-recirc .ad-text-container{background:#fff6d1;overflow:auto;border-bottom-right-radius:10px;border-bottom-left-radius:10px}.advertory-abo-ad-native-recirc .ad-text-container .ad-sponsored-by{display:block;color:#64625a;font-size:13px;padding:5px 8px;text-transform:uppercase;font-family:Roboto,sans-serif}.advertory-abo-ad-native-recirc .ad-text-container .ad-title{padding:6px 8px;margin-bottom:12px;color:#000;font-size:17px;font-weight:700;font-family:Arial,sans-serif}"),Zt('.advertory-abo-ad-native-content-video{position:relative;display:table;table-layout:fixed;width:100%;margin:0 auto;background:#fff;font-family:"Inter",sans-serif;font-weight:700;text-align:left;color:#000}.advertory-abo-ad-native-content-video *{line-height:1}.advertory-abo-ad-native-content-video a.ad-link{display:block;text-decoration:none;color:inherit}.advertory-abo-ad-native-content-video a.ad-link:hover{text-decoration:none}.advertory-abo-ad-native-content-video .ad-info{z-index:10;top:44px}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-info{top:50px}}.advertory-abo-ad-native-content-video .ad-info div[role=button]{top:44px !important;border-bottom-right-radius:13px;background-color:hsla(0,0%,100%,.45);z-index:10}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-info div[role=button]{top:51px !important}}.advertory-abo-ad-native-content-video .ad-content{display:flex;flex-direction:column}.advertory-abo-ad-native-content-video .ad-content .ad-header{position:relative;height:44px;display:flex;align-items:center;text-transform:uppercase;padding:0 8px}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-content .ad-header{height:51px;min-height:0}}.advertory-abo-ad-native-content-video .ad-content .ad-header span{font-weight:700;font-size:13px;position:absolute;top:50%;transform:translateY(-50%)}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-content .ad-header span{font-size:20px;padding-left:12px}}.advertory-abo-ad-native-content-video .ad-content .ad-header .ad-logo{position:absolute;right:0;width:auto;height:40px;margin-right:8px}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-content .ad-header .ad-logo{width:auto;height:35px}}.advertory-abo-ad-native-content-video .ad-content .ad-image-container{display:flex;position:relative}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-content .ad-image-container{min-height:0}}.advertory-abo-ad-native-content-video .ad-content .ad-image-container .ad-image{width:100%;height:auto;object-fit:cover;object-position:center 0}.advertory-abo-ad-native-content-video .ad-content .ad-image-container .ad-player-wrapper{height:56.4971751412vw;width:100%}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-content .ad-image-container .ad-player-wrapper{height:407px}}.advertory-abo-ad-native-content-video .ad-content .ad-text-container{display:flex;flex-direction:column;color:#2b2b2b;padding-bottom:10px}.advertory-abo-ad-native-content-video .ad-content .ad-text-container .sponsored-by{display:block;padding:8px;font-size:12px;font-weight:normal;text-transform:uppercase}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-content .ad-text-container .sponsored-by{padding:8px 10px}}.advertory-abo-ad-native-content-video .ad-content .ad-text-container .ad-title{display:block;padding:0 8px;margin-left:0;margin-bottom:0;font-size:var(--mobileTitleSize);font-weight:bold;line-height:1}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-content .ad-text-container .ad-title{padding:4px 12px 8px 12px;font-size:var(--desktopTitleSize)}}.advertory-abo-ad-native-content-video .ad-content .ad-text-container .ad-description{margin:4px 0;padding:0 8px;font-size:16px;line-height:calc(15px);color:#000}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video .ad-content .ad-text-container .ad-description{padding:0 12px}}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video.bt .ad-content .ad-image-container .ad-player-wrapper,.advertory-abo-ad-native-content-video.sa .ad-content .ad-image-container .ad-player-wrapper{height:302px}}@media screen and (min-width: 768px){.advertory-abo-ad-native-content-video.bt .ad-content .ad-text-container .ad-title,.advertory-abo-ad-native-content-video.sa .ad-content .ad-text-container .ad-title{font-size:23px}}'),Zt('.advertory-no-ad-native-default{width:calc(100% - 32px);min-height:250px;margin:auto;color:#dfdfdf;font-family:"Inter",sans-serif;font-weight:600;text-align:left;position:relative;box-sizing:border-box;text-decoration:none;display:table;table-layout:fixed;font-size:14px}@media screen and (min-width: 768px){.advertory-no-ad-native-default{width:580px;height:400px}}.advertory-no-ad-native-default *{box-sizing:border-box;line-height:normal;text-transform:none}.advertory-no-ad-native-default .ad-info{position:absolute;top:0;left:0;height:26px;width:26px;z-index:1000;background-color:#dfdfdf;border-bottom-right-radius:13px;transform:none;transform-origin:center}.advertory-no-ad-native-default .ad-link{display:block;text-decoration:none;color:#000;background-color:rgba(0,0,0,0);border:1px solid #dfdfdf}.advertory-no-ad-native-default .ad-content{display:block}.advertory-no-ad-native-default .ad-image-container{background-color:#dfdfdf;display:flex;position:relative;line-height:0}.advertory-no-ad-native-default .ad-image-container .ad-image{position:static;width:100%;aspect-ratio:1.91;height:auto}.advertory-no-ad-native-default .ad-text-container{background:#f5faff;overflow:auto;padding:8px}@media screen and (min-width: 768px){.advertory-no-ad-native-default .ad-text-container{padding:12px 16px}}.advertory-no-ad-native-default .ad-text-container .ad-sponsor{font-size:12px;margin:0;text-transform:uppercase;display:block}@media screen and (min-width: 768px){.advertory-no-ad-native-default .ad-text-container .ad-sponsor{font-size:14px;margin-right:8px}}.advertory-no-ad-native-default .ad-text-container .ad-sponsor .ad-label{font-weight:600;color:#fff;background-color:#467aae;display:inline-block;padding:4px 6px;border-radius:4px;border:none;margin-right:4px}.advertory-no-ad-native-default .ad-text-container .ad-title{margin:4px 0 0 0;line-height:normal;color:#000;font-size:18px;display:flex;flex-direction:column;justify-content:center}@media screen and (min-width: 768px){.advertory-no-ad-native-default .ad-text-container .ad-title{margin:12px 0 0 0;font-size:28px}}.advertory-vg-native-ad__front .advertory-no-ad-native-default{width:100%;height:auto}.advertory-aftenposten-native-ad-wrapper__front{justify-content:center}.advertory-e24-native-ad-wrapper__article{margin-bottom:calc(-40px + 4rem)}@media screen and (min-width: 768px){.advertory-e24-native-ad-wrapper__article{margin-bottom:calc(12px + .75rem)}}');Zt('.advertory-no-ad-native-recirc{width:100%;min-height:250px;margin:0 auto;color:#000;text-align:left;position:relative;box-sizing:border-box;text-decoration:none;display:table;table-layout:fixed;background-color:#fff;font-family:"Inter",sans-serif;font-weight:600;text-align:left;font-size:14px;container-type:inline-size}.advertory-no-ad-native-recirc *{box-sizing:border-box;line-height:normal;text-transform:none}.advertory-no-ad-native-recirc .ad-info{position:absolute;top:0;left:0;height:26px;width:26px;z-index:1000;background-color:#dfdfdf;border-bottom-right-radius:13px;transform:none;transform-origin:center}.advertory-no-ad-native-recirc .ad-link{display:block;text-decoration:none;color:#000;background-color:rgba(0,0,0,0);border:1px solid #dfdfdf}.advertory-no-ad-native-recirc .ad-content{display:flex;flex-direction:column}.advertory-no-ad-native-recirc .ad-image-container{background-color:#dfdfdf;display:flex;position:relative;line-height:0}@container (min-width: dna.$md){.advertory-no-ad-native-recirc .ad-image-container{min-height:0}}.advertory-no-ad-native-recirc .ad-image-container .ad-image{position:static;width:100%;aspect-ratio:1.91;height:auto}.advertory-no-ad-native-recirc .ad-text-container{background:#f5faff;overflow:auto;padding:8px;container-type:inline-size}@container (min-width: dna.$md){.advertory-no-ad-native-recirc .ad-text-container{padding:12px 16px}}.advertory-no-ad-native-recirc .ad-text-container .ad-sponsor{font-size:12px;margin:0;text-transform:uppercase;display:block}@container (min-width: dna.$md){.advertory-no-ad-native-recirc .ad-text-container .ad-sponsor{font-size:14px;margin-right:8px}}.advertory-no-ad-native-recirc .ad-text-container .ad-sponsor .ad-label{font-weight:600;color:#fff;background-color:#467aae;display:inline-block;padding:4px 6px;border-radius:4px;border:none;margin-right:4px}.advertory-no-ad-native-recirc .ad-text-container .ad-title{margin:4px 0 0 0;line-height:normal;color:#000;font-size:18px;display:flex;flex-direction:column;justify-content:center}@container (min-width: 420px){.advertory-no-ad-native-recirc .ad-text-container .ad-title{margin:12px 0 0 0;font-size:28px}}'),Zt('.advertory-no-ad-native-seamless .ad-info div[role=button]{left:100%;transform:translateX(-100%);background-color:hsla(0,0%,100%,.45);border-bottom-left-radius:13px}.advertory-no-ad-native-seamless .ad-link{text-decoration:none;color:inherit}.advertory-no-ad-native-seamless .ad-link .ad-content{min-width:320px;height:100%;margin:0 auto;padding:8px 8px 0;font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;border-radius:10px;background-color:var(--color-background-secondary, #ffffff);color:var(--color-text-primary, #333)}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-header{padding:8px 10px 10px 10px}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-header .ad-brand{display:flex;align-items:center;gap:12px;margin-bottom:11px}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-header .ad-brand .ad-logo{max-height:44px;border-radius:50%}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-header .ad-brand .ad-brand-text{display:flex;flex-direction:column;gap:3px;align-items:start}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-header .ad-brand .ad-brand-text .sponsored-by{font-size:16px;font-weight:500;line-height:1}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-header .ad-brand .ad-brand-text .ad-annons{font-size:14px;font-weight:400;line-height:1.1;color:var(--color-text-primary, #333);text-transform:lowercase}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-header .ad-brand .ad-brand-text .ad-annons::first-letter{text-transform:uppercase}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-header .ad-headline{margin:0;font-size:16px;font-weight:400;line-height:1.2;word-spacing:-1px;text-align:left}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-image-container{width:100%;aspect-ratio:1/1;overflow:hidden;display:flex;justify-content:center;align-items:center}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-image-container .ad-image{height:100%;width:auto;object-fit:cover}@media screen and (min-width: 768px){.advertory-no-ad-native-seamless .ad-link .ad-content .ad-image-container{aspect-ratio:1.91/1}}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-footer{display:flex;flex-direction:column;justify-content:center;padding:13px 10px}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-footer .ad-row{display:flex;align-items:center;justify-content:space-between}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-footer .ad-row .ad-text-wrapper{display:flex;flex-direction:column;gap:5px;flex-grow:1;padding-right:8px;align-items:start}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-footer .ad-row .ad-text-wrapper .ad-domain{font-size:11px;line-height:1;color:#666;text-transform:uppercase;text-align:left;font-weight:500}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-footer .ad-row .ad-text-wrapper .ad-description{font-size:15.5px;font-weight:500;text-align:left;word-spacing:-1px;color:var(--color-text-primary, #111111)}.advertory-no-ad-native-seamless .ad-link .ad-content .ad-footer .ad-row .ad-action{flex-shrink:0;padding:10px 14px;font-size:12px;line-height:1;color:var(--color-text-primary, #111111);white-space:nowrap;background-color:var(--color-background-tertiary, #d9d9d9);border-radius:12px;font-weight:500}.advertory-aftenposten-native-ad-wrapper__front:has(.advertory-no-ad-native-seamless),.advertory-aftenposten-native-ad__front:has(.advertory-no-ad-native-seamless),.advertory-bt-native-ad-wrapper__front:has(.advertory-no-ad-native-seamless),.advertory-bt-native-ad__front:has(.advertory-no-ad-native-seamless),.advertory-sa-native-ad-wrapper__front:has(.advertory-no-ad-native-seamless){max-width:100%}');const ar={NATIVE_TEMPLATE:({containerId:e,url:t,sponsoredBy:n,title:i,img:o,adText:r})=>`<article class="advertory-no-ad-native-default">\n <div class="ad-info" id="${e}-button"></div>\n <a class="ad-link" href="${t}" target="_self">\n <div class="ad-content">\n <div class="ad-image-container">\n <img alt="${i}" class="ad-image" src="${o}" />\n </div>\n <div class="ad-text-container">\n <div class="ad-sponsor">\n <span class="ad-label">${r}</span> ${n}\n </div>\n <div class="ad-title">${i}</div>\n </div>\n </div>\n </a>\n </article>`},dr={displayTemplates:{default:ar.NATIVE_TEMPLATE},videoTemplates:{}},sr=((e,t)=>n=>Qo(Object.assign(Object.assign({},n),{siteSpecificConfig:t}),e))({initNativeAd:(e,t)=>{const{targetId:n}=e;if(!document.querySelector(`#${n}`))return;const{pageType:i=In.FRONT,nativeTrackingConfig:o,appearanceConfig:r,deviceType:a}=null!=t?t:{},d={language:x.NO,publisher:Tn.PENT,deviceType:a,pageType:i,nativeTrackingConfig:o,appearanceConfig:r};rr(e,d,dr)},wallpaperHandlers:{initWallpaperAd:(e,t)=>{if(!t)return;const{options:{appMainContainerSelector:n,wallpaperAnchorSelector:i}={}}=t;(e=>{const t=document.querySelector(e||"#application");if(!t)return;ye();const n=document.createElement("div");n.classList.add(me),document.body.insertBefore(n,t.nextSibling),n.style.setProperty("position","fixed"),n.style.setProperty("width","100%"),n.style.setProperty("height","calc(100% - var(--header-height, 0px) - 15px)"),n.style.setProperty("background-position","center top"),n.style.setProperty("background-repeat","no-repeat")})(n),(e=>{const t=e||".advertory-wrapper-common-skyscraperleft_1",n=document.querySelector(t);n&&(be(n),window.addEventListener("scroll",()=>be(n)))})(i),e()},adjustAdToHorseshoe:e=>{var t;const n=document.querySelector(`#${e}`);n&&(null===(t=n.parentElement)||void 0===t||t.classList.add(fe),n.classList.add(fe))}},loadFinnBlinkAd:ue,replaceAdsWithFinnBlink:ue,preparePageOptions:ae,prepareTag:e=>{const{keywords:t,targetId:n,invCode:i}=e,{useAppTabletInvCode:o=!0}=l.get(),r=((e,t)=>{const{isMobileApp:n}=l.get();return n?((e,t)=>e.replace(/wtb|wde|wph/g,e=>"wph"===e?"aph":t?"atb":e))(e,t):e})(i,o),a=(e=>{const{country:t}=l.get(),{keywords:n,dynamicSizeWidthCheck:i}=e,o=`${$(t)}-adformat`,r=n?n[o]:[];if(!r)return{};const a=(Array.isArray(r)?r:[r]).filter(e=>!(e in Ue)||window.innerWidth>=Ue[e]);return{[o]:i?a:r}})(e),d=(e=>{const{country:t}=l.get(),n=`${$(t)}-targetid`;return e?{[n]:[e]}:{}})(n),s=Zo(),c=(e=>er(e)?{"aa-sch-dynamic-outstream":["true"]}:{})(i),p=((e,t)=>er(e)?Object.assign(Object.assign({},t),{playerSkin:{videoBackgroundColor:"#e6e7e8"}}):{})(i);return Object.assign(Object.assign({},e),{invCode:r,keywords:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},t),a),d),c),s),rendererOptions:p})},siteEvents:Lt,librariesToLoad:[]},tr),lr=Zt("[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-slider-time,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-slider-time{display:none}[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container{padding:0 6px;height:36px}[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-icon-fullscreen,[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-settings-sharing,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-icon-fullscreen,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-settings-sharing{display:none}[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-icon,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-icon{margin-right:3px;height:unset;width:unset;bottom:0}[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-icon-volume,[id^=integration_godt-menu]>article .jw-controls>.jw-controlbar .jw-button-container .jw-icon-playback,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-icon-volume,.advertory-godt-ad-weekly-menu .jw-controls>.jw-controlbar .jw-button-container .jw-icon-playback{display:flex}");var cr=Object.freeze({__proto__:null,default:lr});exports.initAdvertoryPackage=sr,exports.updateAdvertory=(t,n)=>e(void 0,void 0,void 0,function*(){var e;if(!(null===(e=null===window||void 0===window?void 0:window.advertory)||void 0===e?void 0:e.initialized))return[];const{clearAds:i,reloadExistingAds:o,renderFinnBlinkPlacements:r,contextSelector:a}=null!=n?n:{};if(i)return Ce(),[];o&&(Ce(),document.querySelectorAll('[data-advertory-ad-rendered="true"]').forEach(e=>{Ee(e.id)})),c(null!=t?t:{}),yield Fo();const{clientSidePlacements:d,serverSidePlacements:s}=vo(je(a));let p=d;return r&&(p=p.filter(e=>Ze(e.id))),ho(s,l.get()),p.length>0&&(Mo=[...Mo,...p.map(e=>Object.assign({},e))],hi(p),fi(p),yield Go(p)),Mo});