
$(document).ready(function() {

  //if twitter exists
  if ($('#twitter').length>0) { 
   
      $(function(){
	      $("#tweets").tweet({
	        join_text: "auto",
	        username: ["higdonmarathon ","higdonmarathon "],
	        avatar_size: 58,
	        count: 2,
			refresh_interval: 600,
	        loading_text: "loading tweets..."
	    });
		
  	});	
	
  }//end if twitter
  
  if ($('#training-info').length>0){

    	$('.training-wrapper').after('<div id="dot-training" class="dots clearfix">').cycle({
	        fx:     'none',
	        speed:  500,
	        timeout: 5000,
			pause: 1,
	        pager:  '#dot-training',
			cleartypeNoBg:true
	 });
  }//end if training-info

  if ($('#skiing-info').length>0){

    	$('.skiing-wrapper').after('<div id="dot-skiing" class="dots clearfix">').cycle({
	        fx:     'none',
	        speed:  500,
	        timeout: 5000,
			pause: 1,
	        pager:  '#dot-skiing',
			cleartypeNoBg:true
	 });
  }//end if skiing-info
  
  if ($('#banner').length>0){

    	$('#banner').cycle({
	        fx:     'fade',
	        speed:  500,
	        timeout: 7000,
			cleartypeNoBg:true
	 });
  }//end if banner

  
 
 
    //Cufon

	Cufon.replace('ul#main-nav li a.nav-main', {hover:true});
    Cufon.replace('#banner h2',{textShadow: '#5e768f 3px 3px'});
	Cufon.replace('.box h3',{textShadow: '#003f73 3px 3px'});
	Cufon.replace('#content h2');
	Cufon.replace('#latest-news h2');
	Cufon.replace('#twitter h3');
	
	
	
});





