$(document).ready(function() {
	$('.slideshow').cycle({
        fx:     'fade',
        speed:  'fast',
        timeout: 0,
        pager:  '.nav',
        pagerAnchorBuilder: function(idx, slide) {
            // return sel string for existing anchor
            return '.nav li:eq(' + (idx) + ') a';
        }
    });
	$('.slideshow2').cycle({
        fx:     'fade',
        speed:  'fast',
        timeout: 0,
        pager:  '.nav2',
        pagerAnchorBuilder: function(idx, slide) {
            // return sel string for existing anchor
            return '.nav2 li:eq(' + (idx) + ') a';
        }
    });
	$('.slideshow3').cycle({
        fx:     'fade',
        speed:  'fast',
        timeout: 0,
        pager:  '.nav3',
        pagerAnchorBuilder: function(idx, slide) {
            // return sel string for existing anchor
            return '.nav3 li:eq(' + (idx) + ') a';
        }
    });
	$('.slideshow4').cycle({
        fx:     'fade',
        speed:  'fast',
        timeout: 0,
        pager:  '.nav4',
        pagerAnchorBuilder: function(idx, slide) {
            // return sel string for existing anchor
            return '.nav4 li:eq(' + (idx) + ') a';
        }
    });
	$('.slideshow5').cycle({
        fx:     'fade',
        speed:  'fast',
        timeout: 0,
        pager:  '.nav5',
        pagerAnchorBuilder: function(idx, slide) {
            // return sel string for existing anchor
            return '.nav5 li:eq(' + (idx) + ') a';
        }
    });
	$('.slideshow6').cycle({
        fx:     'fade',
        speed:  'fast',
        timeout: 0,
        pager:  '.nav6',
        pagerAnchorBuilder: function(idx, slide) {
            // return sel string for existing anchor
            return '.nav6 li:eq(' + (idx) + ') a';
        }
    });
	
	SexyLightbox.initialize({color:'black', dir: 'images/sexyimages',emergefrom:'bottom'});
	
	$('a[href*=#]').click(function() {
    if (location.pathname.replace(/^\//,'') == this.pathname.replace(/^\//,'')
    && location.hostname == this.hostname) {
      var $target = $(this.hash);
      $target = $target.length && $target
      || $('[name=' + this.hash.slice(1) +']');
      if ($target.length) {
        var targetOffset = $target.offset().top;
        $('html,body')
        .animate({scrollTop: targetOffset}, 1000);
       return false;
      }
    }
  });
});
