


/***
    Simple jQuery Slideshow Script
    Released by Jon Raasch (jonraasch.com) under FreeBSD license: free to use or modify, not responsible for anything, etc.  Please link out to me if you like it :)
***/

 $(document).ready(function() {
  var cont=1;
  var first=0;
  var last=$('.art-head-silde div').length-1;
  $('.art-head-silde div').eq(last).fadeIn().css("visibility", "visible");
  var auto_refresh = setInterval(function (){


         $('.art-head-silde div').eq(cont).css("visibility", "visible");
         $('.art-head-silde div').not($('.art-head-silde  div').eq(cont)).css("visibility", "hidden");

        cont++;
         if(cont>last){
            cont=0;
        }

     }, 5000); // refresh every 10000 milliseconds
    });


    $(document).ready(function() {
        $('.artmix-our-work img').animate({
            "opacity": .7
        });
        $('.artmix-our-work img').hover(function() {
            $(this).stop().animate({"opacity": 1});
        }, function() {
            $(this).stop().animate({"opacity": .7});
        });

    });

      $(document).ready(function() {
        $('.artmix-box img').animate({
            "opacity": .7
        });
        $('.artmix-box img').hover(function() {
            $(this).stop().animate({"opacity": 1});
        }, function() {
            $(this).stop().animate({"opacity": .7});
        });

    });
          $(document).ready(function() {
        $('.artmix-f-under img').animate({
            "opacity": .7
        });
        $('.artmix-f-under img').hover(function() {
            $(this).stop().animate({"opacity": 1});
        }, function() {
            $(this).stop().animate({"opacity": .7});
        });

    });






  $(function() {
        $('.artmix-box a').lightBox();
    });
     $(function() {
        $('.artmix-f-under a').lightBox();
    });

  $(function() {
        $('.artmix-our-work a').lightBox();
    });

$(document).ready(function(){

var dept=$('.artmix-gallery').attr("id");

	//Display Loading Image
	function Display_Load()
	{
	    $(".artmix-galleryloading").fadeIn(900,0);
		$(".artmix-galleryloading").html("<img src='art-images/artmixloading.gif' />");
	}
	//Hide Loading Image
	function Hide_Load()
	{
		$(".artmix-galleryloading").fadeOut('slow');
	};


   //Default Starting Page Results

	$(".artmix-pagination li:first").css({'color' : '#000000'}).css({'background' : '#FFFFFF'});

	Display_Load();

	$(".artmix-galleryup").load("includes/galleryreselt.php?page=1&dept="+dept, Hide_Load());



	//Pagination Click
	$(".artmix-pagination li").click(function(){

		Display_Load();

		//CSS Styles
		$(".artmix-pagination li")
		.css({'border' : 'solid #dddddd 1px'})
		.css({'color' : '#000000 '})
                .css({'background' : '#FFFFFF '})
                ;

		$(this)
		.css({'color' : '#FFFFFF'})
		.css({'background' : '#000000'});

		//Loading Data
		var pageNum = this.id;

		$(".artmix-galleryup").load("includes/galleryreselt.php?page=" + pageNum+"&dept="+dept, Hide_Load());
	});


});


  
       $(document).ready(function() {
      var first=0;
      var last=$('.hazem div').length-1;
      var cont=0;


        $('.hazem div').not($('.hazem div').eq(cont)).hide().fadeOut('slow');
        $('.hazem div').eq(cont).show().fadeIn('slow');


        $('#art-arrows #art-left').click(function() {
            if (cont>=last){cont=0;} else{cont++;}

        $('.hazem div').not($('.hazem div').eq(cont)).hide().fadeOut('slow');
        $('.hazem div').eq(cont).fadeIn('slow');
        });

                $('#art-arrows #art-right').click(function() {

            if (cont<=0){cont=last;} else{cont--;}
        $('.hazem div').not($('.hazem div').eq(cont)).hide().fadeOut('slow');
        $('.hazem div').eq(cont).fadeIn('slow');
        });




    });
