/* Author: Gijora Dammann

*/

$(document).ready(function(){
	$('.big_button').each(function(){
		var loc = $(this).children(0).attr('href');
		$(this).click(function(){
			var baseurl = window.location.href.slice(0,window.location.href.lastIndexOf('/')+1) ;
			window.location.href = baseurl + loc;
		});
		//console.log(loc);
		
	});
	/*
	$('.big_button').hover(
		function(){
			$(this).animate({background-color:})
			//$(this).addClass('deep_blue_gradient_box');
		},	
		function(){min
			//$(this).removeClass('deep_blue_gradient_box');
			//$(this).addClass('blue_gradient_box');

		});
	*/
	imgSizer.collate();
	$('.flexslider').flexslider({randomize:true,pauseOnHover:true});
	$('.next, .prev').hide();
	$('.flexslider').hover(function(){
		$('.next, .prev').fadeIn();
	},function(){
		$('.next, .prev').hide();
	});
	/*	
	$(".big_button").hover(function() {
	                $(this).stop().animate({ backgroundColor: "#ffffff"}, 500);
	                },function() {
	                $(this).stop().animate({ backgroundColor: "#49aaf3" }, 500);
	                });
	*/
	/*
	if(screen.width>=768){
		$('#nav').before('<div class="row"><div class="twelvecol last"><div id="slideshow"></div></div></div>');
		for(var i=1;i<3;i++){
			$('#slideshow').append('<img src="img/slideshow/'+i+'.jpg">');
		}
		// Simplest jQuery slideshow by Jonathan Snook
		$('#slideshow img:gt(0)').hide();
		setInterval(function () {
			$('#slideshow :first-child').fadeOut(1000)
				.next('img').fadeIn(1000).end().appendTo('#slideshow');
		}, 6500);
	}
	*/
	
});
























