$(function () {

        var $callout = $('#callout');


        var callouts = [

			// Month of Love
			{
				duration: 6000,
				src: "//" +  STATIC_HOST() + "/callouts/monthoflove.png",
				css: {
					'width': '164px',
					'overflow': 'hidden',
					'visibility': 'visible',
					'opacity': '0.0',
					'left': '-100px',
					'margin-top': '-21px',
					'position': 'relative',
					'margin-left': '90px'
				},
				init: function(){},
				load: function(){
					$callout.animate({
						'opacity': '1.0',
						'left': '0px'
					});
				},
				unload: function(){
					$.when(
						$callout.animate({
							'opacity': '0.0',
							'left': '100px'
						}, 500)
					).then(function(){
						$.fn.callouts.advance();
					});
				},
				click: function(){
					location.href = '/month-of-love/';
				}
			},


			// Lisa Ann Wins XBIZ
			{
				duration: 6000,
				src: "//" +  STATIC_HOST() + "/callouts/lisawins.png",
				css: {
					'width': '164px',
					'overflow': 'hidden',
					'visibility': 'visible',
					'opacity': '0.0',
					'left': '-100px',
					'margin-top': '-21px',
					'position': 'relative',
					'margin-left': '90px'
				},
				init: function(){},
				load: function(){
					$callout.animate({
						'opacity': '1.0',
						'left': '0px'
					});
				},
				unload: function(){
					$.when(
						$callout.animate({
							'opacity': '0.0',
							'left': '100px'
						}, 500)
					).then(function(){
						$.fn.callouts.advance();
					});
				},
				click: function(){
					location.href = '/fleshlight-girls/fleshlight-toys/lisa-ann/';
				}
			},
			// Free Shipping
/*
			{
				duration: 6000,
				src: "//" +  STATIC_HOST() + "/callouts/free-shipping.png",
				css: {
					'width': '164px',
					'overflow': 'hidden',
					'visibility': 'visible',
					'opacity': '0.0',
					'left': '-100px',
					'margin-top': '-21px',
					'position': 'relative',
					'margin-left': '90px'
				},
				init: function(){},
				load: function(){
					$callout.animate({
						'opacity': '1.0',
						'left': '0px'
					});
				},
				unload: function(){
					$.when(
						$callout.animate({
							'opacity': '0.0',
							'left': '100px'
						}, 500)
					).then(function(){
						$.fn.callouts.advance();
					});
				}
				//click: function(){
					//location.href = '/body-heat-dvd-combo-pack/';
				//}
			},
*/

			// Body Heat
			{
				duration: 6000,
				src: "//" +  STATIC_HOST() + "/callouts/body-heat.png",
				css: {
					'width': '164px',
					'overflow': 'hidden',
					'visibility': 'visible',
					'opacity': '0.0',
					'left': '-100px',
					'margin-top': '-21px',
					'position': 'relative',
					'margin-left': '90px'
				},
				init: function(){},
				load: function(){
					$callout.animate({
						'opacity': '1.0',
						'left': '0px'
					});
				},
				unload: function(){
					$.when(
						$callout.animate({
							'opacity': '0.0',
							'left': '100px'
						}, 500)
					).then(function(){
						$.fn.callouts.advance();
					});
				},
				click: function(){
					location.href = '/body-heat-dvd-combo-pack/';
				}
			},

            // 15% Sitewide sale
            {                                                                                                                             
                    duration: 6000,                                                                                                       
                    src: "//" +  STATIC_HOST() + "/callouts/15-sitewide.png",
                    css: {
                            'width': '164px',
                            'overflow': 'hidden',
                            'visibility': 'visible',
                            'opacity': '0.0',
                            'left': '-100px',
                            'margin-top': '-2px',
                            'position': 'relative',
                            'margin-left': '90px'
                            //'width':      '164px',
                    },
                    init: function(){},
                    load: function(){
                            $callout.animate({
                                    'opacity': '1.0',
                                    'left': '0px'
                            });
                    },
                    unload: function(){
                            $.when(
                                    $callout.animate({
                                            'opacity': '0.0',
                                            'left': '100px'
                                    }, 500)
                            ).then(function(){
                                    $.fn.callouts.advance();
                            });
                    },
                    click: function(){
                    }
            }
        ];

		shuffle = function(o){ //v1.0
			for(var j, x, i = o.length; i; j = parseInt(Math.random() * i), x = o[--i], o[i] = o[j], o[j] = x);
			return o;
		};

        //$.fn.callouts(shuffle(callouts));
        $.fn.callouts(shuffle(callouts));
});

