$(function(){
	//displayOverlay();
	$(window).load(function(){
		$('#col-left,#col-right').equalizeCols();
		$('div#grey ul#imgs').cycle('fade');
		$('#orange,#grey').equalizeCols();
		if ($.cookie('mchome')==null) {
			displayOverlay();
			$.cookie('mchome', 'set', { path: '/', expires: 10 });
		}

	});
});
function closeModal() {
	$('#modalIframe').remove();
	$.modal.close();
}
function displayOverlay() {
	var iframe = document.createElement('div'); 
	$(iframe).html('<iframe src="/splash" frameborder="0" width="666" height="412"></iframe>')
	$(iframe).modal({containerCss:{width:'666px',height:'412px'}, overlay:60,
	onClose:function(){
		closeModal();
	},onShow:function(){
			$('#modalOverlay').bind('click',function(){
				closeModal();
			});
	}});
}