// JavaScript Document
 $(document).ready(function() {
  $(".carousel").jCarouselLite({
       btnNext: ".next",
       btnPrev: ".prev",
	   visible: 5
 });
  
      $("#studiothmb1").click(function () {
	  $('#spotLightWrapper').jOverlay();
	/*  $.dimScreen(1000, 0.7, function() {
	  var myImage = document.getElementById("spotLight");
	  $('#spotLightWrapper').fadeIn();
	  //$('#tabBenefitContent').hide();								
     //$('#tabFaqContent').fadeIn();
		  }); */
    	});
	      $(".closeThmb1").click(function () {
			$('#spotLightWrapper').fadeOut();							  
			$.dimScreenStop();
    	});
		
		$("#studiothmb2").click(function () {
	  $('#spotLightWrapper2').jOverlay();
	
    	});
	      $(".closeThmb1").click(function () {
			$('#spotLightWrapper2').fadeOut();							  
			$.dimScreenStop();
    	});
		  	$("#studiothmb3").click(function () {
	  $('#spotLightWrapper3').jOverlay();
	
    	});
			$("#studiothmb4").click(function () {
	  $('#spotLightWrapper4').jOverlay();
	
    	});
	      $(".closeThmb1").click(function () {
			$('#spotLightWrapper3').fadeOut();							  
			$.dimScreenStop();
    	});
		  
		  $(".debug").click(function () {
			$('#debugger').debug();							  
			
    	});
	//$('#spotLightWrapper').jqm(); 
//	$('#spotLightWrapper').jqmAddTrigger('#studiothmb1');
	//$('#spotLightWrapper').jqmAddClose('.closeThmb'); 
	
	 
 /*     var loadInIframeModal = function(hash){
  
          var $trigger = $(hash.t);
 
          var $modal = $(hash.w);
 
          var myUrl = $trigger.attr('href');
 
          var myTitle= $trigger.attr('title');
 
          var $modalContent = $("iframe", $modal);

          $modalContent.html('').attr('src', myUrl);

          //let's use the anchor "title" attribute as modal window title
 
          $('#jqmTitleText').text(myTitle);

          $modal.jqmShow();

      }
 
      // initialise jqModal

      $('#spotLightWrapper').jqm({

      modal: true,

      trigger: '#studiothmb1',

      target: '#jqmContent',
 
      onShow:  loadInIframeModal
      });
*/
  

   });