function cp_column_equilize(){setTimeout(function(){jQuery(".cp-columns-equalized").each(function(){if(jQuery(this).closest(".cp-overlay").hasClass("cp-open")||jQuery(this).closest(".global_modal_container").hasClass("cp-modal-inline")){var a=jQuery(window).width(),b=Array();jQuery(this).children(".cp-column-equalized-center").each(function(){var a=jQuery(this).outerHeight();b.push(a)});var c=0;jQuery(this).find(".cp-image-container").length>0&&jQuery(this).find(".cp-highlight").each(function(a,b){c++});var d=parseInt(jQuery(this).css("padding-top")),e=parseInt(jQuery(this).css("padding-top")),f=d+e,g=Math.max.apply(Math,b)+f;g-=c,a>768?jQuery(this).css("height",g):jQuery(this).css("height","auto")}})},200)}function CPResponsiveTypoInit(){jQuery(".cp_responsive").each(function(a,b){var c=jQuery(b);if(!c.hasClass("cp_line_height")){var d=c.css("font-size"),e=c.attr("data-font-size");e||c.attr("data-font-size-init",d)}if(!c.hasClass("cp_font")){var f=c.css("line-height"),e=c.attr("data-line-height");e||c.attr("data-line-height-init",f)}})}function CPModelHeight(){setTimeout(function(){jQuery(".cp-modal-popup-container").each(function(a,b){var c=jQuery(b),d=c.find(".cp-modal"),e=c.find(".cp-overlay"),f=c.find(".cp-overlay").outerHeight(),g=c.find(".cp-modal-body").outerHeight();jQuery(window).width();jQuery(this).find(".cp-overlay").hasClass("cp-open")&&(jQuery(this).hasClass("cp-inline-modal-container")||(g>f?(d.addClass("cp-modal-exceed"),e.each(function(a,b){jQuery(b).hasClass("cp-open")&&jQuery("html").addClass("cp-exceed-vieport"),jQuery("html").removeClass("cp-window-viewport")})):(d.removeClass("cp-modal-exceed"),jQuery("html").removeClass("cp-exceed-vieport"),d.css("height","")))),set_affiliate_link()})},1200)}function set_affiliate_link(a){jQuery(".cp-overlay").each(function(){var b=jQuery(this).find(".cp-modal").hasClass("cp-modal-window-size"),c=jQuery(this).data("affiliate_setting");if(vw=jQuery(window).width(),cp_affilate_link=jQuery(this).find(".cp-affilate-link"),cp_animate_container=jQuery(this).find(".cp-animate-container"),cp_overlay=jQuery(this),jQuery(this).hasClass("ps-container"))var c=a;if("1"==c)if(b)if(vw<=768){cp_affilate_link.addClass("cp-afl-for-smallscreen"),cp_affilate_link.appendTo(cp_animate_container);jQuery(this).find(".cp-modal-content").outerHeight()-40}else cp_affilate_link.removeClass("cp-afl-for-smallscreen"),cp_affilate_link.appendTo(cp_overlay),cp_affilate_link.css("top","");else vw<=768?(cp_affilate_link.appendTo(cp_animate_container),cp_affilate_link.addClass("cp-afl-for-smallscreen")):(cp_affilate_link.removeClass("cp-afl-for-smallscreen"),cp_affilate_link.appendTo(cp_overlay))})}function cp_color_for_list_tag(){jQuery(".cp-overlay").each(function(){var a=jQuery(this);jQuery(this).parents(".cp_responsive").length;jQuery(this).find("li").each(function(){if(0==jQuery(this).parents(".cp_social_networks").length&&0==jQuery(this).parents(".custom-html-form").length){var b=jQuery(a).find(".cp-modal-body").attr("class").split(" ")[1],c=jQuery(this).parents(".cp_responsiv").attr("class");c=null!==c&&"undefined"!=typeof c?jQuery(this).parents(".cp_responsive").attr("class").split(" ")[0]:jQuery(this).parents("div").attr("class").split(" ")[0];var d=jQuery(this).index()+1,e=jQuery(this).find(".cp_font").css("font-size"),f=jQuery(this).find("span").css("color"),g=jQuery(this).parent(),g=g[0].nodeName.toLowerCase(),h="";"ul"==g?(h=jQuery(this).closest("ul").css("list-style-type"),"none"==h&&jQuery(this).closest("ul").css("list-style-type","disc")):(h=jQuery(this).closest("ol").css("list-style-type"),"none"==h&&jQuery(this).closest("ol").css("list-style-type","decimal")),jQuery(this).find("span").each(function(){var a=jQuery(this).css("color");a.length>0&&(f=a)});var i="";jQuery(".cp-li-color-css-"+d).remove(),jQuery(".cp-li-font-css-"+d).remove(),e&&(i="font-size:"+e,jQuery("head").append('")),f&&jQuery("head").append('")}})})}function cp_modal_common(a){cp_column_equilize(),cp_row_equilize(),addPaddingtoYoutubeFrame()}function cp_form_sep_setting(){jQuery(".cp-overlay").each(function(){if(jQuery(this).find(".cp-modal-body").hasClass("cp-jugaad")){var a=jQuery(this).find(".cp-form-separator").data("form-sep-pos"),b=jQuery(this).find(".cp-form-separator").data("form-sep-part"),c=jQuery(this).find(".cp-form-separator").data("form-sep");if("horizontal"==a?"part-of-content"==b?jQuery(this).find(".cp-form-separator").appendTo(jQuery(this).find(".cp-modal-body > .cp-row .cp-content-section")):jQuery(this).find(".cp-form-separator").appendTo(jQuery(this).find(".cp-modal-body > .cp-row .cp-form-section")):"part-of-content"==b?jQuery(this).find(".cp-form-separator").appendTo(jQuery(this).find(".cp-modal-body > .cp-row")):jQuery(this).find(".cp-form-separator").appendTo(jQuery(this).find(".cp-modal-body > .cp-row")),"part-of-content"==b)var d=jQuery(this).find(".cp-content-section-overlay").css("background-color");else var d=jQuery(this).find(".cp-form-section-overlay").css("background-color");var e=cp_get_viewbox_svg(c),f=cp_get_svg(c,d,e,b);jQuery(this).find(".cp-form-separator").html(f)}})}function cp_get_svg(a,b,c,d){var e="";"waves"==a?aspRatio='preserveAspectRatio="none"':aspRatio="",0==d?svgclass=" right":svgclass=" left";jQuery(".cp-modal-content").outerHeight()+10+"px";switch(e+='',a){case"waves":var f='';e+=f;break;case"triangle":var f='';e+=f;break;case"big_triangle_right":var g='';e+=g;break;case"big_triangle_left":var g='';e+=g;break;case"clouds":var h='';e+=h;break;case"curve_center":var f='';e+=f;break;case"tilt":var g='';e+=g;break;case"circle_bottom":var f='';e+=f;break;case"round_split":var f='';e+=f}return e+=""}function cp_get_viewbox_svg(a){var b="";switch(a){case"triangle":var b="0 0 4.66666 0.333331";break;case"big_triangle_left":var b="0 -148 1600 90";break;case"big_triangle_right":var b="0 -148 1600 90";break;case"waves":var b="0 0 6 0.1";break;case"clouds":var b="0 0 1600 90";break;case"curve_center":var b="0 0 4.66666 0.333331";break;case"tilt":var b="0 172 1600 90";break;case"circle_bottom":var b="0 0 0.2 0.1";break;case"round_split":var b="0 0 1600 90"}return b}function cp_form_sep_top(){setTimeout(function(){jQuery(".cp-overlay").each(function(){var a=jQuery(this).find(".cp-modal-body").hasClass("cp-jugaad");if(a){var b=jQuery(this).find(".cp-form-separator"),c=jQuery(this).find(".cp-content-section").outerHeight()-5+"px",d=jQuery(this).find(".cp-form-section").outerHeight()-5+"px";b.hasClass("cp-fs-horizontal")&&(b.hasClass("part-of-content")?b.hasClass("upward")?b.css("bottom",c):b.css("top",c):b.hasClass("upward")?b.css("bottom",d):b.css("top",d))}})},500)}function cp_set_width_svg(){setTimeout(function(){jQuery(".cp-overlay").each(function(){if(jQuery(this).find(".cp-modal-body").hasClass("cp-jugaad")){var a=jQuery(this).find(".cp-form-separator");if(a.length>0){var b=jQuery(this).find(".cp-content-section"),c=jQuery(this).find(".cp-form-section"),d=a.find("svg").outerHeight()+10+"px";a.hasClass("form_bottom")||a.hasClass("img_left_form_bottom")||a.hasClass("img_right_form_bottom")||a.hasClass("form_bottom_img_top")?a.hasClass("part-of-content")?(c.css("padding",d+" 15px 15px 15px"),b.css("padding","15px")):(b.css("padding","15px 15px "+d+" 15px"),c.css("padding","15px")):a.hasClass("form_left")||a.hasClass("form_left_img_botttom")||a.hasClass("form_left_img_top")?f>=768?a.hasClass("part-of-content")?(c.css("padding","15px "+d+" 15px 15px"),b.css("padding","15px")):(b.css("padding","15px 15px 15px "+d),c.css("padding","15px")):a.hasClass("part-of-content")?(c.css("padding","15px 15px "+d+" 15px"),b.css("padding","15px")):(b.css("padding",d+" 15px 15px 15px"),c.css("padding","15px")):f>=768?a.hasClass("part-of-content")?(c.css("padding","15px 15px 15px "+d),b.css("padding","15px")):(b.css("padding","15px "+d+" 15px 15px"),c.css("padding","15px")):a.hasClass("part-of-content")?(c.css("padding",d+" 15px 15px 15px"),b.css("padding","15px")):(b.css("padding","15px 15px "+d+" 15px"),c.css("padding","15px"))}var e=jQuery(this).find(".cp-modal-body > .cp-row").outerHeight()+5+"px",f=jQuery(window).width();(a.hasClass("triangle")||a.hasClass("round_split")||a.hasClass("tilt"))&&(a.hasClass("form_bottom")||a.hasClass("img_left_form_bottom")||a.hasClass("img_right_form_bottom")||a.hasClass("form_bottom_img_top")?a.find("svg").attr("width","100%"):f>=768?a.hasClass("tilt")?a.find("svg").attr("width","100%"):a.find("svg").attr("width",e):a.find("svg").attr("width","100%"))}})},200)}function form_sep_position(){jQuery(".cp-overlay").each(function(){if(jQuery(this).find(".cp-modal-body").hasClass("cp-jugaad")){var a=jQuery(this).find(".cp-form-separator"),b=jQuery(window).width();a.hasClass("form_bottom")||jQuery(".cp-form-separator").hasClass("form_bottom_img_top")||(768>b?a.hasClass("part-of-form")?(a.removeClass("cp-fs-vertical cp-fs-vertical-form").addClass("cp-fs-horizontal cp-fs-horizontal-form"),jQuery(this).find(".cp-form-separator").appendTo(jQuery(this).find(".cp-form-section"))):(jQuery(this).find(".cp-form-separator").appendTo(jQuery(this).find(".cp-content-section")),a.removeClass("cp-fs-vertical cp-fs-vertical-content").addClass("cp-fs-horizontal cp-fs-horizontal-content")):a.hasClass("img_left_form_bottom")||a.hasClass("img_right_form_bottom")||(jQuery(this).find(".cp-form-separator").appendTo(jQuery(this).find(".cp-modal-body > .cp-row")),jQuery(this).find(".cp-form-separator").hasClass("part-of-form")?jQuery(this).find(".cp-form-separator").removeClass("cp-fs-horizontal cp-fs-horizontal-form cp-fs-vertical-content").addClass("cp-fs-vertical cp-fs-vertical-form"):jQuery(this).find(".cp-form-separator").removeClass("cp-fs-horizontal cp-fs-horizontal-content").addClass("cp-fs-vertical cp-fs-vertical-content"),jQuery(this).find(".cp-form-separator").css({bottom:"",top:""})))}})}function addPaddingtoYoutubeFrame(){if(jQuery(".cp-youtube-container").length)if(jQuery(".cp-modal").hasClass("cp-modal-window-size")){var a=jQuery(".cp-form-container").outerHeight(),b=jQuery(".cp-form-container").css("display");"none"!=b?jQuery(".cp-youtube-frame").css("padding-bottom",a+"px"):jQuery(".cp-youtube-frame").css("padding-bottom","")}else jQuery(".cp-youtube-frame").css("padding-bottom","")}function cp_row_equilize(){setTimeout(function(){jQuery(".cp-row-equalized-center").each(function(){var a=(jQuery(window).width(),jQuery(this).closest(".cp-row-equalized-center").outerHeight()),b=jQuery(this).closest(".cp-modal-body").css("min-height").replace("px","");a>b?jQuery(this).parent(".cp-row-center").addClass("cp-big-content"):jQuery(this).parent(".cp-row-center").removeClass("cp-big-content")})},200)}function apply_box_shaddow_to_count_down(a){jQuery(".cp-overlay").each(function(){var a=jQuery(this).find(".cp-modal-body-overlay"),b=a.css("box-shadow");a.css("background-color"),jQuery(this).find(".cp-modal-content");b.indexOf("inset")>=0?a.addClass("count-down-shadow"):a.removeClass("count-down-shadow")})}function cp_social_responsive(){var a=jQuery(window).width();jQuery(".cp_social_networks").each(function(){var b=jQuery(this).data("column-no"),c="";768>a?(jQuery(this).removeClass("cp_social_networks"),jQuery(this).removeClass(b),c=jQuery(this).attr("class"),jQuery(this).attr("class","cp_social_networks cp_social_autowidth "+c)):(jQuery(this).removeClass("cp_social_networks"),jQuery(this).removeClass("cp_social_autowidth"),jQuery(this).removeClass(b),c=jQuery(this).attr("class"),jQuery(this).attr("class","cp_social_networks "+b+" "+c))})}!function(a){function b(a,b){a.hasClass("cp-description")||a.hasClass("cp-short-description")||a.hasClass("cp-info-container")?a.fitText(1.7,{minFontSize:"12px",maxFontSize:b}):a.fitText(1.2,{minFontSize:"16px",maxFontSize:b})}function c(){jQuery(".cp_responsive").each(function(a,c){var d="",e=jQuery(window).width(),f=jQuery(c),g=f.css("font-size"),h=f.attr("data-font-size"),i=f.attr("data-font-size-init"),j=f.attr("data-line-height"),k=f.attr("data-line-height-init");h?g=h:i&&(g=i),j?d=j:k&&(d=k),800>=e?(f.hasClass("cp-submit")?f.css({"line-height":"1.15em"}):f.css({display:"block","line-height":"1.15em"}),b(f,g)):(f.css({display:"","line-height":d}),f.fitText(1.2,{minFontSize:g,maxFontSize:g}))})}function d(){jQuery(".cp-overlay").each(function(){var a=jQuery(window).innerWidth(),b=(jQuery(this).data("image-position"),jQuery(this).data("hide-img-on-mobile"));b&&(b>=a?jQuery(this).find(".cp-image-container").addClass("cp-hide-image"):jQuery(this).find(".cp-image-container").removeClass("cp-hide-image"))})}function e(){jQuery(".cp-overlay").each(function(){if(jQuery(this).find(".cp-modal-body").hasClass("cp-optin-to-win")){var a=jQuery(window).innerWidth(),b=(jQuery(this).data("image-position"),jQuery(this).data("hide-img-on-mobile"));b>=a?b>=768&&jQuery(this).find(".cp-text-container").removeClass("col-lg-7 col-md-7 col-sm-7").addClass("col-lg-12 col-md-12 col-sm-12 cp-bigtext-container"):jQuery(this).find(".cp-text-container").removeClass("col-lg-12 col-md-12 col-sm-12 cp-bigtext-container").addClass("col-lg-7 col-md-7 col-sm-7 ")}})}function f(){jQuery(".cp-overlay").each(function(){if(jQuery(this).find(".cp-modal-body").hasClass("cp-direct-download")){var a=jQuery(window).width(),b=(jQuery(this).data("image-position"),jQuery(this).data("hide-img-on-mobile"));b>=a?b>=768&&jQuery(this).find(".cp-text-container").removeClass("col-lg-7 col-md-7 col-sm-7").addClass("col-lg-12 col-md-12 col-sm-12 cp-bigtext-container"):jQuery(this).find(".cp-text-container").removeClass("col-lg-12 col-md-12 col-sm-12 cp-bigtext-container").addClass("col-lg-7 col-md-7 col-sm-7 ")}})}function g(){jQuery(".cp-overlay").each(function(){if(jQuery(this).find(".cp-modal-body").hasClass("cp-free-ebook")){var a=jQuery(window).outerWidth(),b=(jQuery(this).data("image-position"),jQuery(this).data("hide-img-on-mobile"));b>=a?b>=768&&jQuery(this).find(".cp-text-container").removeClass("col-lg-7 col-md-7 col-sm-7").addClass("col-lg-12 col-md-12 col-sm-12 cp-bigtext-container"):jQuery(this).find(".cp-text-container").removeClass("col-lg-12 col-md-12 col-sm-12 cp-bigtext-container").addClass("col-lg-7 col-md-7 col-sm-7 ")}})}!function(a){a.fn.fitText=function(b,c){var d=b||1,e=a.extend({minFontSize:Number.NEGATIVE_INFINITY,maxFontSize:Number.POSITIVE_INFINITY},c);return this.each(function(){var b=a(this),c=function(){b.css("font-size",Math.max(Math.min(b.width()/(10*d),parseFloat(e.maxFontSize)),parseFloat(e.minFontSize)))};c(),a(window).on("resize.fittext orientationchange.fittext",c)})}}(jQuery),jQuery(document).ready(function(){setTimeout(function(){CPResponsiveTypoInit(),cp_color_for_list_tag(),cp_column_equilize()},500),d(),e(),f(),g(),cp_form_sep_setting(),form_sep_position(),cp_set_width_svg(),setTimeout(function(){cp_column_equilize()},300),cp_social_responsive()}),jQuery(window).resize(function(){CPModelHeight(),c(),jQuery(".cp-onload").each(function(a){var b=jQuery(this).data("class-id"),c=jQuery("."+b);c.hasClass("cp-window-size")&&c.windowSize()}),d(),e(),f(),g(),setTimeout(function(){cp_column_equilize(),cp_row_equilize()},300),cp_form_sep_top(),form_sep_position(),set_affiliate_link(),cp_set_width_svg(),cp_social_responsive()}),jQuery(window).on("load",function(){set_affiliate_link()}),jQuery.fn.windowSize=function(){var a=this.find(".cp-content-container"),b=this.find(".cp-modal"),c=this.find(".cp-modal-content"),d=this.find(".cp-modal-body");b.removeAttr("style"),c.removeAttr("style"),a.removeAttr("style"),d.removeAttr("style");var e=jQuery(window).width()+30,f=jQuery(window).height();jQuery(this).find("iframe").css("width",e),a.css({"max-width":e+"px",width:"100%",height:f+"px",padding:"0",margin:"0 auto"}),c.css({"max-width":e+"px",width:"100%"}),b.css({"max-width":e+"px",width:"100%",left:"0",right:"0"}),d.css({"max-width":e+"px",width:"100%",height:f+"px"})}}(jQuery);var smile_global_data="";jQuery(document).on("smile_data_continue_received",function(a){addPaddingtoYoutubeFrame()}),jQuery(document).on("smile_data_received",function(a,b){cp_modal_common(b)}),jQuery(document).on("after_cp_column_equilize",function(a){jQuery(".cp-overlay").each(function(){if(jQuery(this).find(".cp-modal-body").hasClass("cp-jugaad")&&jQuery(this).find(".cp-modal-body .cp-form-separator").length){var a=jQuery(this).find(".cp-modal-body .cp-form-separator").outerHeight(),b=jQuery(this).find(".cp-modal-body .cp-columns-equalized").outerHeight()+a;jQuery(this).find(".cp-modal-body .cp-columns-equalized").css("height",b)}})}),function(a){"use strict";function b(){jQuery(".cp_responsive[data-font-size-init]").each(function(a,b){var c=jQuery(b),d=jQuery(this).html();d.toLowerCase().indexOf("cp_font")>=0&&d.match("^$")?c.addClass("cp-no-responsive"):c.removeClass("cp-no-responsive")})}function c(a){var b=a.find(".cp-form-container");if(a.find(".cp-modal-body").hasClass("cp-youtube")&&!b.hasClass("cp-youtube-cta-none")){var c=b.attr("data-cta-delay")||"";""!=typeof c&&null!=c&&(c=parseInt(1e3*c),b.slideUp("500"),setTimeout(function(){b.slideDown("500")},c))}}function d(a){if("undefined"!=typeof a){a=a.split("|");var b=!1,c=!1,d=!1;c=DetectTierTablet(),d=DetectTierIphone(),jQuery.each(a,function(){var a=jQuery(this).selector;("desktop"==a&&!d&&!c||"tablet"==a&&c||"mobile"==a&&d)&&(b=!0)})}else b=!1;return b}function e(){var a="none";return jQuery(".cp-onload").each(function(b,c){var d=jQuery(this).data("class-id"),e=jQuery(this).hasClass("priority_modal");return e?a=jQuery("."+d):void 0}),a}function f(a){return"/"===a.substr(-1)?a.substr(0,a.length-1):a}function g(a){var b={action:"smile_update_impressions",impression:!0,styles:a,option:"smile_modal_styles"};jQuery.ajax({url:smile_ajax.url,data:b,type:"POST",dataType:"HTML",success:function(a){}})}function h(){jQuery(".cp-overlay").each(function(a){var b=jQuery(this).find(".cp-tooltip-icon").data("classes"),c=(jQuery(this).find(".cp-tooltip-icon").data("closeid"),jQuery(this).find(".cp-tooltip-icon").data("color")),d=jQuery(this).find(".cp-tooltip-icon").data("bgcolor"),e=(jQuery(this).find(".cp-modal-content").height(),jQuery(window).width(),jQuery(this).data("modal-id"),"");jQuery(this).find(".cp-overlay-close").hasClass("cp-adjacent-left")?e="right":jQuery(this).find(".cp-overlay-close").hasClass("cp-adjacent-right")&&(e="left"),jQuery(this).find(".cp-overlay-close").hasClass("cp-inside-close"),jQuery(this).find(".cp-tooltip-icon").removeAttr("data-position"),jQuery(this).find(".cp-tooltip-icon").attr("data-position",e);var f=e;jQuery("body").addClass("customize-support"),jQuery("."+b).remove(),jQuery("head").append('"),"left"==f?jQuery("head").append('"):"right"==f?jQuery("head").append('"):jQuery("head").append('")})}function i(b){var c=b,d=a(window),e=d.scrollTop(),f=e+d.height(),g=c.offset().top,h=g+c.height();return f>=h&&g>=e}function j(){jQuery(".cp-modal-inline-end").each(function(a){var b=jQuery(this),c=i(b),d=jQuery(this).data("style");if(c){var e=Array();jQuery(".cp-overlay[data-modal-style="+d+"]").hasClass("impression_counted")||(e.push(d),g(e)),jQuery(".cp-overlay[data-modal-style="+d+"]").each(function(){jQuery(this).addClass("impression_counted")})}})}b(),jQuery(document).on("smile_customizer_field_change",function(a){CPResponsiveTypoInit()}),jQuery(document).on("smile_data_received",function(a,b){CPResponsiveTypoInit()}),jQuery.fn.isReferrer=function(a,b,c){var d=!0;b=f(b.replace(/.*?:\/\//g,""));var e=a.split(",");return jQuery.each(e,function(a,e){e=f(e),b=b.replace("www.","");var g=b.split(".");e.match(/./gim).length,g[0];e=f(e.replace(/.*?:\/\//g,"")),e=e.replace("www.","");var h=e.split("*");-1!==b.indexOf("t.co")&&(b="twitter.com"),-1!==b.indexOf("plus.google.co")?b="plus.google.com":-1!==b.indexOf("google.co")&&(b="google.com");var i=h[0];if(i=f(i),"display"==c){if(-1!==e.indexOf("*"))return i==b?(d=!0,!1):-1!==b.indexOf(i)?(d=!0,!1):(d=!1,!1);if(e==b)return d=!0,!1;d=!1}else if("hide"==c){if(-1!==e.indexOf("*"))return i==b?(d=!1,!1):-1!==b.indexOf(i)?(d=!1,!1):(d=!0,!1);if(e==b)return d=!1,!1;if(-1!==b.indexOf(i))return d=!1,!1;d=!0}}),d},jQuery.fn.isScheduled=function(){var a=new Date(gmt),b=this.data("timezonename"),c=this.data("tz-offset"),d=(a.toGMTString(),a.toLocaleString()),e=new Date,f=e.getTime()+6e4*e.getTimezoneOffset(),g=new Date(f+36e5*c),h=this.data("scheduled");if("undefined"!=typeof h&&1==h){var i=this.data("start"),j=this.data("end");return i=Date.parse(i),j=Date.parse(j),d="system"==b?Date.parse(e):Date.parse(g),d>=i&&j>=d?!0:!1}return!0};var k=function(a,b,c){if(c){var d=new Date;d.setTime(d.getTime()+24*c*60*60*1e3);var e="; expires="+d.toGMTString()}else var e="";document.cookie=a+"="+b+e+"; path=/"},l=function(a){for(var b=a+"=",c=document.cookie.split(";"),d=0;d=1){var f=c.contentWindow;"play"==b?f.postMessage('{"event":"command","func":"playVideo","args":""}',"*"):(f.postMessage('{"event":"command","func":"pauseVideo","args":""}',"*"),f.postMessage('{"event":"command","func":"stopVideo","args":""}',"*"))}var g=d.search("vimeo.com");if(g>=1){var h=c.contentWindow;"play"==b?h.postMessage('{"method":"play"}',"*"):h.postMessage('{"method":"pause"}',"*")}})};jQuery(window).on("load",function(){var a=Array();jQuery(".cp-onload").each(function(b){var e=jQuery(this),f=jQuery(this).data("class-id"),h=jQuery(this).data("dev-mode"),i=jQuery("."+f).data("modal-id"),j="temp_"+i;m(j);var o=(jQuery(this).data("exit-intent"),jQuery("."+f).data("option"),jQuery("."+f).data("modal-style")),p=jQuery("."+f),q=jQuery(this).data("onload-delay");q=1e3*q;var r=jQuery("."+f).data("load-on-refresh");100*jQuery(window).scrollTop()/(jQuery(document).height()-jQuery(window).height()),jQuery(this).data("onscroll-value");p.hasClass("cp-window-size")&&p.windowSize();var s=!1,t=p.isScheduled(),u=jQuery(this).data("hide-on-devices"),v=d(u);if("disabled"==r){var w=l(i+"-refresh");w?s=!0:(k(i+"-refresh",!0,1),s=!1)}else s=!0,m(i+"-refresh");v&&(s=!1);var x=l(i),y=l(j);x="enabled"==h&&y?!0:l(i),null==x&&(x=!1);var z=e.data("referrer-domain"),A=e.data("referrer-check"),B=document.referrer.toLowerCase(),C=!1;C="undefined"!=typeof z&&""!==z?p.isReferrer(z,B,A):!0,!x&&q&&s&&t&&C&&jQuery(".cp-open").length<=0&&setTimeout(function(){x=l(i);var b=l(j),d=!1;if(d="enabled"==h&&b?!1:null==x?!0:!1,d=jQuery(".cp-open").length<=0?!0:!1){jQuery(window).trigger("modalOpen",[p]),p.show(),jQuery(document).trigger("resize");var e=p.find(".cp-youtube-frame").attr("data-autoplay")||"0";"1"===e&&n(p,"play"),p.addClass("cp-open"),p.hasClass("impression_counted")||(a.push(o),p.addClass("impression_counted"),0!==a.length&&g(a)),c(p)}},parseInt(q)),"enabled"==h&&m(i)})}),jQuery(".wpcf7").on("wpcf7:invalid",function(a){cp_column_equilize()}),jQuery(document).scroll(function(a){j();var b=100*jQuery(window).scrollTop()/(jQuery(document).height()-jQuery(window).height()),d=b.toFixed(0),e=Array();jQuery(".cp-onload").each(function(a){var b=jQuery(this),f=(jQuery(this).data("exit-intent"),jQuery(this).data("class-id")),h=jQuery(this).data("dev-mode"),i=jQuery("."+f).data("modal-id"),j="temp_"+i,o=(jQuery("."+f).data("option"),jQuery("."+f).data("modal-style")),p=jQuery("."+f),q=jQuery(this).data("onscroll-value");"enabled"==h&&m(i);var r=l(i),s=l(j);j?"enabled"==h&&s&&(r=!0):k(j,!0,1),p.hasClass("cp-window-size")&&p.windowSize();var t=p.isScheduled(),u=b.data("referrer-domain"),v=b.data("referrer-check"),w=document.referrer.toLowerCase(),x=!1;if(x="undefined"!=typeof u&&""!==u?p.isReferrer(u,w,v):!0,!r&&q&&t&&x&&jQuery(".cp-open").length<=0&&d>=q){jQuery(window).trigger("modalOpen",[p]),p.show();var y=p.find(".cp-youtube-frame").attr("data-autoplay")||"0";"1"===y&&n(p,"play"),p.addClass("cp-open"),c(p),p.hasClass("impression_counted")||(e.push(o),p.addClass("impression_counted"),0!==e.length&&g(e))}})}),jQuery(document).scroll(function(a){var b=jQuery(window).scrollTop(),e=Array();jQuery(".cp-after-post").each(function(a){var f=jQuery(this),h=(jQuery(this).data("exit-intent"),jQuery(this).data("class-id")),i=jQuery(this).data("dev-mode"),j=jQuery(this).data("after-content-value"),o=jQuery("."+h).data("modal-id"),p="temp_"+o,q=(jQuery("."+h).data("option"),jQuery("."+h).data("modal-style")),r=jQuery("."+h),s=jQuery(".cp-load-after-post").length;if(s>0){var t=jQuery(".cp-load-after-post").offset().top-30,u=jQuery(this).data("hide-on-devices"),v=d(u);"enabled"==i&&m(o);var w=l(o),x=l(p);p?"enabled"==i&&x&&(w=!0):k(p,!0,1),r.hasClass("cp-window-size")&&r.windowSize();var y=r.isScheduled();t-=jQuery(window).height()*j/100;var z=f.data("referrer-domain"),A=f.data("referrer-check"),B=document.referrer.toLowerCase(),C=!1; if(C="undefined"!=typeof z&&""!==z?r.isReferrer(z,B,A):!0,v&&(w=t=y=C=!1),!w&&t&&y&&C&&jQuery(".cp-open").length<=0&&b>=t){jQuery(window).trigger("modalOpen",[r]),r.show();var D=r.find(".cp-youtube-frame").attr("data-autoplay")||"0";"1"===D&&n(r,"play"),r.addClass("cp-open"),c(r),r.hasClass("impression_counted")||(e.push(q),r.addClass("impression_counted"),0!==e.length&&g(e))}}})}),jQuery(document).on("mouseleave",function(a){var b=Array(),f=e();jQuery(".cp-onload").each(function(e){var h=jQuery(this);if("none"!==f){var i=f,j=i.data("modal-id");h=jQuery(".cp-onload.cp-"+j)}var o=h.data("exit-intent"),p=h.data("class-id"),q=h.data("dev-mode"),r=jQuery("."+p).data("modal-id"),s="temp_"+r,t=(jQuery("."+p).data("option"),jQuery("."+p).data("modal-style")),i=jQuery("."+p),u=jQuery(this).data("hide-on-devices"),v=d(u);"enabled"==q&&m(r);var w=l(r),x=l(s);s?"enabled"==q&&x&&(w=!0):k(s,!0,1);var y=i.isScheduled();v&&(o=y=!1);var z=h.data("referrer-domain"),A=h.data("referrer-check"),B=document.referrer.toLowerCase(),C=!1;if(C="undefined"!=typeof z&&""!==z?i.isReferrer(z,B,A):!0,!w&&C&&"enabled"==o&&y&&a.clientY<=0&&jQuery(".cp-open").length<=0){jQuery(window).trigger("modalOpen",[i]),i.show(),i.hasClass("cp-window-size")&&i.windowSize();var D=i.find(".cp-youtube-frame").attr("data-autoplay")||"0";"1"===D&&n(i,"play"),i.addClass("cp-open"),c(i),i.hasClass("impression_counted")||(b.push(t),i.addClass("impression_counted"),0!==b.length&&g(b))}})}),jQuery(document).ready(function(){var a=new Array,b=Array();j(),jQuery(".blinking-cursor").remove(),jQuery(".cp-onload").each(function(a){var b=jQuery(this).data("inactive-time");"undefined"!=typeof b&&(b=1e3*b,jQuery(document).idleTimer({timeout:b,idle:!1}))}),CPResponsiveTypoInit(),jQuery.each(jQuery(".cp-onload"),function(){var a=jQuery(this).data("class-id"),b=jQuery("."+a),c=b.find("iframe");b.hasClass("cp-window-size")&&b.windowSize(),jQuery.each(c,function(b,c){var d=c.src,e=d.search("youtube.com"),f=d.search("vimeo.com");if(d=d.replace("&autoplay=1",""),-1!==e){var g=-1===d.indexOf("?")?d+"?enablejsapi=1":d+"&enablejsapi=1";c.src=g,c.id="yt-"+a}if(-1!==f){-1===d.indexOf("?")?d+"?api=1":d+"&api=1";c.src=c.src+"?api=1",c.id="vim-"+a}})}),jQuery.each(jQuery(".cp-overlay"),function(){var b=jQuery(this).data("custom-class");"undefined"!=typeof b&&""!==b&&(b=b.split(" "),jQuery.each(b,function(b,c){a.push(c)}))}),jQuery.each(a,function(a,d){jQuery("."+d).click(function(a){a.preventDefault();var e=jQuery(".cp-modal-global."+d);if(!e.siblings(".cp-modal-popup-container").find(".cp-animate-container").hasClass("cp-form-submit-success")){var f=(e.data("exit-intent"),e.data("class-id")),h=(jQuery("."+f).data("modal-id"),jQuery("."+f).data("option"),jQuery("."+f).data("modal-style")),i=jQuery("."+f);if(i.hasClass("cp-window-size")&&i.windowSize(),jQuery(".cp-open").length<=0){i.hasClass("cp-window-size")&&i.windowSize();var j=i.find(".cp-youtube-frame").attr("data-autoplay")||"0";"1"===j&&n(i,"play"),i.addClass("cp-open"),jQuery(window).trigger("modalOpen",[i]),i.show(),c(i);var j=i.find(".cp-youtube-frame").attr("data-autoplay")||"0";"1"===j&&n(i,"play"),i.hasClass("impression_counted")||(b.push(h),i.addClass("impression_counted"));var k=i.find(".cp-tooltip-icon").data("classes");jQuery("head").append('")}0!==b.length&&(jQuery(this).hasClass("disabled")||(g(b),jQuery(document).trigger("cp_custom_class_clicked",[this])))}})}),set_affiliate_link(),setTimeout(function(){h()},1e3)}),jQuery(document).on("closeModal",function(a,b){var c=b.parents(".cp-modal-popup-container"),d=c.data("template"),e=b.data("closed-cookie-time"),f=b.data("modal-id"),g=b.find(".cp-animate-container"),h=b.data("overlay-animation"),i=g.data("exit-animation"),j="temp_"+f;jQuery("html").removeClass("cp-exceed-vieport cp-window-viewport"),k(j,!0,1);var m=l(f);n(b,"pause"),a.preventDefault(),m||e&&(k(f,!0,e),n(b,"pause"));var o=g.data("disable-animationwidth"),p=jQuery(window).width();("cp-overlay-none"==i||"undefined"!=typeof o&&o>=p)&&(b.removeClass("cp-open"),b.hasClass("cp-hide-inline-style")&&(i="cp-overlay-none"),i="cp-overlay-none",jQuery(".cp-open").length<1&&jQuery("html").removeAttr("style")),d||(g.removeClass(h),(p>=o||"undefined"==typeof o)&&g.addClass(i),"cp-overlay-none"!==i&&setTimeout(function(){n(b,"pause"),b.removeClass("cp-open"),jQuery(".cp-open").length<1&&jQuery("html").removeAttr("style"),setTimeout(function(){g.removeClass(i)})},1e3)),b.find(".cp-msg-on-submit").css("visibility","hidden")}),jQuery(document).on("click",".cp-overlay",function(a){if(!jQuery(this).hasClass("do_not_close")&&jQuery(this).hasClass("close_btn_nd_overlay")){var b=jQuery(this);n(b,"pause"),jQuery(document).trigger("closeModal",[b])}}),jQuery(document).on("idle.idleTimer",function(a,b,f){var h=Array(),i=e();jQuery(".cp-onload").each(function(a){var b=jQuery(this);if("none"!==i){var e=i,f=e.data("modal-id");b=jQuery(".cp-onload.cp-"+f)}var g=(b.data("exit-intent"),b.data("class-id")),j=b.data("dev-mode"),o=jQuery("."+g).data("modal-id"),p="temp_"+o,q=(jQuery("."+g).data("option"),jQuery("."+g).data("modal-style")),e=jQuery("."+g),r=jQuery(this).data("hide-on-devices"),s=d(r);"enabled"==j&&m(o);var t=l(o),u=l(p);p?"enabled"==j&&u&&(t=!0):k(p,!0,1);var v=!1,w=jQuery(this).data("inactive-time");"undefined"!=typeof w&&(v=!0),s&&(v=!1);var x=b.data("referrer-domain"),y=b.data("referrer-check"),z=document.referrer.toLowerCase(),A=!1;if(A="undefined"!=typeof x&&""!==x?e.isReferrer(x,z,y):!0,!t&&v&&A&&jQuery(".cp-open").length<=0){jQuery(window).trigger("modalOpen",[e]),e.show(),e.hasClass("cp-window-size")&&e.windowSize();var B=e.find(".cp-youtube-frame").attr("data-autoplay")||"0";"1"===B&&n(e,"play"),e.addClass("cp-open"),c(e),e.hasClass("impression_counted")||(h.push(q),e.addClass("impression_counted"))}}),0!==h.length&&g(h)}),jQuery(".cp-overlay").on("idle.idleTimer",function(a,b,c){var d=jQuery(this);jQuery(document).trigger("closeModal",[d]);var e=d.find(".cp-tooltip-icon").data("classes");setTimeout(function(){jQuery("head").append('")},1e3)}),jQuery(document).on("click",".cp-overlay-close",function(a){if(!jQuery(this).hasClass("do_not_close")){var b=(jQuery(this).parents(".cp-modal-popup-container"),jQuery(this).parents(".cp-overlay")),c=b.find(".cp-tooltip-icon").data("classes");n(b,"pause"),jQuery(document).trigger("closeModal",[b]),jQuery("head").append('")}}),jQuery(document).on("click",".cp-close",function(a){if(!jQuery(this).parents(".cp-overlay").hasClass("do_not_close")){var b=jQuery(this).parents(".cp-overlay");n(b,"pause"),jQuery(document).trigger("closeModal",[b])}}),jQuery(document).on("click",".cp-inner-close",function(a){var b=jQuery(this).parents(".cp-overlay");n(b,"pause"),jQuery(document).trigger("closeModal",[b])}),jQuery(document).on("click",".cp-overlay .cp-modal",function(a){a.stopPropagation()}),jQuery(window).on("modalOpen",function(a,b){var c=b.data("close-btnonload-delay");c=Math.round(1e3*c),c&&setTimeout(function(){b.find(".cp-overlay-close").removeClass("cp-hide-close")},c),cp_column_equilize(),CPModelHeight(),cp_form_sep_top(),cp_set_width_svg(),cp_row_equilize();var d=b.find(".cp-animate-container"),e=d.data("overlay-animation"),f=d.data("disable-animationwidth"),g=jQuery(window).width();(g>=f||"undefined"==typeof f)&&jQuery(d).addClass("smile-animated "+e),jQuery("#cp-tooltip-close-css").remove(),jQuery(".cp-modal-popup-container").each(function(a,b){var c=jQuery(b),d=c.find(".cp-modal");d.hasClass("cp-modal-exceed")||(d.hasClass("cp-modal-window-size")?jQuery("html").addClass("cp-window-viewport"):jQuery("html").css({overflow:"hidden"}))});var i=b.data("close-after");jQuery.idleTimer("destroy"),"undefined"!=typeof i&&(i=1e3*i,jQuery(".cp-overlay").idleTimer({timeout:i,idle:!1})),h()}),jQuery(window).resize(function(){h()}),jQuery(document).on("click",".cp-form-submit-error",function(a){var b=jQuery(this).find(".cp-form-processing-wrap"),c=jQuery(this).find(".cp-tooltip-icon").data("classes"),d=jQuery(this).find(".cp-msg-on-submit");jQuery(this).find(".cp-form-processing");b.hide(),jQuery(this).removeClass("cp-form-submit-error"),d.html(""),d.removeAttr("style"),jQuery("head").append('")}),jQuery(document).ready(function(){b(),jQuery(document).bind("keydown",function(a){if(27==a.which){var b=jQuery(".cp-open"),c=b;b.hasClass("close_btn_nd_overlay")&&!b.hasClass("do_not_close")&&jQuery(document).trigger("closeModal",[c])}})}),jQuery(document).on("cp_conversion_done",function(a,b){if(!jQuery(b).parents(".cp-form-container").find(".cp-email").length>0){var c=jQuery(b).parents(".cp-form-container").find('[name="only_conversion"]').length;c>0&&jQuery(b).addClass("disabled")}}),jQuery(document).on("cp_custom_class_clicked",function(a,b){jQuery(b).addClass("disabled")});var o=[];jQuery.each(jQuery(".cp-onload"),function(){var a=jQuery(this).data("scroll-class");"undefined"!=typeof a&&""!==a&&(a=a.split(" "),jQuery.each(a,function(a,b){o.push(b)}))}),jQuery.each(o,function(a,b){jQuery(document).scroll(function(a){j();var d=100*jQuery(window).scrollTop()/(jQuery(document).height()-jQuery(window).height()),e=(d.toFixed(0),Array());jQuery(".cp-onload").each(function(a){var d=jQuery(this),f=(jQuery(this).data("exit-intent"),jQuery(this).data("class-id")),h=jQuery(this).data("dev-mode"),i=jQuery("."+f).data("modal-id"),j="temp_"+i,o=(jQuery("."+f).data("option"),jQuery("."+f).data("modal-style")),p=jQuery("."+f),q=b,r="";if("undefined"!=typeof q&&" "!==q){var s=jQuery(q).position();"undefined"!=typeof s&&" "!==s&&(r=jQuery(q).cp_modal_isOnScreen())}"enabled"==h&&m(i);var t=l(i),u=l(j);j?"enabled"==h&&u&&(t=!0):k(j,!0,1),p.hasClass("cp-window-size")&&p.windowSize();var v=p.isScheduled(),w=d.data("referrer-domain"),x=d.data("referrer-check"),y=document.referrer.toLowerCase(),z=!1;if(z="undefined"!=typeof w&&""!==w?p.isReferrer(w,y,x):!0,!t&&r&&v&&z&&jQuery(".cp-open").length<=0&&1==r){jQuery(window).trigger("modalOpen",[p]),p.show();var A=p.find(".cp-youtube-frame").attr("data-autoplay")||"0";"1"===A&&n(p,"play"),p.addClass("cp-open"),c(p),p.hasClass("impression_counted")||(e.push(o),p.addClass("impression_counted"),0!==e.length&&g(e))}})})}),jQuery.fn.cp_modal_isOnScreen=function(){var b=a(window),c={top:b.scrollTop(),left:b.scrollLeft()};c.right=c.left+b.width(),c.bottom=c.top+b.height();var d=this.offset();return d.right=d.left+this.outerWidth(),d.bottom=d.top+this.outerHeight(),!(c.rightd.right||c.bottomd.bottom)}}(jQuery),function(a){"use strict";function b(a){var b=new RegExp(/^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?$/i);return b.test(a)}function c(a,c){return c.trim()?a.hasClass("cp-email")?b(c)?!1:!0:a.hasClass("cp-textfeild")&&0==/^[a-zA-Z0-9- ]*$/.test(c)?!0:!1:!0}function d(a){var d=jQuery(a).parents(".cp-modal-body").find("#smile-optin-form"),g=d.serialize(),h=jQuery(a).parents(".cp-animate-container").find(".cp-msg-on-submit"),i=(jQuery(a).parents(".cp-modal-body").find(".cp-form-container"),jQuery(a).parents(".cp-animate-container").find(".cp-form-processing")),j=jQuery(a).parents(".global_modal_container "),k=jQuery(a).parents(".cp-animate-container").find(".cp-form-processing-wrap"),l=jQuery(a).parents(".cp-animate-container"),m=j.find(".cp-tooltip-icon").data("classes"),n=j.data("conversion-cookie-time"),o=j.data("modal-id"),p=jQuery(a).parents(".global_modal_container ").hasClass("do_not_close"),q=jQuery(a).parents(".global_modal_container ").data("redirect-lead-data"),r=jQuery(a).parents(".global_modal_container ").data("redirect-to"),s=jQuery(a).parents(".global_modal_container").data("form-action"),t=jQuery(a).parents(".global_modal_container").data("form-action-time"),t=parseInt(1e3*t),u="",v=!0,w="";d.find(".cp-input").each(function(a){var b=jQuery(this);if(!b.hasClass("cp-submit-button")){var d=b.attr("name"),e=b.val(),f=d.replace(/param/gi,function(a){return""});f=f.replace("[",""),f=f.replace("]",""),u+=0!=a?"&":"",u+=f+"="+e;var g=b.attr("required")?!0:!1;g&&(c(b,e)?(v=!1,b.addClass("cp-input-error")):b.removeClass("cp-input-error"))}});var x=0,y="";d.find("select, textarea, input").each(function(a,c){if(jQuery(c).prop("required"))if(jQuery(c).val())if(jQuery(c).hasClass("cp-email")){var d=jQuery(c).val();if(b(d))jQuery(c).removeClass("cp-error");else{jQuery(c).addClass("cp-error"),x++;var e=jQuery(c).attr("name")||"";y+=e+" is required \n"}}else jQuery(c).removeClass("cp-error");else x++,jQuery(c).addClass("cp-error"),e=jQuery(c).attr("name"),y+=e+" is required \n"}),x>0?console.log(y):(k.show(),h.fadeOut(120,function(){jQuery(this).show().css({visibility:"hidden"})}),i.hide().css({visibility:"visible"}).fadeIn(100),jQuery.ajax({url:smile_ajax.url,data:g,type:"POST",dataType:"HTML",success:function(b){console.log("result: "+b),n&&f(o,!0,n);var c=jQuery.parseJSON(b),g="",v="";"undefined"!=typeof c.status&&null!=c.status&&(v=c.status),c.email_status?d.find(".cp-email").removeClass("cp-error"):(d.find(".cp-email").addClass("cp-error"),d.find(".cp-email").focus());var x="undefined"!=typeof c.detailed_msg&&null!==c.detailed_msg?c.detailed_msg:"";if(""!==x&&null!==x&&(x="Here is More Information:"+x+"",x+="Read How to Fix This, click here",x+="Go Back",g+='[Only you can see this message]'),c.message=c.message.replace(/\\/g,""),"undefined"!=typeof c.message&&null!=c.message&&(h.hide().css({visibility:"visible"}).fadeIn(120),g+=''+c.message+""+x+"",h.html(g),l.addClass("cp-form-submit-"+v)),"undefined"!=typeof c.action&&null!=c.action&&(i.fadeOut(100,function(){jQuery(this).show().css({visibility:"hidden"})}),h.hide().css({visibility:"visible"}).fadeIn(120),"success"===v)){if(jQuery("head").append('"),"redirect"===c.action){k.hide(),j.hide();var y=c.url,z="";z=y.indexOf("?")>-1?"&":"?";var A=y+z+decodeURI(u);A=1==q?A:c.url,"download"!==r?(w=r,window.open(A,"_"+w)):e(A)}else{if(k.show(),jQuery(a).find("a").length>0){var B=jQuery(a).find("a").attr("href"),C=jQuery(a).find("a").attr("target");(""==C||"undefined"==typeof C)&&(C="_self"),(""!=B||"#"!=B)&&window.open(B,C)}"disappear"==s?(j.removeClass("cp-hide-inline-style"),setTimeout(function(){j.hasClass("cp-modal-inline")&&j.addClass("cp-hide-inline-style"),jQuery(document).trigger("closeModal",[j])},t)):"reappear"==s&&setTimeout(function(){h.empty(),k.css({display:"none"}),h.removeAttr("style"),i.removeAttr("style"),d.trigger("reset")},t)}p&&setTimeout(function(){jQuery(document).trigger("closeModal",[j])},3e3)}},error:function(a){k.hide(),i.fadeOut(100,function(){jQuery(this).show().css({visibility:"hidden"})})}}))}function e(a,b){if(window.ActiveXObject){if(window.ActiveXObject&&document.execCommand){var c=window.open(a,"_blank");c.document.close(),c.document.execCommand("SaveAs",!0,b||a),c.close()}}else{var d=document.createElement("a");d.href=a,d.target="_blank";var e=a.substring(a.lastIndexOf("/")+1);d.download=b||e;var f=new MouseEvent("click",{view:window,bubbles:!0,cancelable:!1});d.dispatchEvent(f),(window.URL||window.webkitURL).revokeObjectURL(d.href)}}var f=function(a,b,c){if(c){var d=new Date;d.setTime(d.getTime()+24*c*60*60*1e3);var e="; expires="+d.toGMTString()}else var e="";document.cookie=a+"="+b+e+"; path=/"};jQuery(document).ready(function(){jQuery(".cp-modal-popup-container").find("#smile-optin-form").each(function(a,b){jQuery(b).find("input").keypress(function(a){if(13==a.which){a.preventDefault();var b=jQuery(this).parents(".cp-animate-container").hasClass("cp-form-submit-success");jQuery(this).parents(".cp-animate-container").hasClass("cp-form-submit-error");b||d(this)}}),jQuery(b).find(".btn-subscribe").click(function(a){if(a.preventDefault,!jQuery(this).hasClass("disabled")){d(this),jQuery(document).trigger("cp_conversion_done",[this]);var b=jQuery(this).attr("data-redirect-link")||"",c=jQuery(this).attr("data-redirect-link-target")||"_blank";"undefined"!=b&&""!=b&&window.open(b,c)}a.preventDefault()})})})}(jQuery);