$(function(){


				$('.horizCarousel').jCarouselLite({
							visible: 2,
							btnNext: ".next",
       						btnPrev: ".prev",
							hoverPause: true,
						scroll: 2,
						auto: 4000,
						speed: 1000

					});
				
				$('.sideCarousel').jCarouselLite({
							vertical: true,
							visible: 3,
							hoverPause: true,
						scroll: 3,
						auto: 4000,
						speed: 1000

					});

				

			$('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}, 1000);
									return false;
								}
							}
						});
			
			
			

			
      SexyLightbox.initialize({color:'black', dir: 'SexyWhite'});




			$('#searchbox').click(function(){
							$(this).removeClass('searchHint');
							});
														
			$('#searchbox').blur(function(){
								if($(this).val() == ""){
									$(this).addClass('searchHint');
								}
							});
			// now add the background style
			if($('#searchbox').val() == ""){
									$('#searchbox').addClass('searchHint');
								}
								
								
			if($('#showNav').text() != ''){
				
				$('ul#navigation').hide();
				
				
				$('#showNav').click(function(){
								
								$('ul#navigation').slideToggle('slow',function(){
										if($('ul#navigation').is(':visible')){
												$('#showNav').text('Hide Main Navigation')
													} else {
												$('#showNav').text('Show Main Navigation')
											}
											
																			   });
							});
			}
/*
$('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}, 1000);
					
					return false;
				
				}
		
		}
	});*/

});
