// THIS FILE CONTAINS ALL THE SETTINGS FOR THE JQUERY PLUGINS USED
// PLAY WELL WITH OTHER LIBRARIES
jQuery(document).ready(function() {

    // CUFON STERLING
    Cufon.replace('h1', {
        fontFamily: 'Gotham Rounded Bold',
        textTransform: 'uppercase',
        letterSpacing: -2
    });
    Cufon.replace('h2', {
        fontFamily: 'Gotham Rounded Bold',
        textTransform: 'uppercase',
        letterSpacing: -1
    });

    // JQUERY TOOLS TABS 
    jQuery('#matchesTabs').tabs('.matchesBox');
    jQuery('#matchesTabs_bid').tabs('.matchesBox_bid');
    jQuery('#matchesTabs_cont').tabs('.matchesBox_cont');
    jQuery('#matchesTabs_match').tabs('.matchesBox_match');
    jQuery('#matchesTabs_inv').tabs('.matchesBox_inv');

    
    //jQuery('.tabsLevel2').tabs('.listingAll,.tabSection').history();
    //jQuery('.tabsLevel3').tabs('.listingAll,.tabSection2').history();

    jQuery('.tabsLevel2').tabs('.tabSection').history();
    jQuery('.tabsLevel3').tabs('.tabSection2').history();
    jQuery('.tabsLevel4').tabs('.tabSection4').history();
    
    // JQUERY TOOLS - SCROLLABLE
    jQuery('#memberList').scrollable({
        items: '#members',
        loop: false,
        size: 5,
        next: '.scrollRight',
        prev: '.scrollLeft'
    });

    // COLORBOX DIALOG
    jQuery('.membersDialog').colorbox({
        initialWidth: 200,
        initialHeight: 200,
        scrolling: true,
        maxHeight: 500,
        opacity: .40
    });

    jQuery('.showSkills').colorbox({
        //href: 'skills.html', -- Changed into inline functionality
        initialWidth: 200,
        initialHeight: 200,
        scrolling: true,
        maxHeight: 500,
        rel: false,
        opacity: .40,
        inline:true,  //Added for inline functionality
        
        // ADD EVEN CLASS TO MODAL FOR ROW STRIPING
        onComplete: function() { jQuery('#skillTable tr:nth-child(even)').addClass('even'); }
    });
    
    
    jQuery('.showIndustrySkills').colorbox({
        //href: 'skills.html', -- Changed into inline functionality
        initialWidth: 200,
        initialHeight: 200,
        scrolling: true,
        maxHeight: 500,
        rel: false,
        opacity: .40,
        inline:true,  //Added for inline functionality
        
        // ADD EVEN CLASS TO MODAL FOR ROW STRIPING
        onComplete: function() { jQuery('#skillTable tr:nth-child(even)').addClass('even'); }
    });
    
    jQuery('.showSoftwareSkills').colorbox({
        //href: 'skills.html', -- Changed into inline functionality
        initialWidth: 200,
        initialHeight: 200,
        scrolling: true,
        maxHeight: 500,
        rel: false,
        opacity: .40,
        inline:true,  //Added for inline functionality
        
        // ADD EVEN CLASS TO MODAL FOR ROW STRIPING
        onComplete: function() { jQuery('#skillTable tr:nth-child(even)').addClass('even'); }
    });
    
    jQuery('.showinvitSkills').colorbox({
        //href: 'skills.html', -- Changed into inline functionality
        initialWidth: 200,
        initialHeight: 200,
        scrolling: true,
        maxHeight: 500,
        rel: false,
        opacity: .40,
        inline:true,  //Added for inline functionality
        
        // ADD EVEN CLASS TO MODAL FOR ROW STRIPING
        onComplete: function() { jQuery('#skillTable tr:nth-child(even)').addClass('even'); }
    });
    // CUSTOM JQUERY
    jQuery('.statusTable tr:nth-child(even)').addClass('even');



    jQuery('.matchesBox li:last-child, #latestFeedback li:last-child').addClass('last');

    jQuery('.listingAll li:nth-child(even)').addClass('even');

    jQuery("#alert .closeButton").click(function() {
        jQuery(this).parent('#alert').slideUp('fast');
        return false;
    });


    /*jQuery('.matchesBox li')
    .mouseover(function(event) {
    jQuery(event.target).addClass('hover');
    })
    .mouseout(function(event) {
    jQuery(event.target).removeClass('hover');
    })*/

});     //end document ready
