var iQuote = -1;
function refreshQuote() {
	var quotes = [
		'The largest producer of playing cards in the USA, the USPC, Ohio, vends over 100,000,000 decks annually',
		'The tallest skyscraper made of cards was made by Bryan Berg and was 25 feet 9 7/16 inches tall',
		'The King of Hearts is the only king without a mustache',
		'The proper name for a Jack of Hearts is One Eyed Jack or La Hire',
		'The proper name for a Jack of Spades is One Eyed Jack or Ogier',
		'The proper name for a Jack of Diamonds is Hector',
		'The proper name for a Jack of Clubs is Lancelot',
		'The proper name for a Queen of Hearts is Judith',
		'The proper name for a Queen of Spades is Palas',
		'The proper name for a Queen of Clubs is Argine',
		'The proper name for a Queen of Diamonds is Rachel',
		'The proper name for a King of Hearts is Suicide King, Charlemagne',
		'The proper name for a King of Spades is David',
		'The proper name for a King of Diamonds is Caesar',
		'The proper name for a King of Clubs is Alexander',
		'A deck of cards is statistically random with five interlocking shuffles',
		'Some Italian cards do not have any numbers and letters identifying their value',
		'The standard 52-card deck is commonly known as a "poker" deck in Taiwan, Japan, China, and South Korea',
		'There are exactly 52! (about 8 × 10<sup>67</sup>) possible ways to order the cards in a 52-card deck',
		'Prior to 1961 in Las Vegas casinos, all blackjack was being dealt from a single deck',
		'Cards are popular with magicians because they are inexpensive, versatile, and easily available',
		'The beer card a slang term used to describe the 7 of diamonds playing card in bridge.',
		'Cartomancy is fortune-telling or divination using a deck of cards'
	];
	
	do {
		var i = Math.floor(Math.random()*quotes.length);
	} while (i==iQuote);
	iQuote = i;
	
	var quote = quotes[iQuote];
	$('#quote-text').html(quote);
	
	return false;
}

$(document).ready( function(){
	$('.rounded').corners();

	refreshQuote();
	$('#quote-refresh').click(refreshQuote);

	$('.hoverable').each(function(){
		$this = $(this);
		$next = $this.next('.hoverable2');
		
		$this.hover(
			function(){
				$this.hide();
				$next.show();
			},
			function() {}
		);
		
		$next.hover(
			function() {},
			function(){
				$next.hide();
				$this.show();
			}
		);
	});
});
