(function() {
try {
    /**/

(function(){

	function getCookies(source, delim1, delim2) {
		var c = source.split(delim1);
		var o = {};

		for (var i = 0; i < c.length; i++) {
			var cSplit = c[i].split(delim2);
			o[ cSplit[0].replace(" ","") ] = cSplit[1];
		}

		return o;
	}

		function pageViews(mtid) {
		if (!mtid) {
			return
		}

		var cookies = getCookies(document.cookie, ";", "=");
		
		if (cookies.hasOwnProperty("mi_pgs") == false) {
			var seen = 1;
		} else {
			var seen = parseInt(cookies.mi_pgs);
			seen += 1;
		}

		if (seen >= 5) {
			(new Image).src = "//pixel.mathtag.com/event/img?mt_id=525856&mt_adid=119635&mt_nsync=0&mt_uuid=f15c635b-a2d6-4b00-a19f-a78f39503620";
		}
		

		document.cookie = "mi_pgs=" + seen + "; path=/";

	}

	pageViews(501667)


	
	var overFiveMin = setInterval(function() {
		var cookies = getCookies(document.cookie, ";", "=");
		if (cookies.hasOwnProperty("mi_tos") == false) {
			document.cookie = "mi_tos=0; path=/"
		} else {
			if (cookies.mi_tos >= 300) {
				(new Image).src = "//pixel.mathtag.com/event/img?mt_id=525857&mt_adid=119635&mt_nsync=0&mt_uuid=f15c635b-a2d6-4b00-a19f-a78f39503620";
				clearInterval(overFiveMin);
			} else {
				document.cookie = "mi_tos=" + (parseInt(cookies.mi_tos) + 1) + "; path=/";
			}
		}
	}, 1000);



}());

(function() {
    try {
        if (document.getElementById('mm_sync_back_ground'))
           return;
        var frm = document.createElement('iframe');
        frm.style.visibility = 'hidden';
        frm.style.display = 'none';
        frm.src = "https://pixel.mathtag.com/sync/iframe?mt_uuid=f15c635b-a2d6-4b00-a19f-a78f39503620&no_iframe=1&mt_adid=119635&source=mathtag";
        frm.setAttribute("id", "mm_sync_back_ground");
        frm.title="MediaMath Advertising";

        if (document.body)
            document.body.appendChild(frm);
        else
            if (document.head)
                document.head.appendChild(frm);
    }
    catch(ex)
    {
        document.createElement("img").src="//pixel.mathtag.com/error/img?error_domain=synciframe&what="+encodeURIComponent(ex.message);
    }
})();

}
catch(ex)
{
   document.createElement("img").src="//pixel.mathtag.com/error/img?error_domain=wrap_js&what="+encodeURIComponent(ex.message);
}
})();
