$(document).ready(function() {
// Function for main slider
  $('.main_slideshow').before('<div id="slide-nav">');
  
  $('.main_slideshow').cycle({
    fx: 'fade',
    timeout: 4000, // Change the time with this number. It's in thousands, so 3000 = 3 seconds, 15000 = 15 seconds, and so on.
    pause: true,
    pauseOnPagerHover: true,
    pager: "#slide-nav"
  });
  
// Bottom slider
  $("div#browsable").scrollable({ 
      circular: true,
      speed: 1000 // Change the time with this number. It's in thousands, so 3000 = 3 seconds, 15000 = 15 seconds, and so on.
      }).navigator();
  
// IE6 png fix
    if($.browser.msie && $.browser.version=="6.0") {
        DD_belatedPNG.fix('*');
    }
  
// Clears default form values when clicked

    jQuery.fn.cleardefault = function() {
    return this.focus(function() {
      if( this.value == this.defaultValue ) {
        this.value = "";
      }
    }).blur(function() {
      if( !this.value.length ) {
        this.value = this.defaultValue;
      }
    });
  };
  $(".clearit input, .clearit textarea, .clearit").cleardefault();
  
// Font resize instance  
  fontResize();
});

// Font resize function
function fontResize(){
    $('.text_size_list li a').click(function(){
        if($(this).hasClass('min')){
            $('#footer').css('font-size','65%');
        }
        else if($(this).hasClass('normal')){
            $('#footer').css('font-size','75%');
        }
        else if($(this).hasClass('max')){
            $('#footer').css('font-size','100%');
        }
        return false;
    });
}

// Main nav hover function
$(function(){
    $("ul#main_nav li").hover(function(){
        $(this).addClass("hover");
        $('ul:first',this).css('visibility', 'visible');
    }, function(){
        $(this).removeClass("hover");
        $('ul:first',this).css('visibility', 'hidden');
    });
    });


// learn more hover
$(document).ready(function() {
$(".get_started").hover(
function() {
    $(this).css('backgroundPosition', '0 -26px');
}, function() {
    $(this).css('backgroundPosition', '0 0');
});
});
