{"version":3,"sources":["plugins-ziggy.js","main-ziggy.js","slick.min.js","waypoints.min.js","jquery.counterup.min.js","jquery.fancybox.js","polyfills.js"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AC/nBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACvlCA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACnBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACPA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACPA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACn+DA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA","file":"scripts-ziggy.min.js","sourcesContent":["(function($) {\n\t'use strict';\n\n\t$.fn.extend({\n\n\n\t\t/* Csrf token */\n\n\n\t\taddToken: function(object) {\n\t\t\tif (object instanceof Array) {\n\t\t\t\tobject.push({\n\t\t\t\t\tname: 'csrf_token',\n\t\t\t\t\tvalue: $('html head meta[name=\"csrf_token\"]').prop('content')\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\tobject.csrf_token = $('html head meta[name=\"csrf_token\"]').prop('content');\n\t\t\t}\n\t\t\treturn object;\n\t\t},\n\n\n\t\t/* Triangles */\n\n\t\tsameHeightSquareInside: function(elementClass) {\n\t\t\tif (!$(this).length) { return this; }\n\t\t\telementClass = elementClass || '';\n\n\t\t\t$(this).on('updateCss', function() {\n\t\t\t\t$(this).each(function() {\n\t\t\t\t\tvar s = $(this).outerHeight();\n\t\t\t\t\tvar $triangle = $(this).find('.' + elementClass);\n\t\t\t\t\tif (!$triangle.length) {\n\t\t\t\t\t\t$triangle = $('
');\n\t\t\t\t\t\t$(this).append($triangle);\n\t\t\t\t\t}\n\t\t\t\t\t$triangle.css({ width:s, height:s });\n\t\t\t\t});\n\t\t\t}).trigger('updateCss');\n\n\t\t\treturn this;\n\t\t},\n\n\n\t\t/* Length select */\n\n\t\tlengthPicker: function(opts) {\n\t\t\tif (!$(this).length) { return this; }\n\t\t\t$(this).each(function() {\n\n\t\t\t\tvar $this = $(this);\n \n\t\t\t\tvar min = .5;\n\t\t\t\tvar max = 7;\n\t\t\t\tvar step = .5;\n\n\t\t\t\t$this.attr({\n\t\t\t\t\tvalue: $this.val(),\n\t\t\t\t\tmin: min,\n\t\t\t\t\tmax: max,\n\t\t\t\t\tstep: step\n\t\t\t\t});\n \n $this.off('newPrice');\n \n $this.on('newPrice', function (e, newPrice) {\n var newPriceString = newPrice.toFixed(2);\n $('.sug-price-calc').text(newPriceString);\n $('#sug-price-hidden').val(newPriceString);\n if ($('.user-price-calc').hasClass('multistep-price'))\n {\n $('.user-price-slider').val(parseInt(newPriceString));\n $('.user-price-calc').text(parseInt(newPriceString).toFixed(2));\n }\n\n });\n\n\t\t\t\tif (opts === 'destroy') {\n\t\t\t\t\t$this\n\t\t\t\t\t\t.off('input change newPrice')\n\t\t\t\t\t\t.unwrap('.length-picker');\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\topts = opts || {};\n\t\t\t\t\t$this.wrap('
');\n var $timeCalc = $('.time-calc', $this.parents('.selectduration:first'));\n\t\t\t\t\t$this.wrap('
');\n\t\t\t\t\tvar calcPrice = function() {\n\t\t\t\t\t\tvar price;\n price = ($this.val() * 40 - 2)/2;\n\t\t\t\t\t\t$this.trigger('newPrice', price);\n\t\t\t\t\t};\n\n\t\t\t\t\t$(this)\n\t\t\t\t\t\t.on('input change', function() {\n var minutes = Math.floor(60 * parseFloat($this.val()) / 60);\n var seconds = parseFloat(60 * $this.val()) % 60;\n var secondsString = seconds.toString().length < 2 ? \"0\" + seconds : seconds;\n $timeCalc.text(minutes + ':' + secondsString);\n\t\t\t\t\t\t\tcalcPrice();\n\t\t\t\t\t\t}).trigger('change');\n\t\t\t\t}\n\n\t\t\t});\n\n\n\t\t\treturn this;\n\t\t},\n\n lengthPickerUserPrice: function (opts) {\n if (!$(this).length) {\n return this;\n }\n $(this).each(function () {\n var $this = $(this);\n\n //var durationEl = $('[name=\"duration\"]');\n //\n //var calcPriceByDuration = function(duration) {\n // return duration * 40 - 2;\n //};\n //\n //var min = calcPriceByDuration(durationEl.attr('min'));\n //var max = calcPriceByDuration(durationEl.attr('max'));\n \n var min = 0;\n var max = 150;\n if ($('.user-price-calc').hasClass('multistep-price'))\n {\n max = 75;\n }\n var step = 1;\n\n $this.attr({\n min : min,\n max : max,\n step : step\n });\n\n $this.off('newPrice');\n\n $this.on('newPrice', function (e, newPrice) {\n var newPriceString = newPrice.toFixed(2);\n $('.user-price-calc').text(newPriceString);\n });\n\n if (opts === 'destroy') {\n $this\n .off('input change newPrice')\n .unwrap('.length-picker');\n }\n else {\n opts = opts || {};\n\n $(this)\n .on('input change', function () {\n var price = parseFloat($this.val());\n $this.trigger('newPrice', price);\n }).trigger('change');\n }\n\n });\n\n return this;\n },\n\n\n\t\t/* Scroll top / bottom */\n\n\t\tscrollToBottom: function(ms) {\n\t\t\t$(this).each(function() {\n\t\t\t\tvar $el = $(this);\n\t\t\t\t$el.animate({\n\t\t\t\t\tscrollTop: this.scrollHeight - $el.outerHeight()\n\t\t\t\t}, ms || 250);\n\t\t\t});\n\t\t\treturn this;\n\t\t},\n\t\tscrollToTop: function() {\n\t\t\t$(this).each(function() {\n\t\t\t\t$(this).animate({\n\t\t\t\t\tscrollTop: 0\n\t\t\t\t}, ms || 250);\n\t\t\t});\n\t\t\treturn this;\n\t\t},\n\n\n\t\t/* Block element during loading */\n\n\t\tloading: function(method) {\n\t\t\tvar overlay = $('');\n\t\t\toverlay.on('click', function(e) {\n\t\t\t\te.preventDefault();\n\t\t\t\te.stopPropagation();\n\t\t\t});\n\t\t\tthis.each(function() {\n\t\t\t\tvar $this = $(this);\n\t\t\t\tswitch (method) {\n\t\t\t\t\tcase ('start'):\n\t\t\t\t\t\tif ($('.loading', $this).length) { return; }\n\t\t\t\t\t\tif($this.css('position') === 'static') {\n\t\t\t\t\t\t\t$this.css({ position: 'relative' });\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$this.append(overlay.clone('true'));\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase ('error'):\n\t\t\t\t\t\t$this.find('.loading').addClass('error');\n\t\t\t\t\t\tsetTimeout(function() {\n\t\t\t\t\t\t\t$this.find('.loading').remove();\n\t\t\t\t\t\t}, 2000);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase ('finish'):\n\t\t\t\t\t\t$this.find('.loading').remove();\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t});\n\t\t\treturn this;\n\t\t},\n\n\n\t\t/*\n\t\t* Init dropzone.js,\n\t\t* returns dropzone instance!)\n\t\t*/\n\n\t\tinitOrderDropZone: function() {\n\n\t\t\tvar $this = this;\n\n\t\t\t/* Init dropzone */\n\n\t\t\tvar filePreviewTemplate = ''\n\t\t\t\t+ '
'\n\t\t\t\t+ '\t
'\n\t\t\t\t+ '\t\t'\n\t\t\t\t+ '\t\t'\n\t\t\t\t+ '\t
'\n\t\t\t\t+ '\t
'\n\t\t\t\t+ '\t
'\n\t\t\t\t+ '\t
'\n\t\t\t\t+ '\t\t
'\n\t\t\t\t+ '\t
'\n\t\t\t\t+ '\t
'\n\t\t\t\t+ '\t
'\n\t\t\t\t+ '
';\n\n\t\t\t$this.dropzone({\n\t\t\t\turl: '/file/upload',\n\t\t\t\tmethod: 'post',\n\t\t\t\tmaxFilesize: 5 * 1024 * 1024, // GB\n\t\t\t\tuploadMultiple: false,\n\t\t\t\tmaxFiles: 10,\n acceptedFiles: 'video/*, image/*, .zip, .rar',\n\t\t\t\tinit: function() {\n\t\t\t\t\t$this.find('.upload-info')\n\t\t\t\t\t\t.text('max ' + this.options.maxFiles + ' files up to ' + Math.round(this.options.maxFilesize / 1024 / 1024) + 'GB each')\n\t\t\t\t},\n\t\t\t\tpreviewsContainer: $this.find('.files-container').length ? $this.find('.files-container')[0] : $this.find('.upload-list ')[0],\n\t\t\t\tclickable: $this.find('.browse-button')[0],\n\t\t\t\tpreviewTemplate: filePreviewTemplate,\n\t\t\t\taddRemoveLinks: false\n\t\t\t});\n\n\t\t\t/* Dropzone events */\n\n\t\t\tvar dz = Dropzone.forElement($this[0]);\n\n\t\t\tdz\n\t\t\t\t.on('addedfile', function(file) {\n\t\t\t\t\t$(window).trigger('resize'); // To fit fullpage.js cell\n\n\t\t\t\t\t/* Add remove button */\n\t\t\t\t\tvar _this = this;\n\t\t\t\t\tvar $removeButton = $(''\n\t\t\t\t\t\t+ '');\n\t\t\t\t\t$removeButton.on('click', function (e) {\n\t\t\t\t\t\te.preventDefault();\n\t\t\t\t\t\te.stopPropagation();\n\t\t\t\t\t\tif (confirm('Are you sure want to remove file?')) {\n\t\t\t\t\t\t\tdz.removeFile(file);\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t\t\n\t\t\t\t\t$(file.previewElement).find('.dz-action').append($removeButton);\n\t\t\t\t\t\n\t\t\t\t\tif ( $(dz.previewsContainer).css('position') != 'relative')\n\t\t\t\t\t\t$(dz.previewsContainer).addClass('upload-list-scroll');\n\t\t\t\t})\n\n\t\t\t\t\n\n\t\t\t\t.on('success', function(file, response) {\n\t\t\t\t\tif (response.csrf_token) {\n\t\t\t\t\t\tjQuery('html head meta[name=csrf_token]')\n\t\t\t\t\t\t\t.prop('content', response.csrf_token)\n\t\t\t\t\t}\n\n\t\t\t\t\tif (response.success === true) {\n\t\t\t\t\t\t$.each(response.data, function (key, value) {\n\t\t\t\t\t\t\t$(file.previewElement).data('file_id',value.id);\n\t\t\t\t\t\t\tfile.file_id = value.id;\n $this.find('.upload-area')\n\t\t\t\t\t\t\t\t.append($(''));\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t})\n\n\t\t\t\t.on('removedfile', function(file) {\n\t\t\t\t\tvar file_id = $(file.previewElement).data('file_id');\n\t\t\t\t\tapi.fileDelete(file_id, function(err, data) {\n\t\t\t\t\t\tif (err) { return; }\n\t\t\t\t\t\t$('#uploaded_file_' + file_id).remove();\n\t\t\t\t\t});\n\t\t\t\t})\n\n\t\t\t\t.on(\"sending\", function (file, xhr, formData) {\n\t\t\t\t\tformData.append(\"order_id\", $this.find('.order-info-panel').data('order-id'));\n\t\t\t\t});\n\t\t\t\t\n\t\t\treturn dz;\n\t\t}\n\n\t});\n\n\n\t\n\n $(function(){\n\n $('.user-price-slider').lengthPickerUserPrice();\n\n //mobile button\n\n $( \".mobile-button\" ).on( \"click\", function() {\n \t\t\t$(this).toggleClass( \"active\" );\n \t\t\t$('.intro-top-menu-list').toggleClass( \"show-menu\" );\n \t\t});\n\n \t\t$( \".info-button\" ).on( \"click\", function() {\n \t\t\t$(this).toggleClass( \"info-button-clicked\" );\n \t\t})\n\n // guarantees read more buttons\n\n \t\t$('.guarantees-item').on(\"click\", '.read-more', function() {\n \t\t\t$(this).parents('.guarantees-item:first').find('.hidden').slideToggle(\"slow\", \"easeOutCubic\");\n \t\t\t$(this).toggleClass( \"exp\" );\n\t\t});\t\t\n\n\n \t\t// how it works more button+flip\n\n \t\t$('.how-it-works-section').on(\"click\", '.read-more', function() {\n \t\t\tif ($(\".flipper\").hasClass('flip')) {\n \t\t\t\t$(\".flipper\").removeClass('flip');\n \t\t\t\t$(\".how-it-works-section .read-more\").removeClass('exp');\n \t\t\t\t$(\".flipper\").height($(\".front\").outerHeight());\n \t\t\t}\n \t\t\telse {\n\t \t\t\t$(\".flipper\").addClass('flip');\n\t \t\t\t$(\".how-it-works-section .read-more\").addClass('exp');\n\t \t\t\t$('.flip').height($('.back').outerHeight());\n \t\t\t}\n\t\t});\n\n\t\t$('.flipper').height($('.front').outerHeight());\n\n\t\t// contact us navigation\n\n\t\t$('.about .intro-text-sub a[href*=#]').click(function (e) {\n e.preventDefault();\n $('html, body').animate({\n scrollTop: $('.contact-us-section').offset().top\n });\n });\n\n // let's start navigation\n\n\t\t$('.intro-call-to-action a[href*=#]').click(function (e) {\n e.preventDefault();\n $('html, body').animate({\n scrollTop: $('.quick-contact-section > a').offset().top\n\n });\n });\n\n\t\t// contact us form reset button\n\n $('.contact-us-reset').click(function() {\n \t\t\t$('.contact-us-content form input, textarea').val('');\n\t\t});\n\n if($('.remodal[data-remodal-id=\"show_message\"]').length)\n {\n $.remodal.lookup[ $('.remodal[data-remodal-id=\"show_message\"]').data('remodal') ].open();\n }\n\t });\n\n\n $(function(){\n\n $(document).on('opened', '.remodal', function () {\n $(this).addClass('remodal-active');\n });\n\n $(document).on('closed', '.remodal', function (e) {\n $(this).removeClass('remodal-active');\n });\n\n });\n\n\n\n //****************************************//\n // //\n // Vimeo videos & SLick Slider //\n // //\n //****************************************//\n\n $(function(){\n\n\t// Change this to your username to load in your clips\n\tvar vimeoUserName = 'user39248415';\n\t\n\t// Tell Vimeo what function to call\n\tvar callback = 'showThumbs';\n\t\n\t// Set up the URLs\n\tvar url = 'https://vimeo.com/api/v2/' + vimeoUserName + '/videos.json?callback=' + callback;\n\t\n\t// This function loads the data from Vimeo\n\tfunction init() {\n\t\tvar js = document.createElement('script');\n\t\tjs.setAttribute('type', 'text/javascript');\n\t\tjs.setAttribute('src', url);\n\t\tdocument.getElementsByTagName('head').item(0).appendChild(js);\n\t}\n\t\n\t// This function goes through the clips and puts them on the page\n\n\tfunction showThumbs(videos) {\n\t\tvar vimeo = document.getElementById('vimeo');\n if (!vimeo)\n {\n return false;\n }\n\t\tvimeo.innerHTML = '';\n\t\t\n\t\tfor (var i = 0; i < videos.length; i++) {\n\n\t\t\tvar videoTitle = document.createElement('h2');\n\t\t\t\tvideoTitle.innerHTML = videos[i].title;\n\n\t\t\tvar videoLength = document.createElement('h3');\n\t\t\t\tvideoLength.setAttribute('class', 'length');\n\t\t\t\tvideoLength.innerHTML = '$' + ( videos[i].duration * 0.325 ).toFixed(0);\n\n\t\t\tvar videoSrcLength = document.createElement('h3');\n\t\t\t\tvideoSrcLength.setAttribute('class', 'src-gb');\n\t\t\t\tvideoSrcLength.innerHTML = 'made from' + (( videos[i].duration * 10 ) / 60 * 300 ).toFixed(0) + 'MB';\n\n\t\t\tvar info = document.createElement('div');\n\t\t\t\tinfo.setAttribute('class', 'info');\n\t\t\t\tinfo.appendChild(videoTitle);\n\t\t\t\tinfo.appendChild(videoLength);\n\t\t\t\tinfo.appendChild(videoSrcLength);\n\n\t\t\tvar thumb = document.createElement('img');\n\t\t\t\tthumb.setAttribute('src', videos[i].thumbnail_large);\n\t\t\t\tthumb.setAttribute('alt', videos[i].tags);\n\t\t\t\tthumb.setAttribute('title', videos[i].title);\n\t\t\t\n\t\t\tvar a = document.createElement('a');\n\t\t\t\ta.setAttribute('href', 'https://player.vimeo.com/video/'+videos[i].id+'?title='+videos[i].title+'&byline=0&portrait=0');\n\t a.setAttribute('data-id', videos[i].id);\n\t a.setAttribute('data-title', videos[i].title);\n\t a.setAttribute('title', videos[i].description.replace(/
/gi, \"\\x0A\"));\n\t\t\t\ta.setAttribute('class', 'fancybox-media');\n\t\t\t\ta.appendChild(info);\n\t\t\t\n\t\t\tvar div = document.createElement('div');\n\t\t\t\tdiv.setAttribute('class', 'slide');\n\t\t\t\tdiv.appendChild(a);\n\t\t\t\tdiv.appendChild(thumb);\n\t\t\t\tvimeo.appendChild(div);\n\t\t}\n\n\t\t// Video slider \n\t\t$('.demos-slider').slick({\n\t\t\tslidesToShow: 6,\n\t\t\tmobileFirst:true,\n\t\t\tslidesToScroll: 1,\n\t\t\tautoplay: true,\n\t\t\tautoplaySpeed: 2000,\n\t\t\tarrows:false,\n\t\t\tswipeToSlide:true,\n\t\t\tvariableWidth:true,\n\t\t\tspeed:200,\n\t\t\tlazyLoad:true,\n\t\t\tprevArrow:false,\n\t\t\tnextArrow:false,\n\t\t\ttouchThreshold: 9\n\t\t});\n\n $('.slide.slick-slide a').click(function(){\n $('.slide.slick-slide a[data-active=1]').attr('data-active', 0);\n $(this).attr('data-active', 1);\n });\n\n //** Testi slider **//\n\n\t $('.testimonials-list').slick({\n\t\t\tslidesToShow: 3,\n\t\t\tmobileFirst:true,\n\t\t\tslidesToScroll: 1,\n\t\t\tautoplay: true,\n\t\t\tautoplaySpeed: 2000,\n\t\t\tarrows:false,\n\t\t\tswipeToSlide:true,\n\t\t\tvariableWidth:true,\n\t\t\tspeed:200,\n\t\t\tlazyLoad:true,\n\t\t\tprevArrow:false,\n\t\t\tnextArrow:false,\n\t\t\ttouchThreshold: 9\n\t\t});\n\n $(\".fancybox-media\").fancybox({\n padding: 0,\n width: 750,\n height: 500,\n autoScale: true,\n autoDimensions: false,\n type: 'iframe',\n fitToView : false,\n afterShow: function(){\n window.location.hash = 'video_' + $('.slide.slick-slide a[data-active=1]').attr('data-id');\n $('.fancybox-skin').before('
' + $('.slide.slick-slide a[data-active=1]').attr('data-title') + '
');\n $('.fancybox-skin').after('
' + $(\".video-control-container\").html() + '
');\n var currentVideo = $('.slide.slick-slide a[data-active=1]').attr('data-id');\n $('.video-change.next').on('click', function(){\n $('.slide.slick-slide:not(.slick-cloned) a[data-id=\"' + currentVideo + '\"]').parent().next().find('a').click();\n });\n $('.video-change.prev').on('click', function(){\n $('.slide.slick-slide:not(.slick-cloned) a[data-id=\"' + currentVideo + '\"]').parent().prev().find('a').click();\n });\n $('.vimeo-control-panel .zig-button').on('click', function(){\n $('.fancybox-close').click();\n });\n $('.slide.slick-slide a[data-active=1]').attr('data-active', 0);\n },\n afterClose: function() {\n window.location.hash = '';\n $('.vimeo-control-panel').remove();\n $('.video-change').off('click');\n $('.vimeo-control-panel .zig-button').off('click');\n }\n });\n\n if (window.location.hash.indexOf('video_') >=0)\n {\n var hash = window.location.hash.replace('#video_','');\n if ( $('.slide.slick-slide a[data-id='+hash+']').length )\n {\n $('.slide.slick-slide a[data-id='+hash+']').first().click();\n }\n }\n\t}\n\t\n\t// Call our init function when the page loads\n\twindow.onload = init;\n\n\twindow.showThumbs = showThumbs;\n\n\t});\n\n\t$(document).ready(function($) {\n\n\t// Counter\n\n\tvar today = new Date();\n\tvar dd = today.getDate();\n\tvar mm = today.getMonth()+1;\n\tvar yyyy = today.getFullYear().toString(); \n\n\tif(dd<10) {\n\t dd='0'+dd\n\t} \n\n\tif(mm<10) {\n\t mm='0'+mm\n\t} \n\n\ttoday = yyyy+mm+dd;\n\n\tvar todayRandom = Math.floor((Math.random() * 3) + 1);\n\tvar projectsInProgress = 9 + todayRandom;\n\tvar projectsCompleted = (today - 20160101) + 170 + todayRandom;\n\tvar filesProcessed = projectsCompleted * ( 19 + todayRandom );\n\n\n\n\t$('.count.projects-completed span.counter').text(projectsCompleted);\n\t$('.count.projects-in-work span.counter').text(projectsInProgress);\n\t$('.count.gb span.counter').text(filesProcessed);\n\n\t$('.counter').counterUp({\n\t delay: 30,\n\t time: 2000\n\t});\n\n\n\t\n\t// Home menu active elem\n\n\tsetActiveMenu();\n\n\tfunction setActiveMenu() {\n\t\tvar path = window.location.pathname;\n\t\t\tpath = path.replace(/\\/$/, '');\n\t\t\tpath = decodeURIComponent(path);\n\n\n\t\t$('.intro-top-menu a').each(function() {\n\t\t\tvar href = $(this).attr('href');\n\n\t if ( path.substring(0,href.length) === href ) {\n\t $(this).addClass('active');\n\t }\n\t });\n\t}\n\t\n});\n\n}(jQuery));","'use strict';\n\n\nfunction translation(langs)\n{\n $('.translation').each(function(){\n if ($(this).hasClass('translation-placeholder'))\n {\n if (langs[$(this).attr('placeholder')])\n {\n $(this).attr('placeholder', langs[$(this).attr('placeholder')]);\n }\n }\n else if ($(this).text())\n {\n if (langs[$(this).text()])\n {\n $(this).text(langs[$(this).text()]);\n }\n }\n else\n {\n if (langs[$(this).val()])\n {\n $(this).val(langs[$(this).val()]);\n }\n\n }\n $(this).removeClass('translation');\n });\n}\n\n(function ($) {\n\n $(function(){\n\n // Steps form\n\n var contactStep = $('ul.step-contacts');\n var uploadStep = $('ul.step-upload');\n var priceStep = $('ul.step-price');\n\n var contactStepNumb = $('.step-count-item.first');\n var uploadStepNumb = $('.step-count-item.second');\n var priceStepNumb = $('.step-count-item.last');\n\n var nextButton = $('.nav > .next');\n var prevButton = $('.nav > .prev');\n var submitButton = $('button.order-submit');\n\n var infoBlock = $('.step-form > .info');\n\n var currentFormStep = 'first';\n\n function firstStep() {\n\n contactStep.show();\n uploadStep.hide();\n priceStep.hide();\n\n nextButton.css('display', 'inline-block');\n prevButton.hide();\n prevButton.removeClass('last-step');\n submitButton.hide();\n infoBlock.show();\n\n contactStepNumb.addClass('active');\n uploadStepNumb.removeClass('active');\n priceStepNumb.removeClass('active');\n\n\n currentFormStep = 'first';\n }\n\n function secondStep() {\n\n contactStep.hide();\n uploadStep.show();\n priceStep.hide();\n\n nextButton.css('display', 'inline-block');\n prevButton.removeClass('last-step');\n\n if ($('body').attr('data-logged-in') === '1') {\n contactStepNumb.hide();\n uploadStepNumb.text('1');\n priceStepNumb.text('2');\n prevButton.hide();\n }\n\n else {\n prevButton.css('display', 'inline-block');\n }\n\n submitButton.hide();\n infoBlock.hide();\n\n contactStepNumb.removeClass('active');\n uploadStepNumb.addClass('active');\n priceStepNumb.removeClass('active');\n\n currentFormStep = 'second';\n }\n\n function lastStep() {\n\n contactStepNumb.removeClass('active');\n uploadStepNumb.removeClass('active');\n priceStepNumb.addClass('active');\n\n contactStep.hide();\n uploadStep.hide();\n priceStep.show();\n\n infoBlock.hide();\n\n nextButton.hide();\n prevButton.css('display', 'inline-block');\n prevButton.addClass('last-step');\n submitButton.css('display', 'inline-block');\n\n currentFormStep = 'last';\n }\n \n\n $(nextButton).on( 'click', function() { \n if ( currentFormStep == 'first' ) {\n secondStep(); \n }\n else { \n lastStep();\n }\n });\n\n $(prevButton).on( 'click', function() {\n if ( currentFormStep == 'last' ) {\n secondStep(); \n }\n else { \n firstStep();\n }\n });\n\n // $(contactStepNumb).on('click', function() {\n // firstStep();\n // })\n\n // $(uploadStepNumb).on('click', function() {\n // secondStep();\n // })\n\n // $(priceStepNumb).on('click', function() {\n // lastStep();\n // })\n\n\n if ($('body').attr('data-logged-in') === '1') {\n var currentFormStep = 'second';\n secondStep();\n }\n else {\n firstStep();\n }\n \n api.checkLogin(); \n\n // EVENTS \n\n\n $(window).on('loggedIn', function (e, mail) {\n $('.signin-button').hide();\n $('.orders-button').show();\n $('.signout-button').show();\n $('.orderform-mail input')\n .val(mail)\n .prop('disabled', true);\n });\n\n $(window).on('loggedOut', function () {\n $('.signin-button').show();\n $('.orders-button').hide();\n $('.signout-button').hide();\n $('.orderform-mail input')\n .val('')\n .prop('disabled', false);\n });\n\n $('.orderform, .orderform-ziggy').on('submit', function (e) {\n e.preventDefault();\n if (!$(this).valid()) {\n firstStep();\n return;\n }\n orderSubmit.call(this);\n });\n\n\n $('[data-remodal-id*=\"edit-order-ziggy\"]')\n .one('open', handleEditOrderOpen)\n .on('close', function () {\n $('.orderform', $(this)).each(function () {\n this.reset();\n });\n });\n\n $('[data-remodal-id=\"restore-ziggy\"] .request-restore-button')\n .on('click', function (e) {\n e.preventDefault();\n $('.request-restore-button').loading('start');\n api.authRestore($('[data-remodal-id=\"restore-ziggy\"]'), function (err, data) {\n if (err) {\n return $('.request-restore-button').loading('error');\n }\n });\n api.createTempOrder($('.orderform-ziggy'), function (e) {\n $('.request-restore-button').loading('finish');\n dialogs.restoreDialogZiggy.close();\n $.remodal.lookup[ $('.remodal[data-remodal-id=\"restore-pass-form\"]').data('remodal') ].open();\n });\n });\n\n\n $('.welcome-confirm-button-ziggy').on('click', function (e) {\n e.preventDefault();\n var $mailField = $('[data-remodal-id=\"welcome-ziggy\"] .email-field');\n if ($mailField.data('submittedMail')\n && $mailField.val() !== $mailField.data('submittedMail')) {\n $('.welcome-confirm-button-ziggy').loading('start');\n api.authUpdate($mailField.val(), function (err) {\n if (err) {\n return $('.welcome-confirm-button-ziggy').loading('error');\n }\n $('.welcome-confirm-button-ziggy').loading('finish');\n window.location.href = $('input[type=\"hidden\"][name=\"language\"]').val() + '/orders';\n });\n }\n else {\n window.location.href = $('input[type=\"hidden\"][name=\"language\"]').val() + '/orders';\n }\n });\n\n $('.social-links a').on('click',function(){\n socialPopup($(this).attr('data-url'), $(this).attr('data-type'));\n });\n\n /* For some reason being called every time you hit 'esc' */\n // $('[data-remodal-id=\"welcome\"]').on('close', function() {\n // \twindow.location.href = '/orders';\n // });\n\n $('[data-remodal-id=\"login-ziggy\"]').on('submit', function (e) {\n e.preventDefault();\n if (!$(this).valid()) {\n return;\n }\n $('.signin-button').loading('start');\n api.authLogin($('[data-remodal-id=\"login-ziggy\"]'), function (err, logged) {\n if (err) {\n $('.signin-button').loading('error');\n if (~err.indexOf('email: Invalid email or password')) {\n $('[data-remodal-id=\"login-ziggy\"]').validate().showErrors({\n email: '',\n password: 'Wrong email or password'\n });\n }\n return;\n }\n if (logged.email)\n {\n $('#email').val(logged.email);\n $('#email').attr('disabled','disabled');\n }\n $('#tel').val(logged.phone);\n $('.signin-button').loading('finish');\n $('#login-pass').val('');\n $(window).trigger('loggedIn', logged.email);\n dialogs.loginDialogZiggy.close();\n if ($('.orderform').data('awaitingForLogin')) {\n $('.orderform').trigger('submit');\n }\n if ($('.orderform-ziggy').data('awaitingForLogin')) {\n $('.orderform-ziggy').trigger('submit');\n }\n });\n });\n\n $('[data-remodal-id=\"login-ziggy\"] .sign-up').on('click', function(){\n $('.remodal-active .remodal-close').click();\n window.location.hash = 'lets-start';\n });\n\n $('[data-remodal-id=\"login-ziggy\"]').on('close', function (e) {\n $('.order-submit', $('.orderform-ziggy')).loading('finish');\n });\n\n $('.signout-button').on('click', function (e) {\n e.preventDefault();\n $('.signout-button').loading('start');\n api.authLogout(true, function (err) {\n if (err) {\n return $('.signout-button').loading('error');\n }\n $(window).trigger('loggedOut');\n window.location.reload();\n });\n });\n\n setTimeout(function(){\n if ($('[data-remodal-id=\"exit-form\"]').attr('data-skip'))\n {\n var dontLeaveModal = false;\n }\n else\n {\n var dontLeaveModal = true;\n }\n var tempYpos = false;\n if (dontLeaveModal)\n {\n $(window).mousemove(function(e){\n if(e.clientY < 5 && tempYpos && dontLeaveModal && !$('.remodal-active').length)\n {\n if (e.clientY < tempYpos)\n {\n $.remodal.lookup[ $('.remodal[data-remodal-id=\"exit-form\"]').data('remodal') ].open();\n dontLeaveModal = false;\n document.cookie=\"leaving_page_interview=1; expires=\" + new Date(new Date().getTime() + 86400 * 30 * 1000);\n }\n }\n tempYpos = e.clientY;\n });\n }\n }, 10000);\n });\n\n\n /* Floating footer */\n $(window).on('resize', $.debounce(300, floatingFooter));\n\n $(floatingFooter);\n function floatingFooter() {\n var $footer = $('.footer-content');\n if (!$footer.length) {\n return;\n }\n var footerBottom = $footer.offset().top + $footer.outerHeight();\n var winHeight = $(window).innerHeight();\n\n if (!$footer.data('marker')) {\n $footer.data('marker', $('
').insertBefore($footer));\n }\n\n var contentEnd = $footer.data('marker').offset().top;\n\n if ($footer.data('floating')) {\n if (contentEnd + $footer.outerHeight() > winHeight) {\n $footer.css({\n position: '',\n bottom: ''\n }).data('floating', false);\n }\n } else {\n if (footerBottom < winHeight) {\n $footer.css({\n position: 'fixed',\n bottom: '0'\n }).data('floating', true);\n }\n }\n }\n\n // Adding files already stored on server\n Dropzone.prototype.addFromServer = function (file) {\n var dz = this;\n file.type = 'video';\n file.status = Dropzone.ADDED;\n file.upload = {\n progress: 0,\n total: file.size,\n bytesSent: 0\n };\n dz.files.push(file);\n dz.emit('addedfile', file);\n // this._enqueueThumbnail(file);\n return dz.accept(file, function (error) {\n if (error) {\n file.accepted = false;\n dz._errorProcessing([file], error);\n }\n file.accepted = true;\n $(file.previewElement)\n .data('file_id', file.file_id)\n .addClass('dz-success')\n .find('.dz-upload').css({width: '100%'});\n return dz._updateMaxFilesReachedClass();\n });\n };\n\n\n function handleEditOrderOpen() {\n var $this = $(this);\n var $thisDialog = $.remodal.lookup[$this.data('remodal')];\n var $thisForm = $(this).find('.orderform');\n api.getOrderInfo($this.data('orderId'), function (err, order) {\n if (err) {\n $thisDialog.close()\n return $thisForm.loading('error');\n }\n $thisForm.loading('finish');\n var orderData = order;\n if (!orderData) {\n return console.error('No order info');\n }\n\n /* Populate form with json data */\n\n $('[name=\"description\"]', $thisForm).text(orderData.description);\n $('.duration', $thisForm)\n .val(orderData.minutes)\n .trigger('slide', orderData.minutes);\n\n var dropzone = Dropzone.forElement($thisForm[0]);\n $.each(orderData.files, function (i, file) {\n\n var fileExists = false;\n\n dropzone.files.forEach(function (v, k) {\n if (file.file_id == v.file_id) {\n fileExists = true;\n }\n });\n\n if (fileExists) {\n return;\n }\n\n dropzone.addFromServer(file);\n\n });\n });\n }\n\n function socialPopup(url, type){\n\n var popup = window.open(url, type, 'width=800,height=600');\n var intervalPopup = window.setInterval(function() {\n try {\n if (popup == null || popup.closed) {\n window.clearInterval(intervalPopup);\n api.checkLogin();\n }\n }\n catch (e) {\n }\n }, 1000);\n return popup;\n\n }\n\n function orderSubmit() {\n var $form = $(this);\n\n $('.order-submit', $form).loading('start');\n\n if ($form.parent('.edit-dialog').length) {\n\n /* Editing existing order */\n\n api.orderUpdate($form, function (err) {\n if (err) {\n return $('.order-submit', $form).loading('error');\n }\n $('.order-submit', $form).loading('finish');\n $.remodal.lookup[$form.parent('.edit-dialog').data('remodal')].close();\n window.location.reload();\n });\n\n } else if ($('body').data('loggedIn')) {\n\n /* User is authorized */\n\n console.info('Is authorized user');\n api.orderCreate($form, function (err) {\n if (err) {\n return $('.order-submit', $form).loading('error');\n }\n $('.order-submit', $form).loading('finish');\n window.location.href = $('input[type=\"hidden\"][name=\"language\"]').val() + '/orders';\n });\n\n } else {\n\n api.checkIsEmailExists($('#email', $form).val(), function (err, checked) {\n if (err) {\n return $('.order-submit', $form).loading('error');\n }\n if (checked.exist) {\n\n $('#login-email-ziggy').val($('#email').val());\n dialogs.loginDialogZiggy.open();\n $form\n .data('awaitingForLogin', true)\n .one('change', function () {\n $form.data('awaitingForLogin', false);\n $('.order-submit', $form).loading('finish');\n });\n\n } else {\n\n /* New user */\n\n api.authCreate($('#email', $form).val(), function (err, created) {\n if (err) {\n return $('.order-submit', $form).loading('error');\n }\n var email = created.email;\n $('[data-remodal-id=\"welcome-ziggy\"] .email-field')\n .data('submittedMail', email)\n .val(email);\n api.orderCreate($form, function (err) {\n if (err) {\n return $('.order-submit', $form).loading('error');\n }\n $('.order-submit', $form).loading('finish');\n dialogs.welcomeDialogZiggy.open();\n });\n });\n }\n });\n\n }\n }\n\n\n /* Validator config */\n\n $.validator.addMethod(\"noFilesQueued\", function (value, element) {\n var dz = Dropzone.forElement($(element).closest('.dropzone')[0]);\n return (!dz.getUploadingFiles().length && !dz.getQueuedFiles().length);\n }, \"Wait till all files are loaded\");\n\n $.validator.addMethod(\"noErrorOccured\", function (value, element) {\n var dz = Dropzone.forElement($(element).closest('.dropzone')[0]);\n return (!dz.getRejectedFiles().length || dz.getAcceptedFiles().length);\n }, 'An error occurred.');\n\n $.validator.addMethod(\"filesUploaded\", function (value, element) {\n var dz = Dropzone.forElement($(element).closest('.dropzone')[0]);\n return (dz.getAcceptedFiles().length);\n }, 'Please, upload videos from your events to turn them into beautiful movie');\n\n $.validator.addMethod(\"emailWithDomainExtensionForNataliaLedenova\", function (value, element) {\n return /\\.[A-z]+$/i.test(value);\n }, $.validator.messages.email);\n\n\n /* Welcome dialog */\n\n $(function () {\n var _welcomeForm = $('[data-remodal-id=\"welcome-ziggy\"]');\n\n $('.edit-button-ziggy', _welcomeForm).on('click', function (e) {\n e.preventDefault();\n $('.edit-button-ziggy', _welcomeForm).addClass('hidden');\n $('.email-field', _welcomeForm).prop('disabled', false).focus();\n return;\n });\n });\n\n\n /* Init */\n\n $(function () {\n\n if ($('body').data('loggedIn')) {\n $(window).trigger('loggedIn', $('body').data('userMail'));\n } else {\n $(window).trigger('loggedOut');\n }\n\n $('.orderform, .orderform-ziggy').initOrderform();\n\n });\n\n\n /*\n *\n * ************ API ************\n *\n * api.method(data[, callback])\n * data - object / jQuery object\n * OR primitive, if only one value can be sent\n * callback - function([err[, data]])\n * err - null | array of errors\n * data - server response\n *\n * *****************************\n */\n\n window.api = (function () {\n\n /* Add token to request object */\n var _addToken = function (object, method) {\n if (method === 'post') {\n var _token = $('html head meta[name=\"csrf_token\"]').prop('content');\n if (object instanceof Array) {\n object.push({\n name: 'csrf_token',\n value: _token\n });\n console.info('Token %s added in request', _token);\n } else {\n object.csrf_token = _token;\n console.info('Token %s added in request', object.csrf_token);\n }\n } else {\n console.info('No add token on get method');\n }\n\n return object;\n };\n\n /* Log response */\n var _log = function (text, response) {\n var rect = 'background:#333; color:#ccc;' +\n 'font-size:11px; display:inline-block;' +\n '-moz-padding-start:5px; -moz-padding-end:5px;' +\n 'margin-right:3px; border-radius:2px;';\n console.log(\n '%c%s%c%s%c%O',\n rect + 'color:#cf6;',\n ' ' + text + ' ',\n rect + 'font-size:10px;',\n ' New token: ' + response.responseJSON.csrf_token + ' ',\n 'background:initial; color:initial;',\n response.responseJSON\n );\n }\n\n /* Log response errors */\n var _logErrors = function (errors) {\n var rect = 'background:#900; color:#eee;' +\n 'font-size:11px; display:inline-block;' +\n '-moz-padding-start:5px; -moz-padding-end:5px;' +\n 'margin-right:3px; border-radius:2px;';\n errors.forEach(function (error) {\n console.warn('%c%s', rect, ' ' + error + ' ');\n });\n }\n\n /*\n * Eah, sometimes there is empty 'errors', although 'success' !== true,\n * sometimes 'errors' is array, sometimes object / string...\n */\n var _pushError = function (errorsArray, response) {\n var error = response.responseJSON.errors\n if (!error || (error instanceof Array && !error.length)) {\n errorsArray.push('Api error (without description)');\n } else if (typeof error === 'string') {\n errorsArray.push(error);\n } else if (error instanceof Array) {\n $.merge(errorsArray, error);\n } else if (error instanceof Object) {\n for (var e in error) {\n if (error.hasOwnProperty(e)) {\n errorsArray.push(e + ': ' + error[e]);\n }\n }\n }\n }\n\n /* Make request */\n var _apiRequest = function (url, method, data, preCallback, callback) {\n if (data instanceof $) {\n data = data.serializeArray();\n }\n $.ajax({\n url: url,\n dataType: 'json',\n method: method,\n data: _addToken(data, method),\n complete: function (response) {\n\n var errors = [];\n if (response.status === 401) {\n errors.push('Relogin needed');\n dialogs.loginDialogZiggy.open();\n }\n if (!response.responseJSON) {\n response.responseJSON = {success: false, data: null}\n errors.push('Bad api response');\n } else {\n if (method === 'post') {\n if (!response.responseJSON.csrf_token) {\n errors.push('Didn\\'t get csrf_token');\n } else {\n $('html head meta[name=\"csrf_token\"]')\n .prop('content', response.responseJSON.csrf_token);\n }\n }\n\n if (!response.responseJSON.success) {\n _pushError(errors, response);\n }\n }\n\n if (!errors.length) {\n errors = null\n } else {\n if (errors) {\n _logErrors(errors);\n }\n }\n\n if (typeof preCallback === 'function') {\n preCallback(errors, response);\n }\n if (typeof callback === 'function') {\n callback(errors, response.responseJSON.data);\n }\n\n }\n });\n }\n\n\n return {\n checkLogin: function (){\n _apiRequest('/auth/checklogin','post', true, function (err, response) {\n if (response.responseJSON.data.status == 1)\n { \n if (response.responseJSON.data.email)\n {\n $('#email').val(response.responseJSON.data.email);\n $('#email').attr('disabled','disabled');\n\n }\n $('#tel').val(response.responseJSON.data.phone);\n $('.intro-top-menu-item .signin-button').hide();\n $('.intro-top-menu-item .orders-button').show();\n $('.intro-top-menu-item .signout-button').show();\n $('.signin-button').loading('finish');\n $('#login-pass').val('');\n $('.social-links').hide();\n if ($('.remodal-active').attr('data-remodal-id') == 'login-ziggy')\n {\n dialogs.loginDialogZiggy.close();\n }\n $('body')\n .data('loggedIn', true)\n .data('userMail', response.responseJSON.email);\n _log('Logged in', response);\n }\n }, function(){});\n },\n /* Login */\n authLogin: function (data, callback) {\n _apiRequest('/auth/login', 'post', data, function (err, response) {\n if (err) {\n return;\n }\n $('body')\n .data('loggedIn', true)\n .data('userMail', response.responseJSON.email);\n _log('Logged in', response);\n },\n callback);\n },\n\n /* Change mail */\n authUpdate: function (email, callback) {\n _apiRequest('/auth/update', 'post', {\n email: email\n }, function (err, response) {\n if (err) {\n return;\n }\n _log('Changed mail', response);\n },\n callback);\n },\n\n /* Restore email */\n authRestore: function (form, callback) {\n _apiRequest('/auth/forgot', 'post', form, function (err, response) {\n if (err) {\n return;\n }\n _log('Requested mail restore', response);\n },\n callback);\n },\n\n /* Check if email exists */\n checkIsEmailExists: function (email, callback) {\n _apiRequest('/auth/check-is-email-exists', 'post', {\n email: email\n }, function (err, response) {\n if (err) {\n return;\n }\n _log('Checked if user exists', response);\n },\n callback);\n },\n /* Check if email exists */\n createTempOrder: function (orderData, callback) {\n _apiRequest('/order/create-temp', 'post',\n orderData,\n function (err, response) {\n if (err) {\n return;\n }\n _log('Temp order created', response);\n },\n callback);\n },\n /* Create user */\n authCreate: function (email, callback) {\n _apiRequest('/auth/create', 'post', {\n email: email\n }, function (err, response) {\n if (err) {\n return;\n }\n $('body').data('loggedIn', true);\n _log('User created', response);\n },\n callback);\n },\n\n /* Create order */\n orderCreate: function (orderData, callback) {\n _apiRequest('/order/create', 'post',\n orderData,\n function (err, response) {\n if (err) {\n return;\n }\n _log('Order created', response);\n },\n callback);\n },\n\n /* Edit order */\n orderUpdate: function (orderData, callback) {\n _apiRequest('/order/update', 'post',\n orderData,\n function (err, response) {\n if (err) {\n return;\n }\n _log('Order updated', response);\n },\n callback);\n },\n\n /* Cancel order */\n orderCancel: function (orderId, callback) {\n _apiRequest('/order/cancel', 'post',\n {order_id: orderId},\n function (err, response) {\n if (err) {\n return;\n }\n _log('Order updated', response);\n },\n callback);\n },\n\n /* Logout */\n authLogout: function (areYouShure, callback) {\n _apiRequest('/auth/logout', 'post', {\n logout: areYouShure\n }, function (err, response) {\n if (err) {\n return;\n }\n $('body')\n .data('loggedIn', false)\n .data('userMail', '');\n _log('Logged out', response);\n },\n callback);\n },\n\n /* Get order data by ID */\n getOrdersList: function (nothing, callback) {\n _apiRequest('/orders/get/', 'get', {}, function (err, response) {\n if (err) {\n return;\n }\n _log('Got orders list', response);\n },\n callback);\n },\n\n /* Get chat messages by order ID */\n getChatMessages: function (orderId, callback) {\n _apiRequest('/messages/get/' + orderId, 'get', {}, function (err, response) {\n if (err) {\n return;\n }\n _log('Got chat messsages', response);\n },\n callback);\n },\n\n /* Mark chat message as read */\n markChatMessageAsRead: function (messagesIds, callback) {\n _apiRequest('/message/mark-as-read/', 'post',\n {\n messages: messagesIds\n },\n function (err, response) {\n if (err) {\n return;\n }\n _log('Marked chat message as read', response);\n },\n callback);\n },\n\n /* Get order data by ID */\n getOrderInfo: function (orderId, callback) {\n _apiRequest('/order/get/' + orderId, 'get', {}, function (err, response) {\n if (err) {\n return;\n }\n _log('Got order info', response);\n },\n callback);\n },\n\n /* Delete Uploaded file by ID */\n fileDelete: function (fileId, callback) {\n _apiRequest('/file/delete', 'post', {\n file_id: fileId\n }, function (err, response) {\n if (err) {\n return;\n }\n _log('Deleted file', response);\n },\n callback);\n },\n\n };\n }());\n\n\n /* Handlebars date helper */\n\n Handlebars.registerHelper('formatDate', function (datetime, format, message) {\n if (datetime === false) {\n message = typeof message === 'string' ? message : '-';\n return message;\n }\n\n if (moment) {\n return moment(datetime).format({\n short: 'MMM D',\n long: 'MMMM DD, YYYY \\\\at HH:mm'\n }[format]);\n }\n else {\n return datetime;\n }\n });\n\n\n /* Handlebars currency helper */\n\n Handlebars.registerHelper('formatCurrency', function (sum, zeroFormat) {\n sum = parseFloat(sum);\n if (sum === 0) {\n switch (zeroFormat) {\n case 'free':\n return 'Free';\n default:\n return sum.toFixed(2);\n }\n }\n else if (!isNaN(sum)) {\n return '$' + sum.toFixed(2);\n }\n else {\n return '--';\n }\n });\n\n\n /* Handlebars plurarize helper */\n\n Handlebars.registerHelper('pluralize', function (number, single, plural) {\n return number === 1 ? single : plural;\n });\n\n\n /* Handlebars length (minutes) helper */\n\n Handlebars.registerHelper('lengthMin', function (mins) {\n var secs = 60 * parseFloat(mins);\n var length = '';\n\n if (secs >= 60) {\n length += Math.floor(secs / 60) + ' min';\n if (secs % 60) {\n length += ', '\n }\n }\n if (secs % 60) {\n length += secs % 60 + ' sec';\n }\n if (length.length) {\n return length;\n }\n else {\n return '--';\n }\n });\n\n Handlebars.registerHelper('ifEqual', function (a, b, opts) {\n if (a === b) {\n return opts.fn(this);\n }\n else {\n return opts.inverse(this);\n }\n });\n\n Handlebars.registerHelper('eachSorted', function (array, key, opts) {\n key = key.trim();\n var reverse = key[0] === '-';\n if (reverse) {\n key = key.substr(1)\n }\n var e, output, _i, _len;\n array = array.sort(function (a, b) {\n a = a[key];\n b = b[key];\n if (a > b === reverse) {\n return 1;\n }\n if (a === b) {\n return 0;\n }\n if (a < b === reverse) {\n return -1;\n }\n });\n output = '';\n for (_i = 0, _len = array.length; _i < _len; _i++) {\n e = array[_i];\n output += opts.fn(e);\n }\n return output;\n });\n\n\n /*\n * jQuery throttle / debounce - v1.1 - 3/7/2010\n * http://benalman.com/projects/jquery-throttle-debounce-plugin/\n */\n (function (b, c) {\n var $ = b.jQuery || b.Cowboy || (b.Cowboy = {}), a;\n $.throttle = a = function (e, f, j, i) {\n var h, d = 0;\n if (typeof f !== \"boolean\") {\n i = j;\n j = f;\n f = c\n }\n function g() {\n var o = this, m = +new Date() - d, n = arguments;\n\n function l() {\n d = +new Date();\n j.apply(o, n)\n }\n\n function k() {\n h = c\n }\n\n if (i && !h) {\n l()\n }\n h && clearTimeout(h);\n if (i === c && m > e) {\n l()\n } else {\n if (f !== true) {\n h = setTimeout(i ? k : l, i === c ? e - m : e)\n }\n }\n }\n\n if ($.guid) {\n g.guid = j.guid = j.guid || $.guid++\n }\n return g\n };\n $.debounce = function (d, e, f) {\n return f === c ? a(d, e, false) : a(d, f, e !== false)\n }\n })(this);\n\n\n\n}(jQuery));\n","/*\n _ _ _ _\n ___| (_) ___| | __ (_)___\n/ __| | |/ __| |/ / | / __|\n\\__ \\ | | (__| < _ | \\__ \\\n|___/_|_|\\___|_|\\_(_)/ |___/\n |__/\n\n Version: 1.5.0\n Author: Ken Wheeler\n Website: http://kenwheeler.github.io\n Docs: http://kenwheeler.github.io/slick\n Repo: http://github.com/kenwheeler/slick\n Issues: http://github.com/kenwheeler/slick/issues\n\n */\n/* global window, document, define, jQuery, setInterval, clearInterval */\n\n!function(a){\"use strict\";\"function\"==typeof define&&define.amd?define([\"jquery\"],a):\"undefined\"!=typeof exports?module.exports=a(require(\"jquery\")):a(jQuery)}(function(a){\"use strict\";var b=window.Slick||{};b=function(){function c(c,d){var f,g,h,e=this;if(e.defaults={accessibility:!0,adaptiveHeight:!1,appendArrows:a(c),appendDots:a(c),arrows:!0,asNavFor:null,prevArrow:'',nextArrow:'',autoplay:!1,autoplaySpeed:3e3,centerMode:!1,centerPadding:\"50px\",cssEase:\"ease\",customPaging:function(a,b){return'\"},dots:!1,dotsClass:\"slick-dots\",draggable:!0,easing:\"linear\",edgeFriction:.35,fade:!1,focusOnSelect:!1,infinite:!0,initialSlide:0,lazyLoad:\"ondemand\",mobileFirst:!1,pauseOnHover:!0,pauseOnDotsHover:!1,respondTo:\"window\",responsive:null,rows:1,rtl:!1,slide:\"\",slidesPerRow:1,slidesToShow:1,slidesToScroll:1,speed:500,swipe:!0,swipeToSlide:!1,touchMove:!0,touchThreshold:5,useCSS:!0,variableWidth:!1,vertical:!1,verticalSwiping:!1,waitForAnimate:!0},e.initials={animating:!1,dragging:!1,autoPlayTimer:null,currentDirection:0,currentLeft:null,currentSlide:0,direction:1,$dots:null,listWidth:null,listHeight:null,loadIndex:0,$nextArrow:null,$prevArrow:null,slideCount:null,slideWidth:null,$slideTrack:null,$slides:null,sliding:!1,slideOffset:0,swipeLeft:null,$list:null,touchObject:{},transformsEnabled:!1},a.extend(e,e.initials),e.activeBreakpoint=null,e.animType=null,e.animProp=null,e.breakpoints=[],e.breakpointSettings=[],e.cssTransitions=!1,e.hidden=\"hidden\",e.paused=!1,e.positionProp=null,e.respondTo=null,e.rowCount=1,e.shouldClick=!0,e.$slider=a(c),e.$slidesCache=null,e.transformType=null,e.transitionType=null,e.visibilityChange=\"visibilitychange\",e.windowWidth=0,e.windowTimer=null,f=a(c).data(\"slick\")||{},e.options=a.extend({},e.defaults,f,d),e.currentSlide=e.options.initialSlide,e.originalSettings=e.options,g=e.options.responsive||null,g&&g.length>-1){e.respondTo=e.options.respondTo||\"window\";for(h in g)g.hasOwnProperty(h)&&(e.breakpoints.push(g[h].breakpoint),e.breakpointSettings[g[h].breakpoint]=g[h].settings);e.breakpoints.sort(function(a,b){return e.options.mobileFirst===!0?a-b:b-a})}\"undefined\"!=typeof document.mozHidden?(e.hidden=\"mozHidden\",e.visibilityChange=\"mozvisibilitychange\"):\"undefined\"!=typeof document.msHidden?(e.hidden=\"msHidden\",e.visibilityChange=\"msvisibilitychange\"):\"undefined\"!=typeof document.webkitHidden&&(e.hidden=\"webkitHidden\",e.visibilityChange=\"webkitvisibilitychange\"),e.autoPlay=a.proxy(e.autoPlay,e),e.autoPlayClear=a.proxy(e.autoPlayClear,e),e.changeSlide=a.proxy(e.changeSlide,e),e.clickHandler=a.proxy(e.clickHandler,e),e.selectHandler=a.proxy(e.selectHandler,e),e.setPosition=a.proxy(e.setPosition,e),e.swipeHandler=a.proxy(e.swipeHandler,e),e.dragHandler=a.proxy(e.dragHandler,e),e.keyHandler=a.proxy(e.keyHandler,e),e.autoPlayIterator=a.proxy(e.autoPlayIterator,e),e.instanceUid=b++,e.htmlExpr=/^(?:\\s*(<[\\w\\W]+>)[^>]*)$/,e.init(),e.checkResponsive(!0)}var b=0;return c}(),b.prototype.addSlide=b.prototype.slickAdd=function(b,c,d){var e=this;if(\"boolean\"==typeof c)d=c,c=null;else if(0>c||c>=e.slideCount)return!1;e.unload(),\"number\"==typeof c?0===c&&0===e.$slides.length?a(b).appendTo(e.$slideTrack):d?a(b).insertBefore(e.$slides.eq(c)):a(b).insertAfter(e.$slides.eq(c)):d===!0?a(b).prependTo(e.$slideTrack):a(b).appendTo(e.$slideTrack),e.$slides=e.$slideTrack.children(this.options.slide),e.$slideTrack.children(this.options.slide).detach(),e.$slideTrack.append(e.$slides),e.$slides.each(function(b,c){a(c).attr(\"data-slick-index\",b)}),e.$slidesCache=e.$slides,e.reinit()},b.prototype.animateHeight=function(){var a=this;if(1===a.options.slidesToShow&&a.options.adaptiveHeight===!0&&a.options.vertical===!1){var b=a.$slides.eq(a.currentSlide).outerHeight(!0);a.$list.animate({height:b},a.options.speed)}},b.prototype.animateSlide=function(b,c){var d={},e=this;e.animateHeight(),e.options.rtl===!0&&e.options.vertical===!1&&(b=-b),e.transformsEnabled===!1?e.options.vertical===!1?e.$slideTrack.animate({left:b},e.options.speed,e.options.easing,c):e.$slideTrack.animate({top:b},e.options.speed,e.options.easing,c):e.cssTransitions===!1?(e.options.rtl===!0&&(e.currentLeft=-e.currentLeft),a({animStart:e.currentLeft}).animate({animStart:b},{duration:e.options.speed,easing:e.options.easing,step:function(a){a=Math.ceil(a),e.options.vertical===!1?(d[e.animType]=\"translate(\"+a+\"px, 0px)\",e.$slideTrack.css(d)):(d[e.animType]=\"translate(0px,\"+a+\"px)\",e.$slideTrack.css(d))},complete:function(){c&&c.call()}})):(e.applyTransition(),b=Math.ceil(b),d[e.animType]=e.options.vertical===!1?\"translate3d(\"+b+\"px, 0px, 0px)\":\"translate3d(0px,\"+b+\"px, 0px)\",e.$slideTrack.css(d),c&&setTimeout(function(){e.disableTransition(),c.call()},e.options.speed))},b.prototype.asNavFor=function(b){var c=this,d=null!==c.options.asNavFor?a(c.options.asNavFor).slick(\"getSlick\"):null;null!==d&&d.slideHandler(b,!0)},b.prototype.applyTransition=function(a){var b=this,c={};c[b.transitionType]=b.options.fade===!1?b.transformType+\" \"+b.options.speed+\"ms \"+b.options.cssEase:\"opacity \"+b.options.speed+\"ms \"+b.options.cssEase,b.options.fade===!1?b.$slideTrack.css(c):b.$slides.eq(a).css(c)},b.prototype.autoPlay=function(){var a=this;a.autoPlayTimer&&clearInterval(a.autoPlayTimer),a.slideCount>a.options.slidesToShow&&a.paused!==!0&&(a.autoPlayTimer=setInterval(a.autoPlayIterator,a.options.autoplaySpeed))},b.prototype.autoPlayClear=function(){var a=this;a.autoPlayTimer&&clearInterval(a.autoPlayTimer)},b.prototype.autoPlayIterator=function(){var a=this;a.options.infinite===!1?1===a.direction?(a.currentSlide+1===a.slideCount-1&&(a.direction=0),a.slideHandler(a.currentSlide+a.options.slidesToScroll)):(0===a.currentSlide-1&&(a.direction=1),a.slideHandler(a.currentSlide-a.options.slidesToScroll)):a.slideHandler(a.currentSlide+a.options.slidesToScroll)},b.prototype.buildArrows=function(){var b=this;b.options.arrows===!0&&b.slideCount>b.options.slidesToShow&&(b.$prevArrow=a(b.options.prevArrow),b.$nextArrow=a(b.options.nextArrow),b.htmlExpr.test(b.options.prevArrow)&&b.$prevArrow.appendTo(b.options.appendArrows),b.htmlExpr.test(b.options.nextArrow)&&b.$nextArrow.appendTo(b.options.appendArrows),b.options.infinite!==!0&&b.$prevArrow.addClass(\"slick-disabled\"))},b.prototype.buildDots=function(){var c,d,b=this;if(b.options.dots===!0&&b.slideCount>b.options.slidesToShow){for(d='\",b.$dots=a(d).appendTo(b.options.appendDots),b.$dots.find(\"li\").first().addClass(\"slick-active\").attr(\"aria-hidden\",\"false\")}},b.prototype.buildOut=function(){var b=this;b.$slides=b.$slider.children(\":not(.slick-cloned)\").addClass(\"slick-slide\"),b.slideCount=b.$slides.length,b.$slides.each(function(b,c){a(c).attr(\"data-slick-index\",b)}),b.$slidesCache=b.$slides,b.$slider.addClass(\"slick-slider\"),b.$slideTrack=0===b.slideCount?a('
').appendTo(b.$slider):b.$slides.wrapAll('
').parent(),b.$list=b.$slideTrack.wrap('
').parent(),b.$slideTrack.css(\"opacity\",0),(b.options.centerMode===!0||b.options.swipeToSlide===!0)&&(b.options.slidesToScroll=1),a(\"img[data-lazy]\",b.$slider).not(\"[src]\").addClass(\"slick-loading\"),b.setupInfinite(),b.buildArrows(),b.buildDots(),b.updateDots(),b.options.accessibility===!0&&b.$list.prop(\"tabIndex\",0),b.setSlideClasses(\"number\"==typeof this.currentSlide?this.currentSlide:0),b.options.draggable===!0&&b.$list.addClass(\"draggable\")},b.prototype.buildRows=function(){var b,c,d,e,f,g,h,a=this;if(e=document.createDocumentFragment(),g=a.$slider.children(),a.options.rows>1){for(h=a.options.slidesPerRow*a.options.rows,f=Math.ceil(g.length/h),b=0;f>b;b++){var i=document.createElement(\"div\");for(c=0;c-1&&null!==c.originalSettings.responsive){e=null;for(d in c.breakpoints)c.breakpoints.hasOwnProperty(d)&&(c.originalSettings.mobileFirst===!1?fc.breakpoints[d]&&(e=c.breakpoints[d]));null!==e?null!==c.activeBreakpoint?e!==c.activeBreakpoint&&(c.activeBreakpoint=e,\"unslick\"===c.breakpointSettings[e]?c.unslick():(c.options=a.extend({},c.originalSettings,c.breakpointSettings[e]),b===!0&&(c.currentSlide=c.options.initialSlide),c.refresh())):(c.activeBreakpoint=e,\"unslick\"===c.breakpointSettings[e]?c.unslick():(c.options=a.extend({},c.originalSettings,c.breakpointSettings[e]),b===!0&&(c.currentSlide=c.options.initialSlide),c.refresh())):null!==c.activeBreakpoint&&(c.activeBreakpoint=null,c.options=c.originalSettings,b===!0&&(c.currentSlide=c.options.initialSlide),c.refresh())}},b.prototype.changeSlide=function(b,c){var f,g,h,d=this,e=a(b.target);switch(e.is(\"a\")&&b.preventDefault(),h=0!==d.slideCount%d.options.slidesToScroll,f=h?0:(d.slideCount-d.currentSlide)%d.options.slidesToScroll,b.data.message){case\"previous\":g=0===f?d.options.slidesToScroll:d.options.slidesToShow-f,d.slideCount>d.options.slidesToShow&&d.slideHandler(d.currentSlide-g,!1,c);break;case\"next\":g=0===f?d.options.slidesToScroll:f,d.slideCount>d.options.slidesToShow&&d.slideHandler(d.currentSlide+g,!1,c);break;case\"index\":var i=0===b.data.index?0:b.data.index||a(b.target).parent().index()*d.options.slidesToScroll;d.slideHandler(d.checkNavigable(i),!1,c);break;default:return}},b.prototype.checkNavigable=function(a){var c,d,b=this;if(c=b.getNavigableIndexes(),d=0,a>c[c.length-1])a=c[c.length-1];else for(var e in c){if(ab.options.slidesToShow&&a(\"li\",b.$dots).off(\"click.slick\",b.changeSlide),b.options.dots===!0&&b.options.pauseOnDotsHover===!0&&b.options.autoplay===!0&&a(\"li\",b.$dots).off(\"mouseenter.slick\",b.setPaused.bind(b,!0)).off(\"mouseleave.slick\",b.setPaused.bind(b,!1)),b.options.arrows===!0&&b.slideCount>b.options.slidesToShow&&(b.$prevArrow&&b.$prevArrow.off(\"click.slick\",b.changeSlide),b.$nextArrow&&b.$nextArrow.off(\"click.slick\",b.changeSlide)),b.$list.off(\"touchstart.slick mousedown.slick\",b.swipeHandler),b.$list.off(\"touchmove.slick mousemove.slick\",b.swipeHandler),b.$list.off(\"touchend.slick mouseup.slick\",b.swipeHandler),b.$list.off(\"touchcancel.slick mouseleave.slick\",b.swipeHandler),b.$list.off(\"click.slick\",b.clickHandler),b.options.autoplay===!0&&a(document).off(b.visibilityChange,b.visibility),b.$list.off(\"mouseenter.slick\",b.setPaused.bind(b,!0)),b.$list.off(\"mouseleave.slick\",b.setPaused.bind(b,!1)),b.options.accessibility===!0&&b.$list.off(\"keydown.slick\",b.keyHandler),b.options.focusOnSelect===!0&&a(b.$slideTrack).children().off(\"click.slick\",b.selectHandler),a(window).off(\"orientationchange.slick.slick-\"+b.instanceUid,b.orientationChange),a(window).off(\"resize.slick.slick-\"+b.instanceUid,b.resize),a(\"[draggable!=true]\",b.$slideTrack).off(\"dragstart\",b.preventDefault),a(window).off(\"load.slick.slick-\"+b.instanceUid,b.setPosition),a(document).off(\"ready.slick.slick-\"+b.instanceUid,b.setPosition)},b.prototype.cleanUpRows=function(){var b,a=this;a.options.rows>1&&(b=a.$slides.children().children(),b.removeAttr(\"style\"),a.$slider.html(b))},b.prototype.clickHandler=function(a){var b=this;b.shouldClick===!1&&(a.stopImmediatePropagation(),a.stopPropagation(),a.preventDefault())},b.prototype.destroy=function(){var b=this;b.autoPlayClear(),b.touchObject={},b.cleanUpEvents(),a(\".slick-cloned\",b.$slider).remove(),b.$dots&&b.$dots.remove(),b.$prevArrow&&\"object\"!=typeof b.options.prevArrow&&b.$prevArrow.remove(),b.$nextArrow&&\"object\"!=typeof b.options.nextArrow&&b.$nextArrow.remove(),b.$slides&&(b.$slides.removeClass(\"slick-slide slick-active slick-center slick-visible\").attr(\"aria-hidden\",\"true\").removeAttr(\"data-slick-index\").css({position:\"\",left:\"\",top:\"\",zIndex:\"\",opacity:\"\",width:\"\"}),b.$slider.html(b.$slides)),b.cleanUpRows(),b.$slider.removeClass(\"slick-slider\"),b.$slider.removeClass(\"slick-initialized\")},b.prototype.disableTransition=function(a){var b=this,c={};c[b.transitionType]=\"\",b.options.fade===!1?b.$slideTrack.css(c):b.$slides.eq(a).css(c)},b.prototype.fadeSlide=function(a,b){var c=this;c.cssTransitions===!1?(c.$slides.eq(a).css({zIndex:1e3}),c.$slides.eq(a).animate({opacity:1},c.options.speed,c.options.easing,b)):(c.applyTransition(a),c.$slides.eq(a).css({opacity:1,zIndex:1e3}),b&&setTimeout(function(){c.disableTransition(a),b.call()},c.options.speed))},b.prototype.filterSlides=b.prototype.slickFilter=function(a){var b=this;null!==a&&(b.unload(),b.$slideTrack.children(this.options.slide).detach(),b.$slidesCache.filter(a).appendTo(b.$slideTrack),b.reinit())},b.prototype.getCurrent=b.prototype.slickCurrentSlide=function(){var a=this;return a.currentSlide},b.prototype.getDotCount=function(){var a=this,b=0,c=0,d=0;if(a.options.infinite===!0)d=Math.ceil(a.slideCount/a.options.slidesToScroll);else if(a.options.centerMode===!0)d=a.slideCount;else for(;bb.options.slidesToShow&&(b.slideOffset=-1*b.slideWidth*b.options.slidesToShow,e=-1*d*b.options.slidesToShow),0!==b.slideCount%b.options.slidesToScroll&&a+b.options.slidesToScroll>b.slideCount&&b.slideCount>b.options.slidesToShow&&(a>b.slideCount?(b.slideOffset=-1*(b.options.slidesToShow-(a-b.slideCount))*b.slideWidth,e=-1*(b.options.slidesToShow-(a-b.slideCount))*d):(b.slideOffset=-1*b.slideCount%b.options.slidesToScroll*b.slideWidth,e=-1*b.slideCount%b.options.slidesToScroll*d))):a+b.options.slidesToShow>b.slideCount&&(b.slideOffset=(a+b.options.slidesToShow-b.slideCount)*b.slideWidth,e=(a+b.options.slidesToShow-b.slideCount)*d),b.slideCount<=b.options.slidesToShow&&(b.slideOffset=0,e=0),b.options.centerMode===!0&&b.options.infinite===!0?b.slideOffset+=b.slideWidth*Math.floor(b.options.slidesToShow/2)-b.slideWidth:b.options.centerMode===!0&&(b.slideOffset=0,b.slideOffset+=b.slideWidth*Math.floor(b.options.slidesToShow/2)),c=b.options.vertical===!1?-1*a*b.slideWidth+b.slideOffset:-1*a*d+e,b.options.variableWidth===!0&&(f=b.slideCount<=b.options.slidesToShow||b.options.infinite===!1?b.$slideTrack.children(\".slick-slide\").eq(a):b.$slideTrack.children(\".slick-slide\").eq(a+b.options.slidesToShow),c=f[0]?-1*f[0].offsetLeft:0,b.options.centerMode===!0&&(f=b.options.infinite===!1?b.$slideTrack.children(\".slick-slide\").eq(a):b.$slideTrack.children(\".slick-slide\").eq(a+b.options.slidesToShow+1),c=f[0]?-1*f[0].offsetLeft:0,c+=(b.$list.width()-f.outerWidth())/2)),c},b.prototype.getOption=b.prototype.slickGetOption=function(a){var b=this;return b.options[a]},b.prototype.getNavigableIndexes=function(){var e,a=this,b=0,c=0,d=[];for(a.options.infinite===!1?(e=a.slideCount-a.options.slidesToShow+1,a.options.centerMode===!0&&(e=a.slideCount)):(b=-1*a.options.slidesToScroll,c=-1*a.options.slidesToScroll,e=2*a.slideCount);e>b;)d.push(b),b=c+a.options.slidesToScroll,c+=a.options.slidesToScroll<=a.options.slidesToShow?a.options.slidesToScroll:a.options.slidesToShow;return d},b.prototype.getSlick=function(){return this},b.prototype.getSlideCount=function(){var c,d,e,b=this;return e=b.options.centerMode===!0?b.slideWidth*Math.floor(b.options.slidesToShow/2):0,b.options.swipeToSlide===!0?(b.$slideTrack.find(\".slick-slide\").each(function(c,f){return f.offsetLeft-e+a(f).outerWidth()/2>-1*b.swipeLeft?(d=f,!1):void 0}),c=Math.abs(a(d).attr(\"data-slick-index\")-b.currentSlide)||1):b.options.slidesToScroll},b.prototype.goTo=b.prototype.slickGoTo=function(a,b){var c=this;c.changeSlide({data:{message:\"index\",index:parseInt(a)}},b)},b.prototype.init=function(){var b=this;a(b.$slider).hasClass(\"slick-initialized\")||(a(b.$slider).addClass(\"slick-initialized\"),b.buildRows(),b.buildOut(),b.setProps(),b.startLoad(),b.loadSlider(),b.initializeEvents(),b.updateArrows(),b.updateDots()),b.$slider.trigger(\"init\",[b])},b.prototype.initArrowEvents=function(){var a=this;a.options.arrows===!0&&a.slideCount>a.options.slidesToShow&&(a.$prevArrow.on(\"click.slick\",{message:\"previous\"},a.changeSlide),a.$nextArrow.on(\"click.slick\",{message:\"next\"},a.changeSlide))},b.prototype.initDotEvents=function(){var b=this;b.options.dots===!0&&b.slideCount>b.options.slidesToShow&&a(\"li\",b.$dots).on(\"click.slick\",{message:\"index\"},b.changeSlide),b.options.dots===!0&&b.options.pauseOnDotsHover===!0&&b.options.autoplay===!0&&a(\"li\",b.$dots).on(\"mouseenter.slick\",b.setPaused.bind(b,!0)).on(\"mouseleave.slick\",b.setPaused.bind(b,!1))},b.prototype.initializeEvents=function(){var b=this;b.initArrowEvents(),b.initDotEvents(),b.$list.on(\"touchstart.slick mousedown.slick\",{action:\"start\"},b.swipeHandler),b.$list.on(\"touchmove.slick mousemove.slick\",{action:\"move\"},b.swipeHandler),b.$list.on(\"touchend.slick mouseup.slick\",{action:\"end\"},b.swipeHandler),b.$list.on(\"touchcancel.slick mouseleave.slick\",{action:\"end\"},b.swipeHandler),b.$list.on(\"click.slick\",b.clickHandler),b.options.autoplay===!0&&a(document).on(b.visibilityChange,b.visibility.bind(b)),b.$list.on(\"mouseenter.slick\",b.setPaused.bind(b,!0)),b.$list.on(\"mouseleave.slick\",b.setPaused.bind(b,!1)),b.options.accessibility===!0&&b.$list.on(\"keydown.slick\",b.keyHandler),b.options.focusOnSelect===!0&&a(b.$slideTrack).children().on(\"click.slick\",b.selectHandler),a(window).on(\"orientationchange.slick.slick-\"+b.instanceUid,b.orientationChange.bind(b)),a(window).on(\"resize.slick.slick-\"+b.instanceUid,b.resize.bind(b)),a(\"[draggable!=true]\",b.$slideTrack).on(\"dragstart\",b.preventDefault),a(window).on(\"load.slick.slick-\"+b.instanceUid,b.setPosition),a(document).on(\"ready.slick.slick-\"+b.instanceUid,b.setPosition)},b.prototype.initUI=function(){var a=this;a.options.arrows===!0&&a.slideCount>a.options.slidesToShow&&(a.$prevArrow.show(),a.$nextArrow.show()),a.options.dots===!0&&a.slideCount>a.options.slidesToShow&&a.$dots.show(),a.options.autoplay===!0&&a.autoPlay()},b.prototype.keyHandler=function(a){var b=this;37===a.keyCode&&b.options.accessibility===!0?b.changeSlide({data:{message:\"previous\"}}):39===a.keyCode&&b.options.accessibility===!0&&b.changeSlide({data:{message:\"next\"}})},b.prototype.lazyLoad=function(){function g(b){a(\"img[data-lazy]\",b).each(function(){var b=a(this),c=a(this).attr(\"data-lazy\"),d=document.createElement(\"img\");d.onload=function(){b.animate({opacity:1},200)},d.src=c,b.css({opacity:0}).attr(\"src\",c).removeAttr(\"data-lazy\").removeClass(\"slick-loading\")})}var c,d,e,f,b=this;b.options.centerMode===!0?b.options.infinite===!0?(e=b.currentSlide+(b.options.slidesToShow/2+1),f=e+b.options.slidesToShow+2):(e=Math.max(0,b.currentSlide-(b.options.slidesToShow/2+1)),f=2+(b.options.slidesToShow/2+1)+b.currentSlide):(e=b.options.infinite?b.options.slidesToShow+b.currentSlide:b.currentSlide,f=e+b.options.slidesToShow,b.options.fade===!0&&(e>0&&e--,f<=b.slideCount&&f++)),c=b.$slider.find(\".slick-slide\").slice(e,f),g(c),b.slideCount<=b.options.slidesToShow?(d=b.$slider.find(\".slick-slide\"),g(d)):b.currentSlide>=b.slideCount-b.options.slidesToShow?(d=b.$slider.find(\".slick-cloned\").slice(0,b.options.slidesToShow),g(d)):0===b.currentSlide&&(d=b.$slider.find(\".slick-cloned\").slice(-1*b.options.slidesToShow),g(d))},b.prototype.loadSlider=function(){var a=this;a.setPosition(),a.$slideTrack.css({opacity:1}),a.$slider.removeClass(\"slick-loading\"),a.initUI(),\"progressive\"===a.options.lazyLoad&&a.progressiveLazyLoad()},b.prototype.next=b.prototype.slickNext=function(){var a=this;a.changeSlide({data:{message:\"next\"}})},b.prototype.orientationChange=function(){var a=this;a.checkResponsive(),a.setPosition()},b.prototype.pause=b.prototype.slickPause=function(){var a=this;a.autoPlayClear(),a.paused=!0},b.prototype.play=b.prototype.slickPlay=function(){var a=this;a.paused=!1,a.autoPlay()},b.prototype.postSlide=function(a){var b=this;b.$slider.trigger(\"afterChange\",[b,a]),b.animating=!1,b.setPosition(),b.swipeLeft=null,b.options.autoplay===!0&&b.paused===!1&&b.autoPlay()},b.prototype.prev=b.prototype.slickPrev=function(){var a=this;a.changeSlide({data:{message:\"previous\"}})},b.prototype.preventDefault=function(a){a.preventDefault()},b.prototype.progressiveLazyLoad=function(){var c,d,b=this;c=a(\"img[data-lazy]\",b.$slider).length,c>0&&(d=a(\"img[data-lazy]\",b.$slider).first(),d.attr(\"src\",d.attr(\"data-lazy\")).removeClass(\"slick-loading\").load(function(){d.removeAttr(\"data-lazy\"),b.progressiveLazyLoad(),b.options.adaptiveHeight===!0&&b.setPosition()}).error(function(){d.removeAttr(\"data-lazy\"),b.progressiveLazyLoad()}))},b.prototype.refresh=function(){var b=this,c=b.currentSlide;b.destroy(),a.extend(b,b.initials),b.init(),b.changeSlide({data:{message:\"index\",index:c}},!1)},b.prototype.reinit=function(){var b=this;b.$slides=b.$slideTrack.children(b.options.slide).addClass(\"slick-slide\"),b.slideCount=b.$slides.length,b.currentSlide>=b.slideCount&&0!==b.currentSlide&&(b.currentSlide=b.currentSlide-b.options.slidesToScroll),b.slideCount<=b.options.slidesToShow&&(b.currentSlide=0),b.setProps(),b.setupInfinite(),b.buildArrows(),b.updateArrows(),b.initArrowEvents(),b.buildDots(),b.updateDots(),b.initDotEvents(),b.options.focusOnSelect===!0&&a(b.$slideTrack).children().on(\"click.slick\",b.selectHandler),b.setSlideClasses(0),b.setPosition(),b.$slider.trigger(\"reInit\",[b])},b.prototype.resize=function(){var b=this;a(window).width()!==b.windowWidth&&(clearTimeout(b.windowDelay),b.windowDelay=window.setTimeout(function(){b.windowWidth=a(window).width(),b.checkResponsive(),b.setPosition()},50))},b.prototype.removeSlide=b.prototype.slickRemove=function(a,b,c){var d=this;return\"boolean\"==typeof a?(b=a,a=b===!0?0:d.slideCount-1):a=b===!0?--a:a,d.slideCount<1||0>a||a>d.slideCount-1?!1:(d.unload(),c===!0?d.$slideTrack.children().remove():d.$slideTrack.children(this.options.slide).eq(a).remove(),d.$slides=d.$slideTrack.children(this.options.slide),d.$slideTrack.children(this.options.slide).detach(),d.$slideTrack.append(d.$slides),d.$slidesCache=d.$slides,d.reinit(),void 0)},b.prototype.setCSS=function(a){var d,e,b=this,c={};b.options.rtl===!0&&(a=-a),d=\"left\"==b.positionProp?Math.ceil(a)+\"px\":\"0px\",e=\"top\"==b.positionProp?Math.ceil(a)+\"px\":\"0px\",c[b.positionProp]=a,b.transformsEnabled===!1?b.$slideTrack.css(c):(c={},b.cssTransitions===!1?(c[b.animType]=\"translate(\"+d+\", \"+e+\")\",b.$slideTrack.css(c)):(c[b.animType]=\"translate3d(\"+d+\", \"+e+\", 0px)\",b.$slideTrack.css(c)))},b.prototype.setDimensions=function(){var a=this;a.options.vertical===!1?a.options.centerMode===!0&&a.$list.css({padding:\"0px \"+a.options.centerPadding}):(a.$list.height(a.$slides.first().outerHeight(!0)*a.options.slidesToShow),a.options.centerMode===!0&&a.$list.css({padding:a.options.centerPadding+\" 0px\"})),a.listWidth=a.$list.width(),a.listHeight=a.$list.height(),a.options.vertical===!1&&a.options.variableWidth===!1?(a.slideWidth=Math.ceil(a.listWidth/a.options.slidesToShow),a.$slideTrack.width(Math.ceil(a.slideWidth*a.$slideTrack.children(\".slick-slide\").length))):a.options.variableWidth===!0?a.$slideTrack.width(5e3*a.slideCount):(a.slideWidth=Math.ceil(a.listWidth),a.$slideTrack.height(Math.ceil(a.$slides.first().outerHeight(!0)*a.$slideTrack.children(\".slick-slide\").length)));var b=a.$slides.first().outerWidth(!0)-a.$slides.first().width();a.options.variableWidth===!1&&a.$slideTrack.children(\".slick-slide\").width(a.slideWidth-b)},b.prototype.setFade=function(){var c,b=this;b.$slides.each(function(d,e){c=-1*b.slideWidth*d,b.options.rtl===!0?a(e).css({position:\"relative\",right:c,top:0,zIndex:800,opacity:0}):a(e).css({position:\"relative\",left:c,top:0,zIndex:800,opacity:0})}),b.$slides.eq(b.currentSlide).css({zIndex:900,opacity:1})},b.prototype.setHeight=function(){var a=this;if(1===a.options.slidesToShow&&a.options.adaptiveHeight===!0&&a.options.vertical===!1){var b=a.$slides.eq(a.currentSlide).outerHeight(!0);a.$list.css(\"height\",b)}},b.prototype.setOption=b.prototype.slickSetOption=function(a,b,c){var d=this;d.options[a]=b,c===!0&&(d.unload(),d.reinit())},b.prototype.setPosition=function(){var a=this;a.setDimensions(),a.setHeight(),a.options.fade===!1?a.setCSS(a.getLeft(a.currentSlide)):a.setFade(),a.$slider.trigger(\"setPosition\",[a])},b.prototype.setProps=function(){var a=this,b=document.body.style;a.positionProp=a.options.vertical===!0?\"top\":\"left\",\"top\"===a.positionProp?a.$slider.addClass(\"slick-vertical\"):a.$slider.removeClass(\"slick-vertical\"),(void 0!==b.WebkitTransition||void 0!==b.MozTransition||void 0!==b.msTransition)&&a.options.useCSS===!0&&(a.cssTransitions=!0),void 0!==b.OTransform&&(a.animType=\"OTransform\",a.transformType=\"-o-transform\",a.transitionType=\"OTransition\",void 0===b.perspectiveProperty&&void 0===b.webkitPerspective&&(a.animType=!1)),void 0!==b.MozTransform&&(a.animType=\"MozTransform\",a.transformType=\"-moz-transform\",a.transitionType=\"MozTransition\",void 0===b.perspectiveProperty&&void 0===b.MozPerspective&&(a.animType=!1)),void 0!==b.webkitTransform&&(a.animType=\"webkitTransform\",a.transformType=\"-webkit-transform\",a.transitionType=\"webkitTransition\",void 0===b.perspectiveProperty&&void 0===b.webkitPerspective&&(a.animType=!1)),void 0!==b.msTransform&&(a.animType=\"msTransform\",a.transformType=\"-ms-transform\",a.transitionType=\"msTransition\",void 0===b.msTransform&&(a.animType=!1)),void 0!==b.transform&&a.animType!==!1&&(a.animType=\"transform\",a.transformType=\"transform\",a.transitionType=\"transition\"),a.transformsEnabled=null!==a.animType&&a.animType!==!1},b.prototype.setSlideClasses=function(a){var c,d,e,f,b=this;b.$slider.find(\".slick-slide\").removeClass(\"slick-active\").attr(\"aria-hidden\",\"true\").removeClass(\"slick-center\"),d=b.$slider.find(\".slick-slide\"),b.options.centerMode===!0?(c=Math.floor(b.options.slidesToShow/2),b.options.infinite===!0&&(a>=c&&a<=b.slideCount-1-c?b.$slides.slice(a-c,a+c+1).addClass(\"slick-active\").attr(\"aria-hidden\",\"false\"):(e=b.options.slidesToShow+a,d.slice(e-c+1,e+c+2).addClass(\"slick-active\").attr(\"aria-hidden\",\"false\")),0===a?d.eq(d.length-1-b.options.slidesToShow).addClass(\"slick-center\"):a===b.slideCount-1&&d.eq(b.options.slidesToShow).addClass(\"slick-center\")),b.$slides.eq(a).addClass(\"slick-center\")):a>=0&&a<=b.slideCount-b.options.slidesToShow?b.$slides.slice(a,a+b.options.slidesToShow).addClass(\"slick-active\").attr(\"aria-hidden\",\"false\"):d.length<=b.options.slidesToShow?d.addClass(\"slick-active\").attr(\"aria-hidden\",\"false\"):(f=b.slideCount%b.options.slidesToShow,e=b.options.infinite===!0?b.options.slidesToShow+a:a,b.options.slidesToShow==b.options.slidesToScroll&&b.slideCount-ab.options.slidesToShow)){for(e=b.options.centerMode===!0?b.options.slidesToShow+1:b.options.slidesToShow,c=b.slideCount;c>b.slideCount-e;c-=1)d=c-1,a(b.$slides[d]).clone(!0).attr(\"id\",\"\").attr(\"data-slick-index\",d-b.slideCount).prependTo(b.$slideTrack).addClass(\"slick-cloned\");for(c=0;e>c;c+=1)d=c,a(b.$slides[d]).clone(!0).attr(\"id\",\"\").attr(\"data-slick-index\",d+b.slideCount).appendTo(b.$slideTrack).addClass(\"slick-cloned\");b.$slideTrack.find(\".slick-cloned\").find(\"[id]\").each(function(){a(this).attr(\"id\",\"\")})}},b.prototype.setPaused=function(a){var b=this;b.options.autoplay===!0&&b.options.pauseOnHover===!0&&(b.paused=a,b.autoPlayClear())},b.prototype.selectHandler=function(b){var c=this,d=a(b.target).is(\".slick-slide\")?a(b.target):a(b.target).parents(\".slick-slide\"),e=parseInt(d.attr(\"data-slick-index\"));return e||(e=0),c.slideCount<=c.options.slidesToShow?(c.$slider.find(\".slick-slide\").removeClass(\"slick-active\").attr(\"aria-hidden\",\"true\"),c.$slides.eq(e).addClass(\"slick-active\").attr(\"aria-hidden\",\"false\"),c.options.centerMode===!0&&(c.$slider.find(\".slick-slide\").removeClass(\"slick-center\"),c.$slides.eq(e).addClass(\"slick-center\")),c.asNavFor(e),void 0):(c.slideHandler(e),void 0)},b.prototype.slideHandler=function(a,b,c){var d,e,f,g,h=null,i=this;return b=b||!1,i.animating===!0&&i.options.waitForAnimate===!0||i.options.fade===!0&&i.currentSlide===a||i.slideCount<=i.options.slidesToShow?void 0:(b===!1&&i.asNavFor(a),d=a,h=i.getLeft(d),g=i.getLeft(i.currentSlide),i.currentLeft=null===i.swipeLeft?g:i.swipeLeft,i.options.infinite===!1&&i.options.centerMode===!1&&(0>a||a>i.getDotCount()*i.options.slidesToScroll)?(i.options.fade===!1&&(d=i.currentSlide,c!==!0?i.animateSlide(g,function(){i.postSlide(d)}):i.postSlide(d)),void 0):i.options.infinite===!1&&i.options.centerMode===!0&&(0>a||a>i.slideCount-i.options.slidesToScroll)?(i.options.fade===!1&&(d=i.currentSlide,c!==!0?i.animateSlide(g,function(){i.postSlide(d)}):i.postSlide(d)),void 0):(i.options.autoplay===!0&&clearInterval(i.autoPlayTimer),e=0>d?0!==i.slideCount%i.options.slidesToScroll?i.slideCount-i.slideCount%i.options.slidesToScroll:i.slideCount+d:d>=i.slideCount?0!==i.slideCount%i.options.slidesToScroll?0:d-i.slideCount:d,i.animating=!0,i.$slider.trigger(\"beforeChange\",[i,i.currentSlide,e]),f=i.currentSlide,i.currentSlide=e,i.setSlideClasses(i.currentSlide),i.updateDots(),i.updateArrows(),i.options.fade===!0?(c!==!0?i.fadeSlide(e,function(){i.postSlide(e)}):i.postSlide(e),i.animateHeight(),void 0):(c!==!0?i.animateSlide(h,function(){i.postSlide(e)}):i.postSlide(e),void 0)))},b.prototype.startLoad=function(){var a=this;a.options.arrows===!0&&a.slideCount>a.options.slidesToShow&&(a.$prevArrow.hide(),a.$nextArrow.hide()),a.options.dots===!0&&a.slideCount>a.options.slidesToShow&&a.$dots.hide(),a.$slider.addClass(\"slick-loading\")},b.prototype.swipeDirection=function(){var a,b,c,d,e=this;return a=e.touchObject.startX-e.touchObject.curX,b=e.touchObject.startY-e.touchObject.curY,c=Math.atan2(b,a),d=Math.round(180*c/Math.PI),0>d&&(d=360-Math.abs(d)),45>=d&&d>=0?e.options.rtl===!1?\"left\":\"right\":360>=d&&d>=315?e.options.rtl===!1?\"left\":\"right\":d>=135&&225>=d?e.options.rtl===!1?\"right\":\"left\":e.options.verticalSwiping===!0?d>=35&&135>=d?\"left\":\"right\":\"vertical\"},b.prototype.swipeEnd=function(){var c,b=this;if(b.dragging=!1,b.shouldClick=b.touchObject.swipeLength>10?!1:!0,void 0===b.touchObject.curX)return!1;if(b.touchObject.edgeHit===!0&&b.$slider.trigger(\"edge\",[b,b.swipeDirection()]),b.touchObject.swipeLength>=b.touchObject.minSwipe)switch(b.swipeDirection()){case\"left\":c=b.options.swipeToSlide?b.checkNavigable(b.currentSlide+b.getSlideCount()):b.currentSlide+b.getSlideCount(),b.slideHandler(c),b.currentDirection=0,b.touchObject={},b.$slider.trigger(\"swipe\",[b,\"left\"]);break;case\"right\":c=b.options.swipeToSlide?b.checkNavigable(b.currentSlide-b.getSlideCount()):b.currentSlide-b.getSlideCount(),b.slideHandler(c),b.currentDirection=1,b.touchObject={},b.$slider.trigger(\"swipe\",[b,\"right\"])}else b.touchObject.startX!==b.touchObject.curX&&(b.slideHandler(b.currentSlide),b.touchObject={})},b.prototype.swipeHandler=function(a){var b=this;\nif(!(b.options.swipe===!1||\"ontouchend\"in document&&b.options.swipe===!1||b.options.draggable===!1&&-1!==a.type.indexOf(\"mouse\")))switch(b.touchObject.fingerCount=a.originalEvent&&void 0!==a.originalEvent.touches?a.originalEvent.touches.length:1,b.touchObject.minSwipe=b.listWidth/b.options.touchThreshold,b.options.verticalSwiping===!0&&(b.touchObject.minSwipe=b.listHeight/b.options.touchThreshold),a.data.action){case\"start\":b.swipeStart(a);break;case\"move\":b.swipeMove(a);break;case\"end\":b.swipeEnd(a)}},b.prototype.swipeMove=function(a){var d,e,f,g,h,b=this;return h=void 0!==a.originalEvent?a.originalEvent.touches:null,!b.dragging||h&&1!==h.length?!1:(d=b.getLeft(b.currentSlide),b.touchObject.curX=void 0!==h?h[0].pageX:a.clientX,b.touchObject.curY=void 0!==h?h[0].pageY:a.clientY,b.touchObject.swipeLength=Math.round(Math.sqrt(Math.pow(b.touchObject.curX-b.touchObject.startX,2))),b.options.verticalSwiping===!0&&(b.touchObject.swipeLength=Math.round(Math.sqrt(Math.pow(b.touchObject.curY-b.touchObject.startY,2)))),e=b.swipeDirection(),\"vertical\"!==e?(void 0!==a.originalEvent&&b.touchObject.swipeLength>4&&a.preventDefault(),g=(b.options.rtl===!1?1:-1)*(b.touchObject.curX>b.touchObject.startX?1:-1),b.options.verticalSwiping===!0&&(g=b.touchObject.curY>b.touchObject.startY?1:-1),f=b.touchObject.swipeLength,b.touchObject.edgeHit=!1,b.options.infinite===!1&&(0===b.currentSlide&&\"right\"===e||b.currentSlide>=b.getDotCount()&&\"left\"===e)&&(f=b.touchObject.swipeLength*b.options.edgeFriction,b.touchObject.edgeHit=!0),b.swipeLeft=b.options.vertical===!1?d+f*g:d+f*(b.$list.height()/b.listWidth)*g,b.options.verticalSwiping===!0&&(b.swipeLeft=d+f*g),b.options.fade===!0||b.options.touchMove===!1?!1:b.animating===!0?(b.swipeLeft=null,!1):(b.setCSS(b.swipeLeft),void 0)):void 0)},b.prototype.swipeStart=function(a){var c,b=this;return 1!==b.touchObject.fingerCount||b.slideCount<=b.options.slidesToShow?(b.touchObject={},!1):(void 0!==a.originalEvent&&void 0!==a.originalEvent.touches&&(c=a.originalEvent.touches[0]),b.touchObject.startX=b.touchObject.curX=void 0!==c?c.pageX:a.clientX,b.touchObject.startY=b.touchObject.curY=void 0!==c?c.pageY:a.clientY,b.dragging=!0,void 0)},b.prototype.unfilterSlides=b.prototype.slickUnfilter=function(){var a=this;null!==a.$slidesCache&&(a.unload(),a.$slideTrack.children(this.options.slide).detach(),a.$slidesCache.appendTo(a.$slideTrack),a.reinit())},b.prototype.unload=function(){var b=this;a(\".slick-cloned\",b.$slider).remove(),b.$dots&&b.$dots.remove(),b.$prevArrow&&\"object\"!=typeof b.options.prevArrow&&b.$prevArrow.remove(),b.$nextArrow&&\"object\"!=typeof b.options.nextArrow&&b.$nextArrow.remove(),b.$slides.removeClass(\"slick-slide slick-active slick-visible\").attr(\"aria-hidden\",\"true\").css(\"width\",\"\")},b.prototype.unslick=function(){var a=this;a.destroy()},b.prototype.updateArrows=function(){var b,a=this;b=Math.floor(a.options.slidesToShow/2),a.options.arrows===!0&&a.options.infinite!==!0&&a.slideCount>a.options.slidesToShow&&(a.$prevArrow.removeClass(\"slick-disabled\"),a.$nextArrow.removeClass(\"slick-disabled\"),0===a.currentSlide?(a.$prevArrow.addClass(\"slick-disabled\"),a.$nextArrow.removeClass(\"slick-disabled\")):a.currentSlide>=a.slideCount-a.options.slidesToShow&&a.options.centerMode===!1?(a.$nextArrow.addClass(\"slick-disabled\"),a.$prevArrow.removeClass(\"slick-disabled\")):a.currentSlide>=a.slideCount-1&&a.options.centerMode===!0&&(a.$nextArrow.addClass(\"slick-disabled\"),a.$prevArrow.removeClass(\"slick-disabled\")))},b.prototype.updateDots=function(){var a=this;null!==a.$dots&&(a.$dots.find(\"li\").removeClass(\"slick-active\").attr(\"aria-hidden\",\"true\"),a.$dots.find(\"li\").eq(Math.floor(a.currentSlide/a.options.slidesToScroll)).addClass(\"slick-active\").attr(\"aria-hidden\",\"false\"))},b.prototype.visibility=function(){var a=this;document[a.hidden]?(a.paused=!0,a.autoPlayClear()):(a.paused=!1,a.autoPlay())},a.fn.slick=function(){var g,a=this,c=arguments[0],d=Array.prototype.slice.call(arguments,1),e=a.length,f=0;for(f;e>f;f++)if(\"object\"==typeof c||\"undefined\"==typeof c?a[f].slick=new b(a[f],c):g=a[f].slick[c].apply(a[f].slick,d),\"undefined\"!=typeof g)return g;return a}});","// Generated by CoffeeScript 1.6.2\n/*!\njQuery Waypoints - v2.0.5\nCopyright (c) 2011-2014 Caleb Troughton\nLicensed under the MIT license.\nhttps://github.com/imakewebthings/jquery-waypoints/blob/master/licenses.txt\n*/\n(function(){var t=[].indexOf||function(t){for(var e=0,n=this.length;e=0;s={horizontal:{},vertical:{}};f=1;c={};u=\"waypoints-context-id\";p=\"resize.waypoints\";y=\"scroll.waypoints\";v=1;w=\"waypoints-waypoint-ids\";g=\"waypoint\";m=\"waypoints\";o=function(){function t(t){var e=this;this.$element=t;this.element=t[0];this.didResize=false;this.didScroll=false;this.id=\"context\"+f++;this.oldScroll={x:t.scrollLeft(),y:t.scrollTop()};this.waypoints={horizontal:{},vertical:{}};this.element[u]=this.id;c[this.id]=this;t.bind(y,function(){var t;if(!(e.didScroll||a)){e.didScroll=true;t=function(){e.doScroll();return e.didScroll=false};return r.setTimeout(t,n[m].settings.scrollThrottle)}});t.bind(p,function(){var t;if(!e.didResize){e.didResize=true;t=function(){n[m](\"refresh\");return e.didResize=false};return r.setTimeout(t,n[m].settings.resizeThrottle)}})}t.prototype.doScroll=function(){var t,e=this;t={horizontal:{newScroll:this.$element.scrollLeft(),oldScroll:this.oldScroll.x,forward:\"right\",backward:\"left\"},vertical:{newScroll:this.$element.scrollTop(),oldScroll:this.oldScroll.y,forward:\"down\",backward:\"up\"}};if(a&&(!t.vertical.oldScroll||!t.vertical.newScroll)){n[m](\"refresh\")}n.each(t,function(t,r){var i,o,l;l=[];o=r.newScroll>r.oldScroll;i=o?r.forward:r.backward;n.each(e.waypoints[t],function(t,e){var n,i;if(r.oldScroll<(n=e.offset)&&n<=r.newScroll){return l.push(e)}else if(r.newScroll<(i=e.offset)&&i<=r.oldScroll){return l.push(e)}});l.sort(function(t,e){return t.offset-e.offset});if(!o){l.reverse()}return n.each(l,function(t,e){if(e.options.continuous||t===l.length-1){return e.trigger([i])}})});return this.oldScroll={x:t.horizontal.newScroll,y:t.vertical.newScroll}};t.prototype.refresh=function(){var t,e,r,i=this;r=n.isWindow(this.element);e=this.$element.offset();this.doScroll();t={horizontal:{contextOffset:r?0:e.left,contextScroll:r?0:this.oldScroll.x,contextDimension:this.$element.width(),oldScroll:this.oldScroll.x,forward:\"right\",backward:\"left\",offsetProp:\"left\"},vertical:{contextOffset:r?0:e.top,contextScroll:r?0:this.oldScroll.y,contextDimension:r?n[m](\"viewportHeight\"):this.$element.height(),oldScroll:this.oldScroll.y,forward:\"down\",backward:\"up\",offsetProp:\"top\"}};return n.each(t,function(t,e){return n.each(i.waypoints[t],function(t,r){var i,o,l,s,f;i=r.options.offset;l=r.offset;o=n.isWindow(r.element)?0:r.$element.offset()[e.offsetProp];if(n.isFunction(i)){i=i.apply(r.element)}else if(typeof i===\"string\"){i=parseFloat(i);if(r.options.offset.indexOf(\"%\")>-1){i=Math.ceil(e.contextDimension*i/100)}}r.offset=o-e.contextOffset+e.contextScroll-i;if(r.options.onlyOnScroll&&l!=null||!r.enabled){return}if(l!==null&&l<(s=e.oldScroll)&&s<=r.offset){return r.trigger([e.backward])}else if(l!==null&&l>(f=e.oldScroll)&&f>=r.offset){return r.trigger([e.forward])}else if(l===null&&e.oldScroll>=r.offset){return r.trigger([e.forward])}})})};t.prototype.checkEmpty=function(){if(n.isEmptyObject(this.waypoints.horizontal)&&n.isEmptyObject(this.waypoints.vertical)){this.$element.unbind([p,y].join(\" \"));return delete c[this.id]}};return t}();l=function(){function t(t,e,r){var i,o;if(r.offset===\"bottom-in-view\"){r.offset=function(){var t;t=n[m](\"viewportHeight\");if(!n.isWindow(e.element)){t=e.$element.height()}return t-n(this).outerHeight()}}this.$element=t;this.element=t[0];this.axis=r.horizontal?\"horizontal\":\"vertical\";this.callback=r.handler;this.context=e;this.enabled=r.enabled;this.id=\"waypoints\"+v++;this.offset=null;this.options=r;e.waypoints[this.axis][this.id]=this;s[this.axis][this.id]=this;i=(o=this.element[w])!=null?o:[];i.push(this.id);this.element[w]=i}t.prototype.trigger=function(t){if(!this.enabled){return}if(this.callback!=null){this.callback.apply(this.element,t)}if(this.options.triggerOnce){return this.destroy()}};t.prototype.disable=function(){return this.enabled=false};t.prototype.enable=function(){this.context.refresh();return this.enabled=true};t.prototype.destroy=function(){delete s[this.axis][this.id];delete this.context.waypoints[this.axis][this.id];return this.context.checkEmpty()};t.getWaypointsByElement=function(t){var e,r;r=t[w];if(!r){return[]}e=n.extend({},s.horizontal,s.vertical);return n.map(r,function(t){return e[t]})};return t}();d={init:function(t,e){var r;e=n.extend({},n.fn[g].defaults,e);if((r=e.handler)==null){e.handler=t}this.each(function(){var t,r,i,s;t=n(this);i=(s=e.context)!=null?s:n.fn[g].defaults.context;if(!n.isWindow(i)){i=t.closest(i)}i=n(i);r=c[i[0][u]];if(!r){r=new o(i)}return new l(t,r,e)});n[m](\"refresh\");return this},disable:function(){return d._invoke.call(this,\"disable\")},enable:function(){return d._invoke.call(this,\"enable\")},destroy:function(){return d._invoke.call(this,\"destroy\")},prev:function(t,e){return d._traverse.call(this,t,e,function(t,e,n){if(e>0){return t.push(n[e-1])}})},next:function(t,e){return d._traverse.call(this,t,e,function(t,e,n){if(et.oldScroll.y})},left:function(t){if(t==null){t=r}return h._filter(t,\"horizontal\",function(t,e){return e.offset<=t.oldScroll.x})},right:function(t){if(t==null){t=r}return h._filter(t,\"horizontal\",function(t,e){return e.offset>t.oldScroll.x})},enable:function(){return h._invoke(\"enable\")},disable:function(){return h._invoke(\"disable\")},destroy:function(){return h._invoke(\"destroy\")},extendFn:function(t,e){return d[t]=e},_invoke:function(t){var e;e=n.extend({},s.vertical,s.horizontal);return n.each(e,function(e,n){n[t]();return true})},_filter:function(t,e,r){var i,o;i=c[n(t)[0][u]];if(!i){return[]}o=[];n.each(i.waypoints[e],function(t,e){if(r(i,e)){return o.push(e)}});o.sort(function(t,e){return t.offset-e.offset});return n.map(o,function(t){return t.element})}};n[m]=function(){var t,n;n=arguments[0],t=2<=arguments.length?e.call(arguments,1):[];if(h[n]){return h[n].apply(null,t)}else{return h.aggregate.call(null,n)}};n[m].settings={resizeThrottle:100,scrollThrottle:30};return i.on(\"load.waypoints\",function(){return n[m](\"refresh\")})})}).call(this);","/*!\n* jquery.counterup.js 1.0\n*\n* Copyright 2013, Benjamin Intal http://gambit.ph @bfintal\n* Released under the GPL v2 License\n*\n* Date: Nov 26, 2013\n*/(function(e){\"use strict\";e.fn.counterUp=function(t){var n=e.extend({time:400,delay:10},t);return this.each(function(){var t=e(this),r=n,i=function(){var e=[],n=r.time/r.delay,i=t.text(),s=/[0-9]+,[0-9]+/.test(i);i=i.replace(/,/g,\"\");var o=/^[0-9]+$/.test(i),u=/^[0-9]+\\.[0-9]+$/.test(i),a=u?(i.split(\".\")[1]||[]).length:0;for(var f=n;f>=1;f--){var l=parseInt(i/n*f);u&&(l=parseFloat(i/n*f).toFixed(a));if(s)while(/(\\d+)(\\d{3})/.test(l.toString()))l=l.toString().replace(/(\\d+)(\\d{3})/,\"$1,$2\");e.unshift(l)}t.data(\"counterup-nums\",e);t.text(\"0\");var c=function(){t.text(t.data(\"counterup-nums\").shift());if(t.data(\"counterup-nums\").length)setTimeout(t.data(\"counterup-func\"),r.delay);else{delete t.data(\"counterup-nums\");t.data(\"counterup-nums\",null);t.data(\"counterup-func\",null)}};t.data(\"counterup-func\",c);setTimeout(t.data(\"counterup-func\"),r.delay)};t.waypoint(i,{offset:\"100%\",triggerOnce:!0})})}})(jQuery);","/*!\n * fancyBox - jQuery Plugin\n * version: 2.1.5 (Fri, 14 Jun 2013)\n * @requires jQuery v1.6 or later\n *\n * Examples at http://fancyapps.com/fancybox/\n * License: www.fancyapps.com/fancybox/#license\n *\n * Copyright 2012 Janis Skarnelis - janis@fancyapps.com\n *\n */\n\n(function (window, document, $, undefined) {\n\t\"use strict\";\n\n\tvar H = $(\"html\"),\n\t\tW = $(window),\n\t\tD = $(document),\n\t\tF = $.fancybox = function () {\n\t\t\tF.open.apply( this, arguments );\n\t\t},\n\t\tIE = navigator.userAgent.match(/msie/i),\n\t\tdidUpdate\t= null,\n\t\tisTouch\t\t= document.createTouch !== undefined,\n\n\t\tisQuery\t= function(obj) {\n\t\t\treturn obj && obj.hasOwnProperty && obj instanceof $;\n\t\t},\n\t\tisString = function(str) {\n\t\t\treturn str && $.type(str) === \"string\";\n\t\t},\n\t\tisPercentage = function(str) {\n\t\t\treturn isString(str) && str.indexOf('%') > 0;\n\t\t},\n\t\tisScrollable = function(el) {\n\t\t\treturn (el && !(el.style.overflow && el.style.overflow === 'hidden') && ((el.clientWidth && el.scrollWidth > el.clientWidth) || (el.clientHeight && el.scrollHeight > el.clientHeight)));\n\t\t},\n\t\tgetScalar = function(orig, dim) {\n\t\t\tvar value = parseInt(orig, 10) || 0;\n\n\t\t\tif (dim && isPercentage(orig)) {\n\t\t\t\tvalue = F.getViewport()[ dim ] / 100 * value;\n\t\t\t}\n\n\t\t\treturn Math.ceil(value);\n\t\t},\n\t\tgetValue = function(value, dim) {\n\t\t\treturn getScalar(value, dim) + 'px';\n\t\t};\n\n\t$.extend(F, {\n\t\t// The current version of fancyBox\n\t\tversion: '2.1.5',\n\n\t\tdefaults: {\n\t\t\tpadding : 15,\n\t\t\tmargin : 20,\n\n\t\t\twidth : 800,\n\t\t\theight : 600,\n\t\t\tminWidth : 100,\n\t\t\tminHeight : 100,\n\t\t\tmaxWidth : 9999,\n\t\t\tmaxHeight : 9999,\n\t\t\tpixelRatio: 1, // Set to 2 for retina display support\n\n\t\t\tautoSize : true,\n\t\t\tautoHeight : false,\n\t\t\tautoWidth : false,\n\n\t\t\tautoResize : true,\n\t\t\tautoCenter : !isTouch,\n\t\t\tfitToView : true,\n\t\t\taspectRatio : false,\n\t\t\ttopRatio : 0.5,\n\t\t\tleftRatio : 0.5,\n\n\t\t\tscrolling : 'auto', // 'auto', 'yes' or 'no'\n\t\t\twrapCSS : '',\n\n\t\t\tarrows : true,\n\t\t\tcloseBtn : true,\n\t\t\tcloseClick : false,\n\t\t\tnextClick : false,\n\t\t\tmouseWheel : true,\n\t\t\tautoPlay : false,\n\t\t\tplaySpeed : 3000,\n\t\t\tpreload : 3,\n\t\t\tmodal : false,\n\t\t\tloop : true,\n\n\t\t\tajax : {\n\t\t\t\tdataType : 'html',\n\t\t\t\theaders : { 'X-fancyBox': true }\n\t\t\t},\n\t\t\tiframe : {\n\t\t\t\tscrolling : 'auto',\n\t\t\t\tpreload : true\n\t\t\t},\n\t\t\tswf : {\n\t\t\t\twmode: 'transparent',\n\t\t\t\tallowfullscreen : 'true',\n\t\t\t\tallowscriptaccess : 'always'\n\t\t\t},\n\n\t\t\tkeys : {\n\t\t\t\tnext : {\n\t\t\t\t\t13 : 'left', // enter\n\t\t\t\t\t34 : 'up', // page down\n\t\t\t\t\t39 : 'left', // right arrow\n\t\t\t\t\t40 : 'up' // down arrow\n\t\t\t\t},\n\t\t\t\tprev : {\n\t\t\t\t\t8 : 'right', // backspace\n\t\t\t\t\t33 : 'down', // page up\n\t\t\t\t\t37 : 'right', // left arrow\n\t\t\t\t\t38 : 'down' // up arrow\n\t\t\t\t},\n\t\t\t\tclose : [27], // escape key\n\t\t\t\tplay : [32], // space - start/stop slideshow\n\t\t\t\ttoggle : [70] // letter \"f\" - toggle fullscreen\n\t\t\t},\n\n\t\t\tdirection : {\n\t\t\t\tnext : 'left',\n\t\t\t\tprev : 'right'\n\t\t\t},\n\n\t\t\tscrollOutside : true,\n\n\t\t\t// Override some properties\n\t\t\tindex : 0,\n\t\t\ttype : null,\n\t\t\thref : null,\n\t\t\tcontent : null,\n\t\t\ttitle : null,\n\n\t\t\t// HTML templates\n\t\t\ttpl: {\n\t\t\t\twrap : '
',\n\t\t\t\timage : '\"\"',\n\t\t\t\tiframe : '',\n\t\t\t\terror : '

The requested content cannot be loaded.
Please try again later.

',\n\t\t\t\tcloseBtn : '',\n\t\t\t\tnext : '',\n\t\t\t\tprev : ''\n\t\t\t},\n\n\t\t\t// Properties for each animation type\n\t\t\t// Opening fancyBox\n\t\t\topenEffect : 'fade', // 'elastic', 'fade' or 'none'\n\t\t\topenSpeed : 250,\n\t\t\topenEasing : 'swing',\n\t\t\topenOpacity : true,\n\t\t\topenMethod : 'zoomIn',\n\n\t\t\t// Closing fancyBox\n\t\t\tcloseEffect : 'fade', // 'elastic', 'fade' or 'none'\n\t\t\tcloseSpeed : 250,\n\t\t\tcloseEasing : 'swing',\n\t\t\tcloseOpacity : true,\n\t\t\tcloseMethod : 'zoomOut',\n\n\t\t\t// Changing next gallery item\n\t\t\tnextEffect : 'elastic', // 'elastic', 'fade' or 'none'\n\t\t\tnextSpeed : 250,\n\t\t\tnextEasing : 'swing',\n\t\t\tnextMethod : 'changeIn',\n\n\t\t\t// Changing previous gallery item\n\t\t\tprevEffect : 'elastic', // 'elastic', 'fade' or 'none'\n\t\t\tprevSpeed : 250,\n\t\t\tprevEasing : 'swing',\n\t\t\tprevMethod : 'changeOut',\n\n\t\t\t// Enable default helpers\n\t\t\thelpers : {\n\t\t\t\toverlay : true,\n\t\t\t\ttitle : true\n\t\t\t},\n\n\t\t\t// Callbacks\n\t\t\tonCancel : $.noop, // If canceling\n\t\t\tbeforeLoad : $.noop, // Before loading\n\t\t\tafterLoad : $.noop, // After loading\n\t\t\tbeforeShow : $.noop, // Before changing in current item\n\t\t\tafterShow : $.noop, // After opening\n\t\t\tbeforeChange : $.noop, // Before changing gallery item\n\t\t\tbeforeClose : $.noop, // Before closing\n\t\t\tafterClose : $.noop // After closing\n\t\t},\n\n\t\t//Current state\n\t\tgroup : {}, // Selected group\n\t\topts : {}, // Group options\n\t\tprevious : null, // Previous element\n\t\tcoming : null, // Element being loaded\n\t\tcurrent : null, // Currently loaded element\n\t\tisActive : false, // Is activated\n\t\tisOpen : false, // Is currently open\n\t\tisOpened : false, // Have been fully opened at least once\n\n\t\twrap : null,\n\t\tskin : null,\n\t\touter : null,\n\t\tinner : null,\n\n\t\tplayer : {\n\t\t\ttimer : null,\n\t\t\tisActive : false\n\t\t},\n\n\t\t// Loaders\n\t\tajaxLoad : null,\n\t\timgPreload : null,\n\n\t\t// Some collections\n\t\ttransitions : {},\n\t\thelpers : {},\n\n\t\t/*\n\t\t *\tStatic methods\n\t\t */\n\n\t\topen: function (group, opts) {\n\t\t\tif (!group) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif (!$.isPlainObject(opts)) {\n\t\t\t\topts = {};\n\t\t\t}\n\n\t\t\t// Close if already active\n\t\t\tif (false === F.close(true)) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t// Normalize group\n\t\t\tif (!$.isArray(group)) {\n\t\t\t\tgroup = isQuery(group) ? $(group).get() : [group];\n\t\t\t}\n\n\t\t\t// Recheck if the type of each element is `object` and set content type (image, ajax, etc)\n\t\t\t$.each(group, function(i, element) {\n\t\t\t\tvar obj = {},\n\t\t\t\t\thref,\n\t\t\t\t\ttitle,\n\t\t\t\t\tcontent,\n\t\t\t\t\ttype,\n\t\t\t\t\trez,\n\t\t\t\t\threfParts,\n\t\t\t\t\tselector;\n\n\t\t\t\tif ($.type(element) === \"object\") {\n\t\t\t\t\t// Check if is DOM element\n\t\t\t\t\tif (element.nodeType) {\n\t\t\t\t\t\telement = $(element);\n\t\t\t\t\t}\n\n\t\t\t\t\tif (isQuery(element)) {\n\t\t\t\t\t\tobj = {\n\t\t\t\t\t\t\thref : element.data('fancybox-href') || element.attr('href'),\n\t\t\t\t\t\t\ttitle : element.data('fancybox-title') || element.attr('title'),\n\t\t\t\t\t\t\tisDom : true,\n\t\t\t\t\t\t\telement : element\n\t\t\t\t\t\t};\n\n\t\t\t\t\t\tif ($.metadata) {\n\t\t\t\t\t\t\t$.extend(true, obj, element.metadata());\n\t\t\t\t\t\t}\n\n\t\t\t\t\t} else {\n\t\t\t\t\t\tobj = element;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\thref = opts.href || obj.href || (isString(element) ? element : null);\n\t\t\t\ttitle = opts.title !== undefined ? opts.title : obj.title || '';\n\n\t\t\t\tcontent = opts.content || obj.content;\n\t\t\t\ttype = content ? 'html' : (opts.type || obj.type);\n\n\t\t\t\tif (!type && obj.isDom) {\n\t\t\t\t\ttype = element.data('fancybox-type');\n\n\t\t\t\t\tif (!type) {\n\t\t\t\t\t\trez = element.prop('class').match(/fancybox\\.(\\w+)/);\n\t\t\t\t\t\ttype = rez ? rez[1] : null;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif (isString(href)) {\n\t\t\t\t\t// Try to guess the content type\n\t\t\t\t\tif (!type) {\n\t\t\t\t\t\tif (F.isImage(href)) {\n\t\t\t\t\t\t\ttype = 'image';\n\n\t\t\t\t\t\t} else if (F.isSWF(href)) {\n\t\t\t\t\t\t\ttype = 'swf';\n\n\t\t\t\t\t\t} else if (href.charAt(0) === '#') {\n\t\t\t\t\t\t\ttype = 'inline';\n\n\t\t\t\t\t\t} else if (isString(element)) {\n\t\t\t\t\t\t\ttype = 'html';\n\t\t\t\t\t\t\tcontent = element;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\t// Split url into two pieces with source url and content selector, e.g,\n\t\t\t\t\t// \"/mypage.html #my_id\" will load \"/mypage.html\" and display element having id \"my_id\"\n\t\t\t\t\tif (type === 'ajax') {\n\t\t\t\t\t\threfParts = href.split(/\\s+/, 2);\n\t\t\t\t\t\thref = hrefParts.shift();\n\t\t\t\t\t\tselector = hrefParts.shift();\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif (!content) {\n\t\t\t\t\tif (type === 'inline') {\n\t\t\t\t\t\tif (href) {\n\t\t\t\t\t\t\tcontent = $( isString(href) ? href.replace(/.*(?=#[^\\s]+$)/, '') : href ); //strip for ie7\n\n\t\t\t\t\t\t} else if (obj.isDom) {\n\t\t\t\t\t\t\tcontent = element;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t} else if (type === 'html') {\n\t\t\t\t\t\tcontent = href;\n\n\t\t\t\t\t} else if (!type && !href && obj.isDom) {\n\t\t\t\t\t\ttype = 'inline';\n\t\t\t\t\t\tcontent = element;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t$.extend(obj, {\n\t\t\t\t\thref : href,\n\t\t\t\t\ttype : type,\n\t\t\t\t\tcontent : content,\n\t\t\t\t\ttitle : title,\n\t\t\t\t\tselector : selector\n\t\t\t\t});\n\n\t\t\t\tgroup[ i ] = obj;\n\t\t\t});\n\n\t\t\t// Extend the defaults\n\t\t\tF.opts = $.extend(true, {}, F.defaults, opts);\n\n\t\t\t// All options are merged recursive except keys\n\t\t\tif (opts.keys !== undefined) {\n\t\t\t\tF.opts.keys = opts.keys ? $.extend({}, F.defaults.keys, opts.keys) : false;\n\t\t\t}\n\n\t\t\tF.group = group;\n\n\t\t\treturn F._start(F.opts.index);\n\t\t},\n\n\t\t// Cancel image loading or abort ajax request\n\t\tcancel: function () {\n\t\t\tvar coming = F.coming;\n\n\t\t\tif (!coming || false === F.trigger('onCancel')) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tF.hideLoading();\n\n\t\t\tif (F.ajaxLoad) {\n\t\t\t\tF.ajaxLoad.abort();\n\t\t\t}\n\n\t\t\tF.ajaxLoad = null;\n\n\t\t\tif (F.imgPreload) {\n\t\t\t\tF.imgPreload.onload = F.imgPreload.onerror = null;\n\t\t\t}\n\n\t\t\tif (coming.wrap) {\n\t\t\t\tcoming.wrap.stop(true, true).trigger('onReset').remove();\n\t\t\t}\n\n\t\t\tF.coming = null;\n\n\t\t\t// If the first item has been canceled, then clear everything\n\t\t\tif (!F.current) {\n\t\t\t\tF._afterZoomOut( coming );\n\t\t\t}\n\t\t},\n\n\t\t// Start closing animation if is open; remove immediately if opening/closing\n\t\tclose: function (event) {\n\t\t\tF.cancel();\n\n\t\t\tif (false === F.trigger('beforeClose')) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tF.unbindEvents();\n\n\t\t\tif (!F.isActive) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif (!F.isOpen || event === true) {\n\t\t\t\t$('.fancybox-wrap').stop(true).trigger('onReset').remove();\n\n\t\t\t\tF._afterZoomOut();\n\n\t\t\t} else {\n\t\t\t\tF.isOpen = F.isOpened = false;\n\t\t\t\tF.isClosing = true;\n\n\t\t\t\t$('.fancybox-item, .fancybox-nav').remove();\n\n\t\t\t\tF.wrap.stop(true, true).removeClass('fancybox-opened');\n\n\t\t\t\tF.transitions[ F.current.closeMethod ]();\n\t\t\t}\n\t\t},\n\n\t\t// Manage slideshow:\n\t\t// $.fancybox.play(); - toggle slideshow\n\t\t// $.fancybox.play( true ); - start\n\t\t// $.fancybox.play( false ); - stop\n\t\tplay: function ( action ) {\n\t\t\tvar clear = function () {\n\t\t\t\t\tclearTimeout(F.player.timer);\n\t\t\t\t},\n\t\t\t\tset = function () {\n\t\t\t\t\tclear();\n\n\t\t\t\t\tif (F.current && F.player.isActive) {\n\t\t\t\t\t\tF.player.timer = setTimeout(F.next, F.current.playSpeed);\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\tstop = function () {\n\t\t\t\t\tclear();\n\n\t\t\t\t\tD.unbind('.player');\n\n\t\t\t\t\tF.player.isActive = false;\n\n\t\t\t\t\tF.trigger('onPlayEnd');\n\t\t\t\t},\n\t\t\t\tstart = function () {\n\t\t\t\t\tif (F.current && (F.current.loop || F.current.index < F.group.length - 1)) {\n\t\t\t\t\t\tF.player.isActive = true;\n\n\t\t\t\t\t\tD.bind({\n\t\t\t\t\t\t\t'onCancel.player beforeClose.player' : stop,\n\t\t\t\t\t\t\t'onUpdate.player' : set,\n\t\t\t\t\t\t\t'beforeLoad.player' : clear\n\t\t\t\t\t\t});\n\n\t\t\t\t\t\tset();\n\n\t\t\t\t\t\tF.trigger('onPlayStart');\n\t\t\t\t\t}\n\t\t\t\t};\n\n\t\t\tif (action === true || (!F.player.isActive && action !== false)) {\n\t\t\t\tstart();\n\t\t\t} else {\n\t\t\t\tstop();\n\t\t\t}\n\t\t},\n\n\t\t// Navigate to next gallery item\n\t\tnext: function ( direction ) {\n\t\t\tvar current = F.current;\n\n\t\t\tif (current) {\n\t\t\t\tif (!isString(direction)) {\n\t\t\t\t\tdirection = current.direction.next;\n\t\t\t\t}\n\n\t\t\t\tF.jumpto(current.index + 1, direction, 'next');\n\t\t\t}\n\t\t},\n\n\t\t// Navigate to previous gallery item\n\t\tprev: function ( direction ) {\n\t\t\tvar current = F.current;\n\n\t\t\tif (current) {\n\t\t\t\tif (!isString(direction)) {\n\t\t\t\t\tdirection = current.direction.prev;\n\t\t\t\t}\n\n\t\t\t\tF.jumpto(current.index - 1, direction, 'prev');\n\t\t\t}\n\t\t},\n\n\t\t// Navigate to gallery item by index\n\t\tjumpto: function ( index, direction, router ) {\n\t\t\tvar current = F.current;\n\n\t\t\tif (!current) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tindex = getScalar(index);\n\n\t\t\tF.direction = direction || current.direction[ (index >= current.index ? 'next' : 'prev') ];\n\t\t\tF.router = router || 'jumpto';\n\n\t\t\tif (current.loop) {\n\t\t\t\tif (index < 0) {\n\t\t\t\t\tindex = current.group.length + (index % current.group.length);\n\t\t\t\t}\n\n\t\t\t\tindex = index % current.group.length;\n\t\t\t}\n\n\t\t\tif (current.group[ index ] !== undefined) {\n\t\t\t\tF.cancel();\n\n\t\t\t\tF._start(index);\n\t\t\t}\n\t\t},\n\n\t\t// Center inside viewport and toggle position type to fixed or absolute if needed\n\t\treposition: function (e, onlyAbsolute) {\n\t\t\tvar current = F.current,\n\t\t\t\twrap = current ? current.wrap : null,\n\t\t\t\tpos;\n\n\t\t\tif (wrap) {\n\t\t\t\tpos = F._getPosition(onlyAbsolute);\n\n\t\t\t\tif (e && e.type === 'scroll') {\n\t\t\t\t\tdelete pos.position;\n\n\t\t\t\t\twrap.stop(true, true).animate(pos, 200);\n\n\t\t\t\t} else {\n\t\t\t\t\twrap.css(pos);\n\n\t\t\t\t\tcurrent.pos = $.extend({}, current.dim, pos);\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\n\t\tupdate: function (e) {\n\t\t\tvar type = (e && e.type),\n\t\t\t\tanyway = !type || type === 'orientationchange';\n\n\t\t\tif (anyway) {\n\t\t\t\tclearTimeout(didUpdate);\n\n\t\t\t\tdidUpdate = null;\n\t\t\t}\n\n\t\t\tif (!F.isOpen || didUpdate) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tdidUpdate = setTimeout(function() {\n\t\t\t\tvar current = F.current;\n\n\t\t\t\tif (!current || F.isClosing) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tF.wrap.removeClass('fancybox-tmp');\n\n\t\t\t\tif (anyway || type === 'load' || (type === 'resize' && current.autoResize)) {\n\t\t\t\t\tF._setDimension();\n\t\t\t\t}\n\n\t\t\t\tif (!(type === 'scroll' && current.canShrink)) {\n\t\t\t\t\tF.reposition(e);\n\t\t\t\t}\n\n\t\t\t\tF.trigger('onUpdate');\n\n\t\t\t\tdidUpdate = null;\n\n\t\t\t}, (anyway && !isTouch ? 0 : 300));\n\t\t},\n\n\t\t// Shrink content to fit inside viewport or restore if resized\n\t\ttoggle: function ( action ) {\n\t\t\tif (F.isOpen) {\n\t\t\t\tF.current.fitToView = $.type(action) === \"boolean\" ? action : !F.current.fitToView;\n\n\t\t\t\t// Help browser to restore document dimensions\n\t\t\t\tif (isTouch) {\n\t\t\t\t\tF.wrap.removeAttr('style').addClass('fancybox-tmp');\n\n\t\t\t\t\tF.trigger('onUpdate');\n\t\t\t\t}\n\n\t\t\t\tF.update();\n\t\t\t}\n\t\t},\n\n\t\thideLoading: function () {\n\t\t\tD.unbind('.loading');\n\n\t\t\t$('#fancybox-loading').remove();\n\t\t},\n\n\t\tshowLoading: function () {\n\t\t\tvar el, viewport;\n\n\t\t\tF.hideLoading();\n\n\t\t\tel = $('
').click(F.cancel).appendTo('body');\n\n\t\t\t// If user will press the escape-button, the request will be canceled\n\t\t\tD.bind('keydown.loading', function(e) {\n\t\t\t\tif ((e.which || e.keyCode) === 27) {\n\t\t\t\t\te.preventDefault();\n\n\t\t\t\t\tF.cancel();\n\t\t\t\t}\n\t\t\t});\n\n\t\t\tif (!F.defaults.fixed) {\n\t\t\t\tviewport = F.getViewport();\n\n\t\t\t\tel.css({\n\t\t\t\t\tposition : 'absolute',\n\t\t\t\t\ttop : (viewport.h * 0.5) + viewport.y,\n\t\t\t\t\tleft : (viewport.w * 0.5) + viewport.x\n\t\t\t\t});\n\t\t\t}\n\t\t},\n\n\t\tgetViewport: function () {\n\t\t\tvar locked = (F.current && F.current.locked) || false,\n\t\t\t\trez = {\n\t\t\t\t\tx: W.scrollLeft(),\n\t\t\t\t\ty: W.scrollTop()\n\t\t\t\t};\n\n\t\t\tif (locked) {\n\t\t\t\trez.w = locked[0].clientWidth;\n\t\t\t\trez.h = locked[0].clientHeight;\n\n\t\t\t} else {\n\t\t\t\t// See http://bugs.jquery.com/ticket/6724\n\t\t\t\trez.w = isTouch && window.innerWidth ? window.innerWidth : W.width();\n\t\t\t\trez.h = isTouch && window.innerHeight ? window.innerHeight : W.height();\n\t\t\t}\n\n\t\t\treturn rez;\n\t\t},\n\n\t\t// Unbind the keyboard / clicking actions\n\t\tunbindEvents: function () {\n\t\t\tif (F.wrap && isQuery(F.wrap)) {\n\t\t\t\tF.wrap.unbind('.fb');\n\t\t\t}\n\n\t\t\tD.unbind('.fb');\n\t\t\tW.unbind('.fb');\n\t\t},\n\n\t\tbindEvents: function () {\n\t\t\tvar current = F.current,\n\t\t\t\tkeys;\n\n\t\t\tif (!current) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t// Changing document height on iOS devices triggers a 'resize' event,\n\t\t\t// that can change document height... repeating infinitely\n\t\t\tW.bind('orientationchange.fb' + (isTouch ? '' : ' resize.fb') + (current.autoCenter && !current.locked ? ' scroll.fb' : ''), F.update);\n\n\t\t\tkeys = current.keys;\n\n\t\t\tif (keys) {\n\t\t\t\tD.bind('keydown.fb', function (e) {\n\t\t\t\t\tvar code = e.which || e.keyCode,\n\t\t\t\t\t\ttarget = e.target || e.srcElement;\n\n\t\t\t\t\t// Skip esc key if loading, because showLoading will cancel preloading\n\t\t\t\t\tif (code === 27 && F.coming) {\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\n\t\t\t\t\t// Ignore key combinations and key events within form elements\n\t\t\t\t\tif (!e.ctrlKey && !e.altKey && !e.shiftKey && !e.metaKey && !(target && (target.type || $(target).is('[contenteditable]')))) {\n\t\t\t\t\t\t$.each(keys, function(i, val) {\n\t\t\t\t\t\t\tif (current.group.length > 1 && val[ code ] !== undefined) {\n\t\t\t\t\t\t\t\tF[ i ]( val[ code ] );\n\n\t\t\t\t\t\t\t\te.preventDefault();\n\t\t\t\t\t\t\t\treturn false;\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif ($.inArray(code, val) > -1) {\n\t\t\t\t\t\t\t\tF[ i ] ();\n\n\t\t\t\t\t\t\t\te.preventDefault();\n\t\t\t\t\t\t\t\treturn false;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t}\n\n\t\t\tif ($.fn.mousewheel && current.mouseWheel) {\n\t\t\t\tF.wrap.bind('mousewheel.fb', function (e, delta, deltaX, deltaY) {\n\t\t\t\t\tvar target = e.target || null,\n\t\t\t\t\t\tparent = $(target),\n\t\t\t\t\t\tcanScroll = false;\n\n\t\t\t\t\twhile (parent.length) {\n\t\t\t\t\t\tif (canScroll || parent.is('.fancybox-skin') || parent.is('.fancybox-wrap')) {\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tcanScroll = isScrollable( parent[0] );\n\t\t\t\t\t\tparent = $(parent).parent();\n\t\t\t\t\t}\n\n\t\t\t\t\tif (delta !== 0 && !canScroll) {\n\t\t\t\t\t\tif (F.group.length > 1 && !current.canShrink) {\n\t\t\t\t\t\t\tif (deltaY > 0 || deltaX > 0) {\n\t\t\t\t\t\t\t\tF.prev( deltaY > 0 ? 'down' : 'left' );\n\n\t\t\t\t\t\t\t} else if (deltaY < 0 || deltaX < 0) {\n\t\t\t\t\t\t\t\tF.next( deltaY < 0 ? 'up' : 'right' );\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\te.preventDefault();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t}\n\t\t},\n\n\t\ttrigger: function (event, o) {\n\t\t\tvar ret, obj = o || F.coming || F.current;\n\n\t\t\tif (!obj) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif ($.isFunction( obj[event] )) {\n\t\t\t\tret = obj[event].apply(obj, Array.prototype.slice.call(arguments, 1));\n\t\t\t}\n\n\t\t\tif (ret === false) {\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t\tif (obj.helpers) {\n\t\t\t\t$.each(obj.helpers, function (helper, opts) {\n\t\t\t\t\tif (opts && F.helpers[helper] && $.isFunction(F.helpers[helper][event])) {\n\t\t\t\t\t\tF.helpers[helper][event]($.extend(true, {}, F.helpers[helper].defaults, opts), obj);\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t}\n\n\t\t\tD.trigger(event);\n\t\t},\n\n\t\tisImage: function (str) {\n\t\t\treturn isString(str) && str.match(/(^data:image\\/.*,)|(\\.(jp(e|g|eg)|gif|png|bmp|webp|svg)((\\?|#).*)?$)/i);\n\t\t},\n\n\t\tisSWF: function (str) {\n\t\t\treturn isString(str) && str.match(/\\.(swf)((\\?|#).*)?$/i);\n\t\t},\n\n\t\t_start: function (index) {\n\t\t\tvar coming = {},\n\t\t\t\tobj,\n\t\t\t\thref,\n\t\t\t\ttype,\n\t\t\t\tmargin,\n\t\t\t\tpadding;\n\n\t\t\tindex = getScalar( index );\n\t\t\tobj = F.group[ index ] || null;\n\n\t\t\tif (!obj) {\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t\tcoming = $.extend(true, {}, F.opts, obj);\n\n\t\t\t// Convert margin and padding properties to array - top, right, bottom, left\n\t\t\tmargin = coming.margin;\n\t\t\tpadding = coming.padding;\n\n\t\t\tif ($.type(margin) === 'number') {\n\t\t\t\tcoming.margin = [margin, margin, margin, margin];\n\t\t\t}\n\n\t\t\tif ($.type(padding) === 'number') {\n\t\t\t\tcoming.padding = [padding, padding, padding, padding];\n\t\t\t}\n\n\t\t\t// 'modal' propery is just a shortcut\n\t\t\tif (coming.modal) {\n\t\t\t\t$.extend(true, coming, {\n\t\t\t\t\tcloseBtn : false,\n\t\t\t\t\tcloseClick : false,\n\t\t\t\t\tnextClick : false,\n\t\t\t\t\tarrows : false,\n\t\t\t\t\tmouseWheel : false,\n\t\t\t\t\tkeys : null,\n\t\t\t\t\thelpers: {\n\t\t\t\t\t\toverlay : {\n\t\t\t\t\t\t\tcloseClick : false\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t}\n\n\t\t\t// 'autoSize' property is a shortcut, too\n\t\t\tif (coming.autoSize) {\n\t\t\t\tcoming.autoWidth = coming.autoHeight = true;\n\t\t\t}\n\n\t\t\tif (coming.width === 'auto') {\n\t\t\t\tcoming.autoWidth = true;\n\t\t\t}\n\n\t\t\tif (coming.height === 'auto') {\n\t\t\t\tcoming.autoHeight = true;\n\t\t\t}\n\n\t\t\t/*\n\t\t\t * Add reference to the group, so it`s possible to access from callbacks, example:\n\t\t\t * afterLoad : function() {\n\t\t\t * this.title = 'Image ' + (this.index + 1) + ' of ' + this.group.length + (this.title ? ' - ' + this.title : '');\n\t\t\t * }\n\t\t\t */\n\n\t\t\tcoming.group = F.group;\n\t\t\tcoming.index = index;\n\n\t\t\t// Give a chance for callback or helpers to update coming item (type, title, etc)\n\t\t\tF.coming = coming;\n\n\t\t\tif (false === F.trigger('beforeLoad')) {\n\t\t\t\tF.coming = null;\n\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\ttype = coming.type;\n\t\t\thref = coming.href;\n\n\t\t\tif (!type) {\n\t\t\t\tF.coming = null;\n\n\t\t\t\t//If we can not determine content type then drop silently or display next/prev item if looping through gallery\n\t\t\t\tif (F.current && F.router && F.router !== 'jumpto') {\n\t\t\t\t\tF.current.index = index;\n\n\t\t\t\t\treturn F[ F.router ]( F.direction );\n\t\t\t\t}\n\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t\tF.isActive = true;\n\n\t\t\tif (type === 'image' || type === 'swf') {\n\t\t\t\tcoming.autoHeight = coming.autoWidth = false;\n\t\t\t\tcoming.scrolling = 'visible';\n\t\t\t}\n\n\t\t\tif (type === 'image') {\n\t\t\t\tcoming.aspectRatio = true;\n\t\t\t}\n\n\t\t\tif (type === 'iframe' && isTouch) {\n\t\t\t\tcoming.scrolling = 'scroll';\n\t\t\t}\n\n\t\t\t// Build the neccessary markup\n\t\t\tcoming.wrap = $(coming.tpl.wrap).addClass('fancybox-' + (isTouch ? 'mobile' : 'desktop') + ' fancybox-type-' + type + ' fancybox-tmp ' + coming.wrapCSS).appendTo( coming.parent || 'body' );\n\n\t\t\t$.extend(coming, {\n\t\t\t\tskin : $('.fancybox-skin', coming.wrap),\n\t\t\t\touter : $('.fancybox-outer', coming.wrap),\n\t\t\t\tinner : $('.fancybox-inner', coming.wrap)\n\t\t\t});\n\n\t\t\t$.each([\"Top\", \"Right\", \"Bottom\", \"Left\"], function(i, v) {\n\t\t\t\tcoming.skin.css('padding' + v, getValue(coming.padding[ i ]));\n\t\t\t});\n\n\t\t\tF.trigger('onReady');\n\n\t\t\t// Check before try to load; 'inline' and 'html' types need content, others - href\n\t\t\tif (type === 'inline' || type === 'html') {\n\t\t\t\tif (!coming.content || !coming.content.length) {\n\t\t\t\t\treturn F._error( 'content' );\n\t\t\t\t}\n\n\t\t\t} else if (!href) {\n\t\t\t\treturn F._error( 'href' );\n\t\t\t}\n\n\t\t\tif (type === 'image') {\n\t\t\t\tF._loadImage();\n\n\t\t\t} else if (type === 'ajax') {\n\t\t\t\tF._loadAjax();\n\n\t\t\t} else if (type === 'iframe') {\n\t\t\t\tF._loadIframe();\n\n\t\t\t} else {\n\t\t\t\tF._afterLoad();\n\t\t\t}\n\t\t},\n\n\t\t_error: function ( type ) {\n\t\t\t$.extend(F.coming, {\n\t\t\t\ttype : 'html',\n\t\t\t\tautoWidth : true,\n\t\t\t\tautoHeight : true,\n\t\t\t\tminWidth : 0,\n\t\t\t\tminHeight : 0,\n\t\t\t\tscrolling : 'no',\n\t\t\t\thasError : type,\n\t\t\t\tcontent : F.coming.tpl.error\n\t\t\t});\n\n\t\t\tF._afterLoad();\n\t\t},\n\n\t\t_loadImage: function () {\n\t\t\t// Reset preload image so it is later possible to check \"complete\" property\n\t\t\tvar img = F.imgPreload = new Image();\n\n\t\t\timg.onload = function () {\n\t\t\t\tthis.onload = this.onerror = null;\n\n\t\t\t\tF.coming.width = this.width / F.opts.pixelRatio;\n\t\t\t\tF.coming.height = this.height / F.opts.pixelRatio;\n\n\t\t\t\tF._afterLoad();\n\t\t\t};\n\n\t\t\timg.onerror = function () {\n\t\t\t\tthis.onload = this.onerror = null;\n\n\t\t\t\tF._error( 'image' );\n\t\t\t};\n\n\t\t\timg.src = F.coming.href;\n\n\t\t\tif (img.complete !== true) {\n\t\t\t\tF.showLoading();\n\t\t\t}\n\t\t},\n\n\t\t_loadAjax: function () {\n\t\t\tvar coming = F.coming;\n\n\t\t\tF.showLoading();\n\n\t\t\tF.ajaxLoad = $.ajax($.extend({}, coming.ajax, {\n\t\t\t\turl: coming.href,\n\t\t\t\terror: function (jqXHR, textStatus) {\n\t\t\t\t\tif (F.coming && textStatus !== 'abort') {\n\t\t\t\t\t\tF._error( 'ajax', jqXHR );\n\n\t\t\t\t\t} else {\n\t\t\t\t\t\tF.hideLoading();\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\tsuccess: function (data, textStatus) {\n\t\t\t\t\tif (textStatus === 'success') {\n\t\t\t\t\t\tcoming.content = data;\n\n\t\t\t\t\t\tF._afterLoad();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}));\n\t\t},\n\n\t\t_loadIframe: function() {\n\t\t\tvar coming = F.coming,\n\t\t\t\tiframe = $(coming.tpl.iframe.replace(/\\{rnd\\}/g, new Date().getTime()))\n\t\t\t\t\t.attr('scrolling', isTouch ? 'auto' : coming.iframe.scrolling)\n\t\t\t\t\t.attr('src', coming.href);\n\n\t\t\t// This helps IE\n\t\t\t$(coming.wrap).bind('onReset', function () {\n\t\t\t\ttry {\n\t\t\t\t\t$(this).find('iframe').hide().attr('src', '//about:blank').end().empty();\n\t\t\t\t} catch (e) {}\n\t\t\t});\n\n\t\t\tif (coming.iframe.preload) {\n\t\t\t\tF.showLoading();\n\n\t\t\t\tiframe.one('load', function() {\n\t\t\t\t\t$(this).data('ready', 1);\n\n\t\t\t\t\t// iOS will lose scrolling if we resize\n\t\t\t\t\tif (!isTouch) {\n\t\t\t\t\t\t$(this).bind('load.fb', F.update);\n\t\t\t\t\t}\n\n\t\t\t\t\t// Without this trick:\n\t\t\t\t\t// - iframe won't scroll on iOS devices\n\t\t\t\t\t// - IE7 sometimes displays empty iframe\n\t\t\t\t\t$(this).parents('.fancybox-wrap').width('100%').removeClass('fancybox-tmp').show();\n\n\t\t\t\t\tF._afterLoad();\n\t\t\t\t});\n\t\t\t}\n\n\t\t\tcoming.content = iframe.appendTo( coming.inner );\n\n\t\t\tif (!coming.iframe.preload) {\n\t\t\t\tF._afterLoad();\n\t\t\t}\n\t\t},\n\n\t\t_preloadImages: function() {\n\t\t\tvar group = F.group,\n\t\t\t\tcurrent = F.current,\n\t\t\t\tlen = group.length,\n\t\t\t\tcnt = current.preload ? Math.min(current.preload, len - 1) : 0,\n\t\t\t\titem,\n\t\t\t\ti;\n\n\t\t\tfor (i = 1; i <= cnt; i += 1) {\n\t\t\t\titem = group[ (current.index + i ) % len ];\n\n\t\t\t\tif (item.type === 'image' && item.href) {\n\t\t\t\t\tnew Image().src = item.href;\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\n\t\t_afterLoad: function () {\n\t\t\tvar coming = F.coming,\n\t\t\t\tprevious = F.current,\n\t\t\t\tplaceholder = 'fancybox-placeholder',\n\t\t\t\tcurrent,\n\t\t\t\tcontent,\n\t\t\t\ttype,\n\t\t\t\tscrolling,\n\t\t\t\thref,\n\t\t\t\tembed;\n\n\t\t\tF.hideLoading();\n\n\t\t\tif (!coming || F.isActive === false) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif (false === F.trigger('afterLoad', coming, previous)) {\n\t\t\t\tcoming.wrap.stop(true).trigger('onReset').remove();\n\n\t\t\t\tF.coming = null;\n\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif (previous) {\n\t\t\t\tF.trigger('beforeChange', previous);\n\n\t\t\t\tprevious.wrap.stop(true).removeClass('fancybox-opened')\n\t\t\t\t\t.find('.fancybox-item, .fancybox-nav')\n\t\t\t\t\t.remove();\n\t\t\t}\n\n\t\t\tF.unbindEvents();\n\n\t\t\tcurrent = coming;\n\t\t\tcontent = coming.content;\n\t\t\ttype = coming.type;\n\t\t\tscrolling = coming.scrolling;\n\n\t\t\t$.extend(F, {\n\t\t\t\twrap : current.wrap,\n\t\t\t\tskin : current.skin,\n\t\t\t\touter : current.outer,\n\t\t\t\tinner : current.inner,\n\t\t\t\tcurrent : current,\n\t\t\t\tprevious : previous\n\t\t\t});\n\n\t\t\thref = current.href;\n\n\t\t\tswitch (type) {\n\t\t\t\tcase 'inline':\n\t\t\t\tcase 'ajax':\n\t\t\t\tcase 'html':\n\t\t\t\t\tif (current.selector) {\n\t\t\t\t\t\tcontent = $('
').html(content).find(current.selector);\n\n\t\t\t\t\t} else if (isQuery(content)) {\n\t\t\t\t\t\tif (!content.data(placeholder)) {\n\t\t\t\t\t\t\tcontent.data(placeholder, $('
').insertAfter( content ).hide() );\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tcontent = content.show().detach();\n\n\t\t\t\t\t\tcurrent.wrap.bind('onReset', function () {\n\t\t\t\t\t\t\tif ($(this).find(content).length) {\n\t\t\t\t\t\t\t\tcontent.hide().replaceAll( content.data(placeholder) ).data(placeholder, false);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\tbreak;\n\n\t\t\t\tcase 'image':\n\t\t\t\t\tcontent = current.tpl.image.replace('{href}', href);\n\t\t\t\tbreak;\n\n\t\t\t\tcase 'swf':\n\t\t\t\t\tcontent = '';\n\t\t\t\t\tembed = '';\n\n\t\t\t\t\t$.each(current.swf, function(name, val) {\n\t\t\t\t\t\tcontent += '';\n\t\t\t\t\t\tembed += ' ' + name + '=\"' + val + '\"';\n\t\t\t\t\t});\n\n\t\t\t\t\tcontent += '';\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tif (!(isQuery(content) && content.parent().is(current.inner))) {\n\t\t\t\tcurrent.inner.append( content );\n\t\t\t}\n\n\t\t\t// Give a chance for helpers or callbacks to update elements\n\t\t\tF.trigger('beforeShow');\n\n\t\t\t// Set scrolling before calculating dimensions\n\t\t\tcurrent.inner.css('overflow', scrolling === 'yes' ? 'scroll' : (scrolling === 'no' ? 'hidden' : scrolling));\n\n\t\t\t// Set initial dimensions and start position\n\t\t\tF._setDimension();\n\n\t\t\tF.reposition();\n\n\t\t\tF.isOpen = false;\n\t\t\tF.coming = null;\n\n\t\t\tF.bindEvents();\n\n\t\t\tif (!F.isOpened) {\n\t\t\t\t$('.fancybox-wrap').not( current.wrap ).stop(true).trigger('onReset').remove();\n\n\t\t\t} else if (previous.prevMethod) {\n\t\t\t\tF.transitions[ previous.prevMethod ]();\n\t\t\t}\n\n\t\t\tF.transitions[ F.isOpened ? current.nextMethod : current.openMethod ]();\n\n\t\t\tF._preloadImages();\n\t\t},\n\n\t\t_setDimension: function () {\n\t\t\tvar viewport = F.getViewport(),\n\t\t\t\tsteps = 0,\n\t\t\t\tcanShrink = false,\n\t\t\t\tcanExpand = false,\n\t\t\t\twrap = F.wrap,\n\t\t\t\tskin = F.skin,\n\t\t\t\tinner = F.inner,\n\t\t\t\tcurrent = F.current,\n\t\t\t\twidth = current.width,\n\t\t\t\theight = current.height,\n\t\t\t\tminWidth = current.minWidth,\n\t\t\t\tminHeight = current.minHeight,\n\t\t\t\tmaxWidth = current.maxWidth,\n\t\t\t\tmaxHeight = current.maxHeight,\n\t\t\t\tscrolling = current.scrolling,\n\t\t\t\tscrollOut = current.scrollOutside ? current.scrollbarWidth : 0,\n\t\t\t\tmargin = current.margin,\n\t\t\t\twMargin = getScalar(margin[1] + margin[3]),\n\t\t\t\thMargin = getScalar(margin[0] + margin[2]),\n\t\t\t\twPadding,\n\t\t\t\thPadding,\n\t\t\t\twSpace,\n\t\t\t\thSpace,\n\t\t\t\torigWidth,\n\t\t\t\torigHeight,\n\t\t\t\torigMaxWidth,\n\t\t\t\torigMaxHeight,\n\t\t\t\tratio,\n\t\t\t\twidth_,\n\t\t\t\theight_,\n\t\t\t\tmaxWidth_,\n\t\t\t\tmaxHeight_,\n\t\t\t\tiframe,\n\t\t\t\tbody;\n\n\t\t\t// Reset dimensions so we could re-check actual size\n\t\t\twrap.add(skin).add(inner).width('auto').height('auto').removeClass('fancybox-tmp');\n\n\t\t\twPadding = getScalar(skin.outerWidth(true) - skin.width());\n\t\t\thPadding = getScalar(skin.outerHeight(true) - skin.height());\n\n\t\t\t// Any space between content and viewport (margin, padding, border, title)\n\t\t\twSpace = wMargin + wPadding;\n\t\t\thSpace = hMargin + hPadding;\n\n\t\t\torigWidth = isPercentage(width) ? (viewport.w - wSpace) * getScalar(width) / 100 : width;\n\t\t\torigHeight = isPercentage(height) ? (viewport.h - hSpace) * getScalar(height) / 100 : height;\n\n\t\t\tif (current.type === 'iframe') {\n\t\t\t\tiframe = current.content;\n\n\t\t\t\tif (current.autoHeight && iframe.data('ready') === 1) {\n\t\t\t\t\ttry {\n\t\t\t\t\t\tif (iframe[0].contentWindow.document.location) {\n\t\t\t\t\t\t\tinner.width( origWidth ).height(9999);\n\n\t\t\t\t\t\t\tbody = iframe.contents().find('body');\n\n\t\t\t\t\t\t\tif (scrollOut) {\n\t\t\t\t\t\t\t\tbody.css('overflow-x', 'hidden');\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\torigHeight = body.outerHeight(true);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t} catch (e) {}\n\t\t\t\t}\n\n\t\t\t} else if (current.autoWidth || current.autoHeight) {\n\t\t\t\tinner.addClass( 'fancybox-tmp' );\n\n\t\t\t\t// Set width or height in case we need to calculate only one dimension\n\t\t\t\tif (!current.autoWidth) {\n\t\t\t\t\tinner.width( origWidth );\n\t\t\t\t}\n\n\t\t\t\tif (!current.autoHeight) {\n\t\t\t\t\tinner.height( origHeight );\n\t\t\t\t}\n\n\t\t\t\tif (current.autoWidth) {\n\t\t\t\t\torigWidth = inner.width();\n\t\t\t\t}\n\n\t\t\t\tif (current.autoHeight) {\n\t\t\t\t\torigHeight = inner.height();\n\t\t\t\t}\n\n\t\t\t\tinner.removeClass( 'fancybox-tmp' );\n\t\t\t}\n\n\t\t\twidth = getScalar( origWidth );\n\t\t\theight = getScalar( origHeight );\n\n\t\t\tratio = origWidth / origHeight;\n\n\t\t\t// Calculations for the content\n\t\t\tminWidth = getScalar(isPercentage(minWidth) ? getScalar(minWidth, 'w') - wSpace : minWidth);\n\t\t\tmaxWidth = getScalar(isPercentage(maxWidth) ? getScalar(maxWidth, 'w') - wSpace : maxWidth);\n\n\t\t\tminHeight = getScalar(isPercentage(minHeight) ? getScalar(minHeight, 'h') - hSpace : minHeight);\n\t\t\tmaxHeight = getScalar(isPercentage(maxHeight) ? getScalar(maxHeight, 'h') - hSpace : maxHeight);\n\n\t\t\t// These will be used to determine if wrap can fit in the viewport\n\t\t\torigMaxWidth = maxWidth;\n\t\t\torigMaxHeight = maxHeight;\n\n\t\t\tif (current.fitToView) {\n\t\t\t\tmaxWidth = Math.min(viewport.w - wSpace, maxWidth);\n\t\t\t\tmaxHeight = Math.min(viewport.h - hSpace, maxHeight);\n\t\t\t}\n\n\t\t\tmaxWidth_ = viewport.w - wMargin;\n\t\t\tmaxHeight_ = viewport.h - hMargin;\n\n\t\t\tif (current.aspectRatio) {\n\t\t\t\tif (width > maxWidth) {\n\t\t\t\t\twidth = maxWidth;\n\t\t\t\t\theight = getScalar(width / ratio);\n\t\t\t\t}\n\n\t\t\t\tif (height > maxHeight) {\n\t\t\t\t\theight = maxHeight;\n\t\t\t\t\twidth = getScalar(height * ratio);\n\t\t\t\t}\n\n\t\t\t\tif (width < minWidth) {\n\t\t\t\t\twidth = minWidth;\n\t\t\t\t\theight = getScalar(width / ratio);\n\t\t\t\t}\n\n\t\t\t\tif (height < minHeight) {\n\t\t\t\t\theight = minHeight;\n\t\t\t\t\twidth = getScalar(height * ratio);\n\t\t\t\t}\n\n\t\t\t} else {\n\t\t\t\twidth = Math.max(minWidth, Math.min(width, maxWidth));\n\n\t\t\t\tif (current.autoHeight && current.type !== 'iframe') {\n\t\t\t\t\tinner.width( width );\n\n\t\t\t\t\theight = inner.height();\n\t\t\t\t}\n\n\t\t\t\theight = Math.max(minHeight, Math.min(height, maxHeight));\n\t\t\t}\n\n\t\t\t// Try to fit inside viewport (including the title)\n\t\t\tif (current.fitToView) {\n\t\t\t\tinner.width( width ).height( height );\n\n\t\t\t\twrap.width( width + wPadding );\n\n\t\t\t\t// Real wrap dimensions\n\t\t\t\twidth_ = wrap.width();\n\t\t\t\theight_ = wrap.height();\n\n\t\t\t\tif (current.aspectRatio) {\n\t\t\t\t\twhile ((width_ > maxWidth_ || height_ > maxHeight_) && width > minWidth && height > minHeight) {\n\t\t\t\t\t\tif (steps++ > 19) {\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\theight = Math.max(minHeight, Math.min(maxHeight, height - 10));\n\t\t\t\t\t\twidth = getScalar(height * ratio);\n\n\t\t\t\t\t\tif (width < minWidth) {\n\t\t\t\t\t\t\twidth = minWidth;\n\t\t\t\t\t\t\theight = getScalar(width / ratio);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (width > maxWidth) {\n\t\t\t\t\t\t\twidth = maxWidth;\n\t\t\t\t\t\t\theight = getScalar(width / ratio);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tinner.width( width ).height( height );\n\n\t\t\t\t\t\twrap.width( width + wPadding );\n\n\t\t\t\t\t\twidth_ = wrap.width();\n\t\t\t\t\t\theight_ = wrap.height();\n\t\t\t\t\t}\n\n\t\t\t\t} else {\n\t\t\t\t\twidth = Math.max(minWidth, Math.min(width, width - (width_ - maxWidth_)));\n\t\t\t\t\theight = Math.max(minHeight, Math.min(height, height - (height_ - maxHeight_)));\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (scrollOut && scrolling === 'auto' && height < origHeight && (width + wPadding + scrollOut) < maxWidth_) {\n\t\t\t\twidth += scrollOut;\n\t\t\t}\n\n\t\t\tinner.width( width ).height( height );\n\n\t\t\twrap.width( width + wPadding );\n\n\t\t\twidth_ = wrap.width();\n\t\t\theight_ = wrap.height();\n\n\t\t\tcanShrink = (width_ > maxWidth_ || height_ > maxHeight_) && width > minWidth && height > minHeight;\n\t\t\tcanExpand = current.aspectRatio ? (width < origMaxWidth && height < origMaxHeight && width < origWidth && height < origHeight) : ((width < origMaxWidth || height < origMaxHeight) && (width < origWidth || height < origHeight));\n\n\t\t\t$.extend(current, {\n\t\t\t\tdim : {\n\t\t\t\t\twidth\t: getValue( width_ ),\n\t\t\t\t\theight\t: getValue( height_ )\n\t\t\t\t},\n\t\t\t\torigWidth : origWidth,\n\t\t\t\torigHeight : origHeight,\n\t\t\t\tcanShrink : canShrink,\n\t\t\t\tcanExpand : canExpand,\n\t\t\t\twPadding : wPadding,\n\t\t\t\thPadding : hPadding,\n\t\t\t\twrapSpace : height_ - skin.outerHeight(true),\n\t\t\t\tskinSpace : skin.height() - height\n\t\t\t});\n\n\t\t\tif (!iframe && current.autoHeight && height > minHeight && height < maxHeight && !canExpand) {\n\t\t\t\tinner.height('auto');\n\t\t\t}\n\t\t},\n\n\t\t_getPosition: function (onlyAbsolute) {\n\t\t\tvar current = F.current,\n\t\t\t\tviewport = F.getViewport(),\n\t\t\t\tmargin = current.margin,\n\t\t\t\twidth = F.wrap.width() + margin[1] + margin[3],\n\t\t\t\theight = F.wrap.height() + margin[0] + margin[2],\n\t\t\t\trez = {\n\t\t\t\t\tposition: 'absolute',\n\t\t\t\t\ttop : margin[0],\n\t\t\t\t\tleft : margin[3]\n\t\t\t\t};\n\n\t\t\tif (current.autoCenter && current.fixed && !onlyAbsolute && height <= viewport.h && width <= viewport.w) {\n\t\t\t\trez.position = 'fixed';\n\n\t\t\t} else if (!current.locked) {\n\t\t\t\trez.top += viewport.y;\n\t\t\t\trez.left += viewport.x;\n\t\t\t}\n\n\t\t\trez.top = getValue(Math.max(rez.top, rez.top + ((viewport.h - height) * current.topRatio)));\n\t\t\trez.left = getValue(Math.max(rez.left, rez.left + ((viewport.w - width) * current.leftRatio)));\n\n\t\t\treturn rez;\n\t\t},\n\n\t\t_afterZoomIn: function () {\n\t\t\tvar current = F.current;\n\n\t\t\tif (!current) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tF.isOpen = F.isOpened = true;\n\n\t\t\tF.wrap.css('overflow', 'visible').addClass('fancybox-opened');\n\n\t\t\tF.update();\n\n\t\t\t// Assign a click event\n\t\t\tif ( current.closeClick || (current.nextClick && F.group.length > 1) ) {\n\t\t\t\tF.inner.css('cursor', 'pointer').bind('click.fb', function(e) {\n\t\t\t\t\tif (!$(e.target).is('a') && !$(e.target).parent().is('a')) {\n\t\t\t\t\t\te.preventDefault();\n\n\t\t\t\t\t\tF[ current.closeClick ? 'close' : 'next' ]();\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t}\n\n\t\t\t// Create a close button\n\t\t\tif (current.closeBtn) {\n\t\t\t\t$(current.tpl.closeBtn).appendTo(F.skin).bind('click.fb', function(e) {\n\t\t\t\t\te.preventDefault();\n\n\t\t\t\t\tF.close();\n\t\t\t\t});\n\t\t\t}\n\n\t\t\t// Create navigation arrows\n\t\t\tif (current.arrows && F.group.length > 1) {\n\t\t\t\tif (current.loop || current.index > 0) {\n\t\t\t\t\t$(current.tpl.prev).appendTo(F.outer).bind('click.fb', F.prev);\n\t\t\t\t}\n\n\t\t\t\tif (current.loop || current.index < F.group.length - 1) {\n\t\t\t\t\t$(current.tpl.next).appendTo(F.outer).bind('click.fb', F.next);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tF.trigger('afterShow');\n\n\t\t\t// Stop the slideshow if this is the last item\n\t\t\tif (!current.loop && current.index === current.group.length - 1) {\n\t\t\t\tF.play( false );\n\n\t\t\t} else if (F.opts.autoPlay && !F.player.isActive) {\n\t\t\t\tF.opts.autoPlay = false;\n\n\t\t\t\tF.play();\n\t\t\t}\n\t\t},\n\n\t\t_afterZoomOut: function ( obj ) {\n\t\t\tobj = obj || F.current;\n\n\t\t\t$('.fancybox-wrap').trigger('onReset').remove();\n\n\t\t\t$.extend(F, {\n\t\t\t\tgroup : {},\n\t\t\t\topts : {},\n\t\t\t\trouter : false,\n\t\t\t\tcurrent : null,\n\t\t\t\tisActive : false,\n\t\t\t\tisOpened : false,\n\t\t\t\tisOpen : false,\n\t\t\t\tisClosing : false,\n\t\t\t\twrap : null,\n\t\t\t\tskin : null,\n\t\t\t\touter : null,\n\t\t\t\tinner : null\n\t\t\t});\n\n\t\t\tF.trigger('afterClose', obj);\n\t\t}\n\t});\n\n\t/*\n\t *\tDefault transitions\n\t */\n\n\tF.transitions = {\n\t\tgetOrigPosition: function () {\n\t\t\tvar current = F.current,\n\t\t\t\telement = current.element,\n\t\t\t\torig = current.orig,\n\t\t\t\tpos = {},\n\t\t\t\twidth = 50,\n\t\t\t\theight = 50,\n\t\t\t\thPadding = current.hPadding,\n\t\t\t\twPadding = current.wPadding,\n\t\t\t\tviewport = F.getViewport();\n\n\t\t\tif (!orig && current.isDom && element.is(':visible')) {\n\t\t\t\torig = element.find('img:first');\n\n\t\t\t\tif (!orig.length) {\n\t\t\t\t\torig = element;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (isQuery(orig)) {\n\t\t\t\tpos = orig.offset();\n\n\t\t\t\tif (orig.is('img')) {\n\t\t\t\t\twidth = orig.outerWidth();\n\t\t\t\t\theight = orig.outerHeight();\n\t\t\t\t}\n\n\t\t\t} else {\n\t\t\t\tpos.top = viewport.y + (viewport.h - height) * current.topRatio;\n\t\t\t\tpos.left = viewport.x + (viewport.w - width) * current.leftRatio;\n\t\t\t}\n\n\t\t\tif (F.wrap.css('position') === 'fixed' || current.locked) {\n\t\t\t\tpos.top -= viewport.y;\n\t\t\t\tpos.left -= viewport.x;\n\t\t\t}\n\n\t\t\tpos = {\n\t\t\t\ttop : getValue(pos.top - hPadding * current.topRatio),\n\t\t\t\tleft : getValue(pos.left - wPadding * current.leftRatio),\n\t\t\t\twidth : getValue(width + wPadding),\n\t\t\t\theight : getValue(height + hPadding)\n\t\t\t};\n\n\t\t\treturn pos;\n\t\t},\n\n\t\tstep: function (now, fx) {\n\t\t\tvar ratio,\n\t\t\t\tpadding,\n\t\t\t\tvalue,\n\t\t\t\tprop = fx.prop,\n\t\t\t\tcurrent = F.current,\n\t\t\t\twrapSpace = current.wrapSpace,\n\t\t\t\tskinSpace = current.skinSpace;\n\n\t\t\tif (prop === 'width' || prop === 'height') {\n\t\t\t\tratio = fx.end === fx.start ? 1 : (now - fx.start) / (fx.end - fx.start);\n\n\t\t\t\tif (F.isClosing) {\n\t\t\t\t\tratio = 1 - ratio;\n\t\t\t\t}\n\n\t\t\t\tpadding = prop === 'width' ? current.wPadding : current.hPadding;\n\t\t\t\tvalue = now - padding;\n\n\t\t\t\tF.skin[ prop ]( getScalar( prop === 'width' ? value : value - (wrapSpace * ratio) ) );\n\t\t\t\tF.inner[ prop ]( getScalar( prop === 'width' ? value : value - (wrapSpace * ratio) - (skinSpace * ratio) ) );\n\t\t\t}\n\t\t},\n\n\t\tzoomIn: function () {\n\t\t\tvar current = F.current,\n\t\t\t\tstartPos = current.pos,\n\t\t\t\teffect = current.openEffect,\n\t\t\t\telastic = effect === 'elastic',\n\t\t\t\tendPos = $.extend({opacity : 1}, startPos);\n\n\t\t\t// Remove \"position\" property that breaks older IE\n\t\t\tdelete endPos.position;\n\n\t\t\tif (elastic) {\n\t\t\t\tstartPos = this.getOrigPosition();\n\n\t\t\t\tif (current.openOpacity) {\n\t\t\t\t\tstartPos.opacity = 0.1;\n\t\t\t\t}\n\n\t\t\t} else if (effect === 'fade') {\n\t\t\t\tstartPos.opacity = 0.1;\n\t\t\t}\n\n\t\t\tF.wrap.css(startPos).animate(endPos, {\n\t\t\t\tduration : effect === 'none' ? 0 : current.openSpeed,\n\t\t\t\teasing : current.openEasing,\n\t\t\t\tstep : elastic ? this.step : null,\n\t\t\t\tcomplete : F._afterZoomIn\n\t\t\t});\n\t\t},\n\n\t\tzoomOut: function () {\n\t\t\tvar current = F.current,\n\t\t\t\teffect = current.closeEffect,\n\t\t\t\telastic = effect === 'elastic',\n\t\t\t\tendPos = {opacity : 0.1};\n\n\t\t\tif (elastic) {\n\t\t\t\tendPos = this.getOrigPosition();\n\n\t\t\t\tif (current.closeOpacity) {\n\t\t\t\t\tendPos.opacity = 0.1;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tF.wrap.animate(endPos, {\n\t\t\t\tduration : effect === 'none' ? 0 : current.closeSpeed,\n\t\t\t\teasing : current.closeEasing,\n\t\t\t\tstep : elastic ? this.step : null,\n\t\t\t\tcomplete : F._afterZoomOut\n\t\t\t});\n\t\t},\n\n\t\tchangeIn: function () {\n\t\t\tvar current = F.current,\n\t\t\t\teffect = current.nextEffect,\n\t\t\t\tstartPos = current.pos,\n\t\t\t\tendPos = { opacity : 1 },\n\t\t\t\tdirection = F.direction,\n\t\t\t\tdistance = 200,\n\t\t\t\tfield;\n\n\t\t\tstartPos.opacity = 0.1;\n\n\t\t\tif (effect === 'elastic') {\n\t\t\t\tfield = direction === 'down' || direction === 'up' ? 'top' : 'left';\n\n\t\t\t\tif (direction === 'down' || direction === 'right') {\n\t\t\t\t\tstartPos[ field ] = getValue(getScalar(startPos[ field ]) - distance);\n\t\t\t\t\tendPos[ field ] = '+=' + distance + 'px';\n\n\t\t\t\t} else {\n\t\t\t\t\tstartPos[ field ] = getValue(getScalar(startPos[ field ]) + distance);\n\t\t\t\t\tendPos[ field ] = '-=' + distance + 'px';\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Workaround for http://bugs.jquery.com/ticket/12273\n\t\t\tif (effect === 'none') {\n\t\t\t\tF._afterZoomIn();\n\n\t\t\t} else {\n\t\t\t\tF.wrap.css(startPos).animate(endPos, {\n\t\t\t\t\tduration : current.nextSpeed,\n\t\t\t\t\teasing : current.nextEasing,\n\t\t\t\t\tcomplete : F._afterZoomIn\n\t\t\t\t});\n\t\t\t}\n\t\t},\n\n\t\tchangeOut: function () {\n\t\t\tvar previous = F.previous,\n\t\t\t\teffect = previous.prevEffect,\n\t\t\t\tendPos = { opacity : 0.1 },\n\t\t\t\tdirection = F.direction,\n\t\t\t\tdistance = 200;\n\n\t\t\tif (effect === 'elastic') {\n\t\t\t\tendPos[ direction === 'down' || direction === 'up' ? 'top' : 'left' ] = ( direction === 'up' || direction === 'left' ? '-' : '+' ) + '=' + distance + 'px';\n\t\t\t}\n\n\t\t\tprevious.wrap.animate(endPos, {\n\t\t\t\tduration : effect === 'none' ? 0 : previous.prevSpeed,\n\t\t\t\teasing : previous.prevEasing,\n\t\t\t\tcomplete : function () {\n\t\t\t\t\t$(this).trigger('onReset').remove();\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t};\n\n\t/*\n\t *\tOverlay helper\n\t */\n\n\tF.helpers.overlay = {\n\t\tdefaults : {\n\t\t\tcloseClick : true, // if true, fancyBox will be closed when user clicks on the overlay\n\t\t\tspeedOut : 200, // duration of fadeOut animation\n\t\t\tshowEarly : true, // indicates if should be opened immediately or wait until the content is ready\n\t\t\tcss : {}, // custom CSS properties\n\t\t\tlocked : !isTouch, // if true, the content will be locked into overlay\n\t\t\tfixed : true // if false, the overlay CSS position property will not be set to \"fixed\"\n\t\t},\n\n\t\toverlay : null, // current handle\n\t\tfixed : false, // indicates if the overlay has position \"fixed\"\n\t\tel : $('html'), // element that contains \"the lock\"\n\n\t\t// Public methods\n\t\tcreate : function(opts) {\n\t\t\topts = $.extend({}, this.defaults, opts);\n\n\t\t\tif (this.overlay) {\n\t\t\t\tthis.close();\n\t\t\t}\n\n\t\t\tthis.overlay = $('
').appendTo( F.coming ? F.coming.parent : opts.parent );\n\t\t\tthis.fixed = false;\n\n\t\t\tif (opts.fixed && F.defaults.fixed) {\n\t\t\t\tthis.overlay.addClass('fancybox-overlay-fixed');\n\n\t\t\t\tthis.fixed = true;\n\t\t\t}\n\t\t},\n\n\t\topen : function(opts) {\n\t\t\tvar that = this;\n\n\t\t\topts = $.extend({}, this.defaults, opts);\n\n\t\t\tif (this.overlay) {\n\t\t\t\tthis.overlay.unbind('.overlay').width('auto').height('auto');\n\n\t\t\t} else {\n\t\t\t\tthis.create(opts);\n\t\t\t}\n\n\t\t\tif (!this.fixed) {\n\t\t\t\tW.bind('resize.overlay', $.proxy( this.update, this) );\n\n\t\t\t\tthis.update();\n\t\t\t}\n\n\t\t\tif (opts.closeClick) {\n\t\t\t\tthis.overlay.bind('click.overlay', function(e) {\n\t\t\t\t\tif ($(e.target).hasClass('fancybox-overlay')) {\n\t\t\t\t\t\tif (F.isActive) {\n\t\t\t\t\t\t\tF.close();\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tthat.close();\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t}\n\n\t\t\tthis.overlay.css( opts.css ).show();\n\t\t},\n\n\t\tclose : function() {\n\t\t\tvar scrollV, scrollH;\n\n\t\t\tW.unbind('resize.overlay');\n\n\t\t\tif (this.el.hasClass('fancybox-lock')) {\n\t\t\t\t$('.fancybox-margin').removeClass('fancybox-margin');\n\n\t\t\t\tscrollV = W.scrollTop();\n\t\t\t\tscrollH = W.scrollLeft();\n\n\t\t\t\tthis.el.removeClass('fancybox-lock');\n\n\t\t\t\tW.scrollTop( scrollV ).scrollLeft( scrollH );\n\t\t\t}\n\n\t\t\t$('.fancybox-overlay').remove().hide();\n\n\t\t\t$.extend(this, {\n\t\t\t\toverlay : null,\n\t\t\t\tfixed : false\n\t\t\t});\n\t\t},\n\n\t\t// Private, callbacks\n\n\t\tupdate : function () {\n\t\t\tvar width = '100%', offsetWidth;\n\n\t\t\t// Reset width/height so it will not mess\n\t\t\tthis.overlay.width(width).height('100%');\n\n\t\t\t// jQuery does not return reliable result for IE\n\t\t\tif (IE) {\n\t\t\t\toffsetWidth = Math.max(document.documentElement.offsetWidth, document.body.offsetWidth);\n\n\t\t\t\tif (D.width() > offsetWidth) {\n\t\t\t\t\twidth = D.width();\n\t\t\t\t}\n\n\t\t\t} else if (D.width() > W.width()) {\n\t\t\t\twidth = D.width();\n\t\t\t}\n\n\t\t\tthis.overlay.width(width).height(D.height());\n\t\t},\n\n\t\t// This is where we can manipulate DOM, because later it would cause iframes to reload\n\t\tonReady : function (opts, obj) {\n\t\t\tvar overlay = this.overlay;\n\n\t\t\t$('.fancybox-overlay').stop(true, true);\n\n\t\t\tif (!overlay) {\n\t\t\t\tthis.create(opts);\n\t\t\t}\n\n\t\t\tif (opts.locked && this.fixed && obj.fixed) {\n\t\t\t\tif (!overlay) {\n\t\t\t\t\tthis.margin = D.height() > W.height() ? $('html').css('margin-right').replace(\"px\", \"\") : false;\n\t\t\t\t}\n\n\t\t\t\tobj.locked = this.overlay.append( obj.wrap );\n\t\t\t\tobj.fixed = false;\n\t\t\t}\n\n\t\t\tif (opts.showEarly === true) {\n\t\t\t\tthis.beforeShow.apply(this, arguments);\n\t\t\t}\n\t\t},\n\n\t\tbeforeShow : function(opts, obj) {\n\t\t\tvar scrollV, scrollH;\n\n\t\t\tif (obj.locked) {\n\t\t\t\tif (this.margin !== false) {\n\t\t\t\t\t$('*').filter(function(){\n\t\t\t\t\t\treturn ($(this).css('position') === 'fixed' && !$(this).hasClass(\"fancybox-overlay\") && !$(this).hasClass(\"fancybox-wrap\") );\n\t\t\t\t\t}).addClass('fancybox-margin');\n\n\t\t\t\t\tthis.el.addClass('fancybox-margin');\n\t\t\t\t}\n\n\t\t\t\tscrollV = W.scrollTop();\n\t\t\t\tscrollH = W.scrollLeft();\n\n\t\t\t\tthis.el.addClass('fancybox-lock');\n\n\t\t\t\tW.scrollTop( scrollV ).scrollLeft( scrollH );\n\t\t\t}\n\n\t\t\tthis.open(opts);\n\t\t},\n\n\t\tonUpdate : function() {\n\t\t\tif (!this.fixed) {\n\t\t\t\tthis.update();\n\t\t\t}\n\t\t},\n\n\t\tafterClose: function (opts) {\n\t\t\t// Remove overlay if exists and fancyBox is not opening\n\t\t\t// (e.g., it is not being open using afterClose callback)\n\t\t\t//if (this.overlay && !F.isActive) {\n\t\t\tif (this.overlay && !F.coming) {\n\t\t\t\tthis.overlay.fadeOut(opts.speedOut, $.proxy( this.close, this ));\n\t\t\t}\n\t\t}\n\t};\n\n\t/*\n\t *\tTitle helper\n\t */\n\n\tF.helpers.title = {\n\t\tdefaults : {\n\t\t\ttype : 'float', // 'float', 'inside', 'outside' or 'over',\n\t\t\tposition : 'bottom' // 'top' or 'bottom'\n\t\t},\n\n\t\tbeforeShow: function (opts) {\n\t\t\tvar current = F.current,\n\t\t\t\ttext = current.title,\n\t\t\t\ttype = opts.type,\n\t\t\t\ttitle,\n\t\t\t\ttarget;\n\n\t\t\tif ($.isFunction(text)) {\n\t\t\t\ttext = text.call(current.element, current);\n\t\t\t}\n\n\t\t\tif (!isString(text) || $.trim(text) === '') {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\ttitle = $('
' + text + '
');\n\n\t\t\tswitch (type) {\n\t\t\t\tcase 'inside':\n\t\t\t\t\ttarget = F.skin;\n\t\t\t\tbreak;\n\n\t\t\t\tcase 'outside':\n\t\t\t\t\ttarget = F.wrap;\n\t\t\t\tbreak;\n\n\t\t\t\tcase 'over':\n\t\t\t\t\ttarget = F.inner;\n\t\t\t\tbreak;\n\n\t\t\t\tdefault: // 'float'\n\t\t\t\t\ttarget = F.skin;\n\n\t\t\t\t\ttitle.appendTo('body');\n\n\t\t\t\t\tif (IE) {\n\t\t\t\t\t\ttitle.width( title.width() );\n\t\t\t\t\t}\n\n\t\t\t\t\ttitle.wrapInner('');\n\n\t\t\t\t\t//Increase bottom margin so this title will also fit into viewport\n\t\t\t\t\tF.current.margin[2] += Math.abs( getScalar(title.css('margin-bottom')) );\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\ttitle[ (opts.position === 'top' ? 'prependTo' : 'appendTo') ](target);\n\t\t}\n\t};\n\n\t// jQuery plugin initialization\n\t$.fn.fancybox = function (options) {\n\t\tvar index,\n\t\t\tthat = $(this),\n\t\t\tselector = this.selector || '',\n\t\t\trun = function(e) {\n\t\t\t\tvar what = $(this).blur(), idx = index, relType, relVal;\n\n\t\t\t\tif (!(e.ctrlKey || e.altKey || e.shiftKey || e.metaKey) && !what.is('.fancybox-wrap')) {\n\t\t\t\t\trelType = options.groupAttr || 'data-fancybox-group';\n\t\t\t\t\trelVal = what.attr(relType);\n\n\t\t\t\t\tif (!relVal) {\n\t\t\t\t\t\trelType = 'rel';\n\t\t\t\t\t\trelVal = what.get(0)[ relType ];\n\t\t\t\t\t}\n\n\t\t\t\t\tif (relVal && relVal !== '' && relVal !== 'nofollow') {\n\t\t\t\t\t\twhat = selector.length ? $(selector) : that;\n\t\t\t\t\t\twhat = what.filter('[' + relType + '=\"' + relVal + '\"]');\n\t\t\t\t\t\tidx = what.index(this);\n\t\t\t\t\t}\n\n\t\t\t\t\toptions.index = idx;\n\n\t\t\t\t\t// Stop an event from bubbling if everything is fine\n\t\t\t\t\tif (F.open(what, options) !== false) {\n\t\t\t\t\t\te.preventDefault();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t};\n\n\t\toptions = options || {};\n\t\tindex = options.index || 0;\n\n\t\tif (!selector || options.live === false) {\n\t\t\tthat.unbind('click.fb-start').bind('click.fb-start', run);\n\n\t\t} else {\n\t\t\tD.undelegate(selector, 'click.fb-start').delegate(selector + \":not('.fancybox-item, .fancybox-nav')\", 'click.fb-start', run);\n\t\t}\n\n\t\tthis.filter('[data-fancybox-start=1]').trigger('click');\n\n\t\treturn this;\n\t};\n\n\t// Tests that need a body at doc ready\n\tD.ready(function() {\n\t\tvar w1, w2;\n\n\t\tif ( $.scrollbarWidth === undefined ) {\n\t\t\t// http://benalman.com/projects/jquery-misc-plugins/#scrollbarwidth\n\t\t\t$.scrollbarWidth = function() {\n\t\t\t\tvar parent = $('
').appendTo('body'),\n\t\t\t\t\tchild = parent.children(),\n\t\t\t\t\twidth = child.innerWidth() - child.height( 99 ).innerWidth();\n\n\t\t\t\tparent.remove();\n\n\t\t\t\treturn width;\n\t\t\t};\n\t\t}\n\n\t\tif ( $.support.fixedPosition === undefined ) {\n\t\t\t$.support.fixedPosition = (function() {\n\t\t\t\tvar elem = $('
').appendTo('body'),\n\t\t\t\t\tfixed = ( elem[0].offsetTop === 20 || elem[0].offsetTop === 15 );\n\n\t\t\t\telem.remove();\n\n\t\t\t\treturn fixed;\n\t\t\t}());\n\t\t}\n\n\t\t$.extend(F.defaults, {\n\t\t\tscrollbarWidth : $.scrollbarWidth(),\n\t\t\tfixed : $.support.fixedPosition,\n\t\t\tparent : $('body')\n\t\t});\n\n\t\t//Get real width of page scroll-bar\n\t\tw1 = $(window).width();\n\n\t\tH.addClass('fancybox-lock-test');\n\n\t\tw2 = $(window).width();\n\n\t\tH.removeClass('fancybox-lock-test');\n\n\t\t$(\"\").appendTo(\"head\");\n\t});\n\n}(window, document, jQuery));","/* Pylyfill Array.find */\nif (!Array.prototype.find) {\n Array.prototype.find = function (predicate) {\n if (this == null) {\n throw new TypeError('Array.prototype.find called on null or undefined');\n }\n if (typeof predicate !== 'function') {\n throw new TypeError('predicate must be a function');\n }\n var list = Object(this);\n var length = list.length >>> 0;\n var thisArg = arguments[1];\n var value;\n for (var i = 0; i < length; i++) {\n value = list[i];\n if (predicate.call(thisArg, value, i, list)) {\n return value;\n }\n }\n return undefined;\n };\n}\n/* Pylyfill Array.filter */\nif (!Array.prototype.filter) {\n Array.prototype.filter = function (fun /*, thisArg*/) {\n 'use strict';\n if (this === void 0 || this === null) {\n throw new TypeError();\n }\n var t = Object(this);\n var len = t.length >>> 0;\n if (typeof fun !== 'function') {\n throw new TypeError();\n }\n var res = [];\n var thisArg = arguments.length >= 2 ? arguments[1] : void 0;\n for (var i = 0; i < len; i++) {\n if (i in t) {\n var val = t[i];\n if (fun.call(thisArg, val, i, t)) {\n res.push(val);\n }\n }\n }\n return res;\n };\n}\n/* Pylyfill Element.matchesSelector */\nthis.Element && function (ElementPrototype) {\n ElementPrototype.matchesSelector = ElementPrototype.matchesSelector || ElementPrototype.mozMatchesSelector || ElementPrototype.msMatchesSelector || ElementPrototype.oMatchesSelector || ElementPrototype.webkitMatchesSelector || function (selector) {\n var node = this, nodes = (node.parentNode || node.document).querySelectorAll(selector), i = -1;\n while (nodes[++i] && nodes[i] != node)\n ;\n return !!nodes[i];\n };\n}(Element.prototype);\n"],"sourceRoot":"/js/"}