The stirring, stylish legal drama “Just Mercy” feels familiar on several levels. The story of a wrongly accused man sent to death row, it is an affecting examination of how justice is confused with inhumane retribution.

Based on factual events, “Just Mercy” is the story of Walter “Johnny D.” McMillian, who in 1987 was arrested for a murder he didn’t commit, but who was railroaded by a racist and incompetent legal system in Alabama — a story that is as old as the rugged cross itself. McMillian’s case became famous by way of a “60 Minutes” episode and the memoir of Bryan Stevenson, a brilliant, Harvard-educated attorney who came to his defense and has gone on to become a visionary leader in criminal justice reform.

Both on a macro and micro level then, “Just Mercy” — which takes its title from Stevenson’s book — might feel like something we’ve seen before. But in the judicious hands of director and co-writer Destin Daniel Cretton, it feels not new exactly, but fresh and urgent and more timely than ever.

Largely, that’s because Cretton, best known for his exceptionally assured 2013 breakthrough “Short Term 12,” knows exactly when to get out of the way and let Stevenson and McMilllian’s story simply unfold. “Just Mercy” begins in 1987, when McMillian — played in an astonishing comeback performance by Jamie Foxx — is in a forest outside Monroeville, where he works as a pulpwood contractor. Arrested for the murder of a white dry cleaning clerk back in town, McMillian insists he couldn’t have committed the crime (he was at a church fish fry that day along with several witnesses). Still, he winds up on death row, the result of countless assaults on his human and constitutional rights that will continue once he’s there.

McMillian would have been just another statistic of structural racism and irrational fear and revenge, had Stevenson not decided to move from the Northeast to Monroeville.

Played by Michael B. Jordan with his usual combination of composure and submerged fire, Stevenson is the main protagonist in “Just Mercy,” but this isn’t a biopic. As much as viewers come to admire him for his courage and dedication, they don’t necessarily come to feel they know him. There are moments when “Just Mercy” threatens to become as meandering and mired-down as McMillian’s case itself.

But Cretton keeps the narrative on course, leading the audience through the stakes and specifics of Stevenson’s quest with welcome clarity.

Foxx, delivering one of the finest performances of his career in a role that involves as dramatic a physical transformation as his Oscar-winning turn in “Ray,” is joined by an equally impressive supporting cast, which includes O’Shea Jackson Jr., Darrell Britt-Gibson and Rob Morgan, who brings enormous sympathy to a prisoner whose extenuating circumstances throw the perversity of the death penalty into heartbreaking relief.

Propelled by a liltingly beautiful musical score by Joel P. West, “Just Mercy” keeps its emotions on a low simmer, its absorbing, tautly designed drama finally coming to a climax that is satisfying on one level, and absolutely shattering on another. From its smooth visuals and warm, swinging sounds to its magnificent performances, “Just Mercy” is masterfully constructed to keep us inside a story that otherwise would be too brutal to bear.

MOVIE REVIEW

“Just Mercy”

Grade: B+

Starring Michael B. Jordan, Jamie Foxx and Brie Larson. Directed by Destin Daniel Cretton.

Rated PG-13 for mature thematic material including some racial epithets. 2 hours, 17 minutes.

Bottom line: An absorbing, tautly designed drama