$(document).ready(function() {

	// And for my next trick: text sizing
	
	var altVar = false;
	var ourVar = false;
	
	function resizeText(diff) {
		var currentSize = $('#main p').css('font-size');
		if(typeof(currentSize) == 'undefined') { currentSize = $('#below-fold p').css('font-size'); altVar = true; }
		
		var strlength = currentSize.length;
		strlength = strlength - 2;
		currentSize = parseInt(currentSize.substring(0,strlength));
		
		if (diff == 'bigger') {
			currentSize = currentSize + 2;
		} else if (diff == 'smaller') {
			currentSize = currentSize - 2;
		}
		
		currentSize = currentSize + 'px';
			
		if (altVar == false) { ourVar = '#main p'; } else { ourVar = '#below-fold p'; }
		
		$(ourVar).css({fontSize: currentSize, lineHeight: '1.3em'});
	}
	
	$('#ts-plus').click(function() {
		resizeText('bigger');
		return false;
	});
	
	$('#ts-minus').click(function() {
		resizeText('smaller');
		return false;
	});
	
});