initial code from http://osvaldas.info/image-lightbox-responsive-touch-friendly