$(document).ready(function() {
	/* ******** sifr - replaces tags with cool font ******** */
	$.sifr({
		path: 'fonts/',
		save: true
	});
	//$('h1, h2, h3, h4, .submenu-heading').sifr({ font: "bellgothic" }); 
	
	$('#faq .question').click(function() {
		$('#a'+this.id).toggle(400);
	});
    
    $('#country').change(function() {
		var url = "includes/getStates.php?country="+this.value;        
        $.getJSON(url, function(data) {
			var output = '<option value="any state">Any</option>';
			for(var i = 0; i < data.states.length; i++){
				output += '<option value="'+data.states[i]+'">'+data.states[i]+'</option>';
			}
			
			$('#state').html(output);
        });

	});
    
	$('#state').change(function() {
		if (this.value == "OT") {
			$('#otherState').attr("disabled", false);
		} else {
			$('#otherState').attr("disabled", true);
			$('#otherState').attr("value", '');
		}
	});
});

