if(!ThriveGlobal||!ThriveGlobal.$j){var __thrive_$oJ=window.$,ThriveGlobal={$j:jQuery.noConflict()};__thrive_$oJ&&(window.$=__thrive_$oJ)}var TVE_jQFn={},TCB_Front={browser:null,detectBrowser:function(){var t,e,i={},r=(e=-1,"Microsoft Internet Explorer"===navigator.appName?(t=navigator.userAgent,null!==new RegExp("MSIE ([0-9]{1,}[\\.0-9]{0,})").exec(t)&&(e=parseFloat(RegExp.$1))):"Netscape"===navigator.appName&&(t=navigator.userAgent,null!==new RegExp("Trident/.*rv:([0-9]{1,}[\\.0-9]{0,})").exec(t)&&(e=parseFloat(RegExp.$1))),e);if(0e.oText?1:t.oTexte.text?1:-1}function c(t,e){return t.text==e.text?t.oText>e.oText?-1:t.oTexte.text?-1:1}e.attr("data-direction",s),ThriveGlobal.$j(i).find("tbody tr").each(function(){var t=ThriveGlobal.$j(this),e=t.find("> td").eq(r).text().trim().replace(/\u200B/g,"").toLowerCase(),i=parseFloat(e);isNaN(i)?o.push({tr:t,text:e,oText:e}):n.push({tr:t,text:i,oText:e})}),"down"==s?o.sort(l):o.sort(c),"down"==s?n.sort(l):n.sort(c),t="down"==s?n.concat(o):o.concat(n),ThriveGlobal.$j.each(t,function(t,e){a.append(e.tr)}),d.attr("data-direction",""),e.attr("data-direction",s)})},getCookie:function(t){for(var e=t+"=",i=document.cookie.split(";"),r=0;r").css(t.extend({},e)),r=t("
").css(t.extend({left:"-1000px",overflow:"scroll",position:"absolute",top:"-1000px"},e)).append(i).appendTo("body").scrollLeft(1e3).scrollTop(1e3),a={height:r.offset().top-i.offset().top||0,width:r.offset().left-i.offset().left||0};return r.remove(),a},openLightbox:function(n,t){var i=ThriveGlobal.$j("body"),r=ThriveGlobal.$j("html"),a="tve-o-hidden tve-l-open tve-hide-overflow",e=this.getBrowserScrollSize().width,o=this,s=parseInt(i.css("padding-right")),l=n.find("input[placeholder]").not(":radio").not(":checkbox");function c(t,e){t.find("iframe").not(".thrv_social_default iframe").each(function(){var t=ThriveGlobal.$j(this).addClass("tcb-dr-done");t.attr("data-src",t.attr("src")),t.attr("src","")}),t.find("video").each(function(){ThriveGlobal.$j(this)[0].pause()}),void 0===e&&1===ThriveGlobal.$j(".tve_lb_open").length&&(i.removeClass(a).css("padding-right",""),r.removeClass(a),t.data("doc-scroll-top")?(document.documentElement.scrollTop=t.data("doc-scroll-top"),t.data("doc-scroll-top","")):t.data("bdy-scroll-top")&&(document.body.scrollTop=t.data("bdy-scroll-top"),t.data("doc-scroll-top",""))),t.removeClass("tve_lb_open tve_lb_opening").addClass("tve_lb_closing"),setTimeout(function(){t.attr("class","").css("display","none").find("tve_p_lb_content").trigger("tve.lightbox-close")},300),ThriveGlobal.$j("#tve-lg-error-container").hide()}function d(t){var e,i,r=n.find(".tve_p_lb_content"),a=TCB_Front.$window.height(),o=void 0!==t&&t?"animate":"css";TCB_Front.postGridLayout(),i=(a-(e=r.outerHeight(!0)))/2,n.find(".tve_p_lb_overlay")[o]({height:e+80+"px","min-height":a+"px"},200),r[o]({top:(i<40?40:i)+"px"},200),a ul li").eq(isNaN(e)?0:e).click()}):n.find("iframe").not(".thrv_social_default iframe").each(function(){var t=ThriveGlobal.$j(this);t.attr("data-src")&&t.attr("src",t.attr("data-src"))}),setTimeout(function(){n.css("display",""),n.addClass("tve_lb_opening"),setTimeout(function(){d()},0)},20),n.find(".tve_p_lb_content").trigger("tve.before-lightbox-open"),setTimeout(function(){n.removeClass("tve_lb_opening").addClass("tve_lb_open").find(".tve_p_lb_content").trigger("tve.lightbox-open")},300),TCB_Front.$window.resize(function(){d()}),n.on("lbresize",function(){d(!0)})},event_triggers:function(t){window.TVE_Event_Manager_Registered_Callbacks&&t.find(".tve_evt_manager_listen").each(function(){var r=ThriveGlobal.$j(this),t=r.attr("data-tcb-events");if(t||(t=r.closest(".thrv_wrapper").attr("data-tcb-events")),!t)return!0;try{t=ThriveGlobal.$j.parseJSON(t.replace("__TCB_EVENT_","").replace("_TNEVE_BCT__","")),ThriveGlobal.$j.each(t,function(t,e){if(TVE_Event_Manager_Registered_Callbacks[e.a]){var i="mouseover"===e.t?"mouseenter":e.t;r.off(i+".tcbevt"+e.t).on(i+".tcbevt"+e.t,function(){return TVE_Event_Manager_Registered_Callbacks[e.a].call(r[0],e.t,e.a,e.config?e.config:{})})}})}catch(t){console.log("Could not parse events"),console.log(t)}})},show_data_elemements:function(i){tve_frontend_options.is_editor_page||ThriveGlobal.$j(".thrv_data_element").filter(":not(.thrv_data_element_start)").each(function(){var t=ThriveGlobal.$j(this),e=TCB_Front.$window.height();i+e>=t.offset().top+t.outerHeight()&&"hidden"!==t.css("visibility")&&t.addClass("thrv_data_element_start").trigger("tve.start-animation")})},onDOMReady:function(i){void 0===i&&(i=ThriveGlobal.$j("body")),ThriveGlobal.$j(".tcb-video-background-el").each(function(){this.parentNode.classList.add("tcb-video-background-parent")}),!window.TVE_Dash||TVE_Dash.ajax_sent?this.getShareCounts():ThriveGlobal.$j(document).on("tve-dash.load",function(t){var e=TCB_Front.getShareCounts(ThriveGlobal.$j("body"),{},!0);e&&TVE_Dash.add_load_item("tcb_social",e[0],e[1])}),ThriveGlobal.$j.each(TVE_jQFn,function(t,e){ThriveGlobal.$j.fn[t]=e});var t=ThriveGlobal.$j("ul.tve_w_menu.tve_horizontal"),e=t.length;if(t.each(function(){this.style.zIndex=e+5;var t=ThriveGlobal.$j(this);t.find("ul").css("z-index",e+6),t.parentsUntil("#tve_editor").each(function(){var t=ThriveGlobal.$j(this);"static"!==t.css("position")&&t.css("z-index",e+7)}),e--}),ThriveGlobal.$j(".tve_scT").each(function(){var t=ThriveGlobal.$j(this),e=parseInt(t.attr("data-selected"));t.find("iframe").not(".thrv_social_default iframe").each(function(){var t=ThriveGlobal.$j(this);t.is(":visible")&&t.attr("data-src")&&t.attr("data-src").length&&t.attr("src").length<=0?(t.attr("src",t.attr("data-src")),t.attr("data-src",""),t.removeClass("tcb-dr-done")):t.is(":visible")||t.attr("src").length&&(t.addClass("tcb-dr-done"),t.attr("data-src",t.attr("src")),t.attr("src",""))}),tve_frontend_options.is_editor_page||t.find("> ul li").eq(isNaN(e)?0:e).click()}),ThriveGlobal.$j(".thrv_toggle_shortcode").each(function(){ThriveGlobal.$j(this).find("iframe").not(".thrv_social_default iframe").not(".tcb-dr-done").each(function(){var t=ThriveGlobal.$j(this);t.addClass("tcb-dr-done"),t.attr("src")&&t.attr("data-src",t.attr("src")),t.attr("src","")})}),tve_frontend_options.is_editor_page)try{ThriveGlobal.$j("html").getNiceScroll().remove()}catch(t){}else{if(void 0===window.tcb_autofill){window.tcb_autofill=TCB_Front.getCookie("account_create_fields");try{window.tcb_autofill&&(window.tcb_autofill=decodeURIComponent(window.tcb_autofill),window.tcb_autofill=JSON.parse(window.tcb_autofill))}catch(t){window.tcb_autofill=null}window.tcb_autofill||(window.tcb_autofill=null)}if(window.tcb_autofill&&ThriveGlobal.$j.isArray(window.tcb_autofill)){ThriveGlobal.$j.each(window.tcb_autofill,function(t,e){i.find("input[name="+e.name+"]").each(function(){var t=ThriveGlobal.$j(this);t.data("tcb-autofill")||(t.val(e.value).hide(),t.parent().append('

'+e.value+'

'),t.data("tcb-autofill",1))})}),setTimeout(function(){TCB_Front.setCookie("account_create_fields",null,{path:"/"})},2500)}ThriveGlobal.$j("input[type=password], input[name=confirm_password]").on("keyup",function(){var t,e=ThriveGlobal.$j(this),i=o(e.val()),r="#e3ecef",a="";e.next().find(".tve-password-strength").css({"background-color":"#e3ecef"}),i<30?(r="#ef5350",a="Weak",t=e.next().find(".tve-password-strength").first()):30<=i&&i<60?(r="#ffa726",a="So-so",t=e.next().find(".tve-password-strength:lt(2)")):60<=i&&i<80?(r="#8bc34a",a="Good",t=e.next().find(".tve-password-strength:lt(3)")):(r="#4caf50",a="Great!",t=e.next().find(".tve-password-strength:lt(4)")),t.each(function(){ThriveGlobal.$j(this).css({"background-color":r})}),e.next().find(".tve-password-strength-text").text(a).css({color:r})});var o=function(t){var e,i=0,r={},a=0;if(!t)return i;for(var o=0;o=t.offset().top&&t.offset().top>i||"start"==t.attr("data-typefocus")?t.typed("start"):(t.attr("data-typefocus"),t.typed("pause")))})}catch(t){console.log(t)}}),TCB_Front.$window.trigger("scroll"),!tve_frontend_options.is_editor_page){var r=ThriveGlobal.$j(".tve-captcha-container");if(r.length){function a(){var i;"undefined"!=typeof grecaptcha&&grecaptcha.render?(i=100,r.filter(":not(.tve-recapcha-rendered)").each(function(){this.id=this.id+"-"+ ++i;var t=ThriveGlobal.$j(this),e=window.innerWidth<400?"compact":t.attr("data-size");t.addClass("tve-recaptcha-rendered"),grecaptcha.render(this.id,{sitekey:t.attr("data-site-key"),theme:t.attr("data-theme"),type:t.attr("data-type"),size:e})})):setTimeout(a,50)}var n=!1;window.tve_gapi_loaded||(ThriveGlobal.$j.getScript("https://www.google.com/recaptcha/api.js?render=explicit",a),n=!0,window.tve_gapi_loaded=!0),n||a()}var s=ThriveGlobal.$j(".tve-fb-comments");s.length&&(ThriveGlobal.$j("#fb-root").length&&ThriveGlobal.$j("head").append('
'),s.each(function(){""===this.getAttribute("data-href")&&this.setAttribute("data-href",window.location.href.split("?")[0]),this.classList.add("fb-comments"),FB.XFBML.parse(this.parentNode)}));var l=ThriveGlobal.$j(".thrv_disqus_comments #disqus_thread");l.length&&(window.disqus_shortname=l.attr("data-disqus_shortname"),""==l.attr("data-disqus_url")?window.disqus_url=window.location:window.disqus_url=l.attr("data-disqus_url"),window.disqus_identifier=window.disqus_url,"undefined"==typeof DISQUS&&ThriveGlobal.$j.getScript("//"+disqus_shortname+".disqus.com/embed.js"))}window.mejs&&ThriveGlobal.$j(".tcb-video-shortcode").not(".mejs-container").filter(function(){return!ThriveGlobal.$j(this).parent().hasClass(".mejs-mediaelement")}).mediaelementplayer(),this.resizePageSection(),this.playBackgroundYoutube(ThriveGlobal.$j("div.tcb-yt-bg"))},resizePageSection:function(t){void 0===t&&(t=ThriveGlobal.$j(".tcb-window-width")),t.each(function(){var t=ThriveGlobal.$j(this),e=(t.parent().width(),t.find(".tve-page-section-in"),t.css("left"));e="auto"===e?0:Number(t.css("left").replace("px","")),t.css({width:TCB_Front.$window.width()+"px",left:-t.offset().left+e+"px"})})},onSocialCustomClick:{wnd:function(t,e,i){var r=void 0!==window.screenLeft?window.screenLeft:screen.left,a=void 0!==window.screenTop?window.screenTop:screen.top,o=(window.innerWidth?window.innerWidth:document.documentElement.clientWidth?document.documentElement.clientWidth:screen.width)/2-e/2+r,n=(window.innerHeight?window.innerHeight:document.documentElement.clientHeight?document.documentElement.clientHeight:screen.height)/2-i/2+a,s=window.open(t,"Thrive Share","scrollbars=yes,resizable=yes,toolbar=no,menubar=no,scrollbars=no,location=no,directories=no,width="+e+", height="+i+", top="+n+", left="+o);return window.focus&&s.focus(),s},fb_share:function(t){var e=t.data();if(e.href||(e.href=location.href),e.type&&"feed"!=e.type)this.wnd("https://www.facebook.com/sharer/sharer.php?u="+encodeURIComponent(e.href),650,500);else{var i="";e.name&&(i+="&title="+encodeURIComponent(e.name)),e.description&&(i+="&description="+encodeURIComponent(e.description)),e.href&&(i+="&u="+encodeURIComponent(e.href)),e.caption&&(i+="&caption="+encodeURIComponent(e.caption)),e.image&&(i+="&picture="+encodeURIComponent(e.image)),i="?"+i.substr(1),this.wnd("https://www.facebook.com/sharer.php"+i,650,500)}return!1},g_share:function(t){var e=t.data();e.href||(e.href=location.href),this.wnd("https://plus.google.com/share?url="+encodeURIComponent(e.href),600,600)},t_share:function(t){var e=t.data();e.href||(e.href=location.href),this.wnd("https://twitter.com/intent/tweet?url="+encodeURIComponent(e.href)+(e.tweet?"&text="+encodeURIComponent(e.tweet):"")+(e.via?"&via="+e.via:""),550,450)},in_share:function(t){var e=t.data();e.href||(e.href=location.href),this.wnd("https://www.linkedin.com/shareArticle?mini=true&url="+encodeURIComponent(e.href),550,400)},pin_share:function(t){var e=t.data();e.href||(e.href=location.href),this.wnd("https://pinterest.com/pin/create/button/?url="+encodeURIComponent(e.href)+(e.media?"&media="+encodeURIComponent(e.media):"")+(e.description?"&description="+encodeURIComponent(e.description):""),600,600)},xing_share:function(t){var e=t.data();e.href||(e.href=location.href),this.wnd("https://www.xing.com/spi/shares/new?url="+encodeURIComponent(e.href),600,500)}},getShareCounts:function(t,e,i){var r=(t=t||ThriveGlobal.$j("body")).find(".tve_social_items.tve_social_custom");if(r.length){var o={action:"tve_social_count",for:[]};if(void 0!==e?ThriveGlobal.$j.each(e,function(t,e){o[t]=e}):"undefined"!=typeof tve_path_params&&tve_path_params.post_id&&(o.post_id=tve_path_params.post_id),r.each(function(t){var e=ThriveGlobal.$j(this),i={};if(e.data("tve-social-counts")||!e.hasClass("tve_social_cb")&&"1"!==e.parent().attr("data-counts"))e.data("tve-social-counts",1);else{e.data("tve-social-counts",1);var r=e.prev(".tve_s_share_count"),a=e.children(".tve_s_item").each(function(){var t=ThriveGlobal.$j(this).addClass("tve_count_loading");i[t.attr("data-s")]=t.attr("data-href")});if(i.hasOwnProperty("t_share")&&1===a.length)return a.removeClass("tve_count_loading"),r.remove(),void e.parent().removeAttr("data-counts");o.for[t]=i}}),!o.for.length)return null;TCB_Front.total_share_counts={};var a=function(o){o&&o.counts&&o.totals&&r.each(function(t){var e=ThriveGlobal.$j(this),i=e.prev(".tve_s_share_count"),r=e.children(".tve_s_item");if(ThriveGlobal.$j.each(o.counts[t],function(t,e){r.filter(".tve_s_"+t).find(".tve_s_count").html(e.formatted)}),r.removeClass("tve_count_loading"),o.totals&&o.totals[t]&&"1"===e.parent().attr("data-counts")){var a=parseInt(e.parent().attr("data-min_shares"));a=isNaN(a)?0:a,i.find(".tve_s_cnt").html(o.totals[t].formatted),a
'+t+"
")}),setTimeout(function(){jQuery(".tvd-toast").hide(),"function"==typeof i&&i()},3e3)}};function isExternal(t){function e(t){return t.replace("http://","").replace("https://","").split("/")[0]}return e(location.href)!==e(t)}function unserialize(t){var a="undefined"!=typeof window?window:global,n=function(t){for(var e=t.length,i=t.length-1;0<=i;i--){var r=t.charCodeAt(i);127t.length&&C("Error","Invalid"),a.push(o),o=t.slice(e+(r-1),e+r),r+=1;return[a.length,a.join("")]},$=function(t,e,i){var r,a,o=[];for(r=0;r'),_=t.find("form")),_.find('input[type="checkbox"],input[type="radio"]').each(function(){if(!this.id)return!0;ThriveGlobal.$j("#"+this.id).not(this).length&&(this.id=this.id+"-"+window.TCB_PAGE_INDEX++,ThriveGlobal.$j(this).next("label").attr("for",this.id))}),void 0!==e&&"#"==_.attr("action")&&_.attr("action",e),t.data("tve_lg_done"))return this;if(t.data("tve_lg_done",!0),void 0!==window.SegMet&&SegMet&&-1!==_[0].action.indexOf("infusionsoft")&&!_.data("tve-segmet-submit")){_.data("tve-segmet-submit",1);var i=_[0].submit;_[0].submit=function(){return _.data("tve-segmet-submitted")?i.call(_[0]):(_.data("tve-segmet-submitted",1),_.submit())}}var c,d={errClass:"tve-lg-error",init:function(){this.container=ThriveGlobal.$j("#tve-lg-error-container"),this.container.length||(this.container=ThriveGlobal.$j('
').appendTo("body"),this.container.on("click",".tve-lg-err-close",ThriveGlobal.$j.proxy(this.close,this))),this.container.empty().hide(),this.clear()},close:function(){this.container.fadeOut(200);var t=_.find("."+this.errClass);return t.length||(t=_.find("input,select,textarea")),t.first().focus(),!1},clear:function(){_.find("input,select,textarea").removeClass(this.errClass)},markApiError:function(t){return this.container.append('
'+t+"
"),this},_markError:function(t,e,i){t&&t.addClass(this.errClass),"required"===i&&this.container.find(".tve-lg-required").length||this.container.append('
'+e+"
")},show:function(){this.container.append('');var a=this;setTimeout(function(){var t=_.offset(),e=parseInt(_.css("margin-top")),i=parseInt(_.css("margin-left")),r=t.top-10-a.container.outerHeight(!0)-(isNaN(e)?0:e);_.parents(".thrv-ribbon").length&&("bottom"==_.parents(".tve-leads-ribbon").attr("data-position")?r+=7:r=t.top+_.outerHeight()),a.container.css({top:r+"px",left:t.left-(isNaN(i)?0:i),width:_.outerWidth()}).fadeIn(200)},50)},phone:function(t,e){return!0},required:function(t,e){return!!("radio"===t.attr("type")?ThriveGlobal.$j('input[name="'+t.attr("name")+'"]').is(":checked"):"checkbox"===t.attr("type")?ThriveGlobal.$j('input[name="'+t.attr("name")+'"]').is(":checked"):0()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(t.val())||(this._markError(t,e,"email"),!1)},getErrors:function(t){try{return JSON.parse(t.find(".tve-lg-err-msg").val())}catch(t){return{required:"Please fill in all of the required fields",phone:"The phone number is not valid",email:"The email address is not valid"}}}},g=function(t,e){var i=ThriveGlobal.$j.extend({success:"Success!",error:"Error!"},e),r=_.find("#_form_type").val(),a=_.find("input[name=name]").val()?_.find("input[name=name]").val():"",o=_.find("input[name=email]").val();if(t){_.parents(".tl-style").first().find(".tve_p_lb_close").trigger("click");var n=ThriveGlobal.$j.Event("leads_messages.tcb");_.trigger(n),"lead_generation"==r&&(_.find("input").val(""),_.parents(".tve_p_lb_content").find(".tve_p_lb_close").click()),i.success=i.success.replace("[lead_email]",o),i.success=i.success.replace("[lead_name]",a),jQuery("body").slideDown("fast",function(){jQuery("body").prepend('
'+i.success+"
")}),setTimeout(function(){jQuery(".tvd-toast").hide()},6e3)}else{var s=_.parent(),l=s.parent(),c=l.find(".tve-error-wrapper");1==_.find("#_error_message_option").val()?(s.hide(),0==c.length?(l.append('
'),i.error=i.error.replace("[lead_email]",o),i.error=i.error.replace("[lead_name]",a),l.find(".tve-error-content").append(i.error)):l.find(".tve-error-wrapper").show()):location.reload()}_.tve_form_loading(!0)};t.data("form-target")&&t.data("form-target").length&&t.find("form").attr("target",t.data("form-target")),t.find(".tve-lg-err-msg").length&&(c=d.getErrors(t),_.submit(function(t){if(_.data("tve-force-submit"))return!0;var e=_.find(".consent-config");e.length&&!e.val()&&"none"!==_.find(".tcb-lg-consent").css("display")&&_.find('[name="user_consent"]').attr("data-required",1);var a=!0,i=ThriveGlobal.$j(this),o={};if(d.init(),i.find("input, select, textarea").each(function(){var t=ThriveGlobal.$j(this),e=t.data("validation"),i=t.data("required"),r=t.data("iphone-placeholder");""!==r&&t.val()===r&&t.val(""),"password"==t.attr("type")&&(o[t.attr("name")]=t.val()),1===i&&(d.required(t,c.required)||(a=!1)),void 0!==e&&"none"!==e&&d[e]&&(d[e](t,c[e])||(a=!1))}),0').appendTo(e),e.css({position:"relative",width:e.width()+"px",height:e.height()+"px"})),e.find("button").hide(),i.show()),this},TVE_jQFn.thrive_tcb_timer=function(){return this.each(function(){var t,a=ThriveGlobal.$j(this),e=new Date,i=new Date(a.attr("data-date")+"T"+a.attr("data-hour")+":"+a.attr("data-min")+":"+(a.attr("data-sec")||"00")+a.attr("data-timezone")),o=0,n=0,s=0,l=0,c=2,r=a.attr("data-text"),d=a.hasClass("thrv-countdown_timer_evergreen")||a.hasClass("tve_countdown_timer_evergreen"),h=a.attr("data-norestart"),v=parseInt(a.attr("data-day")),u=parseInt(a.attr("data-hour")),f=parseInt(a.attr("data-min")),p=parseInt(a.attr("data-sec"));if(a.data("tcb_timer_done"))return this;if(a.data("tcb_timer_done",!0),d){i=new Date;var _=TCB_Front.getCookie(a.attr("data-id"));if(_){_=_.split("-");var g=new Date(_[0],_[1]-1,_[2],_[3],_[4],_[5]);i.setTime(g)}else{i.setTime(e.getTime()+24*v*3600*1e3+3600*u*1e3+60*f*1e3+1e3*p);var m=i.getFullYear()+"-"+(i.getMonth()+1)+"-"+i.getDate()+"-"+i.getHours()+"-"+i.getMinutes()+"-"+i.getSeconds(),b=new Date("2034-01-01");if(!parseInt(h)){var T=new Date(i.getTime());b=T.setDate(i.getDate()+parseInt(a.attr("data-expday"))),b=T.setHours(i.getHours()+parseInt(a.attr("data-exphour"))),b=new Date(b)}TCB_Front.setCookie(a.attr("data-id"),m,{expires:b})}}function w(){setTimeout(function(){a.find(".tve_t_day .t-digits").css("min-width",a.find(".tve_t_sec .t-digits > span").outerWidth()*c+"px")},10)}a.parents(".thrv_content_reveal").on("tve-content-revealed",w),a.parents(".tve_p_lb_content").on("tve.before-lightbox-open",w);var y=function(t,e){if(t.html()==e)return t;t.removeClass("next");var i=t.clone().removeClass("go-down").addClass("next").html(e);return t.before(i).next(".go-down").remove(),t.addClass("go-down"),setTimeout(function(){i.addClass("go-down")},20),t},C=function(t,e,i){void 0===i&&(i=!1);var r=0;if(e<=99)y(t.find(".part-1").first(),e%10),y(t.find(".part-2").first(),Math.floor(e/10)),r=2;else for(;e;)r++,y(t.find(".part-"+r).first(),e%10),e=Math.floor(e/10);if(!1!==i&&r '+e+"")};a.find(".tve_t_sec .t-digits").empty().append(t(2,Math.floor(l/10))).append(t(1,l%10)),a.find(".tve_t_min .t-digits").empty().append(t(2,Math.floor(s/10))).append(t(1,s%10)),a.find(".tve_t_hour .t-digits").empty().append(t(2,Math.floor(n/10))).append(t(1,n%10));for(var e=a.find(".tve_t_day .t-digits").empty(),i=o,r=1;r<=c;r++)e.append(t(r,i%10)),i=Math.floor(i/10);e.css("min-width","")}(),a.addClass("init_done"),t=setInterval(function(){$(),C(a.find(".tve_t_sec .t-digits"),l),C(a.find(".tve_t_min .t-digits"),s),C(a.find(".tve_t_hour .t-digits"),n),C(a.find(".tve_t_day .t-digits"),o,c),o<=0&&n<=0&&s<=0&&l<=0&&(o=n=s=l=0,clearInterval(t),j())},1e3)),d&&i<=e&&(clearInterval(t),j())})},TVE_jQFn.thrive_iphone_placeholder=function(){if(!0===(/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream))return this.each(function(){var t=ThriveGlobal.$j(this),e=t.attr("placeholder");return"password"===t.attr("type")||"checkbox"===this.type||"radio"===this.type?this:t.data("iphone-placeholder")?this:(t.attr("placeholder","").val(e),void t.on("focus",function(){t.val()===e&&t.val("")}).on("blur",function(){""===t.val()&&t.val(e)}).data("iphone-placeholder",e))})},void 0!==ThriveGlobal&&(TCB_Front.$window=ThriveGlobal.$j(window),TCB_Front.browser=TCB_Front.detectBrowser(),ThriveGlobal.$j(document).ready(function(){var t=ThriveGlobal.$j(tve_frontend_options.is_editor_page?"#tve_editor":"body"),e=[];t.on("click",".tve_scT > ul li",function(t){var i=ThriveGlobal.$j(this),e=i.parents(".tve_scT").first(),r=e.find("> .tve_scTC").eq(i.index()),a=e.find("> ul .tve_tS"),o=a.attr("data-tve-custom-colour"),n=i.attr("data-tve-custom-colour");i.attr("data-tve-custom-colour",void 0!==o&&!1!==o?o:""),a.attr("data-tve-custom-colour",void 0!==n&&!1!==n?n:""),e.find("> ul .tve_tS").removeClass("tve_tS"),e.find("> .tve_scTC").hide(),i.addClass("tve_tS"),r.show(),TCB_Front.postGridLayout(),r.find("iframe").not(".thrv_social_default iframe").each(function(){var t=ThriveGlobal.$j(this);t.attr("data-src")&&(t.attr("src",t.attr("data-src")),t.attr("data-src",""),t.removeClass("tcb-dr-done"))}),TCB_Front.changeAutoplayVideo(r),e.find("> .tve_scTC").each(function(t){if(t!==i.index()){var e=ThriveGlobal.$j(this);e.find("iframe").not(".thrv_social_default iframe").not(".tcb-dr-done").each(function(){var t=ThriveGlobal.$j(this);t.attr("src")&&(t.attr("data-src",t.attr("src")),t.attr("src",""),t.addClass("tcb-dr-done"))}),e.find("video").each(function(){ThriveGlobal.$j(this)[0].pause()})}})}),t.off("click.tvetoggleelem").on("click.tvetoggleelem",".tve_faqB",function(){var t=ThriveGlobal.$j(this).parents(".tve_faq"),e=ThriveGlobal.$j(this),i=ThriveGlobal.$j(e).siblings(".tve_faqC");i.is(":visible")?(i.find("iframe").not(".thrv_social_default iframe").each(function(){var t=ThriveGlobal.$j(this);t.attr("src")&&t.attr("data-src",t.attr("src")),t.attr("src","")}),i.find("video").each(function(){ThriveGlobal.$j(this)[0].pause()}),i.slideUp("fast",function(){i.trigger("lbresize")}),t.removeClass("tve_oFaq")):(i.find("iframe").not(".thrv_social_default iframe").each(function(){var t=ThriveGlobal.$j(this);t.attr("data-src")&&t.attr("src",t.attr("data-src"))}),i.slideDown("fast",function(){i.trigger("lbresize")}),TCB_Front.postGridLayout(),TCB_Front.changeAutoplayVideo(i),t.addClass("tve_oFaq"))}).on("click",".thrv_social_custom .tve_s_link",function(){var t=ThriveGlobal.$j(this).parents(".tve_s_item"),e=t.attr("data-s");TCB_Front.onSocialCustomClick[e]&&TCB_Front.onSocialCustomClick[e](t)}),t.on("mouseenter.menu",".tve_w_menu.tve_horizontal li",function(){var t=ThriveGlobal.$j(this);if(!t.closest(".thrive-shortcode-html").find(".tve-m-trigger").is(":visible")){if(t.addClass("expand-children"),t.parents(".tve-m-expanded").length)return!!tve_frontend_options.is_editor_page;t.parentsUntil(".tve_w_menu").filter("li").addClass("expand-children")}return!!tve_frontend_options.is_editor_page}).on("mouseleave.menu",".tve_w_menu.tve_horizontal li",function(){var t=ThriveGlobal.$j(this);if(!t.closest(".thrive-shortcode-html").find(".tve-m-trigger").is(":visible")){if(t.parents(".tve-m-expanded").length)return!!tve_frontend_options.is_editor_page;if(t.closest(".tve_w_menu > li").find(".edit_mode").length)return!!tve_frontend_options.is_editor_page;t.closest(".tve_w_menu > li").removeClass("expand-children").find(".expand-children").removeClass("expand-children")}return!!tve_frontend_options.is_editor_page}),ThriveGlobal.$j(document).on("click",function(t){0===ThriveGlobal.$j(t.target).closest(".thrv_widget_menu").length&&0===ThriveGlobal.$j(t.target).closest("#tcb-inner-actions").length&&ThriveGlobal.$j(".thrv_widget_menu").find(".tve-m-expanded").removeClass("tve-m-expanded").end().find(".tve-triggered-icon").removeClass("tve-triggered-icon").end().find(".tcb-icon-close").removeClass("tve-trigger-active").end().find(".tcb-icon-open").addClass("tve-trigger-active")});var r=!1;if(tve_frontend_options.is_editor_page&&(t.on("click",".tve_w_menu li a",function(t){var e=ThriveGlobal.$j(this),i=e.closest(".tve_w_menu");if(!r)return t.preventDefault(),t.stopPropagation(),0!==i.find(".active-expand-children").length&&(i.find(".active-expand-children").removeClass("active-expand-children"),e.closest(".tve_horizontal").find(".active-expand-children").removeClass("active-expand-children")),e.parent("li").parentsUntil(".tve_w_menu").filter("li").addClass("expand-children"),e.parent("li").toggleClass("active-expand-children"),(i.hasClass("tve_vertical")||e.closest(".thrive-shortcode-html").find(".tve-m-trigger").is(":visible"))&&e.parent("li").toggleClass("expand-children"),r=!0,ThriveGlobal.$j(this).trigger("click"),!1;r=!1}),TVE.add_filter("tcb.group.on_blur",function(t){t&&t.find(".expand-children").removeClass("expand-children")})),!tve_frontend_options.is_editor_page){function i(){ThriveGlobal.$j(".tve-m-trigger:visible").length?ThriveGlobal.$j(".tve-m-trigger").each(function(){var t=ThriveGlobal.$j(this).parent().find("> ul");if(!t.data("tve-colors-added")&&t.find("ul a").attr("data-tve-custom-colour")){var e=t.find("ul a").attr("data-tve-custom-colour");t.find("> li > a").each(function(){var t=ThriveGlobal.$j(this);t.attr("data-tve-custom-colour")&&(t.attr("data-o-color",t.attr("data-tve-custom-colour")),t.attr("data-tve-custom-colour",e))})}t.data("tve-colors-added",!0)}):(ThriveGlobal.$j(".tve-m-expanded").removeClass("tve-m-expanded"),ThriveGlobal.$j(".tve-m-trigger").each(function(){var t=ThriveGlobal.$j(this).parent().find("> ul");if(!t.data("tve-colors-added")&&t.find("> li > a").attr("data-o-color")){var e=t.find("> li > a"),i=e.attr("data-o-color");e.attr("data-tve-custom-colour",i).removeAttr("data-o-color")}t.data("tve-colors-added",!1)}))}t.on("click",".tve_w_menu li a",function(t){var e=ThriveGlobal.$j(this);if(e.attr("href"))return!0;t.preventDefault(),t.stopPropagation(),e.find(".tve-item-dropdown-trigger").trigger("click")}),t.on("click",".tve_w_menu li span.tve-item-dropdown-trigger",function(t){var e=ThriveGlobal.$j(this);return!e.closest(".thrive-shortcode-html").find(".tve-m-trigger").is(":visible")&&e.closest(".tve_w_menu").hasClass("tve_horizontal")||e.closest("li").toggleClass("expand-children"),!1}),t.on("click.custom_menu",".tve-m-trigger",function(){var t=ThriveGlobal.$j(this),e=t.parent().find("> ul");return t.parent().find(".tcb-icon-open, .tcb-icon-close").toggleClass("tve-trigger-active"),t.toggleClass("tve-triggered-icon"),e.toggleClass("tve-m-expanded"),!1}),t.on("click",".thrv_contents_table a",function(t){var e=ThriveGlobal.$j,i=e(e(this).attr("href"));i.length&&e("html, body").animate({scrollTop:i.offset().top-130})}),"undefined"!=typeof TVE_Event_Manager_Registered_Callbacks&&(TCB_Front.event_triggers(t),tve_frontend_options.page_events&&ThriveGlobal.$j.each(tve_frontend_options.page_events,function(t,r){TVE_Event_Manager_Registered_Callbacks[r.a]&&ThriveGlobal.$j(document).on("tve-page-event-"+r.t,function(t,e){var i=!0;return"timer"===r.t&&e&&r.config&&r.config.t_delay!==e&&(i=!1),!!i&&TVE_Event_Manager_Registered_Callbacks[r.a].call(document,r.t,r.a,r.config?r.config:{})})})),e.push(TCB_Front.postGridLayout),e.push(i),i()}function a(){ThriveGlobal.$j(".thrv_widget_menu").each(function(){var t,e=ThriveGlobal.$j(this),i=e.attr("data-tve-switch-icon");i||(i="tablet,mobile"),e.removeClass(function(t,e){return(e.match(/(^|\s)tve-custom-menu-switch-icon-\S+/g)||[]).join(" ")}),t=i.split(","),768()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(String(i).toLowerCase())&&(e=!1,o.add({input:t,error:a.email})),e},this.validate_textarea_field=function(t){var e=!0,i=t.value.trim();return n(t)&&i.length<=0&&(e=!1,o.add({input:t,error:a.required})),e},this.validate_tel_field=function(t){var e,i=!0,r=t.value.trim();return n(t)&&r.length<=0&&(i=!1,o.add({input:t,error:a.required})),i&&0>2,o=(3&e)<<4|(i=t.charCodeAt(c++))>>4,n=(15&i)<<2|(r=t.charCodeAt(c++))>>6,s=63&r,isNaN(i)?n=s=64:isNaN(r)&&(s=64),l=l+this._keyStr.charAt(a)+this._keyStr.charAt(o)+this._keyStr.charAt(n)+this._keyStr.charAt(s);return l},decode:function(t){var e,i,r,a,o,n,s="",l=0;for(t=t.replace(/[^A-Za-z0-9\+\/\=]/g,"");l>4,i=(15&a)<<4|(o=this._keyStr.indexOf(t.charAt(l++)))>>2,r=(3&o)<<6|(n=this._keyStr.indexOf(t.charAt(l++))),s+=String.fromCharCode(e),64!=o&&(s+=String.fromCharCode(i)),64!=n&&(s+=String.fromCharCode(r));return s=this._utf8_decode(s)},_utf8_encode:function(t){t=t.replace(/\r\n/g,"\n");for(var e="",i=0;i>6|192):(e+=String.fromCharCode(r>>12|224),e+=String.fromCharCode(r>>6&63|128)),e+=String.fromCharCode(63&r|128))}return e},_utf8_decode:function(t){for(var e="",i=0,r=0,a=0,o=0;i'+this.cursorChar+""),this.el.after(this.cursor)),this.stringsElement){i.strings=[],this.stringsElement.hide();var t=this.stringsElement.find("p");l.each(t,function(t,e){i.strings.push(l(e).html())})}this.init()},typewrite:function(o,n){if(!0!==this.stop){var t=this.typeSpeed,s=this;l(this.el);s.timeout=setTimeout(function(){var t=0,e=o.substr(n);if("^"===e.charAt(0)){var i=1;/^\^\d+/.test(e)&&(i+=(e=/\d+/.exec(e)[0]).length,t=parseInt(e)),o=o.substring(0,n)+o.substring(n+i)}if("html"===s.contentType){var r=o.substr(n).charAt(0);if("<"===r||"&"===r){var a="";for(a="<"===r?">":";";o.substr(n).charAt(0)!==a;)o.substr(n).charAt(0),n++;n++,a}}s.timeout=setTimeout(function(){if(n===o.length){if(s.options.onStringTyped(s.arrayPos),s.arrayPos===s.strings.length-1&&(s.options.callback(),s.curLoop++,!1===s.loop||s.curLoop===s.loopCount))return;s.timeout=setTimeout(function(){s.options.highlightClass?s.highlight(o,n):s.backspace(o,n)},s.backDelay)}else{0===n&&s.options.preStringTyped(s.arrayPos);var t=o.substr(0,n+1);s.attr?s.el.attr(s.attr,t):s.isInput?s.el.val(t):"html"===s.contentType?s.el.html(t):s.el.text(t),n++,s.typewrite(o,n)}},t)},t)}},highlight:function(i,r){if(!0!==this.stop){var t=this.backSpeed,a=this;l(a.el),l("");a.timeout=setTimeout(function(){if("html"===a.contentType&&">"===i.substr(r).charAt(0)){for(;"<"!==i.substr(r).charAt(0);)i.substr(r).charAt(0),r--;r--,"<"}var t=i.substr(0,r),e=i.substr(r);a.attr?a.el.attr(a.attr,t):a.el.html(t+''+e+""),r>a.stopNum?(r--,a.highlight(i,r)):r<=a.stopNum&&setTimeout(function(){a.arrayPos++,a.arrayPos===a.strings.length?(a.arrayPos=0,a.init("write")):a.typewrite(a.strings[a.sequence[a.arrayPos]],r)},200)},t)}},backspace:function(e,i){if(!0!==this.stop){var t=this.backSpeed,r=this,a=l(r.el);r.timeout=setTimeout(function(){if("html"===r.contentType&&">"===e.substr(i).charAt(0)){for(;"<"!==e.substr(i).charAt(0);)e.substr(i).charAt(0),i--;i--,"<"}var t=e.substr(0,i);r.attr?r.el.attr(r.attr,t):r.isInput?r.el.val(t):"html"===r.contentType?r.el.html(t):r.el.text(t),i>r.stopNum?(i--,r.backspace(e,i)):i<=r.stopNum&&(r.arrayPos++,r.arrayPos===r.strings.length?(r.arrayPos=0,r.shuffle&&(r.sequence=r.shuffleArray(r.sequence)),r.init("write")):r.typewrite(r.strings[r.sequence[r.arrayPos]],i),r.options.highlightClass&&a.is("."+r.options.highlightClass)&&a.removeClass(r.options.highlightClass))},t)}},shuffleArray:function(t){var e,i,r=t.length;if(r)for(;--r;)e=t[i=Math.floor(Math.random()*(r+1))],t[i]=t[r],t[r]=e;return t},pause:function(){this.stop=!0,clearInterval(this.timeout)},start:function(){!1!==this.stop&&(this.stop=!1,this.init())},reset:function(){clearInterval(this.timeout);var t=this.el.attr("id");this.el.after(''),this.el.remove(),void 0!==this.cursor&&this.cursor.remove(),this.options.resetCallback()}},l.fn.typed=function(r){return this.each(function(){var t=l(this),e=t.data("typed"),i="object"==typeof r&&r;e||t.data("typed",e=new a(this,i)),"string"==typeof r&&e[r]()})},l.fn.typed.defaults={strings:["These are the default values...","You know what you should do?","Use your own!","Have a great day!"],stringsElement:null,typeSpeed:0,startDelay:0,backSpeed:0,shuffle:!1,backDelay:500,loop:!1,loopCount:!1,showCursor:!0,cursorChar:"|",attr:null,contentType:"html",callback:function(){},preStringTyped:function(){},onStringTyped:function(){},resetCallback:function(){}}}(window.jQuery); var TL_Front=TL_Front||{},ThriveGlobal=ThriveGlobal||{$j:jQuery.noConflict()};TL_Front.add_page_css=function(a){ThriveGlobal.$j.each(a,function(a,b){a+="-css",b=b.replace(/^http(s)?:\/\//,"//"),ThriveGlobal.$j("#"+a).length||ThriveGlobal.$j('link[href="http:'+b+'"]').length||ThriveGlobal.$j('link[href="https:'+b+'"]').length||ThriveGlobal.$j('').prependTo("head")})},TL_Front.document_write=function(a){ThriveGlobal.$j("body").append(a)},TL_Front.add_head_script=function(a,b,c){var d=document.createElement("script"),e=ThriveGlobal.$j("head")[0];d.async=!0,"function"==typeof c&&(d.onload=d.onreadystatechange=c),void 0!==b&&(d.id=b),d.src=a,e.insertBefore(d,e.firstChild)},TL_Front.add_page_js=function(a,b){function c(){if(0===d)return void b();setTimeout(c,50)}"function"!=typeof b&&(b=function(){});var d=0;ThriveGlobal.$j.each(a,function(a,b){if("tve_frontend"===a&&"undefined"!=typeof TCB_Front)return!0;if(a+="-js",b&&!ThriveGlobal.$j("#"+a).length&&!ThriveGlobal.$j('script[src="'+b+'"]').length){if(d++,-1!==b.indexOf("connect.facebook.net"))return TL_Front.add_head_script(b,a,function(){d--}),!0;ThriveGlobal.$j.getScript(b,function(){d--})}}),c()},TL_Front.do_impression=function(){var a=TL_Front.impressions_data;if(void 0===a)return void console.log("No form to register impression for !");var b={security:TL_Const.security,action:TL_Const.action_impression,tl_data:a,current_screen:TL_Const.current_screen};ThriveGlobal.$j.each(TL_Const.custom_post_data,function(a,c){b[a]=c}),window.TVE_Dash&&!TVE_Dash.ajax_sent?TVE_Dash.add_load_item("tl_impression",b):ThriveGlobal.$j.post(TL_Const.ajax_url,b)},ThriveGlobal.$j(function(){function a(){var a,b,c=-1;return"Microsoft Internet Explorer"==navigator.appName?(a=navigator.userAgent,b=new RegExp("MSIE ([0-9]{1,}[\\.0-9]{0,})"),null!==b.exec(a)&&(c=parseFloat(RegExp.$1))):"Netscape"==navigator.appName&&(a=navigator.userAgent,b=new RegExp("Trident/.*rv:([0-9]{1,}[\\.0-9]{0,})"),null!==b.exec(a)&&(c=parseFloat(RegExp.$1))),c}function b(){function a(a){if(a.find('[data-validation="email"]').length)return a.find('[data-validation="email"]').val();var b="";return a.find("input").each(function(){if(this.name&&this.name.match(/email/i))return b=this.value,!1}),b}if(!TL_Const.forms)return!1;ThriveGlobal.$j("body").on("submit",".tve-leads-conversion-object form",function(b){var c=ThriveGlobal.$j(this),d=c.parents(".tve-leads-conversion-object").first().attr("data-tl-type"),e={};if(c.data("tve-force-submit")||c.data("tl-do-submit")||!d||!TL_Const.forms[d])return!0;c.tve_form_loading(),c.find("input").each(function(){var a=ThriveGlobal.$j(this),b=a.attr("name");void 0!==b&&-1===TL_Const.ignored_fields.indexOf(b)&&(e[a.attr("name")]=a.val())});var f={security:TL_Const.security,action:TL_Const.action_conversion,type:d,tl_data:TL_Const.forms[d],custom_fields:e,email:a(c),current_screen:TL_Const.current_screen};return ThriveGlobal.$j.each(TL_Const.custom_post_data,function(a,b){f[a]=b}),ThriveGlobal.$j.ajax({url:TL_Const.ajax_url,data:f,type:"post",xhrFields:{withCredentials:!0}}).always(function(){void 0===c.attr("action")?location.reload():c.data("tve-force-submit",!0).submit()}),!1}),ThriveGlobal.$j("body").on("form_conversion.tcb",".tve-leads-conversion-object form",function(a){var b=ThriveGlobal.$j(this),c=b.parents(".tve-leads-conversion-object").first().attr("data-tl-type");if(!c||!TL_Const.hasOwnProperty("forms")||!TL_Const.forms[c])return!0;var d={type:c,tl_data:TL_Const.forms[c],current_screen:TL_Const.current_screen};ThriveGlobal.$j.each(TL_Const.custom_post_data,function(a,b){d[a]=b}),a.post_data=a.post_data||{},a.post_data.thrive_leads=d}).on("lead_conversion_success.tcb",".tve_lead_lock_shortcode form",function(a){var b=ThriveGlobal.$j(this),c=b.parents(".tve_content_lock");c.removeClass("tve_lead_lock").find(".tve_lead_lock_shortcode").remove(),c.find(".tve_lead_locked_overlay").remove(),a.content_unlocked=!0}).on("leads_states.tcb",".tve-leads-conversion-object form",function(a,b){var c=ThriveGlobal.$j(this);switch(c.find("#_form_type").val()){case"ribbon":var d=c.parents(".tve-leads-ribbon");c.parents(".tve_shortcode_editor").empty().html(b),TL_Front.open_ribbon(d);break;case"lightbox":case"tve_lead_2s_lightbox":c.parents(".tve_p_lb_control").empty().html(b);break;case"widget":case"in-content":case"post-footer":case"php-insert":c.parents(".tve_shortcode_editor").empty().html(b);break;case"slide-in":var e=c.parents(".tve-leads-slide-in");c.parents(".tve_shortcode_editor").empty().html(b),TL_Front.open_slide_in(e);break;case"screen-filler-lightbox":var f=c.parents(".tve-leads-screen-filler");c.parents(".tve_shortcode_editor").empty().html(b),TL_Front.open_screen_filler(f);break;case"scroll-mat":var d=c.parents(".tve-leads-greedy_ribbon");c.parents(".tve_shortcode_editor").empty().html(b),TL_Front.open_ribbon(d);break;case"tve_lead_shortcode":c.parents(".tve-leads-shortcode").empty().html(b);break;case"lead_generation":default:a.change_states=!1}a.change_states=!0}).on("leads_messages.tcb",".tve-leads-conversion-object form",function(a){var b=ThriveGlobal.$j(this);switch(b.find("#_form_type").val()){case"tve_lead_shortcode":a.lightbox_state&&b.parents(".tve-leads-shortcode").hide();break;case"ribbon":b.parents(".thrv-ribbon").find(".tve-ribbon-close").click();break;case"lightbox":case"tve_lead_2s_lightbox":b.parents(".tve_p_lb_content").find(".tve_p_lb_close").click(),b.parents(".tve-leads-screen-filler").find(".tve-screen-filler-close").click();break;case"slide-in":b.parents(".thrv-leads-slide-in").find(".tve-leads-close").click();break;case"screen-filler-lightbox":b.parents(".tve-leads-screen-filler").find(".tve-screen-filler-close").click();break;case"scroll-mat":b.parents(".thrv-greedy-ribbon").find(".tve_et_click").click();break;case"widget":case"in-content":case"post-footer":case"php-insert":default:b.find("input:not(:hidden)").val("")}b.parents(".tve-leads-conversion-object").find(".tve_ea_thrive_leads_form_close").click(),TL_Front.parent_state&&TL_Front.close_form(TL_Front.parent_state)})}if("undefined"!=typeof TL_Const){if(ThriveGlobal.$j(".tve-leads-screen-filler iframe, .tve-leads-ribbon iframe").not(".thrv_social_default iframe").not(".tcb-dr-done").each(function(){var a=ThriveGlobal.$j(this).addClass("tcb-dr-done");a.attr("src")&&a.attr("data-src",a.attr("src")),a.attr("src","")}),"undefined"!=typeof TCB_Front&&ThriveGlobal.$j(TCB_Front).on("content_loaded.thrive",function(a,b){b.find(".tve-tl-anim").each(function(){var a=ThriveGlobal.$j(this);ThriveGlobal.$j(TL_Front).trigger("showform.thriveleads",{$target:a})})}),ThriveGlobal.$j(TL_Front).on("showform.thriveleads",function(a,b){var c,d=b.$target?b.$target:ThriveGlobal.$j("."+b.form_id);d.length&&(b.first&&(d=d.first()),d.attr("data-s-state")&&(d=d.closest(".tl-states-root").find('[data-state="'+d.attr("data-s-state")+'"] .tl-lb-target')),c=d.hasClass("tve-tl-anim")?d:d.find(".tve-tl-anim"),d.css("display",""),setTimeout(function(){c.addClass("tve-leads-triggered"),TL_Front.handle_typefocus(c,"start"),TCB_Front.postGridLayout()},0),"function"==typeof TL_Front["open_"+b.form_type]?TL_Front["open_"+b.form_type](d,b.TargetEvent):d.show(),setTimeout(function(){d.find(".thrv_responsive_video iframe, .thrv_custom_html_shortcode iframe").each(function(){var a=ThriveGlobal.$j(this);a.attr("data-src")&&a.attr("src",a.attr("data-src"))})},200))}),ThriveGlobal.$j("body").on("click",".tve-ribbon-close",function(){var a=ThriveGlobal.$j(this).closest(".tve-leads-ribbon"),b=a.data("position");a.find(".thrv_responsive_video iframe, .thrv_custom_html_shortcode iframe, .thrv_responsive_video video").each(function(){var a=ThriveGlobal.$j(this);a.attr("data-src",a.attr("src")),a.attr("src","")}),a.removeClass("tve-leads-triggered"),"top"===b?ThriveGlobal.$j("body").animate({marginTop:0},200,function(){document.body.style.removeProperty("margin-top")}):"bottom"===b&&ThriveGlobal.$j("body").animate({marginBottom:"0px"},200,function(){document.body.style.removeProperty("margin-bottom")}),TL_Front.handle_typefocus(a,"pause"),setTimeout(function(){a.css(b,"")},400),ThriveGlobal.$j("#tve-lg-error-container").hide()}),TL_Const.ajax_load||TL_Front.do_impression(),TL_Front.ajax_load_callback=function(d){function e(a){var b=a.replace("two_step_","");ThriveGlobal.$j(".tl-2step-trigger-"+b).show()}function f(){if(!c)return void setTimeout(f,50);TCB_Front.event_triggers(ThriveGlobal.$j("body")),TCB_Front.onDOMReady(),b(),ThriveGlobal.$j(TCB_Front).trigger("tl-ajax-loaded")}if(d&&d.res&&d.js&&d.html){if(TL_Front.add_page_css(d.res.css),TL_Front.add_page_css(d.res.fonts),d.html&&(d.html.widget||ThriveGlobal.$j(".tl-widget-container").remove(),ThriveGlobal.$j.each(d.html,function(a,b){if(!b)return!0;if("in_content"===a){var c="after",f=ThriveGlobal.$j(".tve-tl-cnt-wrap"),g=f.find("p").filter(":visible");0===g.length&&0==d.in_content_pos?ThriveGlobal.$j(".tve-tl-cnt-wrap").prepend(b):(0==d.in_content_pos&&(d.in_content_pos=1,c="before"),g.eq(parseInt(d.in_content_pos)-1)[c](b))}else{var h=ThriveGlobal.$j(".tl-placeholder-f-type-"+a);if(d.js[a]&&d.js[a].content_locking){var i=h.parents(".tve_content_lock").first();if(d.js[a].has_conversion)return i.removeClass("tve_lock_hide"),!0;"tve_lock_blur"==d.js[a].lock&&i.removeClass("tve_lock_hide").addClass(d.js[a].lock)}h.replaceWith(b),"widget"===a&&ThriveGlobal.$j(".tl-widget-container").children().unwrap(),0===a.indexOf("two_step")&&e(a)}}),a()>0&&setTimeout(function(){var a="";ThriveGlobal.$j("body style.tve_custom_style").each(function(){a=this.innerText,this.innerText=a})})),d.body_end){var g=ThriveGlobal.$j(d.body_end);g.find(".tve_wistia_popover").each(function(){ThriveGlobal.$j("#"+this.id).length&&this.parentNode.removeChild(this)}),g.filter("link[href]").each(function(){ThriveGlobal.$j('link[href="'+this.getAttribute("href")+'"]').length&&(g=g.not(this))}),g.filter("script[src]").each(function(){ThriveGlobal.$j('script[src="'+this.getAttribute("src")+'"]').length&&(g=g.not(this))});try{ThriveGlobal.$j("body").append(g)}catch(a){console.log("Body append: "+a)}}void 0!==d.js.TVO_Form&&(TVO_Form=d.js.TVO_Form),TL_Front.add_page_js(d.res.js,function(){c=!0}),setTimeout(f,50),TL_Const.forms=d.js}},TL_Const.ajax_load){var c=!1,d=(ThriveGlobal.$j(".tve-leads-two-step-trigger").hide(),{tcb_js:"undefined"!=typeof TCB_Front?1:0,main_group_id:TL_Const.main_group_id,shortcode_ids:TL_Const.shortcode_ids,two_step_ids:TL_Const.two_step_ids,action:"tve_leads_ajax_load_forms",security:TL_Const.security,display_options:TL_Const.display_options,current_screen:TL_Const.current_screen});return ThriveGlobal.$j.each(TL_Const.custom_post_data,function(a,b){d[a]=b}),void(window.TVE_Dash&&!TVE_Dash.ajax_sent?ThriveGlobal.$j(document).on("tve-dash.load",function(a){TVE_Dash.add_load_item("tl_lazy_load",d,TL_Front.ajax_load_callback)}):ThriveGlobal.$j.ajax({url:TL_Const.ajax_url,type:"post",dataType:"json",data:d,xhrFields:{withCredentials:!0}}).done(TL_Front.ajax_load_callback))}b()}}),TL_Front.switch_lightbox_state=function(a,b){return a.find(".tve_p_lb_overlay").css("opacity","0.8"),a.find(".tve_p_lb_content").css("top",b.find(".tve_p_lb_content").css("top")).addClass("tve-leads-triggered"),window.tve_lb_switch_state=!0,TL_Front.open_lightbox(a.find(".tl-lb-target"))},TL_Front.close_lightbox=function(){var a=ThriveGlobal.$j("body"),b=ThriveGlobal.$j("html"),c=arguments[0]||a.data("tl-open-lightbox");c&&c.length&&(c.find(".tve-tl-anim").removeClass("tve-leads-triggered"),window.tve_lb_switch_state||(1===ThriveGlobal.$j(".tve_lb_open").length&&(a.removeClass("tve-o-hidden tve-l-open tve-hide-overflow").css("padding-right",""),b.removeClass("tve-o-hidden tve-l-open tve-hide-overflow"),c.data("doc-scroll-top")?(document.documentElement.scrollTop=c.data("doc-scroll-top"),c.data("doc-scroll-top","")):c.data("bdy-scroll-top")&&(document.body.scrollTop=c.data("bdy-scroll-top"),c.data("bdy-scroll-top",""))),b.removeClass(b.data("tl-anim-class"))),window.tve_lb_switch_state=!1,setTimeout(function(){c.addClass("tve_lb_closing"),c.removeClass("tve_lb_open tve_lb_opening tve_lb_closing tve_p_lb_background").css({visibility:"hidden",position:"fixed",left:"-9000px"}).find("tve_p_lb_content").trigger("tve.lightbox-close")},200),c.find(".thrv_responsive_video iframe, .thrv_custom_html_shortcode iframe, .thrv_responsive_video video").each(function(){var a=ThriveGlobal.$j(this);a.attr("data-src",a.attr("src")),a.attr("src","")}),TL_Front.handle_typefocus(c,"pause"),ThriveGlobal.$j("#tve-lg-error-container").hide())},TL_Front.open_lightbox=function(a,b){var c=window.tve_lb_switch_state;ThriveGlobal.$j.fn.thrive_iphone_placeholder&&a.find("input[placeholder]").thrive_iphone_placeholder(),TL_Front.close_lightbox(ThriveGlobal.$j(".tve_p_lb_background.tve_lb_open")),a.css({visibility:"",position:"",left:"",display:""}).parents(".tl-style").css({visibility:"",position:"",left:"",display:""});var d=ThriveGlobal.$j("body"),e=ThriveGlobal.$j("html"),f=function(){var a=ThriveGlobal.$j,b={border:"none",height:"200px",margin:"0",padding:"0",width:"200px"},c=a("
").css(a.extend({},b)),d=a("
").css(a.extend({left:"-1000px",overflow:"scroll",position:"absolute",top:"-1000px"},b)).append(c).appendTo("body").scrollLeft(1e3).scrollTop(1e3),e={height:d.offset().top-c.offset().top||0,width:d.offset().left-c.offset().left||0};return d.remove(),e}().width,g=parseInt(d.css("paddingRight")),h=ThriveGlobal.$j(".tve_p_lb_background.tve_lb_open").length;isNaN(g)&&(g=0),a.find(".tve_p_lb_close").off().on("click",function(){return TL_Front.close_lightbox(),!1}),d.off("keyup.tve_lb_close").on("keyup.tve_lb_close",function(a){if(27==a.which)return TL_Front.close_lightbox(),!1}),a.find(".tve_p_lb_overlay").off("click.tve_lb_close").on("click.tve_lb_close",function(){return TL_Front.close_lightbox(),!1}),d.data("tl-open-lightbox",a),a.addClass("tve_p_lb_background"),a.data("doc-scroll-top",document.documentElement.scrollTop),a.data("bdy-scroll-top",document.body.scrollTop),d.addClass("tve-o-hidden tve-l-open tve-hide-overflow"),e.addClass("tve-o-hidden tve-l-open tve-hide-overflow");var i=ThriveGlobal.$j(window).height(),j=id&&a.addClass("tve-scroll")}setTimeout(function(){a.addClass("tve_lb_opening")},0),a.find("iframe").not(".thrv_social_default iframe").each(function(){var a=ThriveGlobal.$j(this);!a.data("tve_ifr_loaded")&&a.attr("data-src")&&a.data("tve_ifr_loaded",1).attr("src",a.attr("data-src"))}),b(),ThriveGlobal.$j(window).on("resize",b)},20),setTimeout(function(){a.removeClass("tve_lb_opening").addClass("tve_lb_open").find(".tve_p_lb_content").trigger("tve.lightbox-open"),ThriveGlobal.$j(window).trigger("scroll")},300),b&&b.preventDefault&&(b.preventDefault(),b.stopPropagation()),a.parents(".tl-states-root").off("switchstate").on("switchstate",function(a,b){var c=Array.prototype.slice.call(arguments,1);TL_Front.switch_lightbox_state.apply(TL_Front,c)})},TL_Front.open_two_step_lightbox=TL_Front.open_lightbox,TL_Front.open_ribbon=function(a){function b(){a.addClass("tve-leads-triggered");var b=a.attr("data-position")||"top";"top"===b?a.css("top",ThriveGlobal.$j("#wpadminbar").length?"32px":"0px"):"bottom"===b&&(a.css("bottom","0px"),a.css("top","auto"));var c=0,d=a.outerHeight(),e=setInterval(function(){c++;var f=a.outerHeight();f==d&&10!=c||clearInterval(e),"top"===b?ThriveGlobal.$j("body").animate({"margin-top":f+"px"},200,function(){document.body.style.setProperty("margin-top",f+"px","important")}):"bottom"===b&&ThriveGlobal.$j("body").animate({"margin-bottom":f+"px"},200)},100);a.off("switchstate").on("switchstate",function(a,b){var c=Array.prototype.slice.call(arguments,1);TL_Front.switch_ribbon_state.apply(TL_Front,c)})}TL_Const.forms.greedy_ribbon?(TL_Const.close_callbacks=TL_Const.close_callbacks||{},TL_Const.close_callbacks.greedy_ribbon=[b]):b()},TL_Front.switch_ribbon_state=function(a){var b=a.outerHeight(!0),c="top"===a.parent().attr("data-position")?"margin-top":"margin-bottom",d={};d[c]=b+"px",ThriveGlobal.$j("body").animate(d,200)},TL_Front.open_greedy_ribbon=function(a){var b=ThriveGlobal.$j("body"),c=ThriveGlobal.$j(window),d=b.css("position");c.scrollTop(0),b.css("position","static"),b.addClass("tve-tl-gr-anim"),a.css("top",ThriveGlobal.$j("#wpadminbar").length?"32px":"0px");var e=a.outerHeight();b[0].style.setProperty("margin-top",e+"px","important");var f=1;setTimeout(function(){ThriveGlobal.$j('.tve-leads-ribbon[data-position="top"]').removeClass("tve-leads-triggered")},50),c.scroll(function(){var g=b.hasClass("tve-tl-gr-anim");if(1===f&&g){var h=c.scrollTop();if(h>e){(a.find(".tve_ea_thrive_wistia").length||a.find(".tve_with_wistia_popover"))&&ThriveGlobal.$j(".wistia_placebo_close_button").trigger("click"),b.removeClass("tve-tl-gr-anim"),a.addClass("tve-no-animation");var i=h-e;a.removeClass("tve-leads-triggered"),a.find(".thrv_responsive_video iframe, .thrv_custom_html_shortcode iframe, .thrv_responsive_video video").each(function(){var a=ThriveGlobal.$j(this);a.attr("data-src",a.attr("src")),a.attr("src","")}),b.css("margin-top",""),b.css("position",d),c.scrollTop(i),a.removeClass("tve-no-animation"),f=0,TL_Front.form_closed("greedy_ribbon"),TL_Const.forms.greedy_ribbon.allow_callbacks=!1}}}),a.off("switchstate").on("switchstate",function(a,b){})},TL_Front.open_screen_filler=function(a,b){function c(a){a.find(".thrv_responsive_video iframe, .thrv_custom_html_shortcode iframe, .thrv_responsive_video video").each(function(){var a=ThriveGlobal.$j(this);a.attr("data-src",a.attr("src")),a.attr("src","")}),a.removeClass("tve-leads-triggered"),TL_Front.handle_typefocus(a,"pause"),ThriveGlobal.$j(document).off("keyup.close-screenfiller"),0==ThriveGlobal.$j.find(".tve-leads-ribbon").length&&ThriveGlobal.$j("body").animate({"margin-top":"0px"},200),e.removeClass(d),f.removeClass(f.data("tl-s-anim-class")),setTimeout(function(){a.css("top","").hide()},400),a.data("doc-scroll-top")?(document.documentElement.scrollTop=a.data("doc-scroll-top"),a.data("doc-scroll-top","")):a.data("bdy-scroll-top")&&(document.body.scrollTop=a.data("bdy-scroll-top"),a.data("bdy-scroll-top","")),ThriveGlobal.$j("#tve-lg-error-container").hide()}var d="tve-so-hidden tve-sl-open tve-s-hide-overflow",e=ThriveGlobal.$j("html,body"),f=ThriveGlobal.$j("html");if(ThriveGlobal.$j.fn.thrive_iphone_placeholder&&a.find("input[placeholder]").thrive_iphone_placeholder(),a.css("top",ThriveGlobal.$j("#wpadminbar").length?"32px":"0px").css("visibility",""),!0===a.hasClass("stl-anim-slip_from_top")){var g=ThriveGlobal.$j(window).scrollTop();a.css("top",g).css("visibility","")}a.find(".tve-screen-filler-close").on("click",function(){c(a)}),a.data("doc-scroll-top",document.documentElement.scrollTop),a.data("bdy-scroll-top",document.body.scrollTop),e.addClass(d);var h="";ThriveGlobal.$j.each(a.attr("class").split(" "),function(a,b){if(0===b.indexOf("stl-anim"))return h=b,!1}),f.addClass(h).data("tl-s-anim-class",h),TL_Front.close_screen_filler=c,b&&b.preventDefault&&(b.preventDefault(),b.stopPropagation()),ThriveGlobal.$j(document).off("keyup.close-screenfiller").on("keyup.close-screenfiller",function(b){27==b.which&&c(a)}),a.find(".thrv_responsive_video iframe, .thrv_custom_html_shortcode iframe, .thrv_responsive_video video").each(function(){var a=jQuery(this);a.attr("data-src")&&a.attr("src",a.attr("data-src"))})},TL_Front.switch_slide_in_state=function(a){TL_Front.slide_in_position(a.find(".thrv-leads-slide-in"))},TL_Front.slide_in_position=function(a){var b=ThriveGlobal.$j(window),c=a.outerHeight();if(b.width()<=782||b.height()d&&a.parents(".tve-leads-slide-in").css("overflow-y","scroll")},0)}},TL_Front.open_slide_in=function(a,b){function c(b){b.removeClass("tve-leads-triggered"),TL_Front.handle_typefocus(b,"pause"),ThriveGlobal.$j(document).off("keyup.close-slidein"),e.removeClass(d),f.removeClass(d),b.find(".thrv_responsive_video iframe, .thrv_custom_html_shortcode iframe, .thrv_responsive_video video").each(function(){var a=ThriveGlobal.$j(this);a.attr("data-src",a.attr("src")),a.attr("src","")}),ThriveGlobal.$j("#tve-lg-error-container").hide(),a.data("doc-scroll-top")?(document.documentElement.scrollTop=a.data("doc-scroll-top"),a.data("doc-scroll-top","")):a.data("bdy-scroll-top")&&(document.body.scrollTop=a.data("bdy-scroll-top"),a.data("bdy-scroll-top",""))}var d="tve-o-hidden tve-l-open tve-hide-overflow",e=ThriveGlobal.$j("body"),f=ThriveGlobal.$j("html");ThriveGlobal.$j.fn.thrive_iphone_placeholder&&a.find("input[placeholder]").thrive_iphone_placeholder(),TL_Front.slide_in_position(a.find(".thrv-leads-slide-in").filter(":visible")),a.off().on("click",".tve-leads-close",function(){c(a)}),a.find(".tve_ea_thrive_leads_form_close").on("click",function(){c(a)}),a.on("switchstate",function(a,b){var c=Array.prototype.slice.call(arguments,1);TL_Front.switch_slide_in_state.apply(TL_Front,c)}),ThriveGlobal.$j(document).off("keyup.close-slidein").on("keyup.close-slidein",function(b){27==b.which&&c(a)}),b&&b.preventDefault&&(b.preventDefault(),b.stopPropagation())},TL_Front.close_form=function(a,b,c,d){var e=ThriveGlobal.$j(a),f=e.parents(".tve-leads-triggered"),g=f.attr("data-tl-type");if(void 0===g&&f.hasClass("tve-leads-widget"))g="widget";else if(void 0===g&&f.hasClass("tve-leads-post-footer"))g="post-footer";else if(void 0===g&&f.hasClass("tve-leads-slide-in"))g="slide-in";else if(void 0===g&&f.hasClass("tve-leads-in-content"))g="in-content";else if(void 0===g&&f.hasClass("tve-leads-shortcode"))g="shortcode";else if(void 0===g&&f.hasClass("tve-leads-greedy_ribbon"))g="greedy_ribbon";else{if(void 0===g&&f.hasClass("tve_p_lb_content"))return TL_Front.close_lightbox(),!1;if(void 0===g&&f.hasClass("tve-leads-screen-filler"))return TL_Front.close_screen_filler(f),!1}switch(f.removeClass("tve-leads-triggered"),TL_Front.handle_typefocus(f,"pause"),g){case"ribbon":var h=f.find(".tve-ribbon-close");h.length||(h=jQuery('').appendTo(f)),h.trigger("click");break;case"slide-in":f.find(".tve-leads-close").trigger("click"),f.find(".thrv_responsive_video iframe, .thrv_custom_html_shortcode iframe, .thrv_responsive_video video").each(function(){var a=ThriveGlobal.$j(this);a.attr("data-src",a.attr("src")),a.attr("src","")});break;case"post-footer":case"in-content":case"shortcode":f.fadeOut(200,function(){TL_Front.form_closed(g)});break;case"widget":f.parent().slideUp(200);break;case"greedy_ribbon":var i=ThriveGlobal.$j("body"),j=ThriveGlobal.$j(window),k=i.css("margin-top");i[0].style.removeProperty("margin-top"),f.find(".thrv_responsive_video iframe, .thrv_custom_html_shortcode iframe, .thrv_responsive_video video").each(function(){var a=ThriveGlobal.$j(this);a.attr("data-src",a.attr("src")),a.attr("src","")}),i.css("margin-top",k),j.scrollTop(0),i.animate({"margin-top":"0px"},300,"linear",function(){TL_Front.form_closed(g)}).removeClass("tve-tl-gr-anim")}},TL_Front.form_closed=function(a){TL_Const.close_callbacks&&TL_Const.close_callbacks[a]&&ThriveGlobal.$j.each(TL_Const.close_callbacks[a],function(a,b){ThriveGlobal.$j.isFunction(b)&&b()})},TL_Front.handle_typefocus=function(a,b){a.find(".tve_typefocus").each(function(){jQuery(this).attr("data-typefocus",b)})}; !function (a){ function b(){ } function c(a){ function c(b){ b.prototype.option||(b.prototype.option=function (b){ a.isPlainObject(b)&&(this.options=a.extend(!0, this.options, b)) }) } function e(b, c){ a.fn[b]=function (e){ if("string"==typeof e){ for (var g=d.call(arguments, 1), h=0, i=this.length; i > h; h++){ var j=this[h], k=a.data(j, b); if(k)if(a.isFunction(k[e])&&"_"!==e.charAt(0)){ var l=k[e].apply(k, g); if(void 0!==l)return l } else f("no such method '" + e + "' for " + b + " instance"); else f("cannot call methods on " + b + " prior to initialization; attempted to call '" + e + "'") } return this } return this.each(function (){ var d=a.data(this, b); d ? (d.option(e), d._init()):(d=new c(this, e), a.data(this, b, d)) }) }} if(a){ var f="undefined"==typeof console ? b:function (a){ console.error(a) }; return a.bridget=function (a, b){ c(b), e(a, b) }, a.bridget }} var d=Array.prototype.slice; "function"==typeof define&&define.amd ? define("jquery-bridget/jquery.bridget", ["jquery"], c):c(a.jQuery) }(window), function (a){ function b(b){ var c=a.event; return c.target=c.target||c.srcElement||b, c } var c=document.documentElement, d=function (){ }; c.addEventListener ? d=function (a, b, c){ a.addEventListener(b, c, !1) }:c.attachEvent&&(d=function (a, c, d){ a[c + d]=d.handleEvent ? function (){ var c=b(a); d.handleEvent.call(d, c) }:function (){ var c=b(a); d.call(a, c) }, a.attachEvent("on" + c, a[c + d]) }); var e=function (){ }; c.removeEventListener ? e=function (a, b, c){ a.removeEventListener(b, c, !1) }:c.detachEvent&&(e=function (a, b, c){ a.detachEvent("on" + b, a[b + c]); try { delete a[b + c] } catch (d){ a[b + c]=void 0 }}); var f={bind: d, unbind: e}; "function"==typeof define&&define.amd ? define("eventie/eventie", f):"object"==typeof exports ? module.exports=f:a.eventie=f }(this), function (a){ function b(a){ "function"==typeof a&&(b.isReady ? a():f.push(a)) } function c(a){ var c="readystatechange"===a.type&&"complete"!==e.readyState; if(!b.isReady&&!c){ b.isReady = !0; for (var d=0, g=f.length; g > d; d++){ var h=f[d]; h() }} } function d(d){ return d.bind(e, "DOMContentLoaded", c), d.bind(e, "readystatechange", c), d.bind(a, "load", c), b } var e=a.document, f=[]; b.isReady = !1, "function"==typeof define&&define.amd ? (b.isReady="function"==typeof requirejs, define("doc-ready/doc-ready", ["eventie/eventie"], d)):a.docReady=d(a.eventie) }(this), function (){ function a(){ } function b(a, b){ for (var c=a.length; c--;)if(a[c].listener===b)return c; return -1 } function c(a){ return function (){ return this[a].apply(this, arguments) }} var d=a.prototype, e=this, f=e.EventEmitter; d.getListeners=function (a){ var b, c, d=this._getEvents(); if(a instanceof RegExp){ b={}; for (c in d)d.hasOwnProperty(c)&&a.test(c)&&(b[c]=d[c]) } else b=d[a]||(d[a]=[]); return b }, d.flattenListeners=function (a){ var b, c=[]; for (b=0; b < a.length; b +=1)c.push(a[b].listener); return c }, d.getListenersAsObject=function (a){ var b, c=this.getListeners(a); return c instanceof Array&&(b={}, b[a]=c), b||c }, d.addListener=function (a, c){ var d, e=this.getListenersAsObject(a), f="object"==typeof c; for (d in e)e.hasOwnProperty(d)&&-1===b(e[d], c)&&e[d].push(f ? c:{listener: c, once: !1}); return this }, d.on=c("addListener"), d.addOnceListener=function (a, b){ return this.addListener(a, {listener: b, once: !0}) }, d.once=c("addOnceListener"), d.defineEvent=function (a){ return this.getListeners(a), this }, d.defineEvents=function (a){ for (var b=0; b < a.length; b +=1)this.defineEvent(a[b]); return this }, d.removeListener=function (a, c){ var d, e, f=this.getListenersAsObject(a); for (e in f)f.hasOwnProperty(e)&&(d=b(f[e], c), -1!==d&&f[e].splice(d, 1)); return this }, d.off=c("removeListener"), d.addListeners=function (a, b){ return this.manipulateListeners(!1, a, b) }, d.removeListeners=function (a, b){ return this.manipulateListeners(!0, a, b) }, d.manipulateListeners=function (a, b, c){ var d, e, f=a ? this.removeListener:this.addListener, g=a ? this.removeListeners:this.addListeners; if("object"!=typeof b||b instanceof RegExp)for (d=c.length; d--;)f.call(this, b, c[d]); else for (d in b)b.hasOwnProperty(d)&&(e=b[d])&&("function"==typeof e ? f.call(this, d, e):g.call(this, d, e)); return this }, d.removeEvent=function (a){ var b, c=typeof a, d=this._getEvents(); if("string"===c)delete d[a]; else if(a instanceof RegExp)for (b in d)d.hasOwnProperty(b)&&a.test(b)&&delete d[b]; else delete this._events; return this }, d.removeAllListeners=c("removeEvent"), d.emitEvent=function (a, b){ var c, d, e, f, g=this.getListenersAsObject(a); for (e in g)if(g.hasOwnProperty(e))for (d=g[e].length; d--;)c=g[e][d], c.once===!0&&this.removeListener(a, c.listener), f=c.listener.apply(this, b||[]), f===this._getOnceReturnValue()&&this.removeListener(a, c.listener); return this }, d.trigger=c("emitEvent"), d.emit=function (a){ var b=Array.prototype.slice.call(arguments, 1); return this.emitEvent(a, b) }, d.setOnceReturnValue=function (a){ return this._onceReturnValue=a, this }, d._getOnceReturnValue=function (){ return this.hasOwnProperty("_onceReturnValue") ? this._onceReturnValue:!0 }, d._getEvents=function (){ return this._events||(this._events={}) }, a.noConflict=function (){ return e.EventEmitter=f, a }, "function"==typeof define&&define.amd ? define("eventEmitter/EventEmitter", [], function (){ return a }):"object"==typeof module&&module.exports ? module.exports=a:this.EventEmitter=a }.call(this), function (a){ function b(a){ if(a){ if("string"==typeof d[a])return a; a=a.charAt(0).toUpperCase() + a.slice(1); for (var b, e=0, f=c.length; f > e; e++)if(b=c[e] + a, "string"==typeof d[b])return b }} var c="Webkit Moz ms Ms O".split(" "), d=document.documentElement.style; "function"==typeof define&&define.amd ? define("get-style-property/get-style-property", [], function (){ return b }):"object"==typeof exports ? module.exports=b:a.getStyleProperty=b }(window), function (a){ function b(a){ var b=parseFloat(a), c=-1===a.indexOf("%")&&!isNaN(b); return c&&b } function c(){ for (var a={ width: 0, height: 0, innerWidth: 0, innerHeight: 0, outerWidth: 0, outerHeight: 0 }, b=0, c=g.length; c > b; b++){ var d=g[b]; a[d]=0 } return a } function d(a){ function d(a){ if("string"==typeof a&&(a=document.querySelector(a)), a&&"object"==typeof a&&a.nodeType){ var d=f(a); if("none"===d.display)return c(); var e={}; e.width=a.offsetWidth, e.height=a.offsetHeight; for (var k=e.isBorderBox = !(!j||!d[j]||"border-box"!==d[j]), l=0, m=g.length; m > l; l++){ var n=g[l], o=d[n]; o=h(a, o); var p=parseFloat(o); e[n]=isNaN(p) ? 0:p } var q=e.paddingLeft + e.paddingRight, r=e.paddingTop + e.paddingBottom, s=e.marginLeft + e.marginRight, t=e.marginTop + e.marginBottom, u=e.borderLeftWidth + e.borderRightWidth, v=e.borderTopWidth + e.borderBottomWidth, w=k&&i, x=b(d.width); x!==!1&&(e.width=x + (w ? 0:q + u)); var y=b(d.height); return y!==!1&&(e.height=y + (w ? 0:r + v)), e.innerWidth=e.width - (q + u), e.innerHeight=e.height - (r + v), e.outerWidth=e.width + s, e.outerHeight=e.height + t, e }} function h(a, b){ if(e||-1===b.indexOf("%"))return b; var c=a.style, d=c.left, f=a.runtimeStyle, g=f&&f.left; return g&&(f.left=a.currentStyle.left), c.left=b, b=c.pixelLeft, c.left=d, g&&(f.left=g), b } var i, j=a("boxSizing"); return function (){ if(j){ var a=document.createElement("div"); a.style.width="200px", a.style.padding="1px 2px 3px 4px", a.style.borderStyle="solid", a.style.borderWidth="1px 2px 3px 4px", a.style[j]="border-box"; var c=document.body||document.documentElement; c.appendChild(a); var d=f(a); i=200===b(d.width), c.removeChild(a) }}(), d } var e=a.getComputedStyle, f=e ? function (a){ return e(a, null) }:function (a){ return a.currentStyle }, g=["paddingLeft", "paddingRight", "paddingTop", "paddingBottom", "marginLeft", "marginRight", "marginTop", "marginBottom", "borderLeftWidth", "borderRightWidth", "borderTopWidth", "borderBottomWidth"]; "function"==typeof define&&define.amd ? define("get-size/get-size", ["get-style-property/get-style-property"], d):"object"==typeof exports ? module.exports=d(require("get-style-property")):a.getSize=d(a.getStyleProperty) }(window), function (a, b){ function c(a, b){ return a[h](b) } function d(a){ if(!a.parentNode){ var b=document.createDocumentFragment(); b.appendChild(a) }} function e(a, b){ d(a); for (var c=a.parentNode.querySelectorAll(b), e=0, f=c.length; f > e; e++)if(c[e]===a)return !0; return !1 } function f(a, b){ return d(a), c(a, b) } var g, h=function (){ if(b.matchesSelector)return "matchesSelector"; for (var a=["webkit", "moz", "ms", "o"], c=0, d=a.length; d > c; c++){ var e=a[c], f=e + "MatchesSelector"; if(b[f])return f }}(); if(h){ var i=document.createElement("div"), j=c(i, "div"); g=j ? c:f } else g=e; "function"==typeof define&&define.amd ? define("matches-selector/matches-selector", [], function (){ return g }):window.matchesSelector=g }(this, Element.prototype), function (a){ function b(a, b){ for (var c in b)a[c]=b[c]; return a } function c(a){ for (var b in a)return !1; return b=null, !0 } function d(a){ return a.replace(/([A-Z])/g, function (a){ return "-" + a.toLowerCase() }) } function e(a, e, f){ function h(a, b){ a&&(this.element=a, this.layout=b, this.position={x: 0, y: 0}, this._create()) } var i=f("transition"), j=f("transform"), k=i&&j, l = !!f("perspective"), m={ WebkitTransition: "webkitTransitionEnd", MozTransition: "transitionend", OTransition: "otransitionend", transition: "transitionend" }[i], n=["transform", "transition", "transitionDuration", "transitionProperty"], o=function (){ for (var a={}, b=0, c=n.length; c > b; b++){ var d=n[b], e=f(d); e&&e!==d&&(a[d]=e) } return a }(); b(h.prototype, a.prototype), h.prototype._create=function (){ this._transn={ingProperties: {}, clean: {}, onEnd: {}}, this.css({position: "absolute"}) }, h.prototype.handleEvent=function (a){ var b="on" + a.type; this[b]&&this[b](a) }, h.prototype.getSize=function (){ this.size=e(this.element) }, h.prototype.css=function (a){ var b=this.element.style; for (var c in a){ var d=o[c]||c; b[d]=a[c] }}, h.prototype.getPosition=function (){ var a=g(this.element), b=this.layout.options, c=b.isOriginLeft, d=b.isOriginTop, e=parseInt(a[c ? "left":"right"], 10), f=parseInt(a[d ? "top":"bottom"], 10); e=isNaN(e) ? 0:e, f=isNaN(f) ? 0:f; var h=this.layout.size; e -=c ? h.paddingLeft:h.paddingRight, f -=d ? h.paddingTop:h.paddingBottom, this.position.x=e, this.position.y=f }, h.prototype.layoutPosition=function (){ var a=this.layout.size, b=this.layout.options, c={}; b.isOriginLeft ? (c.left=this.position.x + a.paddingLeft + "px", c.right=""):(c.right=this.position.x + a.paddingRight + "px", c.left=""), b.isOriginTop ? (c.top=this.position.y + a.paddingTop + "px", c.bottom=""):(c.bottom=this.position.y + a.paddingBottom + "px", c.top=""), this.css(c), this.emitEvent("layout", [this]) }; var p=l ? function (a, b){ return "translate3d(" + a + "px, " + b + "px, 0)" }:function (a, b){ return "translate(" + a + "px, " + b + "px)" }; h.prototype._transitionTo=function (a, b){ this.getPosition(); var c=this.position.x, d=this.position.y, e=parseInt(a, 10), f=parseInt(b, 10), g=e===this.position.x&&f===this.position.y; if(this.setPosition(a, b), g&&!this.isTransitioning)return void this.layoutPosition(); var h=a - c, i=b - d, j={}, k=this.layout.options; h=k.isOriginLeft ? h:-h, i=k.isOriginTop ? i:-i, j.transform=p(h, i), this.transition({ to: j, onTransitionEnd: {transform: this.layoutPosition}, isCleaning: !0 }) }, h.prototype.goTo=function (a, b){ this.setPosition(a, b), this.layoutPosition() }, h.prototype.moveTo=k ? h.prototype._transitionTo:h.prototype.goTo, h.prototype.setPosition=function (a, b){ this.position.x=parseInt(a, 10), this.position.y=parseInt(b, 10) }, h.prototype._nonTransition=function (a){ this.css(a.to), a.isCleaning&&this._removeStyles(a.to); for (var b in a.onTransitionEnd)a.onTransitionEnd[b].call(this) }, h.prototype._transition=function (a){ if(!parseFloat(this.layout.options.transitionDuration))return void this._nonTransition(a); var b=this._transn; for (var c in a.onTransitionEnd)b.onEnd[c]=a.onTransitionEnd[c]; for (c in a.to)b.ingProperties[c] = !0, a.isCleaning&&(b.clean[c] = !0); if(a.from){ this.css(a.from); var d=this.element.offsetHeight; d=null } this.enableTransition(a.to), this.css(a.to), this.isTransitioning = !0 }; var q=j&&d(j) + ",opacity"; h.prototype.enableTransition=function (){ this.isTransitioning||(this.css({ transitionProperty: q, transitionDuration: this.layout.options.transitionDuration }), this.element.addEventListener(m, this, !1)) }, h.prototype.transition=h.prototype[i ? "_transition":"_nonTransition"], h.prototype.onwebkitTransitionEnd=function (a){ this.ontransitionend(a) }, h.prototype.onotransitionend=function (a){ this.ontransitionend(a) }; var r={"-webkit-transform": "transform", "-moz-transform": "transform", "-o-transform": "transform"}; h.prototype.ontransitionend=function (a){ if(a.target===this.element){ var b=this._transn, d=r[a.propertyName]||a.propertyName; if(delete b.ingProperties[d], c(b.ingProperties)&&this.disableTransition(), d in b.clean&&(this.element.style[a.propertyName]="", delete b.clean[d]), d in b.onEnd){ var e=b.onEnd[d]; e.call(this), delete b.onEnd[d] } this.emitEvent("transitionEnd", [this]) }}, h.prototype.disableTransition=function (){ this.removeTransitionStyles(), this.element.removeEventListener(m, this, !1), this.isTransitioning = !1 }, h.prototype._removeStyles=function (a){ var b={}; for (var c in a)b[c]=""; this.css(b) }; var s={transitionProperty: "", transitionDuration: ""}; return h.prototype.removeTransitionStyles=function (){ this.css(s) }, h.prototype.removeElem=function (){ this.element.parentNode.removeChild(this.element), this.emitEvent("remove", [this]) }, h.prototype.remove=function (){ if(!i||!parseFloat(this.layout.options.transitionDuration))return void this.removeElem(); var a=this; this.on("transitionEnd", function (){ return a.removeElem(), !0 }), this.hide() }, h.prototype.reveal=function (){ delete this.isHidden, this.css({display: ""}); var a=this.layout.options; this.transition({from: a.hiddenStyle, to: a.visibleStyle, isCleaning: !0}) }, h.prototype.hide=function (){ this.isHidden = !0, this.css({display: ""}); var a=this.layout.options; this.transition({ from: a.visibleStyle, to: a.hiddenStyle, isCleaning: !0, onTransitionEnd: { opacity: function (){ this.isHidden&&this.css({display: "none"}) }} }) }, h.prototype.destroy=function (){ this.css({position: "", left: "", right: "", top: "", bottom: "", transition: "", transform: ""}) }, h } var f=a.getComputedStyle, g=f ? function (a){ return f(a, null) }:function (a){ return a.currentStyle }; "function"==typeof define&&define.amd ? define("outlayer/item", ["eventEmitter/EventEmitter", "get-size/get-size", "get-style-property/get-style-property"], e):(a.Outlayer={}, a.Outlayer.Item=e(a.EventEmitter, a.getSize, a.getStyleProperty)) }(window), function (a){ function b(a, b){ for (var c in b)a[c]=b[c]; return a } function c(a){ return "[object Array]"===l.call(a) } function d(a){ var b=[]; if(c(a))b=a; else if(a&&"number"==typeof a.length)for (var d=0, e=a.length; e > d; d++)b.push(a[d]); else b.push(a); return b } function e(a, b){ var c=n(b, a); -1!==c&&b.splice(c, 1) } function f(a){ return a.replace(/(.)([A-Z])/g, function (a, b, c){ return b + "-" + c }).toLowerCase() } function g(c, g, l, n, o, p){ function q(a, c){ if("string"==typeof a&&(a=h.querySelector(a)), !a||!m(a))return void(i&&i.error("Bad " + this.constructor.namespace + " element: " + a)); this.element=a, this.options=b({}, this.constructor.defaults), this.option(c); var d=++r; this.element.outlayerGUID=d, s[d]=this, this._create(), this.options.isInitLayout&&this.layout() } var r=0, s={}; return q.namespace="outlayer", q.Item=p, q.defaults={ containerStyle: {position: "relative"}, isInitLayout: !0, isOriginLeft: !0, isOriginTop: !0, isResizeBound: !0, isResizingContainer: !0, transitionDuration: "0.4s", hiddenStyle: {opacity: 0, transform: "scale(0.001)"}, visibleStyle: {opacity: 1, transform: "scale(1)"}}, b(q.prototype, l.prototype), q.prototype.option=function (a){ b(this.options, a) }, q.prototype._create=function (){ this.reloadItems(), this.stamps=[], this.stamp(this.options.stamp), b(this.element.style, this.options.containerStyle), this.options.isResizeBound&&this.bindResize() }, q.prototype.reloadItems=function (){ this.items=this._itemize(this.element.children) }, q.prototype._itemize=function (a){ for (var b=this._filterFindItemElements(a), c=this.constructor.Item, d=[], e=0, f=b.length; f > e; e++){ var g=b[e], h=new c(g, this); d.push(h) } return d }, q.prototype._filterFindItemElements=function (a){ a=d(a); for (var b=this.options.itemSelector, c=[], e=0, f=a.length; f > e; e++){ var g=a[e]; if(m(g))if(b){ o(g, b)&&c.push(g); for (var h=g.querySelectorAll(b), i=0, j=h.length; j > i; i++)c.push(h[i]) } else c.push(g) } return c }, q.prototype.getItemElements=function (){ for (var a=[], b=0, c=this.items.length; c > b; b++)a.push(this.items[b].element); return a }, q.prototype.layout=function (){ this._resetLayout(), this._manageStamps(); var a=void 0!==this.options.isLayoutInstant ? this.options.isLayoutInstant:!this._isLayoutInited; this.layoutItems(this.items, a), this._isLayoutInited = !0 }, q.prototype._init=q.prototype.layout, q.prototype._resetLayout=function (){ this.getSize() }, q.prototype.getSize=function (){ this.size=n(this.element) }, q.prototype._getMeasurement=function (a, b){ var c, d=this.options[a]; d ? ("string"==typeof d ? c=this.element.querySelector(d):m(d)&&(c=d), this[a]=c ? n(c)[b]:d):this[a]=0 }, q.prototype.layoutItems=function (a, b){ a=this._getItemsForLayout(a), this._layoutItems(a, b), this._postLayout() }, q.prototype._getItemsForLayout=function (a){ for (var b=[], c=0, d=a.length; d > c; c++){ var e=a[c]; e.isIgnored||b.push(e) } return b }, q.prototype._layoutItems=function (a, b){ function c(){ d.emitEvent("layoutComplete", [d, a]) } var d=this; if(!a||!a.length)return void c(); this._itemsOn(a, "layout", c); for (var e=[], f=0, g=a.length; g > f; f++){ var h=a[f], i=this._getItemLayoutPosition(h); i.item=h, i.isInstant=b||h.isLayoutInstant, e.push(i) } this._processLayoutQueue(e) }, q.prototype._getItemLayoutPosition=function (){ return {x: 0, y: 0}}, q.prototype._processLayoutQueue=function (a){ for (var b=0, c=a.length; c > b; b++){ var d=a[b]; this._positionItem(d.item, d.x, d.y, d.isInstant) }}, q.prototype._positionItem=function (a, b, c, d){ d ? a.goTo(b, c):a.moveTo(b, c) }, q.prototype._postLayout=function (){ this.resizeContainer() }, q.prototype.resizeContainer=function (){ if(this.options.isResizingContainer){ var a=this._getContainerSize(); a&&(this._setContainerMeasure(a.width, !0), this._setContainerMeasure(a.height, !1)) }}, q.prototype._getContainerSize=k, q.prototype._setContainerMeasure=function (a, b){ if(void 0!==a){ var c=this.size; c.isBorderBox&&(a +=b ? c.paddingLeft + c.paddingRight + c.borderLeftWidth + c.borderRightWidth:c.paddingBottom + c.paddingTop + c.borderTopWidth + c.borderBottomWidth), a=Math.max(a, 0), this.element.style[b ? "width":"height"]=a + "px" }}, q.prototype._itemsOn=function (a, b, c){ function d(){ return e++, e===f&&c.call(g), !0 } for (var e=0, f=a.length, g=this, h=0, i=a.length; i > h; h++){ var j=a[h]; j.on(b, d) }}, q.prototype.ignore=function (a){ var b=this.getItem(a); b&&(b.isIgnored = !0) }, q.prototype.unignore=function (a){ var b=this.getItem(a); b&&delete b.isIgnored }, q.prototype.stamp=function (a){ if(a=this._find(a)){ this.stamps=this.stamps.concat(a); for (var b=0, c=a.length; c > b; b++){ var d=a[b]; this.ignore(d) }} }, q.prototype.unstamp=function (a){ if(a=this._find(a))for (var b=0, c=a.length; c > b; b++){ var d=a[b]; e(d, this.stamps), this.unignore(d) }}, q.prototype._find=function (a){ return a ? ("string"==typeof a&&(a=this.element.querySelectorAll(a)), a=d(a)):void 0 }, q.prototype._manageStamps=function (){ if(this.stamps&&this.stamps.length){ this._getBoundingRect(); for (var a=0, b=this.stamps.length; b > a; a++){ var c=this.stamps[a]; this._manageStamp(c) }} }, q.prototype._getBoundingRect=function (){ var a=this.element.getBoundingClientRect(), b=this.size; this._boundingRect={ left: a.left + b.paddingLeft + b.borderLeftWidth, top: a.top + b.paddingTop + b.borderTopWidth, right: a.right - (b.paddingRight + b.borderRightWidth), bottom: a.bottom - (b.paddingBottom + b.borderBottomWidth) }}, q.prototype._manageStamp=k, q.prototype._getElementOffset=function (a){ var b=a.getBoundingClientRect(), c=this._boundingRect, d=n(a), e={ left: b.left - c.left - d.marginLeft, top: b.top - c.top - d.marginTop, right: c.right - b.right - d.marginRight, bottom: c.bottom - b.bottom - d.marginBottom }; return e }, q.prototype.handleEvent=function (a){ var b="on" + a.type; this[b]&&this[b](a) }, q.prototype.bindResize=function (){ this.isResizeBound||(c.bind(a, "resize", this), this.isResizeBound = !0) }, q.prototype.unbindResize=function (){ this.isResizeBound&&c.unbind(a, "resize", this), this.isResizeBound = !1 }, q.prototype.onresize=function (){ function a(){ b.resize(), delete b.resizeTimeout } this.resizeTimeout&&clearTimeout(this.resizeTimeout); var b=this; this.resizeTimeout=setTimeout(a, 100) }, q.prototype.resize=function (){ this.isResizeBound&&this.needsResizeLayout()&&this.layout() }, q.prototype.needsResizeLayout=function (){ var a=n(this.element), b=this.size&&a; return b&&a.innerWidth!==this.size.innerWidth }, q.prototype.addItems=function (a){ var b=this._itemize(a); return b.length&&(this.items=this.items.concat(b)), b }, q.prototype.appended=function (a){ var b=this.addItems(a); b.length&&(this.layoutItems(b, !0), this.reveal(b)) }, q.prototype.prepended=function (a){ var b=this._itemize(a); if(b.length){ var c=this.items.slice(0); this.items=b.concat(c), this._resetLayout(), this._manageStamps(), this.layoutItems(b, !0), this.reveal(b), this.layoutItems(c) }}, q.prototype.reveal=function (a){ var b=a&&a.length; if(b)for (var c=0; b > c; c++){ var d=a[c]; d.reveal() }}, q.prototype.hide=function (a){ var b=a&&a.length; if(b)for (var c=0; b > c; c++){ var d=a[c]; d.hide() }}, q.prototype.getItem=function (a){ for (var b=0, c=this.items.length; c > b; b++){ var d=this.items[b]; if(d.element===a)return d }}, q.prototype.getItems=function (a){ if(a&&a.length){ for (var b=[], c=0, d=a.length; d > c; c++){ var e=a[c], f=this.getItem(e); f&&b.push(f) } return b }}, q.prototype.remove=function (a){ a=d(a); var b=this.getItems(a); if(b&&b.length){ this._itemsOn(b, "remove", function (){ this.emitEvent("removeComplete", [this, b]) }); for (var c=0, f=b.length; f > c; c++){ var g=b[c]; g.remove(), e(g, this.items) }} }, q.prototype.destroy=function (){ var a=this.element.style; a.height="", a.position="", a.width=""; for (var b=0, c=this.items.length; c > b; b++){ var d=this.items[b]; d.destroy() } this.unbindResize(), delete this.element.outlayerGUID, j&&j.removeData(this.element, this.constructor.namespace) }, q.data=function (a){ var b=a&&a.outlayerGUID; return b&&s[b] }, q.create=function (a, c){ function d(){ q.apply(this, arguments) } return Object.create ? d.prototype=Object.create(q.prototype):b(d.prototype, q.prototype), d.prototype.constructor=d, d.defaults=b({}, q.defaults), b(d.defaults, c), d.prototype.settings={}, d.namespace=a, d.data=q.data, d.Item=function (){ p.apply(this, arguments) }, d.Item.prototype=new p, g(function (){ for (var b=f(a), c=h.querySelectorAll(".js-" + b), e="data-" + b + "-options", g=0, k=c.length; k > g; g++){ var l, m=c[g], n=m.getAttribute(e); try { l=n&&JSON.parse(n) } catch (o){ i&&i.error("Error parsing " + e + " on " + m.nodeName.toLowerCase() + (m.id ? "#" + m.id:"") + ": " + o); continue } var p=new d(m, l); j&&j.data(m, a, p) }}), j&&j.bridget&&j.bridget(a, d), d }, q.Item=p, q } var h=a.document, i=a.console, j=a.jQuery, k=function (){ }, l=Object.prototype.toString, m="object"==typeof HTMLElement ? function (a){ return a instanceof HTMLElement }:function (a){ return a&&"object"==typeof a&&1===a.nodeType&&"string"==typeof a.nodeName }, n=Array.prototype.indexOf ? function (a, b){ return a.indexOf(b) }:function (a, b){ for (var c=0, d=a.length; d > c; c++)if(a[c]===b)return c; return -1 }; "function"==typeof define&&define.amd ? define("outlayer/outlayer", ["eventie/eventie", "doc-ready/doc-ready", "eventEmitter/EventEmitter", "get-size/get-size", "matches-selector/matches-selector", "./item"], g):a.Outlayer=g(a.eventie, a.docReady, a.EventEmitter, a.getSize, a.matchesSelector, a.Outlayer.Item) }(window), function (a){ function b(a, b){ var d=a.create("masonry"); return d.prototype._resetLayout=function (){ this.getSize(), this._getMeasurement("columnWidth", "outerWidth"), this._getMeasurement("gutter", "outerWidth"), this.measureColumns(); var a=this.cols; for (this.colYs=[]; a--;)this.colYs.push(0); this.maxY=0 }, d.prototype.measureColumns=function (){ if(this.getContainerWidth(), !this.columnWidth){ var a=this.items[0], c=a&&a.element; this.columnWidth=c&&b(c).outerWidth||this.containerWidth } this.columnWidth +=this.gutter, this.cols=Math.floor((this.containerWidth + this.gutter) / this.columnWidth), this.cols=Math.max(this.cols, 1) }, d.prototype.getContainerWidth=function (){ var a=this.options.isFitWidth ? this.element.parentNode:this.element, c=b(a); this.containerWidth=c&&c.innerWidth }, d.prototype._getItemLayoutPosition=function (a){ a.getSize(); var b=a.size.outerWidth % this.columnWidth, d=b&&1 > b ? "round":"ceil", e=Math[d](a.size.outerWidth / this.columnWidth); e=Math.min(e, this.cols); for (var f=this._getColGroup(e), g=Math.min.apply(Math, f), h=c(f, g), i={ x: this.columnWidth * h, y: g }, j=g + a.size.outerHeight, k=this.cols + 1 - f.length, l=0; k > l; l++)this.colYs[h + l]=j; return i }, d.prototype._getColGroup=function (a){ if(2 > a)return this.colYs; for (var b=[], c=this.cols + 1 - a, d=0; c > d; d++){ var e=this.colYs.slice(d, d + a); b[d]=Math.max.apply(Math, e) } return b }, d.prototype._manageStamp=function (a){ var c=b(a), d=this._getElementOffset(a), e=this.options.isOriginLeft ? d.left:d.right, f=e + c.outerWidth, g=Math.floor(e / this.columnWidth); g=Math.max(0, g); var h=Math.floor(f / this.columnWidth); h -=f % this.columnWidth ? 0:1, h=Math.min(this.cols - 1, h); for (var i=(this.options.isOriginTop ? d.top:d.bottom) + c.outerHeight, j=g; h >=j; j++)this.colYs[j]=Math.max(i, this.colYs[j]) }, d.prototype._getContainerSize=function (){ this.maxY=Math.max.apply(Math, this.colYs); var a={height: this.maxY}; return this.options.isFitWidth&&(a.width=this._getContainerFitWidth()), a }, d.prototype._getContainerFitWidth=function (){ for (var a=0, b=this.cols; --b&&0===this.colYs[b];)a++; return (this.cols - a) * this.columnWidth - this.gutter }, d.prototype.needsResizeLayout=function (){ var a=this.containerWidth; return this.getContainerWidth(), a!==this.containerWidth }, d } var c=Array.prototype.indexOf ? function (a, b){ return a.indexOf(b) }:function (a, b){ for (var c=0, d=a.length; d > c; c++){ var e=a[c]; if(e===b)return c } return -1 }; "function"==typeof define&&define.amd ? define(["outlayer/outlayer", "get-size/get-size"], b):a.Masonry=b(a.Outlayer, a.getSize) }(window); if(void 0===ThriveApp)var ThriveApp={};var _isAdmin=0,_is_blankPage=0;ThriveApp.is_theme_layout=!1,ThriveApp.winWidth=jQuery(window).width(),ThriveApp.viewportHeight=jQuery(window).height(),jQuery(function(){_isAdmin=jQuery("#wpadminbar").length,ThriveApp.menuPositionTop=jQuery(".m-si nav").length?jQuery(".m-si nav").position().top:0,_is_blankPage=jQuery(".bp-t").length,_is_blankPage||(ThriveApp.menuPositionTop=jQuery("nav.right").length?jQuery("nav.right").position().top:0),ThriveApp.is_theme_layout=!!(jQuery(".bSe .awr .tve-c").length+jQuery(".bp-t .wrp").length),ThriveApp.menuResponsive(),ThriveApp.shortcodeTabsResize(),ThriveApp.setPageSectionHeight(),ThriveApp.bind_comments_handlers(),ThriveApp.check_comments_hash(),ThriveApp.videoShorcode(),ThriveApp.image_post_resize(),ThriveApp.blog_gallery(),jQuery(".cdt").thrive_timer(),ThriveApp.post_format_gallery(),ThriveApp.show_search(),ThriveApp.bold_first_paragraph(),ThriveApp.grid_layout(".gin",".gr-i"),jQuery(".sm_icons, .scfm .ss").each(function(){jQuery(this).mouseover(function(){jQuery(".bubb",this).css("left",function(){return(jQuery(this).parent().width()-jQuery(this).width())/2}).show(0)}),jQuery(this).mouseout(function(){jQuery(".bubb",this).hide()})}),jQuery(".tmw").hover(function(){jQuery(this).find(".tmm").slideDown()},function(){jQuery(this).find(".tmm").slideUp()}),jQuery(".faqB").click(function(){var a=jQuery(this).parents(".faqI");return a.toggleClass("oFaq"),jQuery(".faqC",a).slideToggle("fast"),!1}),jQuery(".accss .acc-h").click(function(){var a=jQuery(this),b=jQuery(this).parents(".accs"),c=b.find(".accss");if(a.parent().hasClass("opac"))return!1;a.parents(".accs").find(".opac").find(".accsi").slideUp(function(){c.removeClass("opac")}),a.next(".accsi").slideDown(function(){a.parents(".accss").addClass("opac")})}),jQuery(".thrive-borderless .wp-video-shortcode").length>0&&(jQuery(".thrive-borderless .wp-video-shortcode").css("width","100%"),jQuery(".thrive-borderless div").css("width","100%")),ThriveApp.comments_page=1,1==ThriveApp.lazy_load_comments&&(jQuery(window).scroll(ThriveApp.bind_scroll),ThriveApp.load_comments()),jQuery(window).trigger("scroll"),ThriveApp.bind_masonry_layout(),jQuery("#shf").on("click",function(){jQuery(".lrp.hid").slideToggle()}),jQuery(window).resize(function(){var a=jQuery(window).width(),b=jQuery(window).height();ThriveApp.winWidth!==a&&ThriveApp.delay(function(){ThriveApp.menuResponsive()},1),ThriveApp.winWidth=a,ThriveApp.viewportHeight=b,ThriveApp.shortcodeTabsResize(),ThriveApp.videoShorcode(),ThriveApp.setVideoPosition(),ThriveApp.setPageSectionHeight(),ThriveApp.image_post_resize(),ThriveApp.grid_layout(".gin",".gr-i")}),jQuery("body").on("added_to_cart",function(a,b,c,d){var e=jQuery(b[".mini-cart-contents"]).find("a.cart-contents-btn");jQuery(".mobile-mini-cart").html("").append(e)}),window.FB&&window.FB.XFBML&&jQuery(".fb-comments").each(function(){window.FB.XFBML.parse(this.parentNode)})}),ThriveApp.grid_layout=function(a,b){jQuery(a).length>0&&jQuery(a).each(function(){var a=jQuery(b,this),c=a.length,d=function(b){for(var d="",e=0;e=940?d(jQuery(".bSe").hasClass("fullWidth")?3:2):940>ThriveApp.winWidth&&ThriveApp.winWidth>=741&&d(2)})},ThriveApp.bold_first_paragraph=function(){"post"==ThriveApp.post_type&&jQuery(".bSe .awr-i .tve-c").children().each(function(){var a=jQuery(this),b=jQuery.trim(a.text()),c=a.html().replace(/ /g,"");if(!a.is(":hidden")&&!a.is(":empty")){if("P"!=a.prop("tagName"))return!1;if(""!=b&&""!=c)return a.addClass("ifp"),!1;if(""!=b||""!=c)return!1}})},ThriveApp.show_search=function(){jQuery(".s-bb").on("click",function(){jQuery(".h-b").toggleClass("s-s").find("#search").focus()})},ThriveApp.bind_masonry_layout=function(){if(jQuery(".bSe").hasClass("mry")){var a=document.querySelector(".mry");new Masonry(a,{itemSelector:".mry-i",gutter:".mry-g"})}},jQuery(window).on("load",function(){ThriveApp.bind_masonry_layout(),ThriveApp.resize_blank_page()}),ThriveApp.post_format_gallery=function(){jQuery("div[id^='thrive-gallery-header']").each(function(){jQuery(this).attr("data-count",jQuery(this).find(".thrive-gallery-item").length);var a=jQuery(this),b=a.find(".gnext"),c=a.find(".gprev"),d=a.find(".gallery-dmy");jQuery(".thrive-gallery-item",a).click(function(){return a.attr("data-index",jQuery(this).attr("data-index")),a.css("background-image","url("+jQuery(this).attr("data-image")+")"),d.attr("src",jQuery(this).attr("data-image")),!1}),c.click(function(){var b=parseInt(a.attr("data-index")),c=b-1;return c<0&&(c=a.attr("data-count")-1),jQuery("#li-thrive-gallery-item-"+c,a).length>0&&(a.attr("data-index",jQuery("#li-thrive-gallery-item-"+c,a).find("a").attr("data-index")),a.css("background-image","url("+jQuery("#li-thrive-gallery-item-"+c,a).find("a").attr("data-image")+")"),d.attr("src",jQuery("#li-thrive-gallery-item-"+c,a).find("a").attr("data-image"))),!1}),b.click(function(){var b=parseInt(a.attr("data-index")),c=b+1;return c>=a.attr("data-count")&&(c=0),jQuery("#li-thrive-gallery-item-"+c,a).length>0&&(a.attr("data-index",jQuery("#li-thrive-gallery-item-"+c,a).find("a").attr("data-index")),a.css("background-image","url("+jQuery("#li-thrive-gallery-item-"+c,a).find("a").attr("data-image")+")"),d.attr("src",jQuery("#li-thrive-gallery-item-"+c,a).find("a").attr("data-image"))),!1})})},ThriveApp.progress_bar=function(){jQuery('.pbfc:not(".stopCount")').each(function(a){if(jQuery(this).parents(".nsd").hasClass("nsds")){var b=jQuery(this),c=b.attr("data-percent"),d=b.find(".pbf span");jQuery({countNum:0}).animate({countNum:c},{duration:3e3,easing:"linear",step:function(){d.text(Math.ceil(this.countNum))},done:function(){d.text()==c&&b.addClass("stopCount")}})}})},ThriveApp.number_counter=function(){jQuery(".nbc.nsds").each(function(){function a(c,f){e=Math.ceil(f/100),c<=f?(b.text(c),c+=e,c+e>f&&(b.text(f),clearTimeout(d)),d=setTimeout(function(){a(c,f)},50)):clearTimeout(d)}var b=jQuery(".nbcn",this),c=b.attr("data-counter"),d=null,e=1;"false"==jQuery(this).attr("data-started")&&(a(0,c),jQuery(this).attr("data-started","true"))})},ThriveApp.image_post_resize=function(){jQuery(".tt-dmy").css({"max-height":ThriveApp.viewportHeight,"max-width":ThriveApp.winWidth})},ThriveApp.setPageSectionHeight=function(){var a=jQuery(" .wrp .bpd,.wrp .fullWidth , .wrp .lnd "),b=a.length;b&&ThriveApp.winWidth;jQuery(".pddbg, .scvps, .vt").css("max-width",ThriveApp.winWidth+"px"),jQuery(".pdfbg").each(function(){var a=jQuery(this).css("box-sizing","border-box"),b=parseInt(a.attr("data-height")),c=parseInt(a.attr("data-width")),d="100%";if(b&&!isNaN(b)&&c&&!isNaN(c)){var e=Math.min(ThriveApp.winWidth,a.parent().width());d=(e=722){var a=jQuery(this).children(".sub-menu"),b=jQuery(this).offset().left,c=a.width(),d=jQuery(".wrp.cnt"),e=d.width(),f=d.offset().left;(bf+e)&&(a.addClass("position_menu"),bf+e&&(a.hasClass("position_left")||a.addClass("position_right"))),jQuery(this).children(".sub-menu").stop().fadeIn("fast")}else jQuery(this).children(".sub-menu").show()}),jQuery(this).mouseleave(function(){jQuery(this).children(".sub-menu").stop().fadeOut("fast")})})},ThriveApp.menuResponsive=function(){ThriveApp.winWidth<774?(jQuery("header nav ul li").each(function(){jQuery(this).unbind("mouseenter"),jQuery(this).unbind("mouseleave")}),jQuery(".hsm").unbind("click").on("click",function(){var a=jQuery("#floating_menu").height(),b=jQuery("#wpadminbar").length?46:0,c=a+b,d=ThriveApp.viewportHeight-c;jQuery(".m-si nav").fadeToggle("fast",function(){var a=jQuery("#floating_menu nav ul").height();ThriveApp.viewportHeight<=a+c&&(jQuery(".m-si nav").css({"max-height":d+"px"}),jQuery("html").addClass("html-hidden")),a<=0&&jQuery("html").removeClass("html-hidden")})})):ThriveApp.winWidth>=774&&ThriveApp.showMenu()},ThriveApp.shortcodeTabsResize=function(){jQuery(".scT ul.scT-tab li").on("click",function(a){var b=jQuery(this),c=b.parents(".shortcode_tabs, .tabs_widget").first(),d=c.find(".scTC").eq(b.index());c.find(".tS").removeClass("tS"),b.addClass("tS"),c.find(".scTC").hide(),d.show(),a.preventDefault()})},ThriveApp.delay=function(){var a=0;return function(b,c){clearTimeout(a),a=setTimeout(b,c)}}(),ThriveApp.check_comments_hash=function(){if(location.hash&&-1!==location.hash.indexOf("#comment-")){var a=location.hash.indexOf("#comment-")+9,b=location.hash.substring(a,location.hash.length),c=jQuery("#comment-container-"+b);0!==c.length&&jQuery("html,body").animate({scrollTop:c.offset().top-30},"slow")}},ThriveApp.videoShorcode=function(){jQuery("iframe").each(function(){var a=jQuery(this);this.getAttribute("src")&&-1!==this.getAttribute("src").indexOf("autoplay")&&(a.closest(".vt-v").show(),a.closest(".vt").addClass("h-vt"))}),jQuery(".scvps .pvb a").click(function(a){a.preventDefault()}),jQuery(".scvps .pvb, .vt-t .pvb").click(function(){var a=jQuery(this),b=a.parents(".scvps").length?a.parents(".scvps"):a.parents(".vt"),c=b.height(),d="scvps"===b.attr("class"),e=b.find("iframe"),f=e.attr("src");if(a.parents(".scvps").css("height",c+"px"),d?(a.parents(".vdc").find("h1").hide(),a.parents(".vdc").find("h2").hide(),a.parents(".vdc").find("h3").hide(),a.hide(),a.parents(".scvps").find(".video-container").show()):(b.addClass("h-vt"),b.find(".vt-v").fadeIn(800)),e.length>0){var g=b.outerWidth(),h=e.attr("width");if(a.hasClass("is-video-format"))var i=b.outerHeight();else var i=9*g/16;g0){var l=b.find("video")[0];a.hasClass("is-video-format"),l.player.play()}e.length>0&&-1===f.indexOf("autoplay")&&(f.indexOf("vimeo")>=0?e.attr("src",ThriveApp.updateQueryStringParameter(f,"autoplay","1")):f.indexOf("youtube")>=0&&e.attr("src",ThriveApp.updateQueryStringParameter(f,"autoplay","1")),e.trigger("click"))})},ThriveApp.bind_scroll=function(){if(jQuery("#comment-bottom").length>0){var a=jQuery("#comment-bottom").offset().top;a>0&&a')},ThriveApp._get_element_height=function(a){var b,c,d=document.getElementById(a);return document.all?(b=d.currentStyle.height,c=parseInt(d.currentStyle.marginTop,10)+parseInt(d.currentStyle.marginBottom,10)+"px"):(b=document.defaultView.getComputedStyle(d,"").getPropertyValue("height"),c=parseInt(document.defaultView.getComputedStyle(d,"").getPropertyValue("margin-top"))+parseInt(document.defaultView.getComputedStyle(d,"").getPropertyValue("margin-bottom"))+"px"),b+c},ThriveApp.updateQueryStringParameter=function(a,b,c){var d=new RegExp("([?|&])"+b+"=.*?(&|$)","i");return separator=-1!==a.indexOf("?")?"&":"?",a.match(d)?a.replace(d,"$1"+b+"="+c+"$2"):a+separator+b+"="+c},ThriveApp.social_scripts={twitter:{src:"https://platform.twitter.com/widgets.js",loaded:0},google:{src:"https://apis.google.com/js/plusone.js?onload=onLoadCallback",loaded:0},facebook:{src:"://platform.twitter.com/widgets.js",loaded:0},linkedin:{src:"//platform.linkedin.com/in.js",loaded:0},pinterest:{src:"//assets.pinterest.com/js/pinit.js",loaded:0},youtube:{src:"https://apis.google.com/js/platform.js",loaded:0}},ThriveApp.load_script=function(a){if(0===ThriveApp.social_scripts[a].loaded)if("//assets.pinterest.com/js/pinit.js"==ThriveApp.social_scripts[a].src){var b=document.createElement("script");b.type="text/javascript",b.async=!0,b.src="https://assets.pinterest.com/js/pinit.js",b["data-pin-build"]="parsePins";var c=document.getElementsByTagName("script")[0];c.parentNode.insertBefore(b,c),ThriveApp.social_scripts[a].loaded=1}else jQuery.getScript(ThriveApp.social_scripts[a].src,function(){ThriveApp.social_scripts[a].loaded=1})},ThriveApp.setVideoPosition=function(){jQuery(".scvps .pvb").each(function(){var a=jQuery(this).parents(".scvps").find(".vwr");a.css({top:jQuery(this).parents(".scvps").outerHeight()/2-a.height()/2,left:jQuery(this).parents(".scvps").outerWidth()/2-a.width()/2})})},ThriveApp.open_share_popup=function(a,b,c){var d,e;return d=window.screen.width/2-(b/2+10),e=window.screen.height/2-(c/2+50),window.open(a,"Window","status=no,height="+c+",width="+b+",resizable=yes,left="+d+",top="+e+",screenX="+d+",screenY="+e+",toolbar=no,menubar=no,scrollbars=no,location=no,directories=no"),!1};var _lastScrollTop=0,_theMenu=jQuery("#floating_menu"),_nextElement=_theMenu.parents(".h-bi").next(),_floatingOption=_theMenu.attr("data-float"),_hasFloatingMenu="float-fixed"==_floatingOption||"float-scroll"==_floatingOption,_defaultPadding=_nextElement.css("padding-top"),_menuHeight=_theMenu.outerHeight(),_textLogoHeight=_theMenu.find("#text_logo").height(),_hasCenterLogo=_theMenu.find(".center").length,_custom_header=_theMenu.children("header"),_custom_header_class=_custom_header.attr("class"),_is_custom_header="hic"==_custom_header_class||"hif"==_custom_header_class,_center_header_height;ThriveApp.menu_float={current_scroll_top:0,anim_done:!1,scroll_dir:"down",hasScroll:function(){return _is_custom_header?this.current_scroll_top>_center_header_height:this.current_scroll_top>0},onScroll:function(a){return _is_custom_header&&(_center_header_height="hic"==_custom_header_class?jQuery("header .tt-dmy").height():jQuery("header").height()),this.current_scroll_top0?(ThriveApp.menu_float.hideLogo(),_theMenu.addClass("a60")):_theMenu.removeClass("a60"),"float-scroll"==_floatingOption&&("down"==this.scroll_dir?_theMenu.removeClass("mfu mfd").addClass("mfd"):_theMenu.removeClass("mfu mfd").addClass("mfu"))},hideLogo:function(){_hasCenterLogo&&(_theMenu.find("#logo img").hide(),this.anim_done||(_theMenu.find("#text_logo").stop().animate({opacity:0,height:0},50),this.anim_done=!0))},showLogo:function(){_hasCenterLogo&&(_theMenu.find("#logo img").show(),_theMenu.find("#text_logo").animate({height:_textLogoHeight,opacity:1},50),this.anim_done=!1)}},ThriveApp.show_shortcodes=function(a){jQuery(".nsd").each(function(){var b=jQuery(this);a+ThriveApp.viewportHeight>=b.offset().top+b.outerHeight()&&(b.addClass("nsds"),ThriveApp.number_counter(),ThriveApp.progress_bar())})},ThriveApp.display_no_shares=function(a){function b(){e.val(d),f.html(ThriveApp._get_share_count_display_text(d,2)),jQuery("#tt-share-count").show()}function c(a){a&&a.total&&(d=parseInt(a.total),b())}var d=0,e=jQuery("#tt-hidden-share-no"),f=jQuery("#share_no_element"),g=[];if(a.linkedin&&g.push("in_share"),a.facebook&&g.push("fb_share"),a.google&&g.push("g_share"),a.pinterest&&g.push("pin_share"),g.length){var h={action:"thrive_get_share_counts",url:a.url,networks:g};window.TVE_Dash&&!TVE_Dash.ajax_sent?jQuery(document).on("tve-dash.load",function(){TVE_Dash.add_load_item("theme_shares",h,c)}):jQuery.post(ThriveApp.ajax_url,h,c)}};var _overlayElement=jQuery(".galleryOverlay");ThriveApp.blog_gallery=function(a){return function(){function b(b,c){a('
').appendTo(c)}function c(a,b,c){c?a.removeClass("g-n-a"):a.addClass("g-n-a");var e=a.find("img[data-index="+b+"]"),g=e.attr("data-cap"),h=e.attr("data-pos");b=e.parent().index(),a.css({left:"-"+100*b+"%"}),f=b,ThriveApp.winWidth>650&&d(e),jQuery(".img_count").text(h),jQuery(".cap_txt").text(g),""!=g?jQuery(".mob_text").text(g):jQuery(".mob_text").text(" - Swipe left/right to see more")}function d(a){var b=a.parents(".galleryOverlay").first().find(".nav_close");if(!a.width())return b.css({top:"20px",right:"20px"});var c=a.position().left-a.parent().position().left+a.width(),d=a.position().top;a.width()>=ThriveApp.winWidth&&(c-=16,d+=16),_isAdmin&&a.position().top<=32&&(d+=32),b.css({top:d-16+"px",left:c-16+"px"})}var f=0,g=0;a(".gallery").each(function(){var d=a(this),h=a(this).find(".galleryOverlay"),i=a(this).find(".galleryStage"),j=d.find(".gallery-item a").length,k=!1,l=!1,m=function(){l||(f0?c(i,f-1,!0):(i.addClass("g-n-a").css("left",-100*j+"%"),l=!0,setTimeout(function(){c(i,j-1,!0),l=!1},20)))};d.find(".gallery-item a").each(function(d){a(this).click(function(){return k=!0,h.show(0).addClass("g-v"),c(i,d,!1),!1}),b(a(this),h.find(".galleryStage"))}),d.find("a.nav_prev").click(function(){return n(),!1}),d.find("a.nav_next").click(function(){return m(),!1}),d.find(".nav_close").click(function(){return k=!1,h.removeClass("g-v").hide(),!1}),d.find(".galleryWrapper").touchwipe({wipeLeft:function(){m()},wipeRight:function(){n()},wipeUp:function(){k=!1,h.removeClass("g-v").hide()},wipeDown:function(){return!1},min_move_x:20,min_move_y:20,preventDefaultEvents:!0}),ThriveApp.winWidth<=650?i.click(function(){if(a(e.target).is("img"))return!1;k=!1,h.removeClass("g-v").hide()}):(i.click(function(b){if(a(b.target).is("img"))return!1;k=!1,h.removeClass("g-v").hide()}),d.mousemove(function(b){clearTimeout(g),a(".gl_ctrl, .gl_ctrl_mob").fadeIn(200),ThriveApp.winWidth<=650||a(b.target).is(".gl_ctrl,.gl_ctrl_mob")||(g=setTimeout(function(){jQuery(".gl_ctrl, .gl_ctrl_mob").fadeOut(200)},1e3))})),a("html").unbind("keydown").keydown(function(a){return!k||(37==a.keyCode?(n(),!1):39==a.keyCode?(m(),!1):27==a.keyCode?(h.removeClass("g-v").hide(),!1):void 0)})})}}(jQuery),jQuery.fn.thrive_timer=function(){return this.each(function(){var a,b=jQuery(this),c=b.attr("data-server-now"),d=c?new Date(c):new Date,e=new Date(b.attr("data-date")),f=0,g=0,h=0,i=0,j=2,k=b.attr("data-fade"),l=b.attr("data-message"),m=function(a,b){if(a.html()==b)return a;a.removeClass("next");var c=a.clone().removeClass("go-down").addClass("next").html(b);return a.before(c).next(".go-down").remove(),a.addClass("go-down"),setTimeout(function(){c.addClass("go-down")},20),a},n=function(a,b,c){void 0===c&&(c=!1);var d=0;if(b<=99)m(a.find(".part-1").first(),b%10),m(a.find(".part-2").first(),Math.floor(b/10)),d=2;else for(;b;)d++,m(a.find(".part-"+d).first(),b%10),b=Math.floor(b/10);if(!1!==c&&de?p():(i=Math.floor((e.getTime()-d.getTime())/1e3),h=Math.floor(i/60),i%=60,g=Math.floor(h/60),h%=60,f=Math.floor(g/24),g%=24,f>99&&(j=f.toString().length),function(){var a=function(a,b){return jQuery(''+b+"")};b.find(".second .cdfc").append(a(2,Math.floor(i/10))).append(a(1,i%10)),b.find(".minute .cdfc").append(a(2,Math.floor(h/10))).append(a(1,h%10)),b.find(".hour .cdfc").append(a(2,Math.floor(g/10))).append(a(1,g%10));for(var c=b.find(".day .cdfc"),d=f,e=1;e<=j;e++)c.append(a(e,d%10)),d=Math.floor(d/10);n(c.css("min-width",35*j+"px"),f,j)}(),b.find(".cdti").addClass("init_done"),a=setInterval(o,1e3))})},jQuery(window).scroll(function(){var a=jQuery(document).scrollTop(),b=0,c=0,d=jQuery(".ssf");if(ThriveApp.is_theme_layout&&(b=_is_blankPage?jQuery(".bp-t .wrp").offset().top:jQuery(".bSe .tve-c").offset().top,c=_is_blankPage?jQuery(".bp-t .wrp").height():jQuery(".bSe .tve-c").height()),_hasFloatingMenu&&ThriveApp.menu_float.onScroll(a),ThriveApp.show_shortcodes(a),d.hasClass("apsf"))return!1;if(a+40>b)if(d.show(0),a>b+c-d.height()){d.removeClass("fpss").addClass("apss");var e=jQuery(".ssf.apss")}else{d.removeClass("apss").addClass("fpss");var e=jQuery(".ssf.fpss");if(_hasFloatingMenu&&e.css({top:_menuHeight,bottom:"auto"}),jQuery(".bSe").length)if(jQuery(".bSe").hasClass("right")){var f=parseInt(jQuery(".bSe").offset().left+jQuery(".bSe").outerWidth());e.css({left:f+36+"px",right:"auto"})}else{var f=jQuery(".bSe").offset().left;e.css({left:f-e.width()-"36",right:"auto"})}}else d.hide(0)}),ThriveApp._get_share_count_display_text=function(a,b){b=Math.pow(10,b);for(var c=["k","m"],d=c.length-1;d>=0;d--){var e=Math.pow(10,3*(d+1));if(e<=a){a=Math.round(a*b/e)/b,1e3==a&&d=a?b.css("height",ThriveApp.viewportHeight):b.css("height",a)}}; var TVE_Dash=TVE_Dash||{};if(!ThriveGlobal||!ThriveGlobal.$j){var __thrive_$oJ=window.$,ThriveGlobal={$j:jQuery.noConflict()};__thrive_$oJ&&(window.$=__thrive_$oJ)}!function(a){TVE_Dash.ajax_sent=!1;var b={},c={};TVE_Dash.add_load_item=function(d,e,f){if("function"!=typeof f&&(f=a.noop),TVE_Dash.ajax_sent){var g={},h={};return g[d]=e,h[d]=f,this.send_ajax(g,h),!0}return e?(b[d]&&console.error&&console.error(d+" ajax action already defined"),b[d]=e,c[d]=f,!0):(console.error&&console.error("missing ajax data"),!1)},TVE_Dash.ajax_load_css=function(b){a.each(b,function(b,c){b+="-css",a("link#"+b).length||a('').appendTo("head")})},TVE_Dash.ajax_load_js=function(b){var c=document.body;a.each(b,function(d,e){if(-1!==d.indexOf("_before"))return!0;var f=document.createElement("script");if(b[d+"_before"]){a('").after(c.lastChild)}d&&(f.id=d+"-script"),f.src=e,c.appendChild(f)})},TVE_Dash.send_ajax=function(b,c){a.ajax({url:tve_dash_front.ajaxurl,xhrFields:{withCredentials:!0},data:{action:"tve_dash_front_ajax",tve_dash_data:b},dataType:"json",type:"post"}).done(function(b){b&&a.isPlainObject(b)&&(b.__resources&&(b.__resources.css&&TVE_Dash.ajax_load_css(b.__resources.css),b.__resources.js&&TVE_Dash.ajax_load_js(b.__resources.js),delete b.__resources),a.each(b,function(a,b){if("function"!=typeof c[a])return!0;c[a].call(null,b)}))})},a(function(){setTimeout(function(){var d=new a.Event("tve-dash.load");return a(document).trigger(d),!a.isEmptyObject(b)&&(!(!tve_dash_front.force_ajax_send&&tve_dash_front.is_crawler)&&(TVE_Dash.send_ajax(b,c),void(TVE_Dash.ajax_sent=!0)))})})}(ThriveGlobal.$j); if(ThriveApprentice===undefined){ var ThriveApprentice={};} jQuery(document).ready(function (){ jQuery("#tt-favorite-lesson").click(function (){ var post_data={ action: 'thrive_appr_add_to_favorites', post_id: ThriveApprentice.current_post_id }; jQuery.post(ThriveApprentice.ajax_url, post_data, ThriveApprentice.favorite_handle); }); jQuery("#completed-lesson").change(function (){ var post_data={ action: 'thrive_appr_set_progress', post_id: ThriveApprentice.current_post_id, status: jQuery(this).prop('checked') ? ThriveApprentice.progress_status.completed:ThriveApprentice.progress_status.started }; jQuery.post(ThriveApprentice.ajax_url, post_data, ThriveApprentice.progress_handle); return false; }); ThriveApprentice.navigation_widget(); }); ThriveApprentice.progress_handle=function (response){ console.log(response); }; ThriveApprentice.favorite_handle=function (response){ if(jQuery("#tt-favorite-lesson").find(".heart").hasClass("fill")){ jQuery("#tt-favorite-lesson").find("span").html(ThriveApprentice.lang.add_to_fav); jQuery("#tt-favorite-lesson").find(".heart").removeClass("fill"); }else{ jQuery("#tt-favorite-lesson").find("span").html(ThriveApprentice.lang.remove_from_fav); jQuery("#tt-favorite-lesson").find(".heart").addClass("fill"); }}; ThriveApprentice.navigation_widget=function (){ jQuery('.opn .apw-b').on('click', function (e){ _parent=jQuery(this).parents('.ap-c').first(); _parent.children('.apw-i').slideToggle('fast'); e.preventDefault(); }); }; !function(d,l){"use strict";var e=!1,n=!1;if(l.querySelector)if(d.addEventListener)e=!0;if(d.wp=d.wp||{},!d.wp.receiveEmbedMessage)if(d.wp.receiveEmbedMessage=function(e){var t=e.data;if(t)if(t.secret||t.message||t.value)if(!/[^a-zA-Z0-9]/.test(t.secret)){for(var r,i,a,s=l.querySelectorAll('iframe[data-secret="'+t.secret+'"]'),n=l.querySelectorAll('blockquote[data-secret="'+t.secret+'"]'),o=new RegExp("^https?:$","i"),c=0;c 0){ children[0].appendChild(ak_js); }} };