Review of The Imaginarium of Doctor Parnassus (2009)
Terry Gilliam (director).
Thousands of years ago, a powerful mystic led a secret society that he thought was necessary for constantly telling a story that sustained the universe by its mere telling. Then the devil came along and interrupted the story, offering the mystic a bet instead, and losing it. In modern-day London, the mystic is losing hope, having been immortal only until quite recently.
Similar to The Adventures of Baron Munchausen (1988) and The Fisher King (1991), aided by CGI. Cool mechanical design, good all around.
References here: The Zero Theorem (2013).