!function(){var e=function(e,t){void 0===t&&(t={}),t.resizer=Object.assign({log:!1,checkOrigin:!0,heightCalculationMethod:"taggedElement",onMessage:function(e){var t=e.iframe;if("ecfready"===e.message){document.getElementById(t.id+"-spinner").style.display="none",t.style.display="block";var n=t.getAttribute("data-animation");"none"!==n&&t.classList.add("animate__animated",n)}}},t.resizer);var n,i=null;if(i=""===(t=Object.assign({width:"100%",height:"auto",id:"ecf-"+(new Date).getTime(),spinner:!0,animation:"animate__fadeIn",hideFooter:!0,insertPosition:"afterend",insertInto:""},t)).insertInto?document.currentScript||(n=document.getElementsByTagName("script"))[n.length-1]:document.querySelector(t.insertInto),"none"!==t.animation&&i.insertAdjacentHTML(t.insertPosition,"<style>@import url(https://cdnjs.cloudflare.com/ajax/libs/animate.css/4.1.1/animate.min.css);</style>"),i.insertAdjacentHTML(t.insertPosition,'<div id="'+t.id+'-spinner" class=ecf-spinner style=text-align:center><svg height=32px version=1.0 viewBox="0 0 128 128"width=32px xml:space=preserve xmlns=http://www.w3.org/2000/svg xmlns:svg=http://www.w3.org/2000/svg xmlns:xlink=http://www.w3.org/1999/xlink><g><path d="M.6 57.54c5.73-6.23 17.33-15.5 33.66-12.35C55.4 48.5 64 63.95 64 63.95S42.42 65 30.28 83.63a38.63 38.63 0 0 0-3.4 32.15 64.47 64.47 0 0 1-5.52-4.44A63.64 63.64 0 0 1 .6 57.54z"fill=#ffcb02 /><path d="M65.32 29.05c7.65 19.98-1.44 35.18-1.44 35.18S52.2 46.05 30.03 44.85A38.6 38.6 0 0 0 .56 57.93 63.8 63.8 0 0 1 37.56 6c8.2 1.8 22.26 7.16 27.76 23.05z"fill=#ff9e02 /><path d="M94.92 47.7c-13.48 16.63-31.2 16.36-31.2 16.36s9.92-19.2-.13-39a38.6 38.6 0 0 0-26.18-19 63.78 63.78 0 0 1 63.52 6.03c2.56 8 4.98 22.85-6.05 35.6z"fill=#ff4b42 /><path d="M93.52 82.53C72.38 79.17 63.75 63.7 63.75 63.7s21.6-1.02 33.7-19.63a38.6 38.6 0 0 0 3.43-32.04 64.33 64.33 0 0 1 5.74 4.6 63.63 63.63 0 0 1 20.82 53.26c-5.62 6.2-17.34 15.8-33.94 12.6z"fill=#c063d6 /><path d="M62.5 99c-7.65-19.98 1.44-35.17 1.44-35.17S75.56 81.6 97.74 82.8a39.1 39.1 0 0 0 29.73-13.03 63.8 63.8 0 0 1-37.16 52.3c-8.2-1.8-22.25-7.15-27.8-23.06z"fill=#17a4f6 /><path d="M26.64 115.63C24 107.6 21.6 93.06 32.5 80.5c13.48-16.62 31.58-16.55 31.58-16.55s-9.6 19.06.44 38.86a38.82 38.82 0 0 0 26.05 19.17 63.78 63.78 0 0 1-63.93-6.3z"fill=#4fca24 /></g></svg></div><style>.ecf-spinner svg{animation:.4s linear infinite rotate;margin-top:40px;position:relative}@keyframes rotate{from{transform:rotate(0)}to{transform:rotate(360deg)}}</style>'),t.spinner||(document.querySelector("#"+t.id+"-spinner").style.display="none"),null===document.querySelector("#js-iframe-resizer")&&"auto"===t.height){var o=document.createElement("script");o.src="https://cdnjs.cloudflare.com/ajax/libs/iframe-resizer/4.3.1/iframeResizer.min.js",o.crossOrigin="anonymous",o.id="js-iframe-resizer",document.getElementsByTagName("head")[0].appendChild(o)}var a=e.match(/\/offers\/(.{8})/),r="";if("string"!=typeof a[1])return!1;r=t.resizer.checkOrigin?"https://"+window.location.hostname+"/offers/"+a[1]+"/checkout":e;var d=(window.location.href.match(/coupon_code=(\w+)(&|$)/)||e.match(/coupon_code=(\w+)(&|$)/)||["",""])[1];r+=""===d?"":"?coupon_code="+d;var s=document.createElement("iframe");if(s.id=t.id,s.src=r,s.allow="payment",s.style.width=t.width,s.frameBorder="0",s.style.border="0",s.style.display="none",s.style.minWidth="330px",s.setAttribute("data-animation",t.animation),i.insertAdjacentElement(t.insertPosition,s),"auto"===t.height)var c=setInterval(function(){"function"==typeof iFrameResize&&(clearInterval(c),iFrameResize(t.resizer,"#"+s.id))},10);else{s.style.height=t.height,document.getElementById(s.id+"-spinner").style.display="none",s.style.display="block";var l=s.getAttribute("data-animation");"none"!==l&&s.classList.add("animate__animated",l)}};window.ECF=window.ECF||e,window.ecf=window.ecf||e,function e(t){return document.readyState[7]?t():setTimeout(e,9,t)}(function(){var e=function(e){return document.querySelectorAll(e)};if(document.body.classList.contains("offer-checkout")&&(/\?embed$/.test(window.location.href)||window.top!==window.self)&&!/editor=true/.test(window.location.href)&&!/\?noembed$/.test(window.location.href)){if(window.JGO_ECF=!0,null==document.querySelector("#js-iframe-content")){var t=document.createElement("script");t.src="https://cdnjs.cloudflare.com/ajax/libs/iframe-resizer/4.2.11/iframeResizer.contentWindow.min.js",t.crossOrigin="anonymous",t.id="js-iframe-content",document.getElementsByTagName("head")[0].appendChild(t)}e("div.checkout-banner").length&&e("div.checkout-banner")[0].remove(),e("#new_checkout_offer").length&&e("#new_checkout_offer")[0].setAttribute("data-iframe-height",""),e("div.col-md-6").length&&e("div.col-md-6")[0].remove(),e("div.checkout-content-left").length&&e("div.checkout-content-left")[0].classList.remove("col-md-offset-1","col-md-5","checkout-content-left"),e("div.content").length&&e("div.content")[0].classList.remove("content"),e("div.container").length&&e("div.container")[0].classList.remove("container"),e("div.row").length&&e("div.row")[0].classList.remove("row"),e(".checkout-footer").length&&e(".checkout-footer")[0].remove();var n=window.JGO_2step?"div.panel-heading{padding:0}div.panel-heading>*:not(div){padding:32px 36px 0 36px}":"div.panel-heading{padding:32px 36px 32px 36px}div.panel-heading>*:not(div):not(.checkout-panel-badge){padding:0}",i=document.createElement("style");i.innerHTML="#preloader {width: 100% !important;height: 100% !important;left:0 !important;}\nbody {background-color:white}\ndiv.checkout-panel {margin:0}\ndiv.checkout-panel{box-shadow: 0 0 0 0 rgba(0,0,0,0.1)}\ndiv.panel-body {padding:36px}\ndiv.price-breakdown {padding: 17px 36px 17px 36px}\n.grecaptcha-badge{visibility: hidden;}\n"+n,document.body.append(i),e("form")[0].setAttribute("target","_top");var o=setInterval(function(){"undefined"!=typeof parentIFrame&&(clearInterval(o),parentIFrame.sendMessage("ecfready"))},10)}})}();
//# sourceMappingURL=ecf.min.js.map