jQuery(document).ready(function($) {

 		$("a[href$='.pdf']").addClass("pdf");
 		$("a[href$='.pdf']").attr('title', 'PDF file');
 		$("a[href$='.doc'], a[href$='.docx']").addClass("doc");
 		$("a[href$='.doc'], a[href$='.docx']").attr('title', 'Microsoft Word file');
 		$("a[href$='.xls'], a[href$='.xlsx']").addClass("xls");
 		$("a[href$='.xls'], a[href$='.xlsx']").attr('title', 'Microsoft Excel file');
 		$("a[href$='.ppt'], a[href$='.pptx']").addClass("ppt");
 		$("a[href$='.ppt'], a[href$='.pptx']").attr('title', 'Microsoft PowerPoint file');
 		$("a[href$='.txt']").addClass("txt");
 		$("a[href$='.txt']").attr('title', 'Text file');
 		$("a[href$='.zip']").addClass("zip");
 		$("a[href$='.zip']").attr('title', 'Zip file');


         var hcolor = '#3b7ab0';
         var rcolor = '#4d4c4c';
         var lcolor = '#3b7ab0';
         var lhcolor = '#44B4FF';
         var navcolor = '#E6E6E6';
         var navhcolor = '#fff';
         var navbgcolor = '#7BB725';
         var navhbgcolor = '#99D642';
         
         
		$("#navaboutus").hover(function() {

				$(this).children('ul').hide();
				$(this).children('ul').fadeIn("fast");
		});

		$("#navmembership").hover(function() {

				$(this).children('ul').hide();
				$(this).children('ul').fadeIn("fast");
		});

		$("#navevents").hover(function() {

				$(this).children('ul').hide();
				$(this).children('ul').fadeIn("fast");
		});	
         
		$("#navigation a").hover(function() {
				$(this).css( 'color', navcolor );		
                $(this).stop().animate({ color: navhcolor }, "fast");
                },
				function() {
                $(this).stop().animate({ color: navcolor }, "slow");
                });
                
		$("ul.dropdown ul li").hover(function() {
				$(this).css( 'background-color', navbgcolor );		
                $(this).stop().animate({ backgroundColor: navhbgcolor }, "slow");
                },
				function() {
                $(this).stop().animate({ backgroundColor: navbgcolor }, "slow");
                });

		$("#footertext a").hover(function() {
				$(this).css( 'background-color', lcolor );
                $(this).stop().animate({ backgroundColor: lhcolor }, "slow");
                },
				function() {
                $(this).stop().css({ 'background-color': 'transparent' }, "slow");
                });
         
		$("#bodymy a").hover(function() {
				$(this).css("color", lcolor );		
                $(this).stop().animate({ color: lhcolor }, "fast");
                },
				function() {
                $(this).stop().animate({ color: hcolor }, "slow");
                });

		$("#aboutus").hover(function() {
			
                $("#aboutusicon").stop().animate({ color: hcolor }, "slow");
                },
				function() {
                $("#aboutusicon").stop().animate({ color: rcolor }, "slow");
                });
                
		$("#conference").hover(function() {
			
                $("#conferenceicon").stop().animate({ color: hcolor }, "slow");
                },
				function() {
                $("#conferenceicon").stop().animate({ color: rcolor }, "slow");
                });

		$("#news").hover(function() {
			
                $("#newsicon").stop().animate({ color: hcolor }, "slow");
                },
				function() {
                $("#newsicon").stop().animate({ color: rcolor }, "slow");
                });

		$("#events").hover(function() {
			
                $("#eventsicon").stop().animate({ color: hcolor }, "slow");
                },
				function() {
                $("#eventsicon").stop().animate({ color: rcolor }, "slow");
                });

		$("#local").hover(function() {
			
                $("#localicon").stop().animate({ color: hcolor }, "slow");
                },
				function() {
                $("#localicon").stop().animate({ color: rcolor }, "slow");
                });

		$("#grants").hover(function() {
			
                $("#grantsicon").stop().animate({ color: hcolor }, "slow");
                },
				function() {
                $("#grantsicon").stop().animate({ color: rcolor }, "slow");
                });

		$("#publications").hover(function() {
			
                $("#publicationsicon").stop().animate({ color: hcolor }, "slow");
                },
				function() {
                $("#publicationsicon").stop().animate({ color: rcolor }, "slow");
                });

		$("#joinnow").hover(function() {
			
                $("#joinnowicon").stop().animate({ color: '#96c616' }, "slow");
                },
				function() {
                $("#joinnowicon").stop().animate({ color: rcolor }, "slow");
                });

		$("#joinnow a").hover(function() {
				$(this).css( 'color', '#96c616' );		
                $(this).stop().animate({ color: '#ade519' }, "fast");
                },
				function() {
                $(this).stop().animate({ color: '#96c616' }, "slow");
                });

		});
