!function(t){"function"==typeof define&&define.amd?define(["jquery"],t):t("object"==typeof module&&module.exports?require("jquery"):jQuery)}(function(t){function e(t){return t.replace(/(:|\.|\/)/g,"\\$1")}var o="1.6.0",i={},l={exclude:[],excludeWithin:[],offset:0,direction:"top",delegateSelector:null,scrollElement:null,scrollTarget:null,beforeScroll:function(){},afterScroll:function(){},easing:"swing",speed:400,autoCoefficient:2,preventDefault:!0},s=function(e){var o=[],i=!1,l=e.dir&&"left"===e.dir?"scrollLeft":"scrollTop";return this.each(function(){var e=t(this);return this!==document&&this!==window?!document.scrollingElement||this!==document.documentElement&&this!==document.body?void(e[l]()>0?o.push(this):(e[l](1),i=e[l]()>0,i&&o.push(this),e[l](0))):(o.push(document.scrollingElement),!1):void 0}),o.length||this.each(function(){"BODY"===this.nodeName&&(o=[this])}),"first"===e.el&&o.length>1&&(o=[o[0]]),o};t.fn.extend({scrollable:function(t){var e=s.call(this,{dir:t});return this.pushStack(e)},firstScrollable:function(t){var e=s.call(this,{el:"first",dir:t});return this.pushStack(e)},smoothScroll:function(o,i){if(o=o||{},"options"===o)return i?this.each(function(){var e=t(this),o=t.extend(e.data("ssOpts")||{},i);t(this).data("ssOpts",o)}):this.first().data("ssOpts");var l=t.extend({},t.fn.smoothScroll.defaults,o),s=function(o){var i=this,s=t(this),n=t.extend({},l,s.data("ssOpts")||{}),c=l.exclude,a=n.excludeWithin,r=0,h=0,u=!0,d={},p=t.smoothScroll.filterPath(location.pathname),f=t.smoothScroll.filterPath(i.pathname),m=location.hostname===i.hostname||!i.hostname,g=n.scrollTarget||f===p,v=e(i.hash);if(n.scrollTarget||m&&g&&v){for(;u&&r<c.length;)s.is(e(c[r++]))&&(u=!1);for(;u&&h<a.length;)s.closest(a[h++]).length&&(u=!1)}else u=!1;u&&(n.preventDefault&&o.preventDefault(),t.extend(d,n,{scrollTarget:n.scrollTarget||v,link:i}),t.smoothScroll(d))};return null!==o.delegateSelector?this.undelegate(o.delegateSelector,"click.smoothscroll").delegate(o.delegateSelector,"click.smoothscroll",s):this.unbind("click.smoothscroll").bind("click.smoothscroll",s),this}}),t.smoothScroll=function(e,o){if("options"===e&&"object"==typeof o)return t.extend(i,o);var l,s,n,c,a,r=0,h="offset",u="scrollTop",d={},p={};"number"==typeof e?(l=t.extend({link:null},t.fn.smoothScroll.defaults,i),n=e):(l=t.extend({link:null},t.fn.smoothScroll.defaults,e||{},i),l.scrollElement&&(h="position","static"===l.scrollElement.css("position")&&l.scrollElement.css("position","relative"))),u="left"===l.direction?"scrollLeft":u,l.scrollElement?(s=l.scrollElement,/^(?:HTML|BODY)$/.test(s[0].nodeName)||(r=s[u]())):s=t("html, body").firstScrollable(l.direction),l.beforeScroll.call(s,l),n="number"==typeof e?e:o||t(l.scrollTarget)[h]()&&t(l.scrollTarget)[h]()[l.direction]||0,d[u]=n+r+l.offset,c=l.speed,"auto"===c&&(a=Math.abs(d[u]-s[u]()),c=a/l.autoCoefficient),p={duration:c,easing:l.easing,complete:function(){l.afterScroll.call(l.link,l)}},l.step&&(p.step=l.step),s.length?s.stop().animate(d,p):l.afterScroll.call(l.link,l)},t.smoothScroll.version=o,t.smoothScroll.filterPath=function(t){return t=t||"",t.replace(/^\//,"").replace(/(?:index|default).[a-zA-Z]{3,4}$/,"").replace(/\/$/,"")},t.fn.smoothScroll.defaults=l}),jQuery.cookie=function(t,e,o){if(arguments.length>1&&"[object Object]"!==String(e)){if(o=jQuery.extend({},o),(null===e||void 0===e)&&(o.expires=-1),"number"==typeof o.expires){var i=o.expires,l=o.expires=new Date;l.setDate(l.getDate()+i)}return e=String(e),document.cookie=[encodeURIComponent(t),"=",o.raw?e:encodeURIComponent(e),o.expires?"; expires="+o.expires.toUTCString():"",o.path?"; path="+o.path:"",o.domain?"; domain="+o.domain:"",o.secure?"; secure":""].join("")}o=e||{};var s,n=o.raw?function(t){return t}:decodeURIComponent;return(s=new RegExp("(?:^|;)"+encodeURIComponent(t)+"=([^;]*)").exec(document.cookie))?n(s[1]):null},jQuery(document).ready(function(t){if("undefined"!=typeof tocplus){if(t.fn.shrinkTOCWidth=function(){t(this).css({width:"auto",display:"table"}),/MSIE 7\./.test(navigator.userAgent)&&t(this).css("width","")},1==tocplus.smooth_scroll){var e=hostname=pathname=qs=hash=null;t("body a").click(function(){if(hostname=t(this).prop("hostname"),pathname=t(this).prop("pathname"),qs=t(this).prop("search"),hash=t(this).prop("hash"),pathname.length>0&&"/"!=pathname.charAt(0)&&(pathname="/"+pathname),window.location.hostname==hostname&&window.location.pathname==pathname&&window.location.search==qs&&""!==hash){var o=hash.replace(/([ !"$%&'()*+,.\/:;<=>?@[\]^`{|}~])/g,"\\$1");t(o).length>0?e=hash:(anchor=hash,anchor=anchor.replace("#",""),e='a[name="'+anchor+'"]',0==t(e).length&&(e="")),offset="undefined"!=typeof tocplus.smooth_scroll_offset?-1*tocplus.smooth_scroll_offset:t("#wpadminbar").length>0&&t("#wpadminbar").is(":visible")?-30:0,e&&t.smoothScroll({scrollTarget:e,offset:offset})}})}if("undefined"!=typeof tocplus.visibility_show){var o="undefined"!=typeof tocplus.visibility_hide_by_default?!0:!1;if(t.cookie)var i=t.cookie("tocplus_hidetoc")?tocplus.visibility_show:tocplus.visibility_hide;else var i=tocplus.visibility_hide;o&&(i=i==tocplus.visibility_hide?tocplus.visibility_show:tocplus.visibility_hide),t("#toc_container p.toc_title").append(' <span class="toc_toggle"><span class="toc_brackets">[</span><a href="#">'+i+'</a><span class="toc_brackets">]</span></span>'),i==tocplus.visibility_show&&(t("ul.toc_list").hide(),t("#toc_container").addClass("contracted").shrinkTOCWidth()),t("span.toc_toggle a").click(function(e){switch(e.preventDefault(),t(this).html()){case t("<div/>").html(tocplus.visibility_hide).text():t(this).html(tocplus.visibility_show),t.cookie&&(o?t.cookie("tocplus_hidetoc",null,{path:"/"}):t.cookie("tocplus_hidetoc","1",{expires:30,path:"/"})),t("ul.toc_list").hide("fast"),t("#toc_container").addClass("contracted").shrinkTOCWidth();break;case t("<div/>").html(tocplus.visibility_show).text():default:t(this).html(tocplus.visibility_hide),t.cookie&&(o?t.cookie("tocplus_hidetoc","1",{expires:30,path:"/"}):t.cookie("tocplus_hidetoc",null,{path:"/"})),t("#toc_container").css("width",tocplus.width).removeClass("contracted"),t("ul.toc_list").show("fast")}})}}});
jQuery.fn.exists=function(callback){
var args=[].slice.call(arguments, 1);
if(this.length){
callback.call(this, args);
}
return this;
};
jQuery(document).ready(function($){
var scrollToAnchor=function(id, event){
var elem=$("a[name='"+ id +"']");
if(typeof(elem.offset())==="undefined"){
elem=$("#"+id);
}
if(typeof(elem.offset())!=="undefined"){
event.preventDefault();
var scroll_to=elem.offset().top;
$('html, body').removeClass('mobile-menu-active').animate({
scrollTop: scroll_to
}, 600, 'swing', function(){ if(scroll_to > 46) window.location.hash=id; });
}};
$("a").click(function(event){
var href=$(this).attr("href");
if(href&&href.match("#")&&href!=='#'){
var parts=href.split('#'),
url=parts[0],
target=parts[1];
if((!url||url==window.location.href.split('#')[0])&&target)
scrollToAnchor(target, event);
}});
});
if(mts_customscript.responsive&&mts_customscript.nav_menu!='none'){
jQuery(document).ready(function($){
$('#primary-navigation').append('<div id="mobile-menu-overlay" />');
if(mts_customscript.nav_menu=='both'&&!$('.navigation.mobile-only').length){
$('.navigation').not('.mobile-menu-wrapper').find('.menu').clone().appendTo('.mobile-menu-wrapper').hide();
}
$('.toggle-mobile-menu').click(function(e){
e.preventDefault();
e.stopPropagation();
$('body').toggleClass('mobile-menu-active');
if($('body').hasClass('mobile-menu-active')){
if($(document).height() > $(window).height()){
var scrollTop=($('html').scrollTop()) ? $('html').scrollTop():$('body').scrollTop();
$('html').addClass('noscroll').css('top', -scrollTop);
}
$('#mobile-menu-overlay').fadeIn();
}else{
var scrollTop=parseInt($('html').css('top'));
$('html').removeClass('noscroll');
$('html,body').scrollTop(-scrollTop);
$('#mobile-menu-overlay').fadeOut();
}});
}).on('click', function(event){
var $target=jQuery(event.target);
if(( $target.hasClass("fa")&&$target.parent().hasClass("toggle-caret"))||$target.hasClass("toggle-caret")){
return;
}
jQuery('body').removeClass('mobile-menu-active');
jQuery('html').removeClass('noscroll');
jQuery('#mobile-menu-overlay').fadeOut();
});
}
jQuery(document).ready(function($){
function mtsDropdownMenu(){
var wWidth=$(window).width();
if(wWidth > 865){
$('.navigation ul.sub-menu, .navigation ul.children').hide();
var timer;
var delay=100;
$('.navigation li').hover(function(){
var $this=$(this);
timer=setTimeout(function(){
$this.children('ul.sub-menu, ul.children').slideDown('fast');
}, delay);
},
function(){
$(this).children('ul.sub-menu, ul.children').hide();
clearTimeout(timer);
}
);
}else{
$('.navigation li').unbind('hover');
$('.navigation li.active > ul.sub-menu, .navigation li.active > ul.children').show();
}}
mtsDropdownMenu();
$(window).resize(function(){
mtsDropdownMenu();
});
});
jQuery(document).ready(function($){
$('.widget_nav_menu, .navigation .menu').addClass('toggle-menu');
$('.toggle-menu ul.sub-menu, .toggle-menu ul.children').addClass('toggle-submenu');
$('.toggle-menu ul.sub-menu').parent().addClass('toggle-menu-item-parent');
$('.toggle-menu .toggle-menu-item-parent').append('<span class="toggle-caret"><i class="fa fa-plus"></i></span>');
$('.toggle-caret').click(function(e){
e.preventDefault();
$(this).parent().toggleClass('active').children('.toggle-submenu').slideToggle('fast');
});
});
jQuery(document).ready(function($){
var lazyloadAvatar=function(){
$('.comment-author .avatar').each(function(){
var distanceToTop=$(this).offset().top;
var scroll=$(window).scrollTop();
var windowHeight=$(window).height();
var isVisible=distanceToTop - scroll < windowHeight;
if(isVisible){
var hashedUrl=$(this).attr('data-src');
if(hashedUrl){
$(this).attr('src',hashedUrl).removeClass('loading');
}}
});
};
if($('.comment-author .avatar').length > 0){
$('.comment-author .avatar').each(function(i,el){
$(el).attr('data-src', el.src).removeAttr('src').addClass('loading');
});
$(function(){
$(window).scroll(function(){
lazyloadAvatar();
});
});
lazyloadAvatar();
}});
jQuery(document).ready(function($){
(function(d, s){
var js, fjs=d.getElementsByTagName(s)[0], load=function(url, id){
if(d.getElementById(id)){return;}
js=d.createElement(s); js.src=url; js.id=id;
fjs.parentNode.insertBefore(js, fjs);
};
jQuery('.facebook_like').exists(function(){
load('//connect.facebook.net/en_US/all.js#xfbml=1&version=v2.8', 'fbjssdk');
});
}(document, 'script'));
});
!function(t,i){"function"==typeof define&&define.amd?define([],i):"object"==typeof exports?module.exports=i():t.Layzr=i()}(this,function(){"use strict";function t(t){this._lastScroll=0,this._ticking=!1,t=t||{},this._optionsContainer=document.querySelector(t.container)||window,this._optionsSelector=t.selector||"[data-layzr]",this._optionsAttr=t.attr||"data-layzr",this._optionsAttrRetina=t.retinaAttr||"data-layzr-retina",this._optionsAttrBg=t.bgAttr||"data-layzr-bg",this._optionsAttrHidden=t.hiddenAttr||"data-layzr-hidden",this._optionsThreshold=t.threshold||0,this._optionsCallback=t.callback||null,this._retina=window.devicePixelRatio>1,this._srcAttr=this._retina?this._optionsAttrRetina:this._optionsAttr,this._nodes=document.querySelectorAll(this._optionsSelector),this._handlerBind=this._requestScroll.bind(this),this._create()}return t.prototype._requestScroll=function(){this._lastScroll=this._optionsContainer===window?window.pageYOffset:this._optionsContainer.scrollTop+this._getOffset(this._optionsContainer),this._requestTick()},t.prototype._requestTick=function(){this._ticking||(requestAnimationFrame(this.update.bind(this)),this._ticking=!0)},t.prototype._getOffset=function(t){return t.getBoundingClientRect().top+window.pageYOffset},t.prototype._getContainerHeight=function(){return this._optionsContainer.innerHeight||this._optionsContainer.offsetHeight},t.prototype._create=function(){this._handlerBind(),this._optionsContainer.addEventListener("scroll",this._handlerBind,!1),this._optionsContainer.addEventListener("resize",this._handlerBind,!1)},t.prototype._destroy=function(){this._optionsContainer.removeEventListener("scroll",this._handlerBind,!1),this._optionsContainer.removeEventListener("resize",this._handlerBind,!1)},t.prototype._inViewport=function(t){var i=this._lastScroll,e=i+this._getContainerHeight(),o=this._getOffset(t),n=o+this._getContainerHeight(),s=this._optionsThreshold/100*window.innerHeight;return n>=i-s&&e+s>=o&&!t.hasAttribute(this._optionsAttrHidden)},t.prototype._reveal=function(t){var i=t.getAttribute(this._srcAttr)||t.getAttribute(this._optionsAttr);t.hasAttribute(this._optionsAttrBg)?t.style.backgroundImage="url("+i+")":t.setAttribute("src",i),"function"==typeof this._optionsCallback&&this._optionsCallback.call(t),t.removeAttribute(this._optionsAttr),t.removeAttribute(this._optionsAttrRetina),t.removeAttribute(this._optionsAttrBg),t.removeAttribute(this._optionsAttrHidden)},t.prototype.updateSelector=function(){this._nodes=document.querySelectorAll(this._optionsSelector)},t.prototype.update=function(){for(var t=this._nodes.length,i=0;t>i;i++){var e=this._nodes[i];e.hasAttribute(this._optionsAttr)&&this._inViewport(e)&&this._reveal(e)}this._ticking=!1},t});
function initLayzr(){
var layzr=new Layzr({
selector: '[data-layzr]',
attr: 'data-layzr',
});
}
jQuery(document).ready(function($){
initLayzr();
});
jQuery(document).ajaxComplete(function(){
initLayzr();
});
var advanced_ads_adblocker_test=true;
var _gaq=_gaq||[];var stFailbackDefaults={trackScrolling:true,stLogInterval:10,docTitle:window.document.title,cutOffTime:900,trackNoEvents:false,trackNoMaxTime:false};window.total_time=0;var stIntervalObj=null;var EventNONInteraction=false;var Frequency=null;var Repentance=null;function TrackingLogTime(a){return a[0]==50?(parseInt(a[1])+1)+":00":(a[1]||"0")+":"+(parseInt(a[0])+10)}function stInitializeControlVars(){if(typeof window.trackScrolling=="undefined"){window.trackScrolling=window.stFailbackDefaults.trackScrolling}if(typeof window.stLogInterval=="undefined"){window.stLogInterval=window.stFailbackDefaults.stLogInterval*1000}if(typeof window.docTitle=="undefined"){window.docTitle=window.stFailbackDefaults.docTitle}if(typeof window.cutOffTime=="undefined"){window.cutOffTime=window.stFailbackDefaults.cutOffTime}if(typeof window.trackNoEvents=="undefined"){window.trackNoEvents=window.stFailbackDefaults.trackNoEvents}if(typeof window.trackNoMaxTime=="undefined"){window.trackNoMaxTime=window.stFailbackDefaults.trackNoMaxTime}if(window.trackScrolling===true){setTimeout(function(){window.onscroll=function(){window.onscroll=null;ga("send","event","Scroll",window.docTitle,"scrolled")}},2000)}}if(window.trackNoEvents===false){function startTimeTracking(a){stInitializeControlVars();window.stIntervalObj=window.setInterval(function(){total_time+=10;if(window.trackNoMaxTime===true){total_time=1}if(window.total_time<=window.cutOffTime){a=TrackingLogTime(a.split(":").reverse());ga("send","event","Time","Log",a)}else{window.clearInterval(window.stIntervalObj)}},(window.stLogInterval))}jQuery(document).ready(function(){startTimeTracking("00")})}if(window.trackScrollingPercentage===true){Frequency=ScrollingPercentageNumber;Repentance=100/ScrollingPercentageNumber;var ScrollMatrix=new Array();for(ix=0;ix<Repentance;ix++){ScrollMatrix[ix]=[Frequency,"false"];Frequency=ScrollingPercentageNumber+Frequency}$(document).scroll(function(a){for(iz=0;iz<ScrollMatrix.length;iz++){if(($(window).scrollTop()+$(window).height()>=$(document).height()*ScrollMatrix[iz][0]/100)&&(ScrollMatrix[iz][1]=="false")){ScrollMatrix[iz][1]="true";ga("send","event","Percentage Page Scroll",window.docTitle,ScrollMatrix[iz][0]+"%",{nonInteraction:EventNONInteraction})}}})};