// JavaScript Document
	$(window).load(function() {
	$('#slider').nivoSlider({
        effect:'fold', //Specify sets like: 'fold,fade,sliceDown, sliceDownLeft, sliceUp, sliceUpLeft, sliceUpDown, sliceUpDownLeft'    

        slices:	20,
        animSpeed:400,
        pauseTime:6000,
        startSlide:0, //Set starting Slide (0 index)
        directionNav:true, //Next & Prev
        directionNavHide:false, //Only show on hover
        controlNav:false, //1,2,3...
        controlNavThumbs:false, //Use thumbnails for Control Nav
        controlNavThumbsFromRel:false, //Use image rel for thumbs
        controlNavThumbsSearch: '.jpg', //Replace this with...
        controlNavThumbsReplace: '_thumb.jpg', //...this in thumb Image src
        keyboardNav:true, //Use left & right arrows
        pauseOnHover:true, //Stop animation while hovering
        manualAdvance:false, //Force manual transitions
        captionOpacity:1, //Universal caption opacity
        beforeChange: function(){},
        afterChange: function(){ Cufon.refresh();$('.nivo-caption').animate({right:'76'},400)},
        slideshowEnd: function(){} //Triggers after all slides have been shown
    });
	Cufon.refresh();
    });
$(document).ready(function() {
   SetData();
   function SetData() {
	    var now = new Date();
	    $('.date').html(now.getDate()+'.');
		mounth=now.getMonth()+1;
		if (mounth<10) {mounth='0'+mounth}
	    $('.date').append(mounth+'.');
		$('.date').append(now.getFullYear()+' / ');
		hour=now.getHours();
	    minutes=now.getMinutes();
	    if (minutes<10) {minutes='0'+minutes};
	    if (hour<=12) {$('.date').append(hour+'.'+minutes+' a.m.');}  else{$('.date').append(hour-12+'.'+minutes+' p.m.');}
	}
  	setInterval(SetData,60); 
});

$(document).ready(function(){
	/* The following code is executed once the DOM is loaded */
	
	$('.sponsorFlip').bind("click",function(){
		
		// $(this) point to the clicked .sponsorFlip element (caching it in elem for speed):
		
		var elem = $(this);
		
		// data('flipped') is a flag we set when we flip the element:
		
		if(elem.data('flipped'))
		{
			// If the element has already been flipped, use the revertFlip method
			// defined by the plug-in to revert to the default state automatically:
			
			elem.revertFlip();
			
			// Unsetting the flag:
			elem.data('flipped',false)
		}
		else
		{
			// Using the flip method defined by the plugin:
			
			elem.flip({
				direction:'lr',
				speed: 350,
				onBefore: function(){
					// Insert the contents of the .sponsorData div (hidden from view with display:none)
					// into the clicked .sponsorFlip div before the flipping animation starts:
					
					elem.html(elem.siblings('.sponsorData').html());
				}
			});
			
			// Setting the flag:
			elem.data('flipped',true);
		}
	});
	
});
$(function() {
		// set opacity to nill on page load
		$("ul#menu span").css("opacity","0");
		// on mouse over
		$("ul#menu span").hover(function () {
			// animate opacity to full
			$(this).stop().animate({
				opacity: 1
			}, 'slow');
		},
		// on mouse out
		function () {
			// animate opacity to nill
			$(this).stop().animate({
				opacity: 0
			}, 'slow');
		});
	});
	
$(document).ready(function(){
         $('#top-left').hover(function(){
		         $(this).children('.front').stop().animate({'top' : '150px', 'left' : '300px'}, 500);
		 }, function(){$(this).children('.front').stop().animate({'top' : '0px', 'left' : '0px'}, 500);});
		 $('#top-center').hover(function(){
		         $(this).children('.front').stop().animate({'top' : '150px', 'left' : '300px'}, 500);
		 }, function(){$(this).children('.front').stop().animate({'top' : '0px', 'left' : '0px'}, 500);});
		 $('#top-right').hover(function(){
		         $(this).children('.front').stop().animate({'top' : '150px', 'left' : '300px'}, 500);
		 }, function(){$(this).children('.front').stop().animate({'top' : '0px', 'left' : '0px'}, 500);});
});	
	

