OK, well... After trying to wrap my head around code I don't really understand, I just added the missing elements for the modal lightbox to the head of the joomla template. Not a great solution, because I am loading those items once on the latest pages and twice on the item pages.
If anyone has a brainstorm on this, let me know.