$(document).ready(function (a) {

local = document.location.hash;

a("#infos").css("visibility", "visible")


sa1 = 1;
sa2 = 1;
sa3 = 1;
sa4 = 1;
sa5 = 1;
sa6 = 1;
sa7 = 1;


  var slides1 = [ 
    'img/trabalhos/smirnoffext/image2.jpg', 
    'img/trabalhos/smirnoffext/image3.jpg', 
    'img/trabalhos/smirnoffext/image4.jpg', 
    'img/trabalhos/smirnoffext/image5.jpg', 
    'img/trabalhos/smirnoffext/image6.jpg', 
    'img/trabalhos/smirnoffext/image7.jpg', 
    'img/trabalhos/smirnoffext/image8.jpg', 
    'img/trabalhos/smirnoffext/image9.jpg', 
    'img/trabalhos/smirnoffext/image10.jpg', 
    'img/trabalhos/smirnoffext/image11.jpg', 
    'img/trabalhos/smirnoffext/image12.jpg', 
    'img/trabalhos/smirnoffext/image13.jpg', 
    'img/trabalhos/smirnoffext/image14.jpg', 
    'img/trabalhos/smirnoffext/image15.jpg', 
    'img/trabalhos/smirnoffext/image16.jpg', 
    'img/trabalhos/smirnoffext/image17.jpg', 
    'img/trabalhos/smirnoffext/image18.jpg', 
    'img/trabalhos/smirnoffext/image19.jpg', 
    'img/trabalhos/smirnoffext/image20.jpg', 
    'img/trabalhos/smirnoffext/image21.jpg', 
    'img/trabalhos/smirnoffext/image22.jpg', 
    'img/trabalhos/smirnoffext/image23.jpg', 
    'img/trabalhos/smirnoffext/image24.jpg',
    'img/trabalhos/smirnoffext/image25.jpg' 
  ] 

    var slides2 = [ 
    'img/trabalhos/spfw/image2.jpg', 
    'img/trabalhos/spfw/image3.jpg', 
    'img/trabalhos/spfw/image4.jpg'
  ]

    var slides3 = [ 
    'img/trabalhos/smirnoffexp/image2.jpg', 
    'img/trabalhos/smirnoffexp/image3.jpg', 
    'img/trabalhos/smirnoffexp/image4.jpg', 
    'img/trabalhos/smirnoffexp/image5.jpg', 
    'img/trabalhos/smirnoffexp/image6.jpg', 
    'img/trabalhos/smirnoffexp/image7.jpg', 
    'img/trabalhos/smirnoffexp/image8.jpg', 
    'img/trabalhos/smirnoffexp/image9.jpg', 
    'img/trabalhos/smirnoffexp/image10.jpg', 
    'img/trabalhos/smirnoffexp/image11.jpg', 
    'img/trabalhos/smirnoffexp/image12.jpg', 
    'img/trabalhos/smirnoffexp/image13.jpg', 
    'img/trabalhos/smirnoffexp/image14.jpg', 
    'img/trabalhos/smirnoffexp/image15.jpg', 
    'img/trabalhos/smirnoffexp/image16.jpg'
  ] 

    var slides4 = [ 
    'img/trabalhos/smirnoffnight/image2.jpg', 
    'img/trabalhos/smirnoffnight/image3.jpg', 
    'img/trabalhos/smirnoffnight/image4.jpg', 
    'img/trabalhos/smirnoffnight/image5.jpg', 
    'img/trabalhos/smirnoffnight/image6.jpg', 
    'img/trabalhos/smirnoffnight/image7.jpg', 
    'img/trabalhos/smirnoffnight/image8.jpg', 
    'img/trabalhos/smirnoffnight/image9.jpg', 
    'img/trabalhos/smirnoffnight/image10.jpg', 
    'img/trabalhos/smirnoffnight/image11.jpg', 
    'img/trabalhos/smirnoffnight/image12.jpg', 
    'img/trabalhos/smirnoffnight/image13.jpg', 
    'img/trabalhos/smirnoffnight/image14.jpg', 
    'img/trabalhos/smirnoffnight/image15.jpg', 
    'img/trabalhos/smirnoffnight/image16.jpg', 
    'img/trabalhos/smirnoffnight/image17.jpg', 
    'img/trabalhos/smirnoffnight/image18.jpg', 
    'img/trabalhos/smirnoffnight/image19.jpg', 
    'img/trabalhos/smirnoffnight/image20.jpg', 
    'img/trabalhos/smirnoffnight/image21.jpg', 
    'img/trabalhos/smirnoffnight/image22.jpg', 
    'img/trabalhos/smirnoffnight/image23.jpg', 
    'img/trabalhos/smirnoffnight/image24.jpg',
    'img/trabalhos/smirnoffnight/image25.jpg', 
    'img/trabalhos/smirnoffnight/image26.jpg', 
    'img/trabalhos/smirnoffnight/image27.jpg', 
    'img/trabalhos/smirnoffnight/image28.jpg', 
    'img/trabalhos/smirnoffnight/image29.jpg', 
    'img/trabalhos/smirnoffnight/image30.jpg', 
    'img/trabalhos/smirnoffnight/image31.jpg', 
    'img/trabalhos/smirnoffnight/image32.jpg', 
    'img/trabalhos/smirnoffnight/image33.jpg', 
    'img/trabalhos/smirnoffnight/image34.jpg', 
    'img/trabalhos/smirnoffnight/image35.jpg', 
    'img/trabalhos/smirnoffnight/image36.jpg'
  ] 

    var slides5 = [ 
    'img/trabalhos/stpatricks/image2.jpg', 
    'img/trabalhos/stpatricks/image3.jpg', 
    'img/trabalhos/stpatricks/image4.jpg'
  ]

    var slides6 = [ 
    'img/trabalhos/motorola/image2.jpg', 
    'img/trabalhos/motorola/image3.jpg', 
    'img/trabalhos/motorola/image4.jpg'
  ] 

    var slides7 = [ 
    'img/trabalhos/whisky/image2.jpg', 
    'img/trabalhos/whisky/image3.jpg', 
    'img/trabalhos/whisky/image4.jpg', 
    'img/trabalhos/whisky/image5.jpg', 
    'img/trabalhos/whisky/image6.jpg', 
    'img/trabalhos/whisky/image7.jpg', 
    'img/trabalhos/whisky/image8.jpg', 
    'img/trabalhos/whisky/image9.jpg', 
    'img/trabalhos/whisky/image10.jpg', 
    'img/trabalhos/whisky/image11.jpg', 
    'img/trabalhos/whisky/image12.jpg', 
    'img/trabalhos/whisky/image13.jpg', 
    'img/trabalhos/whisky/image14.jpg', 
    'img/trabalhos/whisky/image15.jpg', 
    'img/trabalhos/whisky/image16.jpg', 
    'img/trabalhos/whisky/image17.jpg', 
    'img/trabalhos/whisky/image18.jpg', 
    'img/trabalhos/whisky/image19.jpg', 
    'img/trabalhos/whisky/image20.jpg', 
    'img/trabalhos/whisky/image21.jpg', 
    'img/trabalhos/whisky/image22.jpg', 
    'img/trabalhos/whisky/image23.jpg'  
  ] 

    function startSlideshow(z, slides) { 

      
        
        var totalSlideCount = 1 + slides.length; 
         
        var aslideshow = a('.pics'+z); 
         
        // markup contains only a single slide; before starting the slideshow we  
        // append one slide and prepend one slide (to account for prev/next behavior) 
        aslideshow.prepend('<img src="'+slides.pop()+'" />'); 
        
 
        // start slideshow 
        a('.pics'+z).cycle({ 
              fx: 'custom', 
              prev: '.p'+z, 
              next: '.n'+z,
              speed: 500,
              timeout: 0,
              cssBefore: { 
                left: -2500, 
                display: 'block',
                position:'absolute',
                top: 0
              }, 
              animIn:  { 
                left: "0px", 
                position:'relative'
              }, 
              animOut: {  
                 left: -2500,
                 position:'relative'
              }, 
            before:   onBefore,
            after: function(){
              thisWidth = (a(this).width());
              a(this).animate( {'margin-left' : -thisWidth/2, 'left' : '50%'}, 80 ); 
            },
            first: function(){
              thisWidth = (a(this).width());
              a(this).animate( {'margin-left' : -thisWidth/2, 'left' : '50%'}, 80 ); 
            },
        }); 
 
        function onBefore(curr, next, opts, fwd) { 
            // on Before arguments: 
            //  curr == DOM element for the slide that is currently being displayed 
            //  next == DOM element for the slide that is about to be displayed 
            //  opts == slideshow options 
            //  fwd  == true if cycling forward, false if cycling backward 
                 
            // on the first pass, addSlide is undefined (plugin hasn't yet created the fn yet) 
            if (!opts.addSlide) 
                return; 
                 
            // have we added all our slides? 
            if (opts.slideCount == totalSlideCount) 
                return; 
 
            // shift or pop from our slide array  
            var nextSlideSrc = fwd ? slides.shift() : slides.pop(); 
             
            // add our next slide 
            opts.addSlide('<img margin:0 auto;" src="'+nextSlideSrc+'" />', fwd == false); 
            

        }; 
    }; 




    function n() {
        var b = "https://graph.facebook.com/nossa.agencia/posts?limit=2&access_token=123975213079|nqKWO89vVW4QH_bNmKH-Wiy3W0w&callback=?";
        a.getJSON(b, function (b) {
            var c = "";
            a.each(b.data, function (a, b) {
                wallPost = b.message;
                if (m(wallPost)) {
                    c += "<li class='fin'>" + wallPost + "</li>"
                }
            });
            c += "";
            a(".timeline .overview").append(c)
        })
    }
    function m(a) {
        return typeof a != "undefined"
    }
    function c() {
        var a = [];
        if (b("name").value.length == "0") {
            a.push("Preencha o formulário com seu nome")
        }
        var c = /^[A-Za-z]{1}([\w\.]{1}[\w]{1}|[\w]{1}[\w\.]{1})([\w]|\.{1}[\w]){0,29}@(([\w]{2,63}\.)+[A-Za-z]{2,6}|[\d{1,3}(\.\d{1,3}){3}])$/;
        if (!c.test(b("email").value)) {
            a.push("Email invalido")
        }
        if (b("subject").value.length == "0") {
            a.push("Preencha o formulário com um assunto")
        }
        if (b("comments").value.length == "0") {
            a.push("Preencha o formulário com sua mensagem")
        }
        if (a.length > 0) {
            alert(a.join(" -- "));
            return false
        }
    }
    function b(a) {
        return document.getElementById(a)
    }
    a("#name").focus(function () {
        if (a(this).val().length == "0") {
            a(this).css("backgroundPosition", "0px -18px")
        } else {};
    });
    a("#email").focus(function () {
        if (a(this).val().length == "0") {
            a(this).css("backgroundPosition", "0px -18px")
        } else {};
    });
    a("#subject").focus(function () {
        if (a(this).val().length == "0") {
            a(this).css("backgroundPosition", "0px -18px")
        } else {};
    });
    a("#comments").focus(function () {
        if (a(this).val().length == "0") {
            a(this).css("backgroundPosition", "0px -100px")
        } else {};
    });
    a("#name").blur(function () {
        if (a(this).val().length == "0") {
            a(this).css("backgroundPosition", "0px -392px")
        } else {};
    });
    a("#email").blur(function () {
        if (a(this).val().length == "0") {
            a(this).css("backgroundPosition", "0px 0px")
        } else {};
    });
    a("#subject").blur(function () {
        if (a(this).val().length == "0") {
            a(this).css("backgroundPosition", "0px -478px")
        } else {};
    });
    a("#comments").blur(function () {
        if (a(this).val().length == "0") {
            a(this).css("backgroundPosition", "0px -85px")
        } else {};
    });
    b("formContact").onsubmit = c;





mt = 0;
mc = 0;

    var d = 0;
    var e = 0;
    var f = 2;
    var g = 2;
    a(".works").hide();
    a(".contact").hide();
    a(".less").hide();
    a(".abstract_more").hide();
    a(".close").hide();
    a(".scrollbar").hide();
    a(".r").show();
    a("#btn_tabalhos").click(function () {
        if (mt == 0){
            a(".works").show(500)
            a(".contact").hide(500)
            mt = 1;
        } else {
            a(".works").hide(500)  
            mt = 0;
        }
    });
    a("#btn_contato").click(function () {
        if (mc == 0){
            a(".works").hide(500)
            a(".contact").show(500)
            mc = 1;
        } else {
            a(".contact").hide(500)  
            mc = 0;
        }
    });
    a(".twitter a").click(function () {
        a("#statuses").show();
        a(".timeline").hide();
        a("div#stream li.facebook").css("backgroundPosition", "0 0");
        a("div#stream ul.twitter li.twitter").css("backgroundPosition", "0px -18px")
    });
    a(".facebook a").click(function () {
        a("#statuses").hide();
        a(".timeline").show();
        a("div#stream ul.twitter li.twitter").css("backgroundPosition", "0px 0px");
        a("div#stream li.facebook").css("backgroundPosition", "0px -18px")
    });
    a("#infos").cycle({
        fx: "scrollVert",
        prev: "#prevslide",
        next: "#nextslide",
        speed: 600,
        manualTrump: false,
        timeout: 0
    });
    a(".timeline").hide(0);
    a("#nextslide").click(function () {
    a('.pics1').fadeOut();
    a('.n1').fadeOut();
    a('.pics2').fadeOut();
    a('.n2').fadeOut();
    a('.pics3').fadeOut();
    a('.n3').fadeOut();
    a('.pics4').fadeOut();
    a('.n4').fadeOut();
    a('.pics5').fadeOut();
    a('.n5').fadeOut();
    a('.pics6').fadeOut();
    a('.n6').fadeOut();
    a('.pics7').fadeOut();
    a('.n7').fadeOut();        
        function b() {
            a("#infos").css({
                overflow: "visible"
            }, 0)
        }
        setTimeout(b, 700)
    });
    a("#prevslide").click(function () {
        a('.pics1').hide();
    a('.n1').fadeOut();
    a('.pics2').fadeOut();
    a('.n2').fadeOut();
    a('.pics3').fadeOut();
    a('.n3').fadeOut();
    a('.pics4').fadeOut();
    a('.n4').fadeOut();
    a('.pics5').fadeOut();
    a('.n5').fadeOut();
    a('.pics6').fadeOut();
    a('.n6').fadeOut();
    a('.pics7').fadeOut();
    a('.n7').fadeOut();
        function b() {
            a("#infos").css({
                overflow: "visible"
            }, 0)
        }
        setTimeout(b, 700)
    });
    for (i = 1; i <= 7; i++) {
        
        a(".info" + i + " .more").click(function () {
            resize = 1;
            function c() {
                a(b).parent().parent().parent().find(".less").fadeIn();
                a(b).parent().parent().parent().find(".close").fadeIn();
                a(b).parent().parent().parent().css({
                    overflow: "visible"
                }, 0)
            }
            
            a(this).parent().find("#first").hide(500);
            a(this).parent().find(".abstract_more").show(500);
            
            a("#infos").animate({
                height: "68%",
                top: "16%"
            }, 500);
            a("#navigation").animate({
                right: "-300px"
            }, 500);
            a("#stream").animate({
                left: "300px"
            }, 500);
            a(this).fadeOut(0);
            a(this).parent().parent().parent().find(".scrollbar").fadeIn();
            var b = this;
            setTimeout(c, 500);
            var d = a(window).height();
            if (d < 700) {
                a(".less").css({
                    bottom: "-65px"
                }, 0)
            } else {
                a(".less").css({
                    bottom: "-55px"
                }, 0)
            }
        });
        a(".info" + i + " .less").click(function () {

            resize = 0;
            function c() {
                a(".more").fadeIn()
            }
            a(this).css({
                display: "none"
            }, 0);
            a(this).next().hide();
            a(this).parent().parent().css({
                overflow: "visible"
            }, 0);
            a(this).parent().find("#first").show(500);
            a(this).next().next().next().find(".abstract_more").hide(500);
            a(this).parent().parent().parent().find(".scrollbar").fadeOut();
            var b = a(window).height();
            if (b < 650) {
                a("#infos").animate({
                    height: "350px",
                    top: "53%"
                }, 500)
            } else if (b < 700) {
                a("#infos").animate({
                    height: "350px",
                    top: "58%"
                }, 500)
            } else if (b < 750) {
                a("#infos").animate({
                    height: "350px",
                    top: "60%"
                }, 500)
            } else {
                a("#infos").animate({
                    height: "350px",
                    top: "65%"
                }, 500)
            } 
            a("#navigation").animate({
                right: "30px"
            }, 500);
            a("#stream").animate({
                left: "0px"
            }, 500);
            setTimeout(c, 500)
        });
        a(".info" + i + " .close").click(function () {
            resize = 0;
            function c() {
                a(".more").fadeIn()
            }
            a(this).parent().find("#first").show(500);
            a(this).next().next().find(".abstract_more").hide(500);
            var b = a(window).height();
            if (b < 650) {
                a("#infos").animate({
                    height: "350px",
                    top: "53%"
                }, 500)
            } else if (b < 700) {
                a("#infos").animate({
                    height: "350px",
                    top: "58%"
                }, 500)
            } else if (b < 750) {
                a("#infos").animate({
                    height: "350px",
                    top: "60%"
                }, 500)
            } else {
                a("#infos").animate({
                    height: "350px",
                    top: "65%"
                }, 500)
            } 
            a("#navigation").animate({
                right: "30px"
            }, 500);
            a("#stream").animate({
                left: "0px"
            }, 500);
            a(".less").fadeOut(0);
            a(this).fadeOut(0);
            a(this).parent().parent().parent().find(".scrollbar").fadeOut();
            setTimeout(c, 500)
        })
    }

//__________________________________________________________________position_star_window_size

    a("#statuses").hide();
    a("#f").next().next().next().hide();
    var h = a(window).height();
    if (h < 650) {
        function j() {
            a("#statuses").fadeIn();
            a("#f").next().next().hide()
        }
        setTimeout(j, 1500);
        a("#infos").css({
            top: "53%"
        })
    } else if (h < 700) {
        function j() {
            a("#statuses").fadeIn();
            a("#f").next().next().hide()
        }
        setTimeout(j, 1500);
        a("#infos").css({
            top: "58%"
        })
    } else if (h < 750) {
        function j() {
            a("#statuses").fadeIn();
            a("#f").next().next().hide()
        }
        setTimeout(j, 1500);
        a("#infos").css({
            top: "60%"
        })
    } else {
        a("#statuses").fadeIn();
        a("#f").next().next().show();
        a("#infos").css({
            top: "65%"
        })
    }


//__________________________________________________________________window_resize

    resize = 0;

    a(window).resize(function () {
        if (resize == 0){
        var b = a(window).height();
    if (b < 650) {
        function j() {
            a("#statuses").fadeIn();
            a("#f").next().next().hide()
        }
        setTimeout(j, 1500);
        a("#infos").css({
            top: "53%"
        })
    } else if (b < 700) {
        function j() {
            a("#statuses").fadeIn();
            a("#f").next().next().hide()
        }
        setTimeout(j, 1500);
        a("#infos").css({
            top: "58%"
        })
    } else if (b < 750) {
        function j() {
            a("#statuses").fadeIn();
            a("#f").next().next().hide()
        }
        setTimeout(j, 1500);
        a("#infos").css({
            top: "60%"
        })
    } else {
        a("#statuses").fadeIn();
        a("#f").next().next().show();
        a("#infos").css({
            top: "65%"
        })
    }
    }
    });




    a("#infos").css({
        overflow: "visible"
    }, 0);
    var k = "http://search.twitter.com/search.json";
    var l = "agencianossa";
    a.ajaxSetup({
        cache: true
    });
    a.getJSON(k + "?callback=?&rpp=2&q=from:" + l, function (b) {
        a.each(b.results, function (b, c) {
            if (c.text !== undefined) {
                var d = '<li class="t1"><a href="http://www.twitter.com/';
                d += l + "/status/" + c.id_str + '" target="_blank">';
                d += c.text + "</a></li>";
                a("#statuses").append(d)
            }
        })
    });
    n()

                
    a('.pics1').hide();
    a('.n1').hide();
    a('.pics2').hide();
    a('.n2').hide();
    a('.pics3').hide();
    a('.n3').hide();
    a('.pics4').hide();
    a('.n4').hide();
    a('.pics5').hide();
    a('.n5').hide();
    a('.pics6').hide();
    a('.n6').hide();
    a('.pics7').hide();
    a('.n7').hide();



startSlideshow('1', slides1) 
startSlideshow('2', slides2) 
startSlideshow('3', slides3) 
startSlideshow('4', slides4) 
startSlideshow('5', slides5) 
startSlideshow('6', slides6) 
startSlideshow('7', slides7) 

    a(".t1-more").click(function () { 
        if (sa1 == 0){
            startSlideshow('1', slides1) 
            sa1 = 1;
        }  
        function go(){ 
        a('.pics1').cycle(1);
        a('.pics1').fadeIn();
        a('.n1').fadeIn();
        }
        setTimeout(go, 2000)
    });
      a(".t1-less").click(function () {   
      a('.pics1').fadeOut();
      a('.n1').fadeOut();
    });


    a(".t2-more").click(function () { 
        if (sa2 == 0){
            startSlideshow('2', slides2) 
            sa2 = 1;
        }  
        function go(){ 
          a('.pics2').fadeIn();
          a('.n2').fadeIn();
          a('.pics2').cycle(1);
        }
        setTimeout(go, 2000)
    });
    a(".t2-less").click(function () {   
      a('.pics2').fadeOut();
      a('.n2').fadeOut();
    });

    a(".t3-more").click(function () { 
        if (sa3 == 0){
            startSlideshow('3', slides3) 
            sa3 = 1;
        }  
        function go(){ 
           a('.pics3').fadeIn();
           a('.n3').fadeIn();
           a('.pics3').cycle(1);
        }
        setTimeout(go, 2000)
    });
    a(".t3-less").click(function () {   
      a('.pics3').fadeOut();
      a('.n3').fadeOut();
    });

    a(".t4-more").click(function () { 
        if (sa4 == 0){
            startSlideshow('4', slides4) 
            sa4 = 1;
        }  
        function go(){ 
           a('.pics4').fadeIn();
           a('.n4').fadeIn();
           a('.pics4').cycle(1);
        }
        setTimeout(go, 2000)
    });
    a(".t4-less").click(function () {   
      a('.pics4').fadeOut();
      a('.n4').fadeOut();
    });

    a(".t5-more").click(function () { 
        if (sa5 == 0){
            startSlideshow('5', slides5) 
            sa5 = 1;
        }  
        function go(){ 
           a('.pics5').fadeIn();
           a('.n5').fadeIn();
           a('.pics5').cycle(1);
        }
        setTimeout(go, 2000)
    });
    a(".t5-less").click(function () {   
      a('.pics5').fadeOut();
      a('.n5').fadeOut();
    });

    a(".t6-more").click(function () { 
        if (sa6 == 0){
            startSlideshow('6', slides6) 
            sa6 = 1;
        }  
        function go(){ 
           a('.pics6').fadeIn();
           a('.n6').fadeIn();
           a('.pics6').cycle(1);
        }
        setTimeout(go, 2000)
    });
    a(".t6-less").click(function () {   
      a('.pics6').fadeOut();
      a('.n6').fadeOut();
    });

    a(".t7-more").click(function () { 

        if (sa7 == 0){
            startSlideshow('7', slides7) 
            sa7 = 1;
        }  
        function go(){ 
           a('.pics7').fadeIn();
           a('.n7').fadeIn();
           a('.pics7').cycle(1);
        }
        setTimeout(go, 2000)
    });
    a(".t7-less").click(function () {   
      a('.pics7').fadeOut();
      a('.n7').fadeOut();
    });

    a('.btn-ext').click(function() { 

            function c() {
                a(".more").fadeIn()
            }
            a("#first").show(500);
            a(".info1 #first").show(500);
            a(".abstract_more").hide(500);
            var b = a(window).height();
            if (b < 650) {
                a("#infos").animate({
                    height: "350px",
                    top: "53%"
                }, 500)
            } else if (b < 700) {
                a("#infos").animate({
                    height: "350px",
                    top: "58%"
                }, 500)
            } else if (b < 750) {
                a("#infos").animate({
                    height: "350px",
                    top: "60%"
                }, 500)
            } else {
                a("#infos").animate({
                    height: "350px",
                    top: "65%"
                }, 500)
            } 
            a("#navigation").animate({
                right: "30px"
            }, 500);
            a("#stream").animate({
                left: "0px"
            }, 500);
            a(".less").fadeOut(0);
            a('.close').fadeOut(0);
            a(".scrollbar").fadeOut();
            setTimeout(c, 500)


        a('#infos').cycle(0); 
        api.goTo(1);
        a('.pics2').fadeOut(); a('.n2').fadeOut();
        a('.pics3').fadeOut(); a('.n3').fadeOut();
        a('.pics4').fadeOut(); a('.n4').fadeOut();
        a('.pics5').fadeOut(); a('.n5').fadeOut();
        a('.pics6').fadeOut(); a('.n6').fadeOut();
        a('.pics7').fadeOut(); a('.n7').fadeOut();
        if (sa1 == 0){
            startSlideshow('1', slides1) 
        function go(){ 
        a('.pics1').cycle(1);
        }
        setTimeout(go, 2000)
            sa1 = 1;
        } 
        function go_(){ 
        a('.pics1').cycle(1);
        a('.pics1').fadeIn();
        a('.n1').fadeIn();
        }
        setTimeout(go_, 1500)  
    }); 



    a('.btn-spfw').click(function() { 

            function c() {
                a(".more").fadeIn()
            }
            a("#first").show(500);
            a(".info2 #first").show(500);
            a(".abstract_more").hide(500);
            var b = a(window).height();
            if (b < 650) {
                a("#infos").animate({
                    height: "350px",
                    top: "53%"
                }, 500)
            } else if (b < 700) {
                a("#infos").animate({
                    height: "350px",
                    top: "58%"
                }, 500)
            } else if (b < 750) {
                a("#infos").animate({
                    height: "350px",
                    top: "60%"
                }, 500)
            } else {
                a("#infos").animate({
                    height: "350px",
                    top: "65%"
                }, 500)
            } 
            a("#navigation").animate({
                right: "30px"
            }, 500);
            a("#stream").animate({
                left: "0px"
            }, 500);
            a(".less").fadeOut(0);
            a('.close').fadeOut(0);
            a(".scrollbar").fadeOut();
            setTimeout(c, 500)


        a('#infos').cycle(6); 
        api.goTo(7);
        a('.pics1').fadeOut(); a('.n1').fadeOut();
        a('.pics3').fadeOut(); a('.n3').fadeOut();
        a('.pics4').fadeOut(); a('.n4').fadeOut();
        a('.pics5').fadeOut(); a('.n5').fadeOut();
        a('.pics6').fadeOut(); a('.n6').fadeOut();
        a('.pics7').fadeOut(); a('.n7').fadeOut();
        if (sa2 == 0){
            startSlideshow('2', slides2) 
        function go(){ 
        a('.pics2').cycle(1);
        }
        setTimeout(go, 2000)
            sa2 = 1;
        }    
        function go_(){ 
        a('.pics2').cycle(1);
        a('.pics2').fadeIn();
        a('.n2').fadeIn();
        }
        setTimeout(go_, 1500)   
    }); 


 a('.btn-exp').click(function() { 

            function c() {
                a(".more").fadeIn()
            }
            a("#first").show(500);
            a(".info3 #first").show(500);
            a(".abstract_more").hide(500);
            var b = a(window).height();
            if (b < 650) {
                a("#infos").animate({
                    height: "350px",
                    top: "53%"
                }, 500)
            } else if (b < 700) {
                a("#infos").animate({
                    height: "350px",
                    top: "58%"
                }, 500)
            } else if (b < 750) {
                a("#infos").animate({
                    height: "350px",
                    top: "60%"
                }, 500)
            } else {
                a("#infos").animate({
                    height: "350px",
                    top: "65%"
                }, 500)
            } 
            a("#navigation").animate({
                right: "30px"
            }, 500);
            a("#stream").animate({
                left: "0px"
            }, 500);
            a(".less").fadeOut(0);
            a('.close').fadeOut(0);
            a(".scrollbar").fadeOut();
            setTimeout(c, 500)


        a('#infos').cycle(5); 
        api.goTo(6);
        a('.pics1').fadeOut(); a('.n1').fadeOut();
        a('.pics2').fadeOut(); a('.n2').fadeOut();
        a('.pics4').fadeOut(); a('.n4').fadeOut();
        a('.pics5').fadeOut(); a('.n5').fadeOut();
        a('.pics6').fadeOut(); a('.n6').fadeOut();
        a('.pics7').fadeOut(); a('.n7').fadeOut();
        if (sa3 == 0){
            startSlideshow('3', slides3)
        function go(){ 
        a('.pics3').cycle(1);
        }
        setTimeout(go, 2000)
            sa3 = 1;
        }    
        function go_(){ 
        a('.pics3').cycle(1);
        a('.pics3').fadeIn();
        a('.n3').fadeIn();
        }
        setTimeout(go_, 1500)  
    }); 


 a('.btn-night').click(function() { 

            function c() {
                a(".more").fadeIn()
            }
            a("#first").show(500);
            a(".info4 #first").show(500);
            a(".abstract_more").hide(500);
            var b = a(window).height();
            if (b < 650) {
                a("#infos").animate({
                    height: "350px",
                    top: "53%"
                }, 500)
            } else if (b < 700) {
                a("#infos").animate({
                    height: "350px",
                    top: "58%"
                }, 500)
            } else if (b < 750) {
                a("#infos").animate({
                    height: "350px",
                    top: "60%"
                }, 500)
            } else {
                a("#infos").animate({
                    height: "350px",
                    top: "65%"
                }, 500)
            } 
            a("#navigation").animate({
                right: "30px"
            }, 500);
            a("#stream").animate({
                left: "0px"
            }, 500);
            a(".less").fadeOut(0);
            a('.close').fadeOut(0);
            a(".scrollbar").fadeOut();
            setTimeout(c, 500)


        a('#infos').cycle(4); 
        api.goTo(5);
        a('.pics1').fadeOut(); a('.n1').fadeOut();
        a('.pics2').fadeOut(); a('.n2').fadeOut();
        a('.pics3').fadeOut(); a('.n3').fadeOut();
        a('.pics5').fadeOut(); a('.n5').fadeOut();
        a('.pics6').fadeOut(); a('.n6').fadeOut();
        a('.pics7').fadeOut(); a('.n7').fadeOut();
        if (sa4 == 0){
            startSlideshow('4', slides4)
        function go(){ 
        a('.pics4').cycle(1);
        }
        setTimeout(go, 2000)
            sa4 = 1;
        }    
        function go_(){ 
        a('.pics4').cycle(1);
        a('.pics4').fadeIn();
        a('.n4').fadeIn();
        }
        setTimeout(go_, 1500)  
    }); 


 a('.btn-patrick').click(function() { 

            function c() {
                a(".more").fadeIn()
            }
            a("#first").show(500);
            a(".info5 #first").show(500);
            a(".abstract_more").hide(500);
            var b = a(window).height();
            if (b < 650) {
                a("#infos").animate({
                    height: "350px",
                    top: "53%"
                }, 500)
            } else if (b < 700) {
                a("#infos").animate({
                    height: "350px",
                    top: "58%"
                }, 500)
            } else if (b < 750) {
                a("#infos").animate({
                    height: "350px",
                    top: "60%"
                }, 500)
            } else {
                a("#infos").animate({
                    height: "350px",
                    top: "65%"
                }, 500)
            } 
            a("#navigation").animate({
                right: "30px"
            }, 500);
            a("#stream").animate({
                left: "0px"
            }, 500);
            a(".less").fadeOut(0);
            a('.close').fadeOut(0);
            a(".scrollbar").fadeOut();
            setTimeout(c, 500)


        a('#infos').cycle(3); 
        api.goTo(4);
        a('.pics1').fadeOut(); a('.n1').fadeOut();
        a('.pics2').fadeOut(); a('.n2').fadeOut();
        a('.pics3').fadeOut(); a('.n3').fadeOut();
        a('.pics4').fadeOut(); a('.n4').fadeOut();
        a('.pics6').fadeOut(); a('.n6').fadeOut();
        a('.pics7').fadeOut(); a('.n7').fadeOut();
        if (sa5 == 0){
            startSlideshow('5', slides5)
        function go(){ 
        a('.pics5').cycle(1);
        }
        setTimeout(go, 2000)
            sa5 = 1;
        }    
        function go_(){ 
        a('.pics5').cycle(1);
        a('.pics5').fadeIn();
        a('.n5').fadeIn();
        }
        setTimeout(go_, 1500)  
    }); 


 a('.btn-motortola').click(function() { 

            function c() {
                a(".more").fadeIn()
            }
            a("#first").show(500);
            a(".info6 #first").show(500);
            a(".abstract_more").hide(500);
            var b = a(window).height();
            if (b < 650) {
                a("#infos").animate({
                    height: "350px",
                    top: "53%"
                }, 500)
            } else if (b < 700) {
                a("#infos").animate({
                    height: "350px",
                    top: "58%"
                }, 500)
            } else if (b < 750) {
                a("#infos").animate({
                    height: "350px",
                    top: "60%"
                }, 500)
            } else {
                a("#infos").animate({
                    height: "350px",
                    top: "65%"
                }, 500)
            } 
            a("#navigation").animate({
                right: "30px"
            }, 500);
            a("#stream").animate({
                left: "0px"
            }, 500);
            a(".less").fadeOut(0);
            a('.close').fadeOut(0);
            a(".scrollbar").fadeOut();
            setTimeout(c, 500)


        a('#infos').cycle(2); 
        api.goTo(3);
        a('.pics1').fadeOut(); a('.n1').fadeOut();
        a('.pics2').fadeOut(); a('.n2').fadeOut();
        a('.pics3').fadeOut(); a('.n3').fadeOut();
        a('.pics4').fadeOut(); a('.n4').fadeOut();
        a('.pics5').fadeOut(); a('.n5').fadeOut();
        a('.pics7').fadeOut(); a('.n7').fadeOut();
        if (sa6 == 0){
            startSlideshow('6', slides6)
        function go(){ 
        a('.pics6').cycle(1);
        }
        setTimeout(go, 2000)
            sa6 = 1;
        }    
        function go_(){ 
        a('.pics6').cycle(1);
        a('.pics6').fadeIn();
        a('.n6').fadeIn();
        }
        setTimeout(go_, 1500)  
    }); 


 a('.btn-whisky').click(function() { 

            function c() {
                a(".more").fadeIn()
            }
            a("#first").show(500);
            a(".info7 #first").show(500);
            a(".abstract_more").hide(500);
            var b = a(window).height();
            if (b < 650) {
                a("#infos").animate({
                    height: "350px",
                    top: "53%"
                }, 500)
            } else if (b < 700) {
                a("#infos").animate({
                    height: "350px",
                    top: "58%"
                }, 500)
            } else if (b < 750) {
                a("#infos").animate({
                    height: "350px",
                    top: "60%"
                }, 500)
            } else {
                a("#infos").animate({
                    height: "350px",
                    top: "65%"
                }, 500)
            } 
            a("#navigation").animate({
                right: "30px"
            }, 500);
            a("#stream").animate({
                left: "0px"
            }, 500);
            a(".less").fadeOut(0);
            a('.close').fadeOut(0);
            a(".scrollbar").fadeOut();
            setTimeout(c, 500)


        a('#infos').cycle(1); 
        api.goTo(2);
        a('.pics1').fadeOut(); a('.n1').fadeOut();
        a('.pics2').fadeOut(); a('.n2').fadeOut();
        a('.pics3').fadeOut(); a('.n3').fadeOut();
        a('.pics4').fadeOut(); a('.n4').fadeOut();
        a('.pics5').fadeOut(); a('.n5').fadeOut();
        a('.pics6').fadeOut(); a('.n6').fadeOut();
        if (sa7 == 0){
            startSlideshow('7', slides7)
        function go(){ 
        a('.pics7').cycle(1);
        }
        setTimeout(go, 2000)
            sa7 = 1;
        }    
        function go_(){ 
        a('.pics7').cycle(1);
        a('.pics7').fadeIn();
        a('.n7').fadeIn();
        }
        setTimeout(go_, 1500)  
    }); 





if (local == "" || local == "#trabalhos"){
    a.supersized({
                
                    // Functionality
                    slideshow               :   1,          // Slideshow on/off
                    autoplay                :   0,          // Slideshow starts playing automatically
                    start_slide             :   1,          // Start slide (0 is random)
                    stop_loop               :   0,          // Pauses slideshow on last slide
                    random                  :   0,          // Randomize slide order (Ignores start slide)
                    slide_interval          :   3000,       // Length between transitions
                    transition              :   6,          // 0-None, 1-Fade, 2-Slide Top, 3-Slide Right, 4-Slide Bottom, 5-Slide Left, 6-Carousel Right, 7-Carousel Left
                    transition_speed        :   500,       // Speed of transition
                    new_window              :   1,          // Image links open in new window/tab
                    pause_hover             :   0,          // Pause slideshow on hover
                    keyboard_nav            :   0,          // Keyboard navigation on/off
                    performance             :   1,          // 0-Normal, 1-Hybrid speed/quality, 2-Optimizes image quality, 3-Optimizes transition speed // (Only works for Firefox/IE, not Webkit)
                    image_protect           :   1,          // Disables image dragging and right click with Javascript
                                                               
                    // Size & Position                         
                    min_width               :   0,          // Min width allowed (in pixels)
                    min_height              :   0,          // Min height allowed (in pixels)
                    vertical_center         :   1,          // Vertically center background
                    horizontal_center       :   1,          // Horizontally center background
                    fit_always              :   0,          // Image will never exceed browser width or height (Ignores min. dimensions)
                    fit_portrait            :   1,          // Portrait images will not exceed browser height
                    fit_landscape           :   0,          // Landscape images will not exceed browser width
                                                               
                    // Components                           
                    slide_links             :   'blank',    // Individual links for each slide (Options: false, 'number', 'name', 'blank')
                    thumb_links             :   1,          // Individual thumb links for each slide
                    thumbnail_navigation    :   0,          // Thumbnail navigation
                    slides                  :   [           // Slideshow Images
                                                        {image : 'img/backgrounds/smirnoffext.jpg'},
                                                        {image : 'img/backgrounds/whisky.jpg'},
                                                        {image : 'img/backgrounds/motorola.jpg'},
                                                        {image : 'img/backgrounds/stpatricks.jpg'},
                                                        {image : 'img/backgrounds/smirnoffnight.jpg'},
                                                        {image : 'img/backgrounds/smirnoffexp.jpg'},
                                                        {image : 'img/backgrounds/spfw.jpg'}
                                                ],
                                                
                    // Theme Options               
                    progress_bar            :   1,          // Timer for each slide                         
                    mouse_scrub             :   0
                    
                });
                a('#infos').hide(); 
     function wait0() {
        a('#infos').fadeIn(500); 
        a('#infos').cycle(0);  
    } 
        setTimeout(wait0, 1500)
}




else if (local == "#nightlife-exchange"){
    a.supersized({
                
                    // Functionality
                    slideshow               :   1,          // Slideshow on/off
                    autoplay                :   0,          // Slideshow starts playing automatically
                    start_slide             :   1,          // Start slide (0 is random)
                    stop_loop               :   0,          // Pauses slideshow on last slide
                    random                  :   0,          // Randomize slide order (Ignores start slide)
                    slide_interval          :   3000,       // Length between transitions
                    transition              :   6,          // 0-None, 1-Fade, 2-Slide Top, 3-Slide Right, 4-Slide Bottom, 5-Slide Left, 6-Carousel Right, 7-Carousel Left
                    transition_speed        :   500,       // Speed of transition
                    new_window              :   1,          // Image links open in new window/tab
                    pause_hover             :   0,          // Pause slideshow on hover
                    keyboard_nav            :   0,          // Keyboard navigation on/off
                    performance             :   1,          // 0-Normal, 1-Hybrid speed/quality, 2-Optimizes image quality, 3-Optimizes transition speed // (Only works for Firefox/IE, not Webkit)
                    image_protect           :   1,          // Disables image dragging and right click with Javascript
                                                               
                    // Size & Position                         
                    min_width               :   0,          // Min width allowed (in pixels)
                    min_height              :   0,          // Min height allowed (in pixels)
                    vertical_center         :   1,          // Vertically center background
                    horizontal_center       :   1,          // Horizontally center background
                    fit_always              :   0,          // Image will never exceed browser width or height (Ignores min. dimensions)
                    fit_portrait            :   1,          // Portrait images will not exceed browser height
                    fit_landscape           :   0,          // Landscape images will not exceed browser width
                                                               
                    // Components                           
                    slide_links             :   'blank',    // Individual links for each slide (Options: false, 'number', 'name', 'blank')
                    thumb_links             :   1,          // Individual thumb links for each slide
                    thumbnail_navigation    :   0,          // Thumbnail navigation
                    slides                  :   [           // Slideshow Images
                                                        {image : 'img/backgrounds/smirnoffext.jpg'},
                                                        {image : 'img/backgrounds/whisky.jpg'},
                                                        {image : 'img/backgrounds/motorola.jpg'},
                                                        {image : 'img/backgrounds/stpatricks.jpg'},
                                                        {image : 'img/backgrounds/smirnoffnight.jpg'},
                                                        {image : 'img/backgrounds/smirnoffexp.jpg'},
                                                        {image : 'img/backgrounds/spfw.jpg'}
                                                ],
                                                
                    // Theme Options               
                    progress_bar            :   1,          // Timer for each slide                         
                    mouse_scrub             :   0
                    
                });
                a('#infos').hide(); 
     function wait1() {
        a('#infos').fadeIn(500); 
        a('#infos').cycle(0);  
    }
        startSlideshow('1', slides1)
        function go1(){ 
        a('.pics1').cycle(1);
        }
        setTimeout(go1, 2000)
        sa1 = 1;

        function go_1(){ 
        a('.pics1').cycle(1);
        a('.pics1').fadeIn();
        a('.n1').fadeIn();
        }
        setTimeout(go_1, 1500) 
        setTimeout(wait1, 1500)
}



else if (local == "#spfw"){
    a.supersized({
                
                    // Functionality
                    slideshow               :   1,          // Slideshow on/off
                    autoplay                :   0,          // Slideshow starts playing automatically
                    start_slide             :   7,          // Start slide (0 is random)
                    stop_loop               :   0,          // Pauses slideshow on last slide
                    random                  :   0,          // Randomize slide order (Ignores start slide)
                    slide_interval          :   3000,       // Length between transitions
                    transition              :   6,          // 0-None, 1-Fade, 2-Slide Top, 3-Slide Right, 4-Slide Bottom, 5-Slide Left, 6-Carousel Right, 7-Carousel Left
                    transition_speed        :   500,       // Speed of transition
                    new_window              :   1,          // Image links open in new window/tab
                    pause_hover             :   0,          // Pause slideshow on hover
                    keyboard_nav            :   0,          // Keyboard navigation on/off
                    performance             :   1,          // 0-Normal, 1-Hybrid speed/quality, 2-Optimizes image quality, 3-Optimizes transition speed // (Only works for Firefox/IE, not Webkit)
                    image_protect           :   1,          // Disables image dragging and right click with Javascript
                                                               
                    // Size & Position                         
                    min_width               :   0,          // Min width allowed (in pixels)
                    min_height              :   0,          // Min height allowed (in pixels)
                    vertical_center         :   1,          // Vertically center background
                    horizontal_center       :   1,          // Horizontally center background
                    fit_always              :   0,          // Image will never exceed browser width or height (Ignores min. dimensions)
                    fit_portrait            :   1,          // Portrait images will not exceed browser height
                    fit_landscape           :   0,          // Landscape images will not exceed browser width
                                                               
                    // Components                           
                    slide_links             :   'blank',    // Individual links for each slide (Options: false, 'number', 'name', 'blank')
                    thumb_links             :   1,          // Individual thumb links for each slide
                    thumbnail_navigation    :   0,          // Thumbnail navigation
                    slides                  :   [           // Slideshow Images
                                                        {image : 'img/backgrounds/smirnoffext.jpg'},
                                                        {image : 'img/backgrounds/whisky.jpg'},
                                                        {image : 'img/backgrounds/motorola.jpg'},
                                                        {image : 'img/backgrounds/stpatricks.jpg'},
                                                        {image : 'img/backgrounds/smirnoffnight.jpg'},
                                                        {image : 'img/backgrounds/smirnoffexp.jpg'},
                                                        {image : 'img/backgrounds/spfw.jpg'}
                                                ],
                                                
                    // Theme Options               
                    progress_bar            :   1,          // Timer for each slide                         
                    mouse_scrub             :   0
                    
                });
                a('#infos').hide(); 
     function wait2() {
        a('#infos').fadeIn(500); 
        a('#infos').cycle(6);  
    }
        startSlideshow('2', slides2)
        function go2(){ 
        a('.pics2').cycle(1);
        }
        setTimeout(go2, 2000)
        sa2 = 1;

        function go_2(){ 
        a('.pics2').cycle(1);
        a('.pics2').fadeIn();
        a('.n2').fadeIn();
        }
        setTimeout(go_2, 1500) 
        setTimeout(wait2, 1500)
}



else if (local == "#smirnoff-experience"){
    a.supersized({
                
                    // Functionality
                    slideshow               :   1,          // Slideshow on/off
                    autoplay                :   0,          // Slideshow starts playing automatically
                    start_slide             :   6,          // Start slide (0 is random)
                    stop_loop               :   0,          // Pauses slideshow on last slide
                    random                  :   0,          // Randomize slide order (Ignores start slide)
                    slide_interval          :   3000,       // Length between transitions
                    transition              :   6,          // 0-None, 1-Fade, 2-Slide Top, 3-Slide Right, 4-Slide Bottom, 5-Slide Left, 6-Carousel Right, 7-Carousel Left
                    transition_speed        :   500,       // Speed of transition
                    new_window              :   1,          // Image links open in new window/tab
                    pause_hover             :   0,          // Pause slideshow on hover
                    keyboard_nav            :   0,          // Keyboard navigation on/off
                    performance             :   1,          // 0-Normal, 1-Hybrid speed/quality, 2-Optimizes image quality, 3-Optimizes transition speed // (Only works for Firefox/IE, not Webkit)
                    image_protect           :   1,          // Disables image dragging and right click with Javascript
                                                               
                    // Size & Position                         
                    min_width               :   0,          // Min width allowed (in pixels)
                    min_height              :   0,          // Min height allowed (in pixels)
                    vertical_center         :   1,          // Vertically center background
                    horizontal_center       :   1,          // Horizontally center background
                    fit_always              :   0,          // Image will never exceed browser width or height (Ignores min. dimensions)
                    fit_portrait            :   1,          // Portrait images will not exceed browser height
                    fit_landscape           :   0,          // Landscape images will not exceed browser width
                                                               
                    // Components                           
                    slide_links             :   'blank',    // Individual links for each slide (Options: false, 'number', 'name', 'blank')
                    thumb_links             :   1,          // Individual thumb links for each slide
                    thumbnail_navigation    :   0,          // Thumbnail navigation
                    slides                  :   [           // Slideshow Images
                                                        {image : 'img/backgrounds/smirnoffext.jpg'},
                                                        {image : 'img/backgrounds/whisky.jpg'},
                                                        {image : 'img/backgrounds/motorola.jpg'},
                                                        {image : 'img/backgrounds/stpatricks.jpg'},
                                                        {image : 'img/backgrounds/smirnoffnight.jpg'},
                                                        {image : 'img/backgrounds/smirnoffexp.jpg'},
                                                        {image : 'img/backgrounds/spfw.jpg'}
                                                ],
                                                
                    // Theme Options               
                    progress_bar            :   1,          // Timer for each slide                         
                    mouse_scrub             :   0
                    
                });
                a('#infos').hide(); 
     function wait3() {
        a('#infos').fadeIn(500); 
        a('#infos').cycle(5);  
    }
        startSlideshow('3', slides3)
        function go3(){ 
        a('.pics3').cycle(1);
        }
        setTimeout(go3, 2000)
        sa3 = 1;

        function go_3(){ 
        a('.pics3').cycle(1);
        a('.pics3').fadeIn();
        a('.n3').fadeIn();
        }
        setTimeout(go_3, 1500) 
        setTimeout(wait3, 1500)
}



else if (local == "#smirnoff-nightlife"){
    a.supersized({
                
                    // Functionality
                    slideshow               :   1,          // Slideshow on/off
                    autoplay                :   0,          // Slideshow starts playing automatically
                    start_slide             :   5,          // Start slide (0 is random)
                    stop_loop               :   0,          // Pauses slideshow on last slide
                    random                  :   0,          // Randomize slide order (Ignores start slide)
                    slide_interval          :   3000,       // Length between transitions
                    transition              :   6,          // 0-None, 1-Fade, 2-Slide Top, 3-Slide Right, 4-Slide Bottom, 5-Slide Left, 6-Carousel Right, 7-Carousel Left
                    transition_speed        :   500,       // Speed of transition
                    new_window              :   1,          // Image links open in new window/tab
                    pause_hover             :   0,          // Pause slideshow on hover
                    keyboard_nav            :   0,          // Keyboard navigation on/off
                    performance             :   1,          // 0-Normal, 1-Hybrid speed/quality, 2-Optimizes image quality, 3-Optimizes transition speed // (Only works for Firefox/IE, not Webkit)
                    image_protect           :   1,          // Disables image dragging and right click with Javascript
                                                               
                    // Size & Position                         
                    min_width               :   0,          // Min width allowed (in pixels)
                    min_height              :   0,          // Min height allowed (in pixels)
                    vertical_center         :   1,          // Vertically center background
                    horizontal_center       :   1,          // Horizontally center background
                    fit_always              :   0,          // Image will never exceed browser width or height (Ignores min. dimensions)
                    fit_portrait            :   1,          // Portrait images will not exceed browser height
                    fit_landscape           :   0,          // Landscape images will not exceed browser width
                                                               
                    // Components                           
                    slide_links             :   'blank',    // Individual links for each slide (Options: false, 'number', 'name', 'blank')
                    thumb_links             :   1,          // Individual thumb links for each slide
                    thumbnail_navigation    :   0,          // Thumbnail navigation
                    slides                  :   [           // Slideshow Images
                                                        {image : 'img/backgrounds/smirnoffext.jpg'},
                                                        {image : 'img/backgrounds/whisky.jpg'},
                                                        {image : 'img/backgrounds/motorola.jpg'},
                                                        {image : 'img/backgrounds/stpatricks.jpg'},
                                                        {image : 'img/backgrounds/smirnoffnight.jpg'},
                                                        {image : 'img/backgrounds/smirnoffexp.jpg'},
                                                        {image : 'img/backgrounds/spfw.jpg'}
                                                ],
                                                
                    // Theme Options               
                    progress_bar            :   1,          // Timer for each slide                         
                    mouse_scrub             :   0
                    
                });
                a('#infos').hide(); 
     function wait4() {
        a('#infos').fadeIn(500); 
        a('#infos').cycle(4);  
    }
        startSlideshow('4', slides4)
        function go4(){ 
        a('.pics4').cycle(1);
        }
        setTimeout(go4, 2000)
        sa4 = 1;

        function go_4(){ 
        a('.pics4').cycle(1);
        a('.pics4').fadeIn();
        a('.n4').fadeIn();
        }
        setTimeout(go_4, 1500) 
        setTimeout(wait4, 1500)
}


else if (local == "#st-patricks-day"){
    a.supersized({
                
                    // Functionality
                    slideshow               :   1,          // Slideshow on/off
                    autoplay                :   0,          // Slideshow starts playing automatically
                    start_slide             :   4,          // Start slide (0 is random)
                    stop_loop               :   0,          // Pauses slideshow on last slide
                    random                  :   0,          // Randomize slide order (Ignores start slide)
                    slide_interval          :   3000,       // Length between transitions
                    transition              :   6,          // 0-None, 1-Fade, 2-Slide Top, 3-Slide Right, 4-Slide Bottom, 5-Slide Left, 6-Carousel Right, 7-Carousel Left
                    transition_speed        :   500,       // Speed of transition
                    new_window              :   1,          // Image links open in new window/tab
                    pause_hover             :   0,          // Pause slideshow on hover
                    keyboard_nav            :   0,          // Keyboard navigation on/off
                    performance             :   1,          // 0-Normal, 1-Hybrid speed/quality, 2-Optimizes image quality, 3-Optimizes transition speed // (Only works for Firefox/IE, not Webkit)
                    image_protect           :   1,          // Disables image dragging and right click with Javascript
                                                               
                    // Size & Position                         
                    min_width               :   0,          // Min width allowed (in pixels)
                    min_height              :   0,          // Min height allowed (in pixels)
                    vertical_center         :   1,          // Vertically center background
                    horizontal_center       :   1,          // Horizontally center background
                    fit_always              :   0,          // Image will never exceed browser width or height (Ignores min. dimensions)
                    fit_portrait            :   1,          // Portrait images will not exceed browser height
                    fit_landscape           :   0,          // Landscape images will not exceed browser width
                                                               
                    // Components                           
                    slide_links             :   'blank',    // Individual links for each slide (Options: false, 'number', 'name', 'blank')
                    thumb_links             :   1,          // Individual thumb links for each slide
                    thumbnail_navigation    :   0,          // Thumbnail navigation
                    slides                  :   [           // Slideshow Images
                                                        {image : 'img/backgrounds/smirnoffext.jpg'},
                                                        {image : 'img/backgrounds/whisky.jpg'},
                                                        {image : 'img/backgrounds/motorola.jpg'},
                                                        {image : 'img/backgrounds/stpatricks.jpg'},
                                                        {image : 'img/backgrounds/smirnoffnight.jpg'},
                                                        {image : 'img/backgrounds/smirnoffexp.jpg'},
                                                        {image : 'img/backgrounds/spfw.jpg'}
                                                ],
                                                
                    // Theme Options               
                    progress_bar            :   1,          // Timer for each slide                         
                    mouse_scrub             :   0
                    
                });
                a('#infos').hide(); 
     function wait5() {
        a('#infos').fadeIn(500); 
        a('#infos').cycle(3);  
    }
        startSlideshow('5', slides5)
        function go5(){ 
        a('.pics5').cycle(1);
        }
        setTimeout(go5, 2000)
        sa5 = 1;

        function go_5(){ 
        a('.pics5').cycle(1);
        a('.pics5').fadeIn();
        a('.n5').fadeIn();
        }
        setTimeout(go_5, 1500) 
        setTimeout(wait5, 1500)
}



else if (local == "#motorola-futurecom"){
    a.supersized({
                
                    // Functionality
                    slideshow               :   1,          // Slideshow on/off
                    autoplay                :   0,          // Slideshow starts playing automatically
                    start_slide             :   3,          // Start slide (0 is random)
                    stop_loop               :   0,          // Pauses slideshow on last slide
                    random                  :   0,          // Randomize slide order (Ignores start slide)
                    slide_interval          :   3000,       // Length between transitions
                    transition              :   6,          // 0-None, 1-Fade, 2-Slide Top, 3-Slide Right, 4-Slide Bottom, 5-Slide Left, 6-Carousel Right, 7-Carousel Left
                    transition_speed        :   500,       // Speed of transition
                    new_window              :   1,          // Image links open in new window/tab
                    pause_hover             :   0,          // Pause slideshow on hover
                    keyboard_nav            :   0,          // Keyboard navigation on/off
                    performance             :   1,          // 0-Normal, 1-Hybrid speed/quality, 2-Optimizes image quality, 3-Optimizes transition speed // (Only works for Firefox/IE, not Webkit)
                    image_protect           :   1,          // Disables image dragging and right click with Javascript
                                                               
                    // Size & Position                         
                    min_width               :   0,          // Min width allowed (in pixels)
                    min_height              :   0,          // Min height allowed (in pixels)
                    vertical_center         :   1,          // Vertically center background
                    horizontal_center       :   1,          // Horizontally center background
                    fit_always              :   0,          // Image will never exceed browser width or height (Ignores min. dimensions)
                    fit_portrait            :   1,          // Portrait images will not exceed browser height
                    fit_landscape           :   0,          // Landscape images will not exceed browser width
                                                               
                    // Components                           
                    slide_links             :   'blank',    // Individual links for each slide (Options: false, 'number', 'name', 'blank')
                    thumb_links             :   1,          // Individual thumb links for each slide
                    thumbnail_navigation    :   0,          // Thumbnail navigation
                    slides                  :   [           // Slideshow Images
                                                        {image : 'img/backgrounds/smirnoffext.jpg'},
                                                        {image : 'img/backgrounds/whisky.jpg'},
                                                        {image : 'img/backgrounds/motorola.jpg'},
                                                        {image : 'img/backgrounds/stpatricks.jpg'},
                                                        {image : 'img/backgrounds/smirnoffnight.jpg'},
                                                        {image : 'img/backgrounds/smirnoffexp.jpg'},
                                                        {image : 'img/backgrounds/spfw.jpg'}
                                                ],
                                                
                    // Theme Options               
                    progress_bar            :   1,          // Timer for each slide                         
                    mouse_scrub             :   0
                    
                });
                a('#infos').hide(); 
     function wait6() {
        a('#infos').fadeIn(500); 
        a('#infos').cycle(2);  
    }
        startSlideshow('6', slides6)
        function go6(){ 
        a('.pics6').cycle(1);
        }
        setTimeout(go6, 2000)
        sa6 = 1;

        function go_6(){ 
        a('.pics6').cycle(1);
        a('.pics6').fadeIn();
        a('.n6').fadeIn();
        }
        setTimeout(go_6, 1500) 
        setTimeout(wait6, 1500)
}


else if (local == "#whisky-festival"){
    a.supersized({
                
                    // Functionality
                    slideshow               :   1,          // Slideshow on/off
                    autoplay                :   0,          // Slideshow starts playing automatically
                    start_slide             :   2,          // Start slide (0 is random)
                    stop_loop               :   0,          // Pauses slideshow on last slide
                    random                  :   0,          // Randomize slide order (Ignores start slide)
                    slide_interval          :   3000,       // Length between transitions
                    transition              :   6,          // 0-None, 1-Fade, 2-Slide Top, 3-Slide Right, 4-Slide Bottom, 5-Slide Left, 6-Carousel Right, 7-Carousel Left
                    transition_speed        :   500,       // Speed of transition
                    new_window              :   1,          // Image links open in new window/tab
                    pause_hover             :   0,          // Pause slideshow on hover
                    keyboard_nav            :   0,          // Keyboard navigation on/off
                    performance             :   1,          // 0-Normal, 1-Hybrid speed/quality, 2-Optimizes image quality, 3-Optimizes transition speed // (Only works for Firefox/IE, not Webkit)
                    image_protect           :   1,          // Disables image dragging and right click with Javascript
                                                               
                    // Size & Position                         
                    min_width               :   0,          // Min width allowed (in pixels)
                    min_height              :   0,          // Min height allowed (in pixels)
                    vertical_center         :   1,          // Vertically center background
                    horizontal_center       :   1,          // Horizontally center background
                    fit_always              :   0,          // Image will never exceed browser width or height (Ignores min. dimensions)
                    fit_portrait            :   1,          // Portrait images will not exceed browser height
                    fit_landscape           :   0,          // Landscape images will not exceed browser width
                                                               
                    // Components                           
                    slide_links             :   'blank',    // Individual links for each slide (Options: false, 'number', 'name', 'blank')
                    thumb_links             :   1,          // Individual thumb links for each slide
                    thumbnail_navigation    :   0,          // Thumbnail navigation
                    slides                  :   [           // Slideshow Images
                                                        {image : 'img/backgrounds/smirnoffext.jpg'},
                                                        {image : 'img/backgrounds/whisky.jpg'},
                                                        {image : 'img/backgrounds/motorola.jpg'},
                                                        {image : 'img/backgrounds/stpatricks.jpg'},
                                                        {image : 'img/backgrounds/smirnoffnight.jpg'},
                                                        {image : 'img/backgrounds/smirnoffexp.jpg'},
                                                        {image : 'img/backgrounds/spfw.jpg'}
                                                ],
                                                
                    // Theme Options               
                    progress_bar            :   1,          // Timer for each slide                         
                    mouse_scrub             :   0
                    
                });
                a('#infos').hide(); 
     function wait7() {
        a('#infos').fadeIn(500); 
        a('#infos').cycle(1);  
    }
        startSlideshow('7', slides7)
        function go7(){ 
        a('.pics7').cycle(1);
        }
        setTimeout(go7, 2000)
        sa7 = 1;

        function go_7(){ 
        a('.pics7').cycle(1);
        a('.pics7').fadeIn();
        a('.n7').fadeIn();
        }
        setTimeout(go_7, 1500) 
        setTimeout(wait7, 1500)
}


})	
