Refactored: using 'require' insted of 'import' in css, using jQuery 'on' event handlers for fancybox