
jQuery(function( $ ){
	$('#toc a').click(function(){//$.scrollTo works EXACTLY the same way, but scrolls the whole screen
		$.scrollTo( this.hash, 1200);
		return false;
	});
});
jQuery(function( $ ){
	$('#speakers_overview a').click(function(){//$.scrollTo works EXACTLY the same way, but scrolls the whole screen
		$.scrollTo( this.hash, 1500, {offset: -104});
		return false;
	});
});


$(function(){
    $('div.fadein div:gt(0)').hide();
    $('div.banner_subtext div:gt(0)').hide();
    $('div.banner_subtext :first-child').fadeIn(3000); 
    $('div.award div:gt(0)').hide();
    $('div.nav-controller div:gt(0)').hide();
    setInterval(function(){                    // javascript do whatever is inside every x milliseconds
      $('div.fadein :first-child').fadeOut(3000)   // all elements inside div.fadein > select all elements that are the first-child of their parent > fade out
         .next('div').delay(0).fadeIn(3000)                 // go to the next img element > fade in
         .end()                                // end the most recent filtering option and return the set of matched elements to it's previous state
         .appendTo('div.fadein');
      $('div.banner_subtext :first-child').fadeOut(3000)   // all elements inside div.banner_subtext > select all elements that are the first-child of their parent > fade out
         .next('div').delay(0).fadeIn(3000)                 // go to the next img element > fade in
         .end()                                // end the most recent filtering option and return the set of matched elements to it's previous state
         .appendTo('div.banner_subtext');   
      $('div.award :first-child').fadeOut(3000)   // all elements inside div.award > select all elements that are the first-child of their parent > fade out
         .next('div').delay(0).fadeIn(3000)                 // go to the next img element > fade in
         .end()                                // end the most recent filtering option and return the set of matched elements to it's previous state
         .appendTo('div.award');  
      $('div.nav-controller :first-child').fadeOut(3000)   // all elements inside div.fadein > select all elements that are the first-child of their parent > fade out
         .next('div').delay(0).fadeIn(3000)                 // go to the next img element > fade in
         .end()                                // end the most recent filtering option and return the set of matched elements to it's previous state
         .appendTo('div.nav-controller');   
     }, 9000);           // insert every element in the set of matched elements to the end of the target div.fadein
});

