$(document).ready(function()
{
   var tempVar  = '';
   var homepage = 'http://govid.tv';

/*
   // Photo gallery carousel
   $('#carousel').jcarousel(
   {
      vertical: true,
      scroll: 2,
      wrap: 'circular',
      start: 2
   });
*/
   // Lightbox
   $('.lightboxGroup').fancybox({ cyclic: true, showCloseButton: false, titleShow: true });
   $('.lightbox').fancybox({ showCloseButton: false, titleShow: false });
   $('.lightbox').click(function()
   {
      if ($(this).attr('rel') !== undefined && $(this).attr('rel').search(',') != -1)
      {
         var rel    = $(this).attr('rel').split(',');
         var width  = rel[0] + 'px';
         var height = rel[1] + 'px';

         $("#fancy_outer").css({'width': width, 'height': height});
         $("tag").fancybox.scrollBox();
      }
   });

   // Google Map Overlay
   $('#googleMap div').append('<div class="overlay" style="position: absolute; left: 0px; top: 0px; width: 100%; height: 100%; background: #686868"><div style="position: absolute; top: 40%; left: 26%"><img src="' + homepage + '/templates/govid/images/govid/googleMap-button.png" /></div></div>');
   $('#googleMap div .overlay').css('opacity', '0.8');

   $('#googleMap div .overlay').click(function() { $(this).remove(); });
});

