// JavaScript Document
/*
 * Copyright (c) 2011 Semih and Bogac.
 *
 */
 
jQuery(document).ready(function(){
  jQuery(".button a")
    .css({  'backgroundPosition': '0 0' })
    .hover(
      function(){
        jQuery(this)
          .stop()
          .animate({
            'opacity': 0.75
          }, 500);
      },
      function(){
        jQuery(this)
          .stop()
          .animate({
            'opacity': 1
          }, 500);
      }
    );
});

jQuery(document).ready(function(){
  jQuery("#mew a")
    .css({  'backgroundPosition': '0 0' })
    .hover(
      function(){
        jQuery(this)
          .stop()
          .animate({
            'opacity': 0.6
          }, 500);
      },
      function(){
        jQuery(this)
          .stop()
          .animate({
            'opacity': 1
          }, 500);
      }
    );
});

var nav  = [ '#main a', '#editorial a', '#advertising a', '#video a', '#about a', '#contact a' ];
jQuery(document).ready(function(){  
	for ( i = 0; i < nav.length; i++ ) {  
		jQuery(nav[i]).bind( 'mouseover', {id: i}, function(event) {
			_x = event.data.id*(-107);
			jQuery(this).stop().animate( { backgroundPosition: _x + 'px 54px' }, 100) 
		}); 
		
		 
		jQuery(nav[i]).bind( 'mouseout', {id: i}, function(event) {
			_x = event.data.id*(-107);
			jQuery(this).stop().animate( { backgroundPosition: _x-16 + 'px 54px' }, 100) 
		}); 
	}
});



