/** global site functions */
/** init cufon */
Cufon.replace('h1', {
	textTransform: 'lowercase'
});
Cufon.replace('h5');
Cufon.now();
/** window checking function */
function checkWindowSize() {
    var min_width = 1000;
    var min_height = 500;
    var w_height = $(window).height();
    var w_width = $(window).width();
    /** show or hide side message based on window width */
    if(w_width <= min_width) {
        $('#side_message').fadeOut();
    } else {
        $('#side_message').fadeIn();
    }
    /** lock footer to keep it from overlapping on resize */
    if(w_height <= min_height) {
        $('#footer').addClass('locked');
    } else {
        $('#footer').removeClass('locked');
    }
}         
/** page load */
$(document).ready(function(){
    checkWindowSize();
    $('#footer').fadeIn();

	// fancy select ie6 hack
	if ($.browser.msie && $.browser.version.substr(0,1)<7) {
		$('.select li').hover(
			function() {
				$(this).find('ul').addClass('ie6Hover');
			}, function() {
				$(this).find('ul').removeClass('ie6Hover');
			});
	}
	
});
/** resize */
$(window).resize(function(){
    checkWindowSize();
});
