// Smooth Scroll
$(function(){
 
    $('a[href*=#]').click(function() {
 
    if (location.pathname.replace(/^\//,'') == this.pathname.replace(/^\//,'') 
        && location.hostname == this.hostname) {
 
            var $target = $(this.hash);
 
            $target = $target.length && $target || $('[name=' + this.hash.slice(1) +']');
 
            if ($target.length) {
 
                var targetOffset = $target.offset().top;
 
                $('html,body').animate({scrollTop: targetOffset}, 600);
 
                return false;
 
            }
 
        }
 
    });
 
});
// DROPDOWN MENU
$(function(){
	$("#top_menu li > a").addClass("cufon");
	$("#top_menu ul ul li > a").removeClass("cufon");
	Cufon.refresh();
	$("#top_menu ul ul").css({display: "none"});
	$("#top_menu ul ul ul").css({display: "none"});
	$('#top_menu ul li').hover(function(){
		$('.cufon', this).addClass("current");
		$('ul:first', this).slideDown(140);
	},
	function(){
		$('ul:first', this).slideUp(75);
		$('.cufon', this).removeClass("current");
	});
});

// PrettyPhoto Setting
$(function() {	
	$("a[rel^='prettyPhoto']").prettyPhoto({animationSpeed:'slow',theme:'dark_rounded'}); 
});
