$(document).ready(function(){
	setBrowser();
	$('body,html').animate({scrollTop:0},1);
	$('div.upper li.page_item').prepend('<span>&nbsp;</span>');
	$('div.upper li.page_item a').hover(function(){
		$(this).stop(true).animate({left:'-5px'}, 300, 'easeOutQuad');
	}, function(){
		$(this).stop(true).animate({left:'-22px'}, 400, 'easeInOutBack');
	});
	/* Establish Pseudo Classes ---------------------------------------- */
	$('ul li:first-child').addClass('first-child');
	$('ul li:last-child').addClass('last-child');
	$('ul li:only-child').addClass('solo');
});
function setBrowser(){
	var browser;
	var $mobile = (navigator.userAgent.match(/(?:iPhone|iPad|iPod|Android)/i) != null);
	if(navigator.userAgent.match('MSIE 6')){
		browser = "ie6";
	}else if(navigator.userAgent.match('MSIE 7')){
		browser = "ie7";
	}else if(navigator.userAgent.match('MSIE 8')){
		browser = "ie8";
	}else if(navigator.userAgent.match('MSIE 9')){
		browser = "ie9";
	}else if(navigator.userAgent.match('MSIE')){
		browser = "ie";
	}else if(navigator.userAgent.match('Firefox')){
		browser = "gecko";
	}else if(navigator.userAgent.match('AppleWebKit')){
		browser = "webkit";
	}else if($mobile){
		browser = "mobile";
	}
	$('body').addClass(browser);
}
Cufon.replace('#main h2.pageTitle, #main h2.subTitle, h2.Heading span:not(.nocufon), h2.blogTitle', {
	textShadow: '1px 1px 0px #2fb1e3',
	fontSize: '24px',
	lineHeight: '24px'
});
Cufon.replace('#tagline', {
    textShadow: '1px 1px 0px #D8D3D8',
	fontSize: '24px',
	lineHeight: '24px'
});
Cufon.replace('#tagline span', {
	textShadow: '1px 1px 0px #D8D3D8',
	fontSize: '20px',
	lineHeight: '20px'
});
Cufon.replace('.upper li.page_item, .lower h2', {
	textShadow: '1px 1px 0px #2fb1e3',
	fontSize: '18px',
	lineHeight: '18px'
});
Cufon.replace('.lower li.page_item, .vevent, #sidebar .event', {
	textShadow: '1px 1px 0px #2fb1e3',
	fontSize: '13px',
	lineHeight: '13px',
	hover: true,
	hoverables: { a: true }
});
if(!Cufon){
    var Cufon = {};   
    Cufon.refresh = function() {};
};
