In “The Lost City of Z,” which plays in Berlinale Special Gala on Tuesday, director James Gray confronts the racism that was rampant at the start of the last century, but does so with one eye on the prejudice that persists to this day, not least in President Trump’s America.

In the film, Charlie Hunnam plays a British explorer, Percy Fawcett, who becomes obsessed with finding an ancient metropolis hidden in the Amazon jungle. In telling Fawcett’s story Gray sought to hit head-on the “human tendency to rank, to put in categories, and to oppress,” he tells Variety.

“The book is not closed on the white man’s racism,” Gray says. “Unfortunately [the subject] is, if anything, as timely as ever, especially given the current President of the United States.”

It was his desire to look at racism’s pernicious effects that led Gray to take on the adaptation of David Grann’s book when it was offered to him by Brad Pitt’s Plan B.

“I felt that [white racism] was not only subtext but text – that the way to do a revisionist ‘white man in the jungle’ movie was to hit that directly and say in a broad sense, ‘mea culpa,’ because the white Europeans screwed up South America big time. They brought disease to the indigenous people [there], killing off a huge portion of the Indian population.”

In the movie, Fawcett wrestles with the dilemma of choosing between pursuing his dream to find the lost civilization, and staying with his wife, played by Sienna Miller, and family.

“I was really interested in the conflict we all face between trying to satisfy our desire for our lives and the inevitable hurdles and distractions that can derail us if we allow them to,” Hunnam says, “but not allowing them to often requires an enormous amount of sacrifice that can create great conflict in our lives, and I’ve experienced that.”

Nina Fawcett was both constrained by society in pre-World War I Britain, but also determined to push against those restraints, which Miller believes will help women today to relate to her character.

“I focused on the fact she was very modern in many ways and her relationship [with her husband] was very modern. He totally supported her involvement in the Suffragette movement,” Miller says. “She felt very contemporary. The repression that she felt and her struggle against it would be my reaction to that environment.”