It’s hard to imagine a better lead actor for a compelling, character-driven mystery than Denzel Washington. He has played many complicated men with rich backgrounds who are inhabitants of moral gray areas. But he has never been in anything like his new film, acted like this or even looked like this.

In “Roman J. Israel, Esq.,” which opens Wednesday, he moves far from his charismatic roots, playing a conflicted, socially awkward, small-time lawyer whose life is about to come crashing down. He has spent his career as the lesser, office-bound partner in a two-man Los Angeles law firm devoted to nonprofit work on social justice issues.

After his colleague’s death, Roman finds himself aged, overweight, inexperienced and unemployed. Propelled beyond his ideals into a side of the legal profession centered around money, he makes life-or-death decisions that are both morally questionable and personally dangerous.

His challenges are all the harder because he is an Asperger’s spectrum savant.

It’s the sort of idiosyncrasy-imbued performance that chameleons like Tilda Swinton or Oscar Isaac would grab in a moment. That’s also what made the role irresistible, Washington explained in a recent phone interview. He shared the call with the movie’s writer/director, Dan Gilroy, creator of 2014’s “Nightcrawler.”

After movies ranging from biographies to shoot-’em-up westerns to Shakespeare, “I was fascinated and impressed by the script when I read it,” Washington said. Taking on a role so complex and vulnerable in emotional and physical terms was a major change of pace.

“That’s why I wanted to do it. That’s the point — to find good material, good challenges that go down a road I’ve never gone before. That’s what you hope for. These kind of scripts are very rare.”

So rare, in fact, that it was a first for him. “I didn’t have any other role, nor had I read any other screenplay, quite like this one.”

Channeling a character whose sense of civil rights was formed in the activist 1970s was a challenge for Washington, who spent that era “in school chasing girls and getting high,” he said with a laugh. “Not the whole time, actually, that was the first part of the ’70s,” before he began his acting career in 1975.

A personal touch

Gilroy always envisioned Washington playing Roman.

“I wrote it exclusively for Denzel,” he said, having been moved by his heartfelt performance in “Philadelphia” as a homophobic lawyer who gains insight as he represents a gay client dying of HIV/AIDS (Tom Hanks).

“I worked on it for a year,” Gilroy said, creating an idealist concerned with injustice and discrimination, but carrying deep personal flaws. “People like this are everywhere. People are complicated. I imagined him doing the part every day I was writing. Had he not done it, I would have put it aside and not done it, either.”

Translating the character of Roman from page to screen involved Washington adopting a Don King-meets-Questlove hairstyle, 40-year-old flared lapel jackets and big, aviator-shaped eyeglasses. The shabby, stuck in the past look carried Washington far from his usually charismatic image. Even the shoes he chose kept him moving in a different way, Washington said.

While Gilroy didn’t write the character with those details, he said he always aims to “let a talented actor come in and invest their creative energies in something. A good actor will always take a character far beyond what a writer can think in terms of motivation and how they look.”

“It’s a little bit of everything,” Washington said. “It’s like if you build a house, what is the most important part? The frame? The steel? The plaster? I don’t know. But that’s why you call it building a house. You’re building a character the same way.”

“I find in life we change minute by minute,” Gilroy said. “And the change sometimes doesn’t last at all. I just find we’re in conflict with ourselves and being challenged all the time. We do the wrong thing and the right thing. We’re constantly moving through currents, trying to find some sort of middle ground for ourselves.”

While the film is largely focused on justice in society, Washington said that wasn’t a key factor in what drew him to it.

“I can’t say I did it for that reason,” he said. “It wasn’t a script tome about social issues. It’s a story about this man and how he fits into our world or doesn’t.”

@colincovert