/***************************************************************************
 * @Copyright: CSSJockey - Unique & Practical Web Presence
 * @Website: http://www.cssjockey.com/
 * @Portfolio: http://www.cssjockey.com/portfolio
 * @Contact: http://www.cssjockey.com/get-in-touch
 * @Privacy Policy & Terms of Use: http://www.cssjockey.com/terms-of-use
 ***************************************************************************/

$(document).ready(function(){
       $('#featured-slideshow').cycle({
        fx:     'scrollHorz',
        speed:   2500,
        timeout: 4000,
        next:   '#next',
        prev:   '#prev'
    });

    var $ul = $('#footer-nav ul > li');
    var el = $ul.eq($ul.length-1);
    $(el).addClass('noborder');

    

    $('.cat-hover-1').hide();
    $('.cat-hover-2').hide();
    $('.cat-hover-3').hide();
    $('.cat-hover-4').hide();
    $('#cat1 a').hover(function(){
        $('.cat-hover-1').show();
    },function(){
        $('.cat-hover-1').hide();
    })
    $('#cat2 a').hover(function(){
        $('.cat-hover-2').show();
    },function(){
        $('.cat-hover-2').hide();
    })
    $('#cat3 a').hover(function(){
        $('.cat-hover-3').show();
    },function(){
        $('.cat-hover-3').hide();
    })
    $('#cat4 a').hover(function(){
        $('.cat-hover-4').show();
    },function(){
        $('.cat-hover-4').hide();
    })

    $('.children li a').hover(function(){
        $(this).parent().parent().parent().addClass('green');
    },function(){
        $(this).parent().parent().parent().removeClass('green');
    })
    $('.online-store').hover(function(){
        $(this).parent().parent().parent().parent().addClass('green');
    },function(){
        $(this).parent().parent().parent().parent().removeClass('green');
    })
    $('.view-all').hover(function(){
        $(this).parent().parent().parent().parent().addClass('green');
    },function(){
        $(this).parent().parent().parent().parent().removeClass('green');
    })

    
    
    $('#tab1 a').hover(function(){
        $('.page-hover-1').show();
        $('.page-hover-2').hide();
            $('.page-hover-3').hide();
            $('.page-hover-4').hide();
    },function(){
        $('.page-hover-1').mouseout(function(){
            $('.page-hover-1').hide();
            $('.page-hover-2').hide();
            $('.page-hover-3').hide();
            $('.page-hover-4').hide();
        })
    })

    
    
    $('#tab2 a').hover(function(){
        $('.page-hover-2').show();
        $('.page-hover-1').hide();
            $('.page-hover-3').hide();
            $('.page-hover-4').hide();
    },function(){
        $('.page-hover-2').mouseout(function(){
            $('.page-hover-2').hide();
            $('.page-hover-1').hide();
            $('.page-hover-3').hide();
            $('.page-hover-4').hide();
        })
    })

    $('#tab3 a').hover(function(){
        $('.page-hover-3').show();
        $('.page-hover-1').hide();
            $('.page-hover-2').hide();
            $('.page-hover-4').hide();
    },function(){
        $('.page-hover-3').mouseout(function(){
            $('.page-hover-3').hide();
            $('.page-hover-1').hide();
            $('.page-hover-2').hide();
            $('.page-hover-4').hide();
        })
    })
    
    $('#tab4 a').hover(function(){
        $('.page-hover-4').show();
        $('.page-hover-1').hide();
            $('.page-hover-2').hide();
            $('.page-hover-3').hide();
    },function(){
        $('.page-hover-4').mouseout(function(){
            $('.page-hover-4').hide();
            $('.page-hover-1').hide();
            $('.page-hover-2').hide();
            $('.page-hover-3').hide();
        })
    })
    


    $('.tab1-content').show();    
    $('.tab2-content').hide();
    $('.tab3-content').hide();
    $('.tab4-content').hide();

    $('.page-hover-1').click(function(){        
        $('.tab1-content').show();
        $('.tab2-content').hide();
        $('.tab3-content').hide();
        $('.tab4-content').hide();
        return false;
    })
    $('.page-hover-2').click(function(){        
        $('.tab1-content').hide();
        $('.tab2-content').show();
        $('.tab3-content').hide();
        $('.tab4-content').hide();
        return false;
    })
    $('.page-hover-3').click(function(){        
        $('.tab1-content').hide();
        $('.tab2-content').hide();
        $('.tab3-content').show();
        $('.tab4-content').hide();
        return false;
    })
    $('.page-hover-4').click(function(){        
        $('.tab1-content').hide();
        $('.tab2-content').hide();
        $('.tab3-content').hide();
        $('.tab4-content').show();
        return false;
    })
    
});
