I had the same problem. It was caused by the SEF upsetting the relative path of the X image.
I changed the image path to an absolute in lightbox.js which cured the problem.
Change
[code:1]var fileBottomNavCloseImage = "components/com_comprofiler/plugin/user/plug_cbprofilegallery/images/close.gif";[/code:1]
To
[code:1]var fileBottomNavCloseImage = "
yoursite.com/components/com_comprofiler/plugin/user/plug_cbprofilegallery/images/close.gif";[/code:1]