
        (function(config) {
            var ConfigWrapper=function(){"use strict";function e(e){function t(e,t){var i,n,r=t.replace(/\[(\w+)\]/g,".$1").replace(/^\./,"").split("."),o=r.length;for(i=0;i<o;i+=1){if(n=r[i],!(n in e))return null;e=e[n]}return e}this.get=function(i,n){var r,o=n;return 0===arguments.length?JSON.parse(JSON.stringify(e)):(1===arguments.length&&(o=null),r=t(e,i),null==r&&(r=o),r?JSON.parse(JSON.stringify(r)):r)}}return e}();!function(e,t){"use strict";function i(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),i=0;i<t.length;i++)t[i]=arguments[i+1];var n={callback:e,args:t};return m[h]=n,u(h),h++}function n(e){delete m[e]}function r(e){var i=e.callback,n=e.args;switch(n.length){case 0:i();break;case 1:i(n[0]);break;case 2:i(n[0],n[1]);break;case 3:i(n[0],n[1],n[2]);break;default:i.apply(t,n)}}function o(e){if(f)setTimeout(o,0,e);else{var t=m[e];if(t){f=!0;try{r(t)}finally{n(e),f=!1}}}}function s(){u=function(e){process.nextTick(function(){o(e)})}}function a(){if(e.postMessage&&!e.importScripts){var t=!0,i=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=i,t}}function l(){var t="setImmediate$"+Math.random()+"$",i=function(i){i.source===e&&"string"==typeof i.data&&0===i.data.indexOf(t)&&o(+i.data.slice(t.length))};e.addEventListener?e.addEventListener("message",i,!1):e.attachEvent("onmessage",i),u=function(i){e.postMessage(t+i,"*")}}function c(){var e=new MessageChannel;e.port1.onmessage=function(e){var t=e.data;o(t)},u=function(t){e.port2.postMessage(t)}}function p(){var e=y.documentElement;u=function(t){var i=y.createElement("script");i.onreadystatechange=function(){o(t),i.onreadystatechange=null,e.removeChild(i),i=null},e.appendChild(i)}}function d(){u=function(e){setTimeout(o,0,e)}}if(!e.setImmediate){var u,h=1,m={},f=!1,y=e.document,v=Object.getPrototypeOf&&Object.getPrototypeOf(e);v=v&&v.setTimeout?v:e,"[object process]"==={}.toString.call(e.process)?s():a()?l():e.MessageChannel?c():y&&"onreadystatechange"in y.createElement("script")?p():d(),v.setImmediate=i,v.clearImmediate=n}}("undefined"==typeof self?"undefined"==typeof global?this:global:self);var EventEmitter=function(){"use strict";function e(){this.listeners={}}var t=function(e,t,i){null!=e[t]&&i>=0&&e[t].length>i&&(e[t][i]=null)},i=function(e,t){null!=e[t]&&(e[t]=null)};return e.prototype.emit=function(e,t){null!=this.listeners[e]&&this.listeners[e].forEach(function(e){null!=e&&window.setImmediate(function(){e(t)})})},e.prototype.emitSync=function(e,t){null!=this.listeners[e]&&this.listeners[e].forEach(function(e){null!=e&&e(t)})},e.prototype.on=function(e,t){return this.listeners[e]?this.listeners[e].push(t):this.listeners[e]=[t],this.listeners[e].length-1},e.prototype.once=function(e,t){var i=this.on(e,function(n){this.listeners[e][i]&&(this.off(e,i),t(n))}.bind(this));return i},e.prototype.off=function(){switch(arguments.length){case 0:this.listeners={};break;case 1:i(this.listeners,arguments[0]);break;default:t(this.listeners,arguments[0],arguments[1])}},e}(),utils=function(){"use strict";var e={};return e.canAccessTopWindow=function(){return e.canAccessWindow(window.top)},e.canAccessWindow=function(e){var t;try{return t=e.location.href,!!t}catch(i){return!1}},e.getRealDomain=function(){var t,i,n;if(e.canAccessTopWindow())i=window.top.location.href;else{for(t=window;e.canAccessWindow(t.parent);)t=t.parent;i=t.document.referrer}return n=i.match(/^https?\:\/\/(?:www\.)?([^\/:?#]+)(?:[\/:?#]|$)/i),n&&n[1]},e.isString=function(e){return"string"==typeof e||e instanceof String},e}(),inDapIF,wnd,doc,injectorPlayerEmitter;config=new ConfigWrapper(config),inDapIF=window!==window.top&&utils.canAccessTopWindow(),wnd=function(e){"use strict";var t=config.get("format_family"),i=config.get("enable_intext_animation",!0),n=!("banner"===t||"display"===t||"gallery"===t||"native"===t&&!i)||"no"!==config.get("vip_mode","no");return inDapIF&&n?e.top:e}(window),doc=wnd.document,injectorPlayerEmitter=new EventEmitter;var cssTpl="@-webkit-keyframes spinner{to{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@-moz-keyframes spinner{to{-moz-transform:rotate(360deg);transform:rotate(360deg)}}@-o-keyframes spinner{to{-o-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes spinner{to{-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);-o-transform:rotate(360deg);transform:rotate(360deg)}}#vr-namespace-viralize-wide-wrapper{display:table;width:100%;float:none}#vr-namespace-wrapper{position:relative;float:none}#vr-namespace-viralize-wide-wrapper.vr-namespace-description-lateral #vr-namespace-placeholder,#vr-namespace-viralize-wide-wrapper.vr-namespace-description-lateral #vr-namespace-wrapper:not(.vr-namespace-vip){display:table-cell;width:70%}#vr-namespace-viralize-wide-wrapper.vr-namespace-description-lateral #vr-namespace-description{display:table-cell;padding:10px;vertical-align:top}#vr-namespace-wrapper:before{display:table;content:\"\";width:100%;padding-top:56.25%;height:0;background:#000}#vr-namespace-wrapper.vr-namespace-fixed-size:before{padding-top:0;height:100%}#vr-namespace-wrapper.vr-namespace-fixed-size{min-width:auto!important}#vr-namespace-wrapper:after{content:'';-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;position:absolute;top:50%;left:50%;width:30px;height:30px;margin-top:-15px;margin-left:-15px;-webkit-border-radius:50%;-moz-border-radius:50%;border-radius:50%;border:1px solid #ccc;border-top-color:#f06;-webkit-animation:spinner 1s linear infinite;-moz-animation:spinner 1s linear infinite;-o-animation:spinner 1s linear infinite;animation:spinner 1s linear infinite;z-index:0}#vr-namespace-close-content:after{content:'\\00d7'}#vr-namespace-wrapper.vr-namespace-vip #vr-namespace-close-content{position:absolute;right:0;top:0;cursor:pointer;color:#fff;font:30px/100% arial,sans-serif;font-weight:700;text-decoration:none;z-index:1000000;padding-top:5px;padding-right:10px;padding-left:8px}#vr-namespace-wrapper #vr-namespace-display{position:absolute;top:0;width:100%;height:100%;z-index:1}#vr-namespace-wrapper.vr-namespace-vip{position:fixed;width:25%;height:auto;z-index:10000}#vr-namespace-close-content{opacity:0;height:0;filter:alpha(opacity=0)}#vr-namespace-wrapper.vr-namespace-vip #vr-namespace-close-content.vr-namespace-show-close{opacity:1;height:auto;filter:alpha(opacity=100)}@media screen and (min-width:1025px) and (orientation:landscape){#vr-namespace-wrapper.vr-namespace-vip{width:25%}#vr-namespace-wrapper.vr-namespace-vip.vr-namespace-medium{min-width:400px}#vr-namespace-wrapper.vr-namespace-vip.vr-namespace-large{min-width:535px}#vr-namespace-wrapper.vr-namespace-desktop-bottom-right{bottom:20px;right:20px}#vr-namespace-wrapper.vr-namespace-desktop-bottom-left{bottom:20px;left:20px}#vr-namespace-wrapper.vr-namespace-desktop-top-left{top:20px;left:20px}#vr-namespace-wrapper.vr-namespace-desktop-top-right{top:20px;right:20px}#vr-namespace-wrapper.vr-namespace-desktop-bottom,#vr-namespace-wrapper.vr-namespace-desktop-top{left:50%;-webkit-transform:translateX(-50%);-moz-transform:translateX(-50%);-ms-transform:translateX(-50%);-o-transform:translateX(-50%);transform:translateX(-50%)}#vr-namespace-wrapper.vr-namespace-desktop-top{top:20px}#vr-namespace-wrapper.vr-namespace-desktop-bottom{bottom:20px}}@media screen and (max-width:1024px) and (orientation:landscape){#vr-namespace-wrapper.vr-namespace-vip{position:fixed;width:50%;min-width:0}#vr-namespace-wrapper.vr-namespace-mobile-landscape-bottom-right{bottom:5px;right:5px}#vr-namespace-wrapper.vr-namespace-mobile-landscape-top-left{top:5px;left:5px}#vr-namespace-wrapper.vr-namespace-mobile-landscape-top-right{top:5px;right:5px}#vr-namespace-wrapper.vr-namespace-mobile-landscape-bottom-left{bottom:5px;left:5px}#vr-namespace-wrapper.vr-namespace-mobile-landscape-bottom,#vr-namespace-wrapper.vr-namespace-mobile-landscape-top{left:50%;-webkit-transform:translateX(-50%);-moz-transform:translateX(-50%);-ms-transform:translateX(-50%);-o-transform:translateX(-50%);transform:translateX(-50%)}#vr-namespace-wrapper.vr-namespace-mobile-landscape-top{top:5px}#vr-namespace-wrapper.vr-namespace-mobile-landscape-bottom{bottom:5px}}@media screen and (orientation:portrait){#vr-namespace-wrapper.vr-namespace-vip{position:fixed;width:75%;min-width:0}#vr-namespace-wrapper.vr-namespace-mobile-portrait-bottom,#vr-namespace-wrapper.vr-namespace-mobile-portrait-top{left:50%;-webkit-transform:translateX(-50%);-moz-transform:translateX(-50%);-ms-transform:translateX(-50%);-o-transform:translateX(-50%);transform:translateX(-50%)}#vr-namespace-wrapper.vr-namespace-mobile-portrait-top{top:0}#vr-namespace-wrapper.vr-namespace-mobile-portrait-bottom{bottom:5px}#vr-namespace-wrapper.vr-namespace-mobile-portrait-top-left{top:0;left:0}#vr-namespace-wrapper.vr-namespace-mobile-portrait-top-right{top:0;right:0}#vr-namespace-wrapper.vr-namespace-mobile-portrait-bottom-left{bottom:5px;left:0}#vr-namespace-wrapper.vr-namespace-mobile-portrait-bottom-right{bottom:5px;right:0}}",CssLoader=function(){"use strict";var e=function(e,t,i){this.id=e,this.css=utils.copyString(t),i&&(this.css+=i)};return e.prototype.getCssNameNamespace=function(){return"vr-"+this.id},e.prototype.loadStyle=function(e){var t=this.css.replace(new RegExp("namespace","g"),this.id),i=doc.createElement("style");if(i.id="vr-"+this.id,e.parentNode.insertBefore(i,e),i.styleSheet)i.styleSheet.disabled||(i.styleSheet.cssText=t);else try{i.innerHTML=t}catch(n){i.innerText=t}},e}(),ajax=function(){"use strict";var e={},t=function(e,t,i,n){var r=!0,o={UNSET:0,OPENED:1,HEADERS_RECEIVED:2,LOADING:3,DONE:4},s=[200,201,202,204,206,304,1223],a=function(){try{return new XDomainRequest}catch(e){r=!1}try{return new XMLHttpRequest}catch(e){}try{return new ActiveXObject("Msxml3.XMLHTTP")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.6.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.3.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP")}catch(e){}try{return new ActiveXObject("Microsoft.XMLHTTP")}catch(e){}return null},l=a(),c=t?"POST":"GET";l&&(l.open(c,e,!0),r?(l.onload=function(){i&&i(l.responseText)},l.onprogress=function(){},l.ontimeout=function(){},l.onerror=function(){n&&n()}):l.onreadystatechange=function(){l.readyState===o.DONE&&(s.indexOf(l.status)>-1?i&&i(l.responseText):n&&n())},"withCredentials"in l&&(l.withCredentials=!0),t&&l.setRequestHeader("Content-type","application/json"),l.send(t))};return e.get=function(e,i,n){return t(e,null,i,n)},e.post=function(e,i,n,r){var o=i?JSON.stringify(i):"{}";return t(e,o,n,r)},e}(),Log;Log=function(){"use strict";function e(e){this.prefix="["+(e||"VR-LOG")+"]"}return e.prototype.debug=function(){},e.prototype.info=function(){},e.prototype.warn=function(){},e.prototype.error=function(){},e}();var TemplateLoader=function(){"use strict";var e={};return e.render=function(e,t){var i=e;return Object.keys(t).forEach(function(e){var n=new RegExp("{{"+e+"}}","g");i=i.replace(n,t[e])}),i},e}(),PlayerDependencies={player:{debug:["//ajax.googleapis.com/ajax/libs/jquery/1.12.1/jquery.js","//cdn.polyfill.io/v2/polyfill.js?flags=gated","//imasdk.googleapis.com/js/sdkloader/ima3_debug.js"],default:["//ajax.googleapis.com/ajax/libs/jquery/1.12.1/jquery.min.js","//cdn.polyfill.io/v2/polyfill.min.js?unknown=polyfill&flags=gated","//imasdk.googleapis.com/js/sdkloader/ima3.js"]},mobi:{debug:["//ajax.googleapis.com/ajax/libs/jquery/1.12.1/jquery.js","//cdn.polyfill.io/v2/polyfill.js?flags=gated"],default:["//ajax.googleapis.com/ajax/libs/jquery/1.12.1/jquery.min.js","//cdn.polyfill.io/v2/polyfill.min.js?unknown=polyfill&flags=gated"]},banner:{debug:["//ajax.googleapis.com/ajax/libs/jquery/1.12.1/jquery.js","//cdn.polyfill.io/v2/polyfill.js?flags=gated"],default:["//ajax.googleapis.com/ajax/libs/jquery/1.12.1/jquery.min.js","//cdn.polyfill.io/v2/polyfill.min.js?unknown=polyfill&flags=gated"]},strip:{debug:["//ajax.googleapis.com/ajax/libs/jquery/1.12.1/jquery.js","//cdn.polyfill.io/v2/polyfill.js?flags=gated"],default:["//ajax.googleapis.com/ajax/libs/jquery/1.12.1/jquery.min.js","//cdn.polyfill.io/v2/polyfill.min.js?unknown=polyfill&flags=gated"]},sentry:"//cdn.ravenjs.com/3.17.0/raven.min.js"},MaxInstancesError=function(){"use strict";function e(e){this.message=e}return e.prototype=new Error,e}(),DuplicateInjectorError=function(){"use strict";function e(e){this.message=e}return e.prototype=new Error,e}(),ViewabilityUnavailableError=function(){"use strict";function e(e){this.message=e}return e.prototype=new Error,e}(),ViewabilityClassNotFoundError=function(){"use strict";function e(e){this.message=e}return e.prototype=new Error,e}(),DuplicatedViewabilityImplementationError=function(){"use strict";function e(e){this.message=e}return e.prototype=new Error,e}(),Constants={ADUNIT_REQUEST_ERRORS:{SCRIPT_NOT_FOUND:30001,LOCATION_INLINE_ERROR:30002,LOCATION_AUTO_ERROR:30003,LOCATION_BY_ID_ERROR:30004,LOCATION_BY_SELECTOR_ERROR:30005,SCRIPT_IN_HEAD:30006,INVALID_VPT_CONFIGURATION:50001}};utils=function(e,t,i){"use strict";try{new CustomEvent("?"),i.CustomEvent=CustomEvent}catch(n){i.CustomEvent=function(e,i){function n(n,o){var s=t.createEvent(e);return null!==n?r.call(s,n,(o||(o=i)).bubbles,o.cancelable,o.detail):s.initCustomEvent=r,s}function r(t,i,n,r){this["init"+e](t,i,n,r),"detail"in this||(this.detail=r)}return n}(e.CustomEvent?"CustomEvent":"Event",{bubbles:!1,cancelable:!1,detail:null})}return i.matchMedia=function(i){if(e.matchMedia)return e.matchMedia(i);var n=e.styleMedia||e.media;if(!n){var r=t.createElement("style"),o=t.getElementsByTagName("script")[0],s=null;r.type="text/css",r.id="matchmediajs-test",o.parentNode.insertBefore(r,o),s="getComputedStyle"in e&&e.getComputedStyle(r,null)||r.currentStyle,n={matchMedium:function(e){var t="@media "+e+"{ #matchmediajs-test { width: 1px; } }";return r.styleSheet?r.styleSheet.cssText=t:r.textContent=t,"1px"===s.width}}}return{matches:n.matchMedium(i||"all"),media:i||"all"}},i.sessionStorage=function(){var t=!0;try{if(e.sessionStorage.setItem("VR_TEST_SESSIONSTORAGE","test"),"test"!==e.sessionStorage.getItem("VR_TEST_SESSIONSTORAGE"))throw new Error("sessionStorage unavailable")}catch(i){e.VR_sessionStorageFallback=e.VR_sessionStorageFallback||{},t=!1}return t?e.sessionStorage:{setItem:function(t,i){e.VR_sessionStorageFallback[t]=i},getItem:function(t){return e.VR_sessionStorageFallback[t]||null},removeItem:function(t){try{delete e.VR_sessionStorageFallback[t]}catch(i){}},clear:function(){e.VR_sessionStorageFallback={}}}},i}(wnd,doc,utils||{}),utils=function(e,t,i){"use strict";var n={BE:!0,BG:!0,CZ:!0,DK:!0,DE:!0,EE:!0,IE:!0,EL:!0,ES:!0,FR:!0,HR:!0,IT:!0,CY:!0,LV:!0,LT:!0,LU:!0,HU:!0,MT:!0,NL:!0,AT:!0,PL:!0,PT:!0,RO:!0,SI:!0,SK:!0,FI:!0,SE:!0,UK:!0},r={mov:"mp4",mkv:"x-matroska","3gp":"3gpp","3g2":"3gpp2",h261:"h261",h263:"h263",h264:"h264",jpgv:"jpeg",jpm:"jpm",mj2:"mj2",mp4:"mp4",mpeg:"mpeg",ogv:"ogg",qt:"quicktime",uvh:"vnd.dece.hd",uvm:"vnd.dece.mobile",uvp:"vnd.dece.pd",uvs:"vnd.dece.sd",uvv:"vnd.dece.video",fvt:"vnd.fvt",mxu:"vnd.mpegurl",pyv:"vnd.ms-playready.media.pyv",uvu:"vnd.uvvu.mp4",viv:"vnd.vivo",webm:"webm",f4v:"x-f4v",fli:"x-fli",flv:"x-flv",m4v:"x-m4v",asf:"x-ms-asf",wm:"x-ms-wm",wmv:"x-ms-wmv",wmx:"x-ms-wmx",wvx:"x-ms-wvx",avi:"x-msvideo",movie:"x-sgi-movie"};return i.urlEncode=function(e){var t=[];for(var i in e)e.hasOwnProperty(i)&&t.push(i+"="+encodeURIComponent(e[i]));return t.join("&")},i.getViewportSize=function(e){var t="inner",i=e;return"innerWidth"in e||(t="client",i=i.document.documentElement||i.document.body),{width:i[t+"Width"],height:i[t+"Height"]}},i.getScreenSize=function(e){return{width:e.screen.width,height:e.screen.height}},i.getPageSize=function(e){return{width:e.document.body.scrollWidth,height:e.document.body.scrollHeight}},i.setCookie=function(e,i,n){var r=(new Date).valueOf(),o=new Date(864e5+r);o.setHours(0,0,0,0),n=n||o;var s=Math.floor((n-r)/1e3),a=e+"="+i+";path=/;max-age="+s+";expires="+n.toUTCString();return t.cookie=a,a},i.getCookie=function(i){i=e.encodeURIComponent(i),i=i.replace(/[\-\.\+\*]/g,"\\$&");var n=new RegExp("(?:(?:^|.*;)\\s*"+i+"\\s*\\=\\s*([^;]*).*$)|^.*$"),r=t.cookie.replace(n,"$1");return""!==r?e.decodeURIComponent(r):null},i.deleteCookie=function(e){t.cookie=e+"=; path=/; expires=Thu, 01 Jan 1970 00:00:01 GMT;"},i.isNumber=function(e){return!isNaN(parseFloat(e))&&isFinite(e)},i.extend=function(){for(var e=1;e<arguments.length;e++)for(var t in arguments[e])arguments[e].hasOwnProperty(t)&&(arguments[0][t]=arguments[e][t]);return arguments[0]},i.filter=function(e,t){for(var i=[],n=0;n<e.length;n++){var r=e[n];t(r)&&i.push(r)}return i},i.classNamePrefix=function(e,t){for(var i=0,n=t.length;i<n;i++)t[i]=e+"-"+t[i];return t.join(" ")},i.addEventListener=function(e,t,i,n){var r=!1;e.addEventListener?(n&&detect.isPassiveListenersSupported()&&(r={passive:!0}),e.addEventListener(t,i,r)):e.attachEvent&&e.attachEvent("on"+t,i)},i.removeEventListener=function(e,t,i,n){var r=!1;e.removeEventListener?(n&&detect.isPassiveListenersSupported()&&(r={passive:!0}),e.removeEventListener(t,i,r)):e.detachEvent&&e.detachEvent("on"+t,i)},i.bind=function(e,t){return function(){return e.apply(t,Array.prototype.slice.call(arguments))}},i.hashCode=function(e){var t,i,n,r=0;if(0===e.length)return r;for(t=0,n=e.length;t<n;t++)i=e.charCodeAt(t),r=(r<<5)-r+i,r|=0;return r},i.pad=function(e,t){for(var i=String(e);i.length<(t||2);)i="0"+i;return i},i.throwException=function(e){setTimeout(function(){throw e},0)},i.getCustomCss=function(e){var t=e.getAttribute("data-custom-style"),i="";if(t){var n=document.getElementById(t);n?i=n.innerHTML:this.throwException("Couldn't find the custom style tag "+t)}return i},i.onDOMContentLoaded=function(e,n){var r=n||"complete";t.readyState===r||"complete"===t.readyState?e():i.addEventListener(t,"readystatechange",function(){t.readyState===r&&e()})},i.trackRequestEvent=function(e,t){var i=t||"ok",n=7,r=config.get("scheme")+"://"+config.get("endpoint_host")+"/track/?session_id="+config.get("sid")+"&request_session_id="+config.get("sid")+"&label="+e+"&ver="+n+"&reason="+i+"&type=event&category=request_session",o=new Image;o.onload=function(){},o.src=r},i.trackUrl=function(e){var t=new Image;t.onload=function(){},t.src=e},i.getVPTInstance=function(e){var t=e.get("is_preview"),i=e.get("is_test");return"instream"===e.get("format_family")&&(t||i)?null:viralize.__VR&&viralize.__VR.vptimpl},i.getAdditionalPlayerConfig=function(e){var t=null,n=e.get("zid"),r=i.getVPTInstance(e);return null!=r&&null!=r.getConfig&&(t=r.getConfig(n)),t},i.loadPlayerIframe=function(e,t,n,r,o,s){var a=n.get("sentry",null),l=n.get("player.mobi"),c="banner"===n.get("format_family"),p=n.get("player.script"),d=c?templates.banner:templates.player,u=s||injectorPlayerEmitter;ajax.get(t,function(t){var r,s=JSON.parse(t),a=e.elem.contentWindow||e.elem;return s.error?void u.emit("event::loadPlayerError"):(o&&o(s),r=i.getVPTInstance(n),void(a.onPlayerReady?a.onPlayerReady(s,u,r):(a.config=s,a.injectorPlayerEmitter=u,a.vpt=r)))});var h=l?"mobi":c?"banner":"player",m=TemplateLoader.render(d,{scripts:function(){var e=PlayerDependencies[h],t=n.get("debug",!1)?e.debug.slice():e["default"].slice();return a&&t.unshift(PlayerDependencies.sentry),t.push(p),t.reduce(function(e,t){return/https?:/i.test(location.protocol)||/^https?/i.test(t)||(t=n.get("scheme")+":"+t),e+'<script type="text/javascript" src="'+t+'"></script>'},"")},ecgEndpoint:n.get("scheme")+"://"+n.get("endpoint_host")+"/track/",sentryConfig:function(){return a?JSON.stringify({dsn:a.dsn,sampleRate:a.sample_rate}):null}});u.once("cmd::dmp_user_data",function(e){r&&r(e.data)}),i.loadFriendlyIframeWithTemplate(e,m)},i.loadFriendlyIframeWithTemplate=function(e,t){var i=e.elem||e,n=i.contentDocument||i.contentWindow.document;n.open("text/html","replace"),n.write(t),n.close()},i.isUrl=function(e){var t=/(http|https):\/\/(\w+:{0,1}\w*@)?(\S+)(:[0-9]+)?(\/|\/([\w#!:.?+=&%@!\-\/]))?/;return t.test(e)},i.getOrigin=function(e){return i.isUrl(e.location.origin)?e.location.origin:config.get("scheme")+"://"+t.domain},i.isInUE=function(e){return n[e]||!1},i.getFifAbsolutePosition=function(e){for(var t,i,n,r={top:0,left:0},o=e;o!==window.top;)t=o.frameElement.getBoundingClientRect(),i=o.parent.pageYOffset||o.parent.document.documentElement.scrollTop||o.parent.document.body.scrollTop||0,n=o.parent.pageXOffset||o.parent.document.documentElement.scrollLeft||o.parent.document.body.scrollLeft||0,r.top+=t.top+i,r.left+=t.left+n,o=o.parent;return r},i.copyString=function(e){return(" "+e).slice(1)},i.getFileExtension=function(e){return null==e?"":e.split(".").pop()},i.getMimetype=function(e){var t=i.getFileExtension(e);return r[t.toLowerCase()]||""},i}(wnd,doc,utils||{}),utils=function(e,t,i){"use strict";function n(e){return this instanceof n?void(this.elem=e):new n(e)}return n.create=function(e,i){var r=new n(t.createElement(e));if(i)for(var o in i)r.attr(o,i[o]);return r},n.get=function(e){var i=t.querySelector(e);return null!==i&&(i=new n(i)),i},n.getById=function(e){var i=t.getElementById(e);return null!==i&&(i=new n(i)),i},n.getAll=function(e){for(var i=t.querySelectorAll(e),r=[],o=0;o<i.length;o++)r[o]=new n(i[o]);return r},n.remove=function(e){var i=t.getElementById(e);null!==i&&i.parentNode&&i.parentNode.removeChild(i)},n.removeByClass=function(e){for(var i=t.getElementsByClassName(e),n=i.length-1;n>=0;n--){var r=i[n];r.parentNode.removeChild(r)}},n.insertHTMLBefore=function(e,t,n){if(""===n)return null;var r=i.Element.create("ins",{id:t});r.elem.innerHTML=n,e.parentNode.insertBefore(r.elem,e);for(var o=r.elem.getElementsByTagName("script"),s=0;s<o.length;s++){for(var a=document.createElement("script"),l=o[s].attributes,c=0;c<l.length;c++)a.setAttribute(l[c].nodeName,l[c].value);o[s].innerHTML&&(a.text=o[s].innerHTML),o[s].parentNode.replaceChild(a,o[s])}return this},n.prototype.remove=function(){this.elem.parentNode.removeChild(this.elem)},n.prototype.attr=function(e,t){return this.elem.setAttribute(e,t),this},n.prototype.appendTo=function(e){return e.appendChild(this.elem),this},n.prototype.append=function(e){return e.nextSibling?e.parentNode.insertBefore(this.elem,e.nextSibling):e.parentNode.appendChild(this.elem),this},n.prototype.prepend=function(e){return e.parentNode.insertBefore(this.elem,e),this},n.prototype.text=function(e){return void 0===e?"textContent"in this.elem?this.elem.textContent:this.elem.innerText:("textContent"in this.elem?this.elem.textContent=e:this.elem.innerText=e,this)},n.prototype.offset=function(){var i=this.elem.getBoundingClientRect(),n=t.body,r=t.documentElement,o=e.pageYOffset||r.scrollTop||n.scrollTop,s=e.pageXOffset||r.scrollLeft||n.scrollLeft,a=r.clientTop||n.clientTop||0,l=r.clientLeft||n.clientLeft||0,c=i.top+o-a,p=i.left+s-l;return{top:Math.round(c),left:Math.round(p)}},n.prototype.hasClass=function(e){return new RegExp(" "+e+" ").test(" "+this.elem.className+" ")},n.prototype.addClass=function(e){return this.hasClass(e)||(this.elem.className+=(this.elem.className.length?" ":"")+e),this},n.prototype.removeClass=function(e){return this.hasClass(e)&&(this.elem.className=this.elem.className.replace(e,"").replace(/\s+$/g,"")),this},n.prototype.hide=function(){return this.elem.style.display="none",this},n.prototype.show=function(){return this.elem.style.visibility="visible",this},i.Element=n,i}(wnd,doc,utils||{});var ViewabilityFactory=function(){"use strict";var e={},t={};return e.publishingPlatform={STANDARD:"standard",ACCELERATED_MOBILE_PAGE:"amp",FACEBOOK_INSTANT_ARTICLES:"fbia",APPLE_NEWS:"an",OEMBED:"oembed"},e.register=function(e,i){var n=t[e];if(n)throw new DuplicatedViewabilityImplementationError(n+" is already registered for the platform "+e);t[e]=i},e.getInstance=function(i,n,r,o,s){var a=i||e.publishingPlatform.STANDARD,l=t[a];if(!l)throw new ViewabilityClassNotFoundError("No viewabilityClass registered for the platform "+i);return new l(n,r,o,s)},e}(),Viewability=function(e){"use strict";function t(e,t,i,n){this.reasons={OUT_OF_VIEWPORT:0,HIDDEN:1,NOT_IN_FOCUS:2,TOO_SMALL:3,IN_VIEWPORT:4,FIXED_VIEWABILITY:5},this.elem=e,this.wnd=t,this.forceViewability=i,this.onViewabilityChange=n}return t.prototype.start=function(){if(this.isViewabilityUnavailable())throw new ViewabilityUnavailableError;this.stop(),this.attachListeners(e.bind(this.notifier,this)),this.notifier()},t.prototype.stop=function(){this.detachListeners()},t.prototype.notifier=function(){this.onViewabilityChange(this.computeViewability())},t}(utils),viewabilityPercentageCalculator=function(e,t){"use strict";var i=e.getBoundingClientRect(),n=i.width*i.height,r=Math.ceil(Math.max(0,i.left)),o=Math.ceil(Math.min(t.width,i.right)),s=Math.ceil(Math.max(0,i.top)),a=Math.ceil(Math.min(t.height,i.bottom)),l=(o-r)*(a-s),c=Math.floor(l/n*100);return c},IntersectionViewabilityObserver=function(e,t){"use strict";function i(e,t){this.callback=null,this.intersectionObserver=null,this.intersectionData=null,this.elem=t,this.wnd=e}return i.prototype.start=function(e){var t=this,i={root:null,rootMargin:"0px",threshold:this.createIntersectionObserverThresholds()};this.callback=e,this.intersectionObserver=new IntersectionObserver(function(e){0!==e.length&&(t.intersectionData=t.parseIntersectionData(e),t.callback())},i),this.intersectionObserver.observe(this.elem)},i.prototype.createIntersectionObserverThresholds=function(){var e,t,i=100,n=[];for(t=0;t<=i;t+=1)e=t/i,n.push(e);return n},i.prototype.parseIntersectionData=function(e){var t=e[e.length-1];return Math.min(100,Math.round(100*t.intersectionRatio))},i.prototype.stop=function(){this.intersectionObserver&&(this.intersectionObserver.disconnect&&this.intersectionObserver.disconnect(),this.intersectionObserver.unobserve&&this.intersectionObserver.unobserve(this.elem),this.intersectionObserver=null)},i.prototype.computeViewabilityPercentage=function(){var i,n=t.getViewportSize(this.wnd);return this.intersectionObserver.takeRecords&&(i=this.intersectionObserver.takeRecords(),i.length>0&&(this.intersectionData=this.parseIntersectionData(i))),null!=this.intersectionData?this.intersectionData:e(this.elem,n)},i}(viewabilityPercentageCalculator,utils),MutationViewabilityObserver=function(e,t){"use strict";function i(e,t){this.callback=null,this.viewabilityObserver=null,this.elem=t,this.wnd=e}return i.prototype.start=function(e){function i(e){var t,i;for(i=0;i<e.length;i+=1)if(t=e[i],t.target.contains(this.elem))return void this.callback()}this.callback=e,this.viewabilityObserver=new this.wnd.MutationObserver(t.bind(i,this)),this.viewabilityObserver.observe(this.wnd.document.body,{attributes:!0,subtree:!0})},i.prototype.stop=function(){this.viewabilityObserver&&(this.viewabilityObserver.disconnect(),this.viewabilityObserver=null)},i.prototype.computeViewabilityPercentage=function(){var i=t.getViewportSize(this.wnd);return e(this.elem,i)},i}(viewabilityPercentageCalculator,utils),PollingViewabilityObserver=function(e,t){"use strict";function i(e,t){this.callback=null,this.viewabilityLoopTimer=null,this.elem=t,this.wnd=e,this.loopInterval=250}return i.prototype.start=function(e){function t(){i.callback(),i.viewabilityLoopTimer=i.wnd.setTimeout(t,i.loopInterval)}var i=this;this.callback=e,t()},i.prototype.stop=function(){this.viewabilityLoopTimer&&(this.wnd.clearTimeout(this.viewabilityLoopTimer),this.viewabilityLoopTimer=null)},i.prototype.computeViewabilityPercentage=function(){var i=t.getViewportSize(this.wnd);return e(this.elem,i)},i}(viewabilityPercentageCalculator,utils),StandardViewability=function(e,t,i,n,r){"use strict";function o(e,t,o,s){Viewability.call(this,e,t,o,s),this.callback=null,this.windowEvents=["focus","blur","check","checkAndNotify"],this.documentEvents=["visibilitychange","mozvisibilitychange","msvisibilitychange","webkitvisibilitychange"],this.hiddenProperty=function(){var e,t=["hidden","mozHidden","webkitHidden","msHidden","oHidden"],i=null;for(e=0;e<t.length;e++)if(i=t[e],i in document)return i;return i}(),this.minElementArea=1,this.ancestors=this.getElementAncestors(),this.viewabilityObserver=null,window.IntersectionObserver?this.viewabilityObserver=new r(this.wnd,this.elem):(this.windowEvents=this.windowEvents.concat(["scroll","resize"]),window.MutationObserver?this.viewabilityObserver=new n(this.wnd,this.elem):this.viewabilityObserver=new i(this.wnd,this.elem))}return o.prototype=Object.create(Viewability.prototype),o.prototype.constructor=o,o.prototype.getElementAncestors=function(){for(var e=[],t=this.elem;t;)e.unshift(t),t=t.parentNode;return e},o.prototype.isViewabilityUnavailable=function(){return!window.IntersectionObserver&&this.isInIframe()},o.prototype.isInIframe=function(){var e,t;if(this.wnd.top!==this.wnd.self)return!0;for(e=this.wnd.top.document.getElementsByTagName("iframe"),t=0;t<e.length;t+=1)if(e[t]===this.elem)return!1;return!0},o.prototype.computeViewability=function(){var e=this.inFocus(),t=this.computeViewabilityReason(e),i={reason:t,focus:e};return!this.forceViewability()||t!==this.reasons.OUT_OF_VIEWPORT&&t!==this.reasons.IN_VIEWPORT?t!==this.reasons.IN_VIEWPORT?(i.perc=0,i):(i.perc=this.viewabilityObserver.computeViewabilityPercentage(),i):(i.perc=100,i)},o.prototype.computeViewabilityReason=function(e){var i,n,r=this.elem,o=t.getViewportSize(this.wnd),s=r.getBoundingClientRect(),a=s.width*s.height,l=this.ancestors;if("none"===r.style.display||"hidden"===r.style.visibility)return this.reasons.HIDDEN;for(i=0;i<l.length;i+=1)if(n=l[i].style,n&&("none"===n.display||"hidden"===n.visibility))return this.reasons.HIDDEN;return e?s.bottom<=0||s.right<=0||s.top>=o.height||s.left>=o.width?this.reasons.OUT_OF_VIEWPORT:a<this.minElementArea?this.reasons.TOO_SMALL:this.reasons.IN_VIEWPORT:this.reasons.NOT_IN_FOCUS},o.prototype.inFocus=function(){var e=this.wnd.document[this.hiddenProperty];return void 0!==e?!e:"function"!=typeof this.wnd.document.hasFocus||this.wnd.document.hasFocus()},o.prototype.attachListeners=function(e){var i;for(this.callback=e,i=0;i<this.windowEvents.length;i+=1)t.addEventListener(this.wnd,this.windowEvents[i],e,!0);for(i=0;i<this.documentEvents.length;i+=1)t.addEventListener(this.wnd.document,this.documentEvents[i],e,!0);this.viewabilityObserver.start(e)},o.prototype.detachListeners=function(){var e;for(e=0;e<this.windowEvents.length;e+=1)t.removeEventListener(this.wnd,this.windowEvents[e],this.callback,!0);for(e=0;e<this.documentEvents.length;e+=1)t.removeEventListener(this.wnd.document,this.documentEvents[e],this.callback,!0);this.viewabilityObserver.stop()},e.register(e.publishingPlatform.STANDARD,o),e.register(e.publishingPlatform.APPLE_NEWS,o),e.register(e.publishingPlatform.OEMBED,o),o}(ViewabilityFactory,utils,PollingViewabilityObserver,MutationViewabilityObserver,IntersectionViewabilityObserver),AmpViewability=function(e){"use strict";function t(e,t,i,n){Viewability.call(this,e,t,i,n),this.detachWiewabilityObserver=null,this.currentViewability=null}return t.prototype=Object.create(Viewability.prototype),t.prototype.constructor=t,t.prototype.isViewabilityUnavailable=function(){return!1},t.prototype.computeViewability=function(){var e=!window.context.hidden,t=this.computeViewabilityReason(e),i={reason:t,focus:e};return t!==this.reasons.IN_VIEWPORT?(i.perc=0,i):(i.perc=this.currentViewability?Math.min(100,Math.round(100*this.currentViewability.intersectionRatio)):0,i)},t.prototype.computeViewabilityReason=function(e){var t=this.currentViewability.boundingClientRect,i=t.width*t.height;return e?this.currentViewability<=0?this.reasons.OUT_OF_VIEWPORT:i<this.minElementArea?this.reasons.TOO_SMALL:this.reasons.IN_VIEWPORT:this.reasons.NOT_IN_FOCUS},t.prototype.attachListeners=function(e){var t=this;this.detachWiewabilityObserver=window.context.observeIntersection(function(i){t.currentViewability=i[i.length-1],e()})},t.prototype.detachListeners=function(){this.detachWiewabilityObserver&&this.detachWiewabilityObserver()},e.register(e.publishingPlatform.ACCELERATED_MOBILE_PAGE,t),t}(ViewabilityFactory),FBiaViewability=function(e,t){
"use strict";function i(e,i,n,r){Viewability.call(this,e,i,n,r),this.boundedListener=t.bind(this.receiveMessage,this),this.callback=null}var n={enters_viewport:1,center_enters_viewport:100,center_exits_viewport:49,exits_viewport:-1};return i.prototype=Object.create(Viewability.prototype),i.prototype.constructor=i,i.prototype.isViewabilityUnavailable=function(){return!1},i.prototype.computeViewability=function(){return{reason:this.wnd.viewabilityPerc>0?this.reasons.IN_VIEWPORT:this.reasons.OUT_OF_VIEWPORT,focus:!0,perc:this.wnd.viewabilityPerc}},i.prototype.attachListeners=function(e){this.wnd.viewabilityPerc=n[this.wnd.lastViewabilityMessage],this.callback=e,this.wnd.addEventListener("message",this.boundedListener)},i.prototype.detachListeners=function(){this.wnd.removeEventListener("message",this.boundedListener)},i.prototype.receiveMessage=function(e){n[e.data]&&(this.wnd.viewabilityPerc=n[e.data],this.callback&&this.callback())},e.register(e.publishingPlatform.FACEBOOK_INSTANT_ARTICLES,i),i}(ViewabilityFactory,utils),IABViewability=function(){"use strict";function e(e,t,i){var n=i||2;this.viewability=e,this.callback=t,this.iabViewabilityTimeout=null,this.counter=8,this.loopInterval=n/this.counter*1e3}return e.prototype.start=function(){function e(){var n=t.viewability.computeViewability();n.perc>=50?(i-=1,0===i?t.callback():t.iabViewabilityTimeout=window.setTimeout(e,t.loopInterval)):(i=t.counter,t.iabViewabilityTimeout=window.setTimeout(e,t.loopInterval))}var t=this,i=this.counter;if(this.stop(),this.viewability.isViewabilityUnavailable())throw new ViewabilityUnavailableError;this.iabViewabilityTimeout=window.setTimeout(e,t.loopInterval)},e.prototype.stop=function(){window.clearTimeout(this.iabViewabilityTimeout)},e}(),detect=function(e){"use strict";var t={};return t.detectAutoplay=function(){var t,i=[/mobile/i,/android/i,/(iphone|ipad|ipod)/i,/silk-accelerated/i];for(t=0;t<i.length;t++)if(e.navigator&&e.navigator.userAgent&&e.navigator.userAgent.match(i[t]))return!1;return!0},t.detectMobile=function(){return navigator.userAgent.match(/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i)},t.detectiOS=function(){return/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream},t.detectAndroidVersion=function(){var e=navigator.userAgent.toLowerCase(),t=e.match(/android\s([0-9\.]*)/);return t[1]},t.isPassiveListenersSupported=function(){var e,t=!1;try{e=Object.defineProperty({},"passive",{get:function(){t=!0}}),window.addEventListener("testPassive",null,e),window.removeEventListener("testPassive",null,e)}catch(i){}return t},t}(wnd),viralize=function(e,t){"use strict";var i=inDapIF?window.top:e;i.__VR=i.__VR||{},i.__VR.widgets=i.__VR.widgets||[],i.__VR.customScripts=i.__VR.customScripts||{},i.__VR.dataLayers=i.__VR.dataLayers||{};var n="((https?:)?//)?{endpoint_host}/.*[?&]",r="kxviralize_segs",o="_kxviralize_segs",s="VR-DMP-COLLECT",a="VR-INJECTOR-INSTANCES-MAP",l={},c={};return c.__VR=i.__VR,c.findScript=function(e,t){var i=document.getElementsByTagName("script"),r=null,o=null,s=null;"undefined"!=typeof t&&null!==t&&(o=n+"zid="+t,o=o.replace("{endpoint_host}",e),s=new RegExp(o,"gi"));for(var a=function(e){return!e.hasAttribute("data-injected")&&!!(null!==e.getAttribute("data-wid")||s&&s.test(e.getAttribute("src")))},l=i.length;l--;)if(a(i[l])){r=i[l];break}return r},c.findIframe=function(){return window.frameElement},c.generateSuffixId=function(){return Math.random().toString(32).substr(2)},c.markAsInjected=function(e){e.hasAttribute("data-injected")||e.setAttribute("data-injected",!0)},c.register=function(e,t,i){var n,r,o,s,l,p;if(t&&i&&this.registerOnSafeFrameApi(t,i),n={},r=utils.sessionStorage().getItem(a),null!=r&&(n=JSON.parse(utils.sessionStorage().getItem(a))),o=n[e.injectorName]||{count:0,instances:{}},s=o.count,l=e.config.get("max_family_instances",0),p=e.config.get("sid"),l>0&&s>=l)throw new MaxInstancesError("Sorry, but the "+e.injectorName+" format can be used at most "+l+" times.");if(o.instances[p])throw new DuplicateInjectorError("Duplicated injector for sid: "+p);o.instances[p]=!0,o.count+=1,n[e.injectorName]=o,utils.sessionStorage().setItem(a,JSON.stringify(n)),c.__VR.widgets.push(e)},c.registerOnSafeFrameApi=function(t,i){e.$sf&&e.$sf.ext&&e.$sf.ext.register(t,i)},c.unRegister=function(e){var t,i,n,r={},o=utils.sessionStorage().getItem(a);for(null!=o&&(r=JSON.parse(utils.sessionStorage().getItem(a))),t=r[e.injectorName]||{count:0,instances:{}},i=e.config.get("sid"),t.count>0&&(t.count-=1),r[e.injectorName]=t,utils.sessionStorage().setItem(a,JSON.stringify(r)),n=0;n<c.__VR.widgets.length;n+=1)c.__VR.widgets[n].config.get("sid")===i&&c.__VR.widgets.splice(n,1)},c.replaceInjector=function(e){for(var i=t.createElement("script"),n=e.attributes,r=0;r<n.length;r++)"data-injected"!==n[r].nodeName&&i.setAttribute(n[r].nodeName,n[r].value);i.src=i.src+"&cb="+(new Date).getTime();var o=e.parentNode;o.insertBefore(i,e),o.removeChild(e)},c.createIframe=function(e,i,n){var r=i?i+"px":"100%",o=n?n+"px":"100%",s={allowfullscreen:!0,webkitallowfullscreen:t.webkitFullscreenEnabled,mozallowfullscreen:t.mozFullScreenEnabled},a=utils.Element.create("iframe",{id:e,src:"about:blank",scrolling:"no",frameborder:0,marginheight:0,marginwidth:0,allow:"autoplay; fullscreen"});for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&s[l]&&a.attr(l,s[l]);return a.elem.style.width=r,a.elem.style.height=o,a},c.createPageId=function(t){function i(){var e,t=52,i="",n=(new Date).getTime();for(n=utils.pad(n.toString(16),12),e=0;e<t;e+=1)i+=Math.round(Math.random()).toString();return i=parseInt(i,2).toString(16),n+i}var n,r=c.getPublishingPlatform(t),o=e.navigator?e.navigator:null,s=t.get("publisher"),a=t.get("page_url"),l=o?o.userAgent||"":"",p=utils.hashCode(s+a+l),d=utils.pad((16777215&p).toString(16),6),u=0;return r===ViewabilityFactory.publishingPlatform.ACCELERATED_MOBILE_PAGE?e.context.computeInMasterFrame(e,"VR-PAGEID-PREFIX",function(e){e(i())},function(e){n=e}):n=i(),n+d+u},c.getPublishingPlatform=function(t){var i=t.get("pub_platform","");try{return e.context&&e.context.observeIntersection?ViewabilityFactory.publishingPlatform.ACCELERATED_MOBILE_PAGE:i===ViewabilityFactory.publishingPlatform.FACEBOOK_INSTANT_ARTICLES?ViewabilityFactory.publishingPlatform.FACEBOOK_INSTANT_ARTICLES:i===ViewabilityFactory.publishingPlatform.OEMBED?ViewabilityFactory.publishingPlatform.OEMBED:""}catch(n){return""}},c.createSrc=function(i,n,r,o,s){var a,l,p={},d=utils.getRealDomain();return c.__VR.pageId=c.__VR.pageId||c.createPageId(o),l=s||{},l.player_size||(l.player_size={width:0,height:0}),a={page_id:c.__VR.pageId,screen:utils.getScreenSize(e),page:utils.getPageSize(e),viewport:utils.getViewportSize(e),player_size:{width:Math.round(l.player_size.width),height:Math.round(l.player_size.height)},semantic_data:l.semantic_data},l.player_position&&(a.player_position={top:Math.round(l.player_position.top),left:Math.round(l.player_position.left)}),p.player_session=JSON.stringify(a),t.referrer&&(p.r=t.referrer),l.cid&&(p.cid=l.cid),l.sound&&(p.sound=l.sound),l.gallery_init&&(p.gallery_init=l.gallery_init),l.sessionCounter>0&&(p.sc=l.sessionCounter),l.pub_platform&&(p.pub_platform=l.pub_platform),l.activation&&(p.activation=l.activation),l.cs&&(p.cs=l.cs),null!=l.gdpr&&(p.gdpr=l.gdpr),l.cmp&&(p.cmp=l.cmp),d&&(p.dd=d),i+"/"+n+"/?"+r+"&"+utils.urlEncode(p)},c.createPlayerSrc=function(e,t){var i=e.get("is_preview"),n=e.get("is_test"),r=i?"preview":n?"test":"player",o=t||{};return c.createSrc(e.get("scheme")+"://"+e.get("endpoint_host"),r,e.get("base_query"),e,o)},c.findInjectionElem=function(e,t){var i={script:"",iframe:""};return i.iframe=c.findIframe(),i.script=document.currentScript||c.findScript(e,t),null===i.script&&utils.trackRequestEvent("adunit_request_error",Constants.ADUNIT_REQUEST_ERRORS.SCRIPT_NOT_FOUND),i},c.isInHead=function(e){for(var t=e.parentNode;null!=t;){if("head"===t.nodeName.toLowerCase())return!0;t=t.parentNode}return!1},c.setElementRemovedListener=function(e,t,i){function n(e,t){for(var i=t;null!=i;){if(e===i)return!0;i=i.parentNode}return!1}var r={childList:!0,subtree:!0};this.unsetElementRemovedListener();try{l=new MutationObserver(function(e){e.forEach(function(e){if(e.removedNodes.length>0)for(var r=0;r<e.removedNodes.length;r++)n(e.removedNodes[r],t)&&i()})}),l.observe(e,r)}catch(o){}},c.unsetElementRemovedListener=function(){l.disconnect&&(l.disconnect(),l={})},c.addPluginsForNotBlacklisted=function(e,t,i){var n={179:!0,358:!0,711:!0};null!=i&&null!=n[i]||c.addCustomScripts(e,null,t)},c.addCustomScripts=function(e,i,n){function r(e){var t=e;return n&&Object.keys(n).forEach(function(e){t=t.split("{"+e+"}").join(n[e])}),t}function o(e){var i=t.createElement("script");i.setAttribute("id",l+e.id),i.src=r(e.src),i.setAttribute("async",""),i=t.body.appendChild(i)}function s(e){utils.Element.insertHTMLBefore(a,l+e.id,r(e.content))}var a,l="";i&&(l=i+"-"),a=t.createElement("placeholder"),t.body.appendChild(a);for(var p=0;p<e.length;p++)c.__VR.customScripts[e[p].id]||(e[p].src?o(e[p]):e[p].content&&s(e[p]),c.__VR.customScripts[e[p].id]=!0);t.body.removeChild(a)},c.getInjectionPoint=function(i,n,r,o){for(var s=utils.Element.getAll(i),a=parseInt((r-n)/o)||1,l=function(e){return function(t){return 0!==t.offset().top&&t.text().length>e}},c=[],p=!1,d=r;d>=n;d-=a)if(c=utils.filter(s,utils.bind(l(d),this)),c.length>0){p=!0;break}if(p){var u=e.innerHeight;void 0===u&&(u=t.documentElement.clientHeight),c=utils.filter(c,function(e){return e.offset().top>u});var h=c.sort(function(e,t){return e.offset().top-t.offset().top});return h[0]?h[~~(h.length/2)]:null}return null},c.searchPlayerLocation=function(t,i,n){var r,o,s,a=function(e){for(var t=window,i=t.document.getElementById(e);null==i&&t!==t.parent&&utils.canAccessWindow(t.parent);)t=t.parent,i=t.document.getElementById(e);return null!==i&&(i=new utils.Element(i)),i},l=function(e){for(var t=window,i=t.document.querySelector(e);null==i&&t!==t.parent&&utils.canAccessWindow(t.parent);)t=t.parent,i=t.document.querySelector(e);return null!==i&&(i=new utils.Element(i)),i},p=new RegExp(/^id-.*/),d=new RegExp(/^sel-.*/),u=t.length,h="article p",m=10,f=100,y=20,v={auto:Constants.ADUNIT_REQUEST_ERRORS.LOCATION_AUTO_ERROR,inline:Constants.ADUNIT_REQUEST_ERRORS.LOCATION_INLINE_ERROR,idSelector:Constants.ADUNIT_REQUEST_ERRORS.LOCATION_BY_ID_ERROR,querySelector:Constants.ADUNIT_REQUEST_ERRORS.LOCATION_BY_SELECTOR_ERROR};for(s=0;s<u;s+=1){if(r=t[s],"inline"===r)return!n||""!==i&&i||utils.trackRequestEvent("adunit_request_error",v.inline),{playerLocation:i,usedCriteria:r};if("auto"===r?o=c.getInjectionPoint(h,m,f,y):p.test(r)?(o=a(r.slice(3)),r="idSelector"):d.test(r)&&(o=l(e.decodeURIComponent(r.slice(4))),r="querySelector"),o)return{playerLocation:o.elem,usedCriteria:r}}return n&&utils.trackRequestEvent("adunit_request_error",v[r]),{playerLocation:null,usedCriteria:null}},c.sendDmpData=function(t,i,n){c.readDmpUserSegments(r,function(e){c.setCookieSyncPixel(t,e)},n),c.__VR.dataLayers.dmp=c.__VR.dataLayers.dmp||{collected:!1,data:{}},c.__VR.dataLayers.dmp.collected||(c.__VR.dataLayers.dmp.collected=!0,c.__VR.dataLayers.dmp.data=i||{},e.dispatchEvent(new utils.CustomEvent(s)))},c.readDmpUserSegments=function(e,t,i){var n=250,r=function(e){function t(e){var t,i,n,r=e.length;for(i=0;i<r;i++){for(t=e[i],n=i-1;n>-1&&e[n]>t;n--)e[n+1]=e[n];e[n+1]=t}return e}return e?t(e.split(",")).join(","):""},s=r(i),a=localStorage.getItem(o),l=0,c=2,p=function(){var i,d=localStorage.getItem(o)!==a;d?(l+=1,i=r(localStorage.getItem(e)),i!==s?t(i):l<c&&setTimeout(p,n)):setTimeout(p,n)};setTimeout(p,n)},c.setCookieSyncPixel=function(e,t){var i=window.encodeURIComponent(t),n=e+"/u-segment/?seg="+i,r=new Image;r.onload=function(){},r.src=n},c.construbCMPPostMessageStub=function(e){for(var t,i,n,r,o,s,a,l=window;!t;){try{l.frames.__cmpLocator&&(t=l)}catch(c){}if(l===window.top)break;l=l.parent}return i={},e.__cmp=function(e,o,s){return t?(n=Math.random().toString(32).substr(2),r={__cmpCall:{command:e,parameter:o,callId:n}},i[n]=s,void t.postMessage(r,"*")):void s({msg:"CMP not found"},!1)},a=function(t){try{o="string"==typeof t.data?JSON.parse(t.data):t.data,o.__cmpReturn&&(utils.removeEventListener(e,"message",a),s=o.__cmpReturn,i[s.callId]&&(i[s.callId](s.returnValue,s.success),i[s.callId]=null))}catch(n){}},utils.addEventListener(e,"message",a),function(){utils.removeEventListener(e,"message",a)}},c.readCMPData=function(e,t){var i,n,r=utils.canAccessTopWindow(),o=r?window.top:window,s=e.get("country"),a=e.get("gdpr");return a?void t(a.cmp,a.gdpr?1:0,a.cs):(r||(n=c.construbCMPPostMessageStub(o)),o.__cmp?(i=setTimeout(function(){i=null,n&&n(),t("timeout",utils.isInUE(s)?1:0,"")},2e3),void o.__cmp("getConsentData",null,function(e,n){if(i){if(clearTimeout(i),n)return void t("available",e.gdprApplies?1:0,e.consentData);t("error",utils.isInUE(s)?1:0,"")}})):void t("unavailable",utils.isInUE(s)?1:0,""))},c.setupVPT=function(e){var t,i,n={EVENTS:e.EVENTS,ALL_ZID:e.ALL_ZID,queue:e.queue,on:e.on,once:e.once,off:e.off,addConfig:e.addConfig,getConfig:e.getConfig};i=window,utils.canAccessTopWindow()&&(i=window.top),null!=i.vpt?"[object Array]"===Object.prototype.toString.call(i.vpt.queue)&&(t=i.vpt.queue,i.vpt=n,c.__VR.vptimpl=e,t.forEach(function(e){e()})):(i.vpt=n,c.__VR.vptimpl=e)},c.evaluatePlayerPosition=function(t,i){var n,r,o,s=null,a=t.getBoundingClientRect();return i===ViewabilityFactory.publishingPlatform.ACCELERATED_MOBILE_PAGE?s={top:e.context.initialLayoutRect.top,left:e.context.initialLayoutRect.left}:e!==window.top?inDapIF?(s=utils.getFifAbsolutePosition(e),s.top+=a.top,s.left+=a.left):e.$sf&&e.$sf.ext&&(o=e.$sf.ext.geom(),null!=o&&null!=o.self&&null!=o.self.t&&null!=o.self.l&&(s={top:o.self.t,left:o.self.l})):(n=e.pageYOffset||e.document.documentElement.scrollTop||e.document.body.scrollTop||0,r=e.pageXOffset||e.document.documentElement.scrollLeft||e.document.body.scrollLeft||0,s={top:a.top+n,left:a.left+r}),s},c}(wnd,doc),setupVPTImpl=function(){"use strict";var e={},t={},i={},n="DELETED",r=function(e,t){var i=e+";"+t,n=Math.random().toString(32).substr(2);return i+";"+n},o=function(t,i,r){null!=e[t]&&null!=e[t][i]&&null!=e[t][i][r]&&(e[t][i][r]=n)},s=function(t,i){null!=e[t]&&null!=e[t][i]&&Object.keys(e[t][i]).forEach(function(e){o(t,i,e)})},a=function(e){var t={event:i.EVENTS.ALL,zid:i.ALL_ZID};return utils.isString(e)?t.event=e:(t.event=e.event||t.event,t.zid=e.zid||t.zid),t},l=function(e,t){Object.keys(t).forEach(function(i){e.push(t[i])})},c=function(t,n){var r=[],o=i.ALL_ZID,s=i.EVENTS.ALL;return e[o]&&e[o][s]&&l(r,e[o][s]),n!==o&&e[n]&&e[n][s]&&l(r,e[n][s]),t!==s&&(e[o]&&e[o][t]&&l(r,e[o][t]),e[n]&&e[n][t]&&l(r,e[n][t])),r};return i.emit=function(e,t,i,r){var o=c(e,t),s={event:e,zid:t,format:i,data:r,timestamp:(new Date).getTime()};o.forEach(function(e){e!==n&&window.setImmediate(function(){e(s)})})},i.on=function(t,i){var n=a(t),o=r(n.zid,n.event);for(e[n.zid]||(e[n.zid]={}),e[n.zid][n.event]||(e[n.zid][n.event]={});null!=e[n.zid][n.event][o];)o=r(n.zid,n.event);return e[n.zid][n.event][o]=i,o},i.once=function(t,r){var o=a(t),s=i.on(o,function(t){e[o.zid][o.event][s]!==n&&(i.off(o,s),r(t))});return s},i.off=function(e,t){var i=a(e);null!=t?o(i.zid,i.event,t):s(i.zid,i.event)},i.EVENTS={ALL:"VPT-EVENT::*",AD_SESSION_START:"VPT-EVENT::AD_SESSION_START",AD_SESSION_END:"VPT-EVENT::AD_SESSION_END",AD_IMPRESSION:"VPT-EVENT::AD_IMPRESSION",COLLAPSE:"VPT-EVENT::COLLAPSE",ACTIVATION:"VPT-EVENT::ACTIVATION",START:"VPT-EVENT::START",FIRST_QUARTILE:"VPT-EVENT::FIRST_QUARTILE",MID_POINT:"VPT-EVENT::MID_POINT",THIRD_QUARTILE:"VPT-EVENT::THIRD_POINT",COMPLETE:"VPT-EVENT::COMPLETE",ERROR:"VPT-EVENT::ERROR",CLICK:"VPT-EVENT::CLICK",SKIP:"VPT-EVENT::SKIP"},i.ALL_ZID="VPT-ZID::*",i.queue={push:function(e){setTimeout(e,0)}},i.addConfig=function(){var e,n;utils.isString(arguments[0])?(e=arguments[0],n=arguments[1]):(e=i.ALL_ZID,n=arguments[0]),t[e]=n},i.getConfig=function(e){return null!=t[e]?t[e]:t[i.ALL_ZID]},function(){viralize.setupVPT(i)}}(),Display=function(e,t,i,n,r,o,s,a,l){"use strict";var c=.5,p={ALWAYS:"always",NOT_VIEWABLE:"notviewable",PLAYING:"playing",NEVER:"no"},d="ext",u=0,h=0,m=0,f=function(){if(!(this instanceof f))return new f;if(this.width=null,this.height=null,this.displayElement=null,this.wrapperElement=null,this.wideWrapperElement=null,this.cssNamespace="",this.injectorName="display",this.script=null,this.injectionElem=null,this.iframe=null,this.suffixId=r.generateSuffixId(),this.viewportParent=null,this.detectedPlatform=r.getPublishingPlatform(n),this.vipModeType=this.getVipModeType(),this.shouldListenForVipMode=this.vipModeType!==p.NEVER&&this.vipModeType!==p.ALWAYS,this.isVip=!1,this.vipPositions=n.get("vip_positions",["desktop-bottom-right","mobile-landscape-bottom-right","mobile-portrait-bottom"]),this.vipSize=n.get("vip_size","large"),this.bindedScrollVipCallback=o.bind(this.scrollVipCallback,this),this.enableContentDescription=n.get("enable_content_description",!1),this.contentDescriptionPosition=n.get("content_description_position","bottom"),this.isDescripionLateral="left"===this.contentDescriptionPosition||"right"===this.contentDescriptionPosition,this.additionalPlayerConfig=o.getAdditionalPlayerConfig(n),this.haveFixedCid=this.checkIfHaveFixedCid(),this.haveCustomContents=this.checkIfHaveCustomContent(),this.shouldLoadContent=!(this.haveFixedCid||this.haveCustomContents),this.contentList=[],this.customContentList=[],this.contentListIndex=0,this.playlistReloaded=!1,this.sessionCounter=1,this.config=n,this.autoReplay=n.get("autoreplay"),this.isPlaylistMode=n.get("playlist_mode",!1),this.pluginLoaded=!1,this.closeVipDelay=n.get("close_delay",0),this.showCloseVipTimeoutId=null,this.restartCallbackId=null,this.setContentDescriptionCallbackId=null,this.playlistPluginReadyCallbackId=null,this.changeVideoCallbackId=null,this.thumbClickCallbackId=null,this.startViewabilityCallBackId=null,this.startIABViewabilityCallBackId=null,this.stopViewabilityCallBackId=null,this.stopIABViewabilityCallBackId=null,this.contentPausedCallbackId=null,this.playCallbackId=null,this.playingCallbackId=null,this.adPausedCallbackId=null,this.adResumedCallbackId=null,this.playerReadyCallbackId=null,this.cmpAvailability=null,this.gdprApplies=null,this.consentString=null,this.playingContent=!1,this.cssLoader=null,this.haveCustomContents)try{this.fillCustomContentList(this.additionalPlayerConfig)}catch(e){throw o.trackRequestEvent("adunit_request_error",Constants.ADUNIT_REQUEST_ERRORS.INVALID_VPT_CONFIGURATION),e}};return f.prototype.checkIfHaveFixedCid=function(){return null!=n.get("base_query","").match(/^cid=|&cid=|\?cid=/)},f.prototype.checkIfHaveCustomContent=function(){return null!=this.additionalPlayerConfig&&null!=this.additionalPlayerConfig.contents&&this.additionalPlayerConfig.contents.length>0},f.prototype.fillCustomContentList=function(e){var t,i=this;e.contents.forEach(function(e,n){i.customContentList[n]=[],Array.isArray(e.videos)?(t=o.isString(e.videos[0]),e.videos.forEach(function(e){var r=o.isString(e);if(r!==t)throw new Error("not accepted");r?i.customContentList[n].push({url:e,type:o.getMimetype(e),resolution:u,height:h,width:m}):i.customContentList[n].push({url:e.url,type:e.type||o.getMimetype(e.url),resolution:e.resolution||u,height:h,width:m})})):o.isString(e.videos)?i.customContentList[n].push({url:e.videos,type:o.getMimetype(e.videos),resolution:u,height:h,width:m}):i.customContentList[n].push({url:e.videos.url,type:e.videos.type||o.getMimetype(e.video.url),resolution:e.videos.resolution||u,height:h,width:m})})},f.prototype.getVipModeType=function(){var e=s.publishingPlatform.ACCELERATED_MOBILE_PAGE,t=s.publishingPlatform.FACEBOOK_INSTANT_ARTICLES;return this.detectedPlatform===e||this.detectedPlatform===t?p.NEVER:n.get("vip_mode")},f.styleValue=function(e){return null===e?"100%":e+"px"},f.prototype.removePlaceholder=function(){var e=o.classNamePrefix(this.cssNamespace,["placeholder"]);o.Element.remove(e),this.descriptionElement.elem.style.visibility="visible"},f.prototype.addPlaceholder=function(){var e,t=o.classNamePrefix(this.cssNamespace,["placeholder"]);this.removePlaceholder(),this.descriptionElement.elem.style.visibility="hidden",e=this.wrapperElement.elem.cloneNode(!1),e.setAttribute("id",t),e.style.height=f.styleValue(this.wideWrapperElement.elem.getBoundingClientRect().height),"left"===this.contentDescriptionPosition||"top"===this.contentDescriptionPosition?this.wideWrapperElement.elem.appendChild(e):this.descriptionElement.elem.parentNode.insertBefore(e,this.descriptionElement.elem)},f.prototype.setVipPosition=function(){var t,i,n,r=20,s=this.wrapperElement;this.wrapperElement.elem.style.height="100%",this.wrapperElement.elem.style.top=e.scrollY+e.innerHeight-(s.elem.offsetHeight+r)+"px",this.wrapperElement.elem.style.bottom="",o.matchMedia("(orientation: portrait)").matches?this.wrapperElement.elem.style.left="":(i=getComputedStyle(this.viewportParent)["margin-right"].split(/[^0-9]+/)[0],i=parseInt(i,10),t=i+s.elem.offsetWidth+r,n=e.innerWidth-t,this.wrapperElement.elem.style.left=n+"px")},f.prototype.disableVip=function(){this.removePlaceholder(),this.isVip=!1,this.wrapperElement.removeClass(o.classNamePrefix(this.cssNamespace,["vip",this.vipSize].concat(this.vipPositions))),null!==this.viewportParent&&(o.removeEventListener(e,"scroll",o.bind(this.setVipPosition,this),!0),o.removeEventListener(e,"resize",o.bind(this.setVipPosition,this))),this.closeVipDelay!==-1&&(null!=this.showCloseVipTimeoutId&&(clearTimeout(this.showCloseVipTimeoutId),this.showCloseVipTimeoutId=null),this.hideCloseButton())},f.prototype.enableVip=function(){var t=this;this.addPlaceholder(),this.isVip=!0,this.wrapperElement.addClass(o.classNamePrefix(this.cssNamespace,["vip",this.vipSize].concat(this.vipPositions))),null!==this.viewportParent&&e.setTimeout(function(){t.setVipPosition(),o.addEventListener(e,"scroll",o.bind(t.setVipPosition,t),!0),o.addEventListener(e,"resize",o.bind(t.setVipPosition,t))},0),this.closeVipDelay!==-1&&this.vipModeType!==p.ALWAYS&&(this.showCloseVipTimeoutId=setTimeout(function(){t.showCloseVipTimeoutId=null,t.showCloseButton()},1e3*this.closeVipDelay))},f.prototype.showCloseButton=function(){this.closeContent.addClass(o.classNamePrefix(this.cssNamespace,["show-close"]))},f.prototype.hideCloseButton=function(){this.closeContent.removeClass(o.classNamePrefix(this.cssNamespace,["show-close"]))},f.prototype.scrollVipCallback=function(){this.isFullyVisible(this.wideWrapperElement.elem,!0)?this.isVip&&this.disableVip():this.isVip||this.enableVip()},f.prototype.hasParentWithTransform=function(t){for(var i=t.parentNode;null!=i;){try{if("none"!==e.getComputedStyle(i).transform)return i}catch(n){}i=i.parentNode}return null},f.prototype.pauseContent=function(){this.vipModeType!==p.NOT_VIEWABLE&&(o.removeEventListener(e,"scroll",this.bindedScrollVipCallback,!0),this.shouldListenForVipMode&&(this.playCallbackId=injectorPlayerEmitter.once("cmd::play",o.bind(this.listenForVipMode,this))))},f.prototype.onAdPaused=function(){this.vipModeType!==p.NOT_VIEWABLE&&(o.removeEventListener(e,"scroll",this.bindedScrollVipCallback,!0),this.shouldListenForVipMode&&(this.adResumedCallbackId=injectorPlayerEmitter.once("cmd::adResumed",o.bind(this.listenForVipMode,this))))},f.prototype.listenForVipMode=function(){this.viewportParent=this.hasParentWithTransform(this.wrapperElement.elem),o.removeEventListener(e,"scroll",this.bindedScrollVipCallback,!0),o.addEventListener(e,"scroll",this.bindedScrollVipCallback,!0)},f.prototype.setupCommunication=function(){var t,i=this;null!=this.restartCallbackId&&injectorPlayerEmitter.off("cmd::restart",this.restartCallbackId),null!=this.setContentDescriptionCallbackId&&injectorPlayerEmitter.off("cmd::setContentDescription",this.setContentDescriptionCallbackId),null!=this.playlistPluginReadyCallbackId&&injectorPlayerEmitter.off("playlist::playlistPluginReady",this.playlistPluginReadyCallbackId),null!=this.changeVideoCallbackId&&injectorPlayerEmitter.off("playlist::changeVideo",this.changeVideoCallbackId),null!=this.thumbClickCallbackId&&injectorPlayerEmitter.off("tracker::thumb_click",this.thumbClickCallbackId),null!=this.contentPausedCallbackId&&injectorPlayerEmitter.off("cmd::contentPaused",this.contentPausedCallbackId),null!=this.playCallbackId&&injectorPlayerEmitter.off("cmd::play",this.playCallbackId),null!=this.playingCallbackId&&injectorPlayerEmitter.off("cmd::playing",this.playingCallbackId),null!=this.adPausedCallbackId&&injectorPlayerEmitter.off("cmd::adPaused",this.adPausedCallbackId),null!=this.adResumedCallbackId&&injectorPlayerEmitter.off("cmd::adResumed",this.adResumedCallbackId),null!=this.playerReadyCallbackId&&injectorPlayerEmitter.off("pl::playerReady",this.playerReadyCallbackId),null!=this.firstTimeInViewportCheckBounded&&o.removeEventListener(e,"scroll",this.firstTimeInViewportCheckBounded,!0),this.restartCallbackId=null,this.setContentDescriptionCallbackId=null,this.playlistPluginReadyCallbackId=null,this.changeVideoCallbackId=null,this.thumbClickCallbackId=null,this.contentPausedCallbackId=null,this.firstTimeInViewportCheckBounded=null,this.playingCallbackId=injectorPlayerEmitter.on("cmd::playing",function(e){e.isContent?i.playingContent=!0:i.playingContent=!1,i.shouldListenForVipMode&&(i.bindedScrollVipCallback(),i.listenForVipMode()),i.closeVipDelay!==-1&&i.vipModeType===p.ALWAYS&&(i.playingContent?i.showCloseVipTimeoutId=setTimeout(function(){i.showCloseVipTimeoutId=null,i.showCloseButton()},1e3*i.closeVipDelay):(i.hideCloseButton(),null!=i.showCloseVipTimeoutId&&(clearTimeout(i.showCloseVipTimeoutId),i.showCloseVipTimeoutId=null)))}),this.restartCallbackId=injectorPlayerEmitter.on("cmd::restart",function(e){i.load(!1,e.sound)}),this.enableContentDescription&&(this.setContentDescriptionCallbackId=injectorPlayerEmitter.on("cmd::setContentDescription",o.bind(function(e){i.descriptionElement.text(e.text)},this))),this.shouldLoadContent&&this.isPlaylistMode&&(this.playlistPluginReadyCallbackId=injectorPlayerEmitter.on("playlist::playlistPluginReady",function(){i.contentList.length>1&&(injectorPlayerEmitter.emit("inj::playlistActive"),injectorPlayerEmitter.emit("inj::playlistContents",{contents:i.contentList,currentIndex:i.contentListIndex}))}),this.changeVideoCallbackId=injectorPlayerEmitter.on("playlist::changeVideo",function(e){i.contentListIndex=e.index,i.playlistReloaded=!1,i.load(!1,e.sound)}),this.thumbClickCallbackId=injectorPlayerEmitter.on("tracker::thumb_click",function(e){o.trackUrl(e.url),injectorPlayerEmitter.emit("playlist::thumb_click_tracked")})),t=function(){i.isFullyVisible(i.wideWrapperElement.elem,!0)&&(i.disableVip(),o.removeEventListener(e,"scroll",t))},this.contentPausedCallbackId=injectorPlayerEmitter.on("cmd::contentPaused",function(){i.pauseContent(),i.vipModeType!==p.NOT_VIEWABLE&&i.shouldListenForVipMode&&i.vipModeType!==p.NOT_VIEWABLE&&o.addEventListener(e,"scroll",t)}),this.adPausedCallbackId=injectorPlayerEmitter.on("cmd::adPaused",function(){i.playingContent||(i.onAdPaused(),i.shouldListenForVipMode&&i.vipModeType!==p.NOT_VIEWABLE&&o.addEventListener(e,"scroll",t))}),this.playerReadyCallbackId=injectorPlayerEmitter.on("pl::playerReady",function(){i.firstTimeInViewportCheckBounded=o.bind(i.firstTimeInViewportCheck,i),o.addEventListener(e,"scroll",i.firstTimeInViewportCheckBounded,!0),i.firstTimeInViewportCheck()})},f.prototype.isFullyVisible=function(i,n){var r,s,a,l,p,d,u=!1,h=o.getViewportSize(e),m=this.wideWrapperElement.elem.getBoundingClientRect().height,f=Math.max(t.body.scrollHeight,t.body.offsetHeight,t.documentElement.clientHeight,t.documentElement.scrollHeight,t.documentElement.offsetHeight),y=e.innerHeight;return void 0===y&&(y=t.documentElement.clientHeight),r=i.getBoundingClientRect(),s=Math.floor(r.top),a=t.documentElement.scrollTop||t.body.scrollTop,l=a+y,p=Math.floor(m*c),n?(d=Math.abs(s),u=s<0?d<p:y-d>=p):u=f===l||s+p<h.height,u},f.prototype.firstTimeInViewportCheck=function(){var t;t=this.vipModeType===p.ALWAYS||this.isFullyVisible(this.wideWrapperElement.elem,!1),t&&(o.removeEventListener(e,"scroll",this.firstTimeInViewportCheckBounded,!0),this.firstTimeInViewportCheckBounded=null,injectorPlayerEmitter.emit("inj::firstTimeInViewport"))},f.prototype.handleFallback=function(){var e,t;r.unRegister(this),e="viralize-fallback-"+this.suffixId,t=o.Element.insertHTMLBefore(this.script,e,n.get("fallback_body")),this.wideWrapperElement&&this.wideWrapperElement.hide(),t&&(o.trackRequestEvent("adunit_response_fallback"),injectorPlayerEmitter.emit("inj::fallback"))},f.prototype.setupDimensions=function(){var e,t=n.get("width"),i=n.get("height");null!==t&&null!==i&&(this.wrapperElement.elem.style.width=f.styleValue(t),this.wrapperElement.elem.style.height=f.styleValue(i),this.wrapperElement.addClass(o.classNamePrefix(this.cssNamespace,["fixed-size"])),e=this.wideWrapperElement.elem.style,e.height=i+"px",e["padding-bottom"]=0),this.width=t,this.height=i},f.prototype.setupViewability=function(){var t,i,n;null!=this.startViewabilityCallBackId&&injectorPlayerEmitter.off("cmd::startViewability",this.startViewabilityCallBackId),null!=this.startIABViewabilityCallBackId&&injectorPlayerEmitter.off("cmd::startIABViewability",this.startIABViewabilityCallBackId),null!=this.stopViewabilityCallBackId&&injectorPlayerEmitter.off("cmd::stopViewability",this.stopViewabilityCallBackId),null!=this.stopIABViewabilityCallBackId&&injectorPlayerEmitter.off("cmd::stopIABViewability",this.stopIABViewabilityCallBackId),this.startViewabilityCallBackId=null,this.startIABViewabilityCallBackId=null,this.stopViewabilityCallBackId=null,this.stopIABViewabilityCallBackId=null,t=o.bind(function(){return l.detectiOS()&&this.isVip},this),i=s.getInstance(this.detectedPlatform,this.iframe.elem,e,t,o.bind(function(e){injectorPlayerEmitter.emit("inj::viewability",e)},this)),n=new a(i,o.bind(function(){injectorPlayerEmitter.emit("inj::viewable")},this)),this.startViewabilityCallBackId=injectorPlayerEmitter.on("cmd::startViewability",o.bind(function(){try{i.start(),injectorPlayerEmitter.emit("inj::viewabilityAvailable")}catch(e){injectorPlayerEmitter.emit("inj::viewabilityNotAvailable")}},this)),this.startIABViewabilityCallBackId=injectorPlayerEmitter.on("cmd::startIABViewability",function(){try{n.start()}catch(e){}}),this.stopViewabilityCallBackId=injectorPlayerEmitter.on("cmd::stopViewability",function(){i.stop()}),this.stopIABViewabilityCallBackId=injectorPlayerEmitter.on("cmd::stopIABViewability",function(){n.stop()})},f.prototype.inject=function(){var t,s,a,l,c,d,u=n.get("zid"),h=n.get("endpoint_host"),m=r.findInjectionElem(h,u),f=m.script,y=n.get("width"),v=n.get("height");if(this.script=f,null===f)return null;r.markAsInjected(f),i?this.injectionElem=m.iframe:this.injectionElem=f;try{r.register(this,y,v)}catch(g){if(g instanceof MaxInstancesError)throw g;return g instanceof DuplicateInjectorError&&r.replaceInjector(this.script),null}this.iframe=r.createIframe("vr-"+this.suffixId+"-player-iframe",y,v),t=o.getCustomCss(f)||n.get("custom_style"),this.cssLoader=new CssLoader(this.suffixId,cssTpl,t),this.cssNamespace=this.cssLoader.getCssNameNamespace(),s=o.Element.create("div"),s.attr("id",o.classNamePrefix(this.cssNamespace,["viralize-wide-wrapper"])),this.wideWrapperElement=s,a=o.Element.create("div"),a.attr("id",o.classNamePrefix(this.cssNamespace,["wrapper"])),this.wrapperElement=a,l=o.Element.create("div"),l.attr("id",o.classNamePrefix(this.cssNamespace,["close-content"])),this.closeContent=l,c=o.Element.create("div"),c.attr("id",o.classNamePrefix(this.cssNamespace,["display"])),this.displayElement=c,d=o.Element.create("div"),d.attr("id",o.classNamePrefix(this.cssNamespace,["description"])),this.descriptionElement=d,l.appendTo(a.elem),c.appendTo(a.elem),"left"===this.contentDescriptionPosition||"top"===this.contentDescriptionPosition?(d.appendTo(s.elem),a.appendTo(s.elem)):(a.appendTo(s.elem),d.appendTo(s.elem)),this.isDescripionLateral&&this.wideWrapperElement.addClass(o.classNamePrefix(this.cssNamespace,["description-lateral"])),
this.shouldListenForVipMode?o.addEventListener(this.closeContent.elem,"click",o.bind(function(){o.removeEventListener(e,"scroll",this.bindedScrollVipCallback,!0),this.disableVip(),injectorPlayerEmitter.emit("inj::dismiss_vip_mode"),this.pauseContent()},this)):this.vipModeType===p.ALWAYS&&o.addEventListener(this.closeContent.elem,"click",o.bind(function(){injectorPlayerEmitter.emit("inj::dismiss_vip_mode"),this.pauseContent(),r.unRegister(this),this.wideWrapperElement&&this.wideWrapperElement.hide()},this)),r.readCMPData(n,o.bind(function(e,t,i){this.cmpAvailability=e,this.gdprApplies=t,this.consentString=i,this.load(!0)},this))},f.prototype.getContents=function(t){var i,s,a,l,c;a={},s={page_id:r.__VR.pageId||r.createPageId(n),screen:o.getScreenSize(e),page:o.getPageSize(e),viewport:o.getViewportSize(e),player_size:this.displayElement.elem.getBoundingClientRect()},i=r.evaluatePlayerPosition(this.displayElement.elem,this.detectedPlatform),i&&(s.player_position=i),a.player_session=JSON.stringify(s),l=o.getRealDomain(),l&&(a.dd=l),c=n.get("scheme")+"://"+n.get("endpoint_host")+"/api/v2/content/?"+n.get("base_query")+"&cs="+this.consentString+"&gdpr="+this.gdprApplies+"&cmp="+this.cmpAvailability+"&"+o.urlEncode(a),ajax.get(c,function(e){var i=JSON.parse(e).items;0!==i.length&&t(i)})},f.prototype.load=function(a,l){var c,u,h,m=this,f=o.bind(function(c,u,h){var f,y,v,g,b,w,E,I,C,_,P,T,V=function(){T=function(e){e.impression.creativity.videos=m.customContentList[m.contentListIndex],m.contentListIndex=(m.contentListIndex+1)%m.customContentList.length},this.shouldLoadContent?(g=this.contentList[this.contentListIndex],this.contentListIndex=(this.contentListIndex+1)%this.contentList.length,v.cid=g.scid):a&&(v.gallery_init=!0),this.isPlaylistMode&&(this.playlistReloaded=0===this.contentListIndex),l&&(v.sound="on"),v.cs=this.consentString,v.gdpr=this.gdprApplies,v.cmp=this.cmpAvailability,f=r.createPlayerSrc(n,v),this.sessionCounter+=1,o.loadPlayerIframe(this.iframe,f,n,function(e){a&&r.sendDmpData(n.get("scheme")+"://"+n.get("endpoint_host"),e,n.get("dmp_segments"))},function(e){null!=m.additionalPlayerConfig&&T(e)}),this.pluginLoaded||(_={gdpr_consent:this.consentString,gdpr:this.gdprApplies,country:n.get("country")},r.addPluginsForNotBlacklisted(n.get("plugins",[]),_,n.get("publisher")),this.pluginLoaded=!0),this.setupDimensions(),this.setupCommunication(),this.setupViewability(),i?r.setElementRemovedListener(e.parent.document.body,this.iframe.elem,function(){throw new Error("Player removed by an external script")}):r.setElementRemovedListener(t.body,this.wideWrapperElement.elem,function(){throw new Error("Player removed by an external script")}),a||this.autoReplay||this.vipModeType===p.NOT_VIEWABLE||(this.disableVip(),this.pauseContent())};if(c)document.body.appendChild(this.wideWrapperElement.elem),this.enableVip();else{if(r.isInHead(u))throw o.trackRequestEvent("adunit_request_error",Constants.ADUNIT_REQUEST_ERRORS.SCRIPT_IN_HEAD),new Error('You are trying to put the player into the head.Please check the script location or the "location" parameter');u&&(I=u.ownerDocument.defaultView||u.ownerDocument.parentWindow,i&&"no"!==this.vipModeType&&I===window&&(this.vipModeType="no",this.shouldListenForVipMode=!1,o.removeEventListener(e,"scroll",this.bindedScrollVipCallback,!0),C=new Error("VIP Mode cannot be enabled: location forced inside an iframe. VIP Mode units must be placed in the top window."),P=console,P.error(C))),i&&"no"===this.vipModeType&&"inline"===h?document.body.appendChild(this.wideWrapperElement.elem):u.parentNode.insertBefore(this.wideWrapperElement.elem,u)}this.cssLoader.loadStyle(this.wideWrapperElement.elem),y=this.displayElement.elem.getBoundingClientRect(),this.script.style.display="none",E=n.get("pub_platform",""),E===s.publishingPlatform.OEMBED&&this.detectedPlatform!==s.publishingPlatform.OEMBED?E+="-"+this.detectedPlatform:E=this.detectedPlatform,w=r.evaluatePlayerPosition(this.displayElement.elem,this.detectedPlatform),v={player_size:y,player_position:w,sessionCounter:this.sessionCounter,pub_platform:E},w&&(v.player_position=w),b=this.autoReplay?"onload":"click",this.isPlaylistMode?this.playlistReloaded?v.activation=b:a||(v.activation="onload"):a||(v.activation=b),this.haveCustomContents&&(v.cid=d),this.shouldLoadContent&&0===this.contentList.length?this.getContents(function(e){this.contentList=e,V.bind(this)()}.bind(this)):V.bind(this)()},this);this.displayElement.elem.innerHTML="",this.iframe.appendTo(this.displayElement.elem),this.vipModeType===p.ALWAYS?t.body?f(!0):e.MutationObserver?(h=new MutationObserver(function(){t.body&&(f(!0),h.disconnect())}),h.observe(t.documentElement,{childList:!0})):o.onDOMContentLoaded(m.start,"interactive"):(c=n.get("location",["inline"]),u=r.searchPlayerLocation([c[0]],this.injectionElem,!1),u.playerLocation?f(!1,u.playerLocation,u.usedCriteria):o.onDOMContentLoaded(o.bind(function(){u=r.searchPlayerLocation(c,this.injectionElem,!0),f(!1,u.playerLocation,u.usedCriteria)},this)))},f}(wnd,doc,inDapIF,config,viralize,utils,ViewabilityFactory,IABViewability,detect),templates={player:'<!DOCTYPE html>\n<html>\n    <head>\n        <meta http-equiv="content-type" content="text/html; charset=UTF-8">\n        <link rel="icon" href="data:;base64,iVBORw0KGgo=">\n        {{scripts}}\n        <script type="text/javascript">\n            Ecg(window, "ecg", "{{ecgEndpoint}}");\n            ecg("create");\n        </script>\n        <title>Viralize Player</title>\n    </head>\n    <body>\n        <script type="text/javascript">\n            function onPlayerReady (config, injectorPlayerEmitter, vpt) {\n                window.config = config;\n                window.injectorPlayerEmitter = injectorPlayerEmitter;\n\n                if (vpt != null) {\n                    window.vpt = vpt;\n                }\n\n                var user_data = config.user_data || {};\n                var sentryConfig = {{sentryConfig}};\n                var player = new Player(config, sentryConfig);\n                player.init();\n                injectorPlayerEmitter.emit("cmd::dmp_user_data", user_data);\n            }\n\n            if (window.config && window.injectorPlayerEmitter) {\n                // window.vpt could be undefined, and this is the expected behaviour\n                // for format without the api (as vpaid)\n                onPlayerReady(window.config, window.injectorPlayerEmitter, window.vpt);\n            } else {\n                window.onPlayerReady = onPlayerReady;\n            }\n        </script>\n    </body>\n</html>\n'};!function(e){"use strict";var t;setupVPTImpl(),t=new e,t.inject()}(Display);
        })({"custom_style": "", "enable_fc_ignore": false, "playlist_mode": false, "zid": "AACYAZh9s5Tbd9g6", "fallback_body": "", "capping_count": 0, "plugins": [{"id": "1", "content": "<img src=\"//ads.stickyadstv.com/auto-user-sync\" style=\"display:none;\" width=\"1\" height=\"1\">"}], "max_family_instances": 0, "location": ["inline"], "pub_platform": null, "vip_size": "large", "enable_content_description": false, "height": null, "width": null, "autoreplay": true, "country": "FI", "dmp_segments": "", "sentry": {"dsn": "https://1aec9d790bc84140bb25fdb76f019171@sentry.viralize.com/6", "sample_rate": 0.05}, "is_test": false, "experiment": null, "close_delay": 0, "scheme": "https", "publisher": "3864", "vip_positions": ["desktop-bottom-right", "mobile-portrait-bottom", "mobile-landscape-bottom-right"], "content_description_position": "bottom", "is_preview": false, "capping_interval": 0, "page_url": "https://battleroyalewithcheese.com/2020/01/no-fathers-in-kashmir-review/", "enable_branding": true, "endpoint_host": "ads.viralize.tv", "vip_mode": "playing", "format_family": "gallery", "player": {"script": "https://static.viralize.tv/viralize_player.min.4704ca33.js", "mobi": false}, "sid": "01ea44b73d7177ce4d4d350e5b9d6981", "gdpr": null, "base_query": "zid=AACYAZh9s5Tbd9g6&sid=01ea44b73d7177ce4d4d350e5b9d6981&activation=adfill&u=https%3A%2F%2Fbattleroyalewithcheese.com%2F2020%2F01%2Fno-fathers-in-kashmir-review%2F&ahd=1&dp1=0.15&dp3=1"});
        