//bg slide**********//
jQuery(document).ready(function(){
        jQuery("#bg").jbgallery({
            menu : "simple", 
            style: "zoom", 
            caption : false,
			slideshow:true
        });
	});
jQuery(document).ready(function(){
		 
	     jQuery("#open_gallery1").click(function(){
            var _hash = parseInt(this.hash.replace("#",""),10);
			jQuery("#bg").jbgallery("destroy");
			$('#main,.tail-top,#toggle-docs').hide('slow');
			$('html, body').animate({scrollTop: '0px'}, 800);
            jQuery("#jbroom").jbgallery({
                current : _hash,
                popup : true,
				clickable : true,
                menu : 'numbers'
            }).show();
			return false;
        });
        jQuery("#open_gallery2").click(function(){
            var _hash = parseInt(this.hash.replace("#",""),10);
			jQuery("#bg").jbgallery("destroy");
			$('#main,.tail-top,#toggle-docs').hide('slow');
			$('html, body').animate({scrollTop: '0px'}, 800);
            jQuery("#jbnos").jbgallery({
                current : _hash,
                popup : true,
				clickable : true,
                menu : 'numbers'
            }).show();
			return false;
        });
		jQuery("#open_gallery3").click(function(){
			var _hash = parseInt(this.hash.replace("#",""),10);
            jQuery("#bg").jbgallery("destroy");
			$('#main,.tail-top,#toggle-docs').hide('slow');
			$('html, body').animate({scrollTop: '0px'}, 800);
            jQuery("#keysan").jbgallery({
                current : _hash,
                popup : true,
				clickable : true,
				style: "centered",
                menu : 'numbers'
            }).show();
			return false;
        });
		jQuery("#open_gallery4").click(function(){
			var _hash = parseInt(this.hash.replace("#",""),10);
            jQuery("#bg").jbgallery("destroy");
			$('#main,.tail-top,#toggle-docs').hide('slow');
			$('html, body').animate({scrollTop: '0px'}, 800);
            jQuery("#keysanhotel").jbgallery({
                current : _hash,
                popup : true,
				clickable : true,
				style: "centered",
                menu : 'numbers'
            }).show();
			return false;
        });
		jQuery("#open_gallery5").click(function(){
			var _hash = parseInt(this.hash.replace("#",""),10);
            jQuery("#bg").jbgallery("destroy");
			$('#main,.tail-top,#toggle-docs').hide('slow');
			$('html, body').animate({scrollTop: '0px'}, 800);
            jQuery("#dlyn").jbgallery({
                current : _hash,
                popup : true,
				clickable : true,
				style: "centered",
                menu : 'numbers'
            }).show();
			return false;
        });
		jQuery("#open_gallery6").click(function(){
			var _hash = parseInt(this.hash.replace("#",""),10);
            jQuery("#bg").jbgallery("destroy");
			$('#main,.tail-top,#toggle-docs').hide('slow');
			$('html, body').animate({scrollTop: '0px'}, 800);
            jQuery("#bbq").jbgallery({
                current : _hash,
                popup : true,
				clickable : true,
				style: "centered",
                menu : 'numbers'
            }).show();
			return false;
        });
		jQuery("#open_gallery7").click(function(){
			var _hash = parseInt(this.hash.replace("#",""),10);
            jQuery("#bg").jbgallery("destroy");
			$('#main,.tail-top,#toggle-docs').hide('slow');
			$('html, body').animate({scrollTop: '0px'}, 800);
            jQuery("#2007").jbgallery({
                current : _hash,
                popup : true,
				clickable : true,
				style: "centered",
                menu : 'numbers'
            }).show();
			return false;
        });
		jQuery("#open_gallery8").click(function(){
			var _hash = parseInt(this.hash.replace("#",""),10);
            jQuery("#bg").jbgallery("destroy");
			$('#main,.tail-top,#toggle-docs').hide('slow');
			$('html, body').animate({scrollTop: '0px'}, 800);
            jQuery("#edizhun").jbgallery({
                current : _hash,
                popup : true,
				clickable : true,
				style: "centered",
                menu : 'numbers'
            }).show();
			return false;
        });
		jQuery("#open_gallery9").click(function(){
			var _hash = parseInt(this.hash.replace("#",""),10);
            jQuery("#bg").jbgallery("destroy");
			$('#main,.tail-top,#toggle-docs').hide('slow');
			$('html, body').animate({scrollTop: '0px'}, 800);
            jQuery("#nostalji").jbgallery({
                current : _hash,
                popup : true,
				clickable : true,
				style: "centered",
                menu : 'numbers'
            }).show();
			return false;
        });
		jQuery("#open_gallery10").click(function(){
			var _hash = parseInt(this.hash.replace("#",""),10);
            jQuery("#bg").jbgallery("destroy");
			$('#main,.tail-top,#toggle-docs').hide('slow');
			$('html, body').animate({scrollTop: '0px'}, 800);
            jQuery("#wedding").jbgallery({
                current : _hash,
                popup : true,
				clickable : true,
				style: "centered",
                menu : 'numbers'
            }).show();
			return false;
        });
		jQuery("#open_gallery11").click(function(){
			var _hash = parseInt(this.hash.replace("#",""),10);
            jQuery("#bg").jbgallery("destroy");
			$('#main,.tail-top,#toggle-docs').hide('slow');
			$('html, body').animate({scrollTop: '0px'}, 800);
            jQuery("#breakfast").jbgallery({
                current : _hash,
                popup : true,
				clickable : true,
				style: "centered",
                menu : 'numbers'
            }).show();
			return false;
        });
		jQuery("#open_gallery12").click(function(){
			var _hash = parseInt(this.hash.replace("#",""),10);
            jQuery("#bg").jbgallery("destroy");
			$('#main,.tail-top,#toggle-docs').hide('slow');
			$('html, body').animate({scrollTop: '0px'}, 800);
            jQuery("#2011").jbgallery({
                current : _hash,
                popup : true,
				clickable : true,
				style: "centered",
                menu : 'numbers'
            }).show();
			return false;
        });
    });
