var image_count_sup;
var headline_count_sup;
var word_count_sup;
var current_image_sup=0;
var current_headline_sup=0;
var current_word_sup=0;
var ieMenuWidthAdj_sup=4;
var ffMenuWidthAdj_sup=17;
var menuWidth_sup;

$(document).ready(function(){
  image_count_sup = $("#banner_superior div").hide().size();
  headline_count_sup = $("div.headline").hide().size();
 
  $("#banner_superior div:eq("+current_image_sup+")").show();
  $("div.headline:eq("+current_headline_sup+")").show();
  setInterval(feature_rotate_sup,10000); //time in milliseconds
});

function feature_rotate_sup() {
  old_image_sup = current_image_sup%image_count_sup;
  new_image_sup = ++current_image_sup%image_count_sup;
  $("#banner_superior div:eq(" + new_image_sup + ")").fadeIn("slow", function() {
    $("#banner_superior div:eq(" + old_image_sup + ")").fadeOut("slow");
  });

   old_headline_sup = current_headline_sup%headline_count_sup;
   new_headline_sup = ++current_headline_sup%headline_count_sup;
  $("div.headline:eq(" + new_headline_sup + ")").fadeIn("slow", function() {
    $("div.headline:eq(" + old_headline_sup + ")").fadeOut("slow");
  });
}

