$(document).ready(function() {
		
		//if (screen.width <= 699) {document.location = "http://mobile.awesomecompany.ca";}
		

		//Slider
		$(".topMenuAction").click( function() {
			if ($("#openCloseIdentifier").is(":hidden")) {
				$("#slider").animate({ 
					marginTop: "-139px"
					}, 500 );
				$("#topMenuImage").html('');
				$("#openCloseIdentifier").show();
			} else {
				$("#slider").animate({ 
					marginTop: "0px"
					}, 500 );
				$("#topMenuImage").html('');
				$("#openCloseIdentifier").hide();
			}
		});  

		//Fancybox
		$("a.enlarge").fancybox();

		//Full Caption Sliding (Hidden to Visible)
		$('.boxgrid.captionfull').hover(function(){
		$(".cover", this).stop().animate({top:'110px'},{queue:false,duration:160});
		}, function() {
		$(".cover", this).stop().animate({top:'260px'},{queue:false,duration:160});
		});
	

});

//Random Image
var theImages = new Array() // do not change this

		theImages[0] = 'images/banners/banner-1.jpg'
		theImages[1] = 'images/banners/banner-4.jpg'
		theImages[2] = 'images/banners/banner-5.jpg'
		theImages[3] = 'images/banners/banner-6.jpg'

		var j = 0
		var p = theImages.length;
		var preBuffer = new Array()
		for (i = 0; i < p; i++){
		preBuffer[i] = new Image()
		preBuffer[i].src = theImages[i]
		}
		var whichImage = Math.round(Math.random()*(p-1));
		function showImage(){
		document.write('<img src="'+theImages[whichImage]+'" alt="Awesome Company. PRINT.WEB.BRAND.VIDEO">');
		}

//Font Replacer
Cufon.replace('h1');
Cufon.replace('h2');
Cufon.replace('h3');
Cufon.replace('.single_image');
Cufon.replace('.link');



