Mimi Leder's idealistic biopic isn't a total loss, but its sunny approach is out of touch with the times.

With few modifications, “On the Basis of Sex” could have been made 30 years ago, and its rousing portrait of Supreme Court Justice Ruth Bader Ginsburg would be a cheesy tearjerker with purpose. Today, it’s out of touch. Like the breakout summer documentary “RBG,” director Mimi Leder’s upbeat tribute is an admirable salute to one woman’s determination against a sexist world, but the non-fiction treatment is forced into heavy-handed dramaturgy and becomes an antiquated soap opera.

The justice’s inspiring legal trajectory, as the pioneering women’s rights lawyer who challenged gender discrimination laws and eventually overturned them in a series of aggressive cases, has inspired generations. Unfortunately, released at the most divisive moments in American politics — a matter of weeks after the Supreme Court became a flashpoint for national outrage, and its longstanding commitment to nonpartisanship went kaput — “On the Basis of Sex” plays like a sunny fantasy from a more optimistic age.

Despite a formidable performance by Felicity Jones, Leder’s maudlin approach is further hobbled by Daniel Stiepleman’s blunt screenplay, which takes Ginsburg’s imminent success for granted with an annoying wink-wink approach that underserves the value of her legacy. As concerns about the 85-year-old Ginsburg’s longevity linger on a court where liberal justices have been relegated to a minority, Leder’s movie arrives with an unspoken and inadvertent aura of fear.

Still, if you’re just getting up to speed on why Ginsburg matters — then and now, with a terrifying future on the horizon — “On the Basis of Sex” does a serviceable job of consolidating the earlier chapters. The movie opens on the steps of Harvard in the early 1950s, when Ginsbeurg entered law school as one of only a handful of women in her class. Discrimination comes at her from every angle, from the moment young Ginsburg takes her seat alongside a male classmate who gives her a discerning look; it carries over to a dinner hosted by the hawkish dean Erwin Griswold (Sam Waterston, all stern looks and furrowed brows), the movie’s de facto villain. Their initial showdown provides the first guilty pleasure kick of watching Jones throw shade at any sexism casually tossed her way: Asked at the dinner table to explain “why you’re occupying a place that could have gone to a man,” she fires back with a sarcastic desire to “be a more supportive wife.”

Of course, as “RBG” viewers and RBG acolytes know, the reality of Ginsburg’s household was the opposite: While Marty Ginsburg found his way through Harvard’s secondary school and suffered through a cancer diagnosis, Ginsburg became the breadwinner. Armie Hammer does a serviceable job with a woefully underwritten part as a sweet, flawless support system (while a welcome inversion of gender dynamics, it’s still a hollow characterization). “On the Basis of Sex” asks for tears early and often, as Marty lies in a hospital bed following his first scary diagnosis and the camera gets intimate with the couple’s faces. “We’re never giving up,” Ginsburg sobs. “I’m spending my life with you.” It’s a wonder an omniscient narrator doesn’t pipe in, “And she did.”

So it goes for much of “On the Basis of Sex,” which presents a series of moments in Ginsburg’s legal career built around the foregone conclusion that she’ll triumph against oppression. The music swells as Ginsburg gives up on Harvard to follow Marty to New York, completing her career at Colombia and finding her footing as a teacher after the male-dominated law firms reject the idea of a working alongside a woman. As the story hits the 1970s, Ginsburg’s enlightened daughter Jane (newcomer Caile Spaeny, an energetic presence with real potential) delivers her mom a reality check about her efforts to effect change in the classroom: “It’s not a movement. It’s a support group.”

Zing! Ginsburg knows she needs to take decisive action to affect real social change, and springs at a chance that comes from an unlikely place: The opportunity to represent a single military veteran denied government support while taking care of his ailing mother, simply because of his gender. By starting with male discrimination, Ginsburg finds the trojan horse that leads to sweeping new legal precedents, and “On the Basis of Sex” develops some intrigue around the evolution of those plans. It also provides an excuse for Justin Theroux to ham it up as the garrulous ACLU head Mel Wulf, who supplies Ginsburg with an important ally even as he distrusts the optics of a woman arguing her case in court.

Of course, she does just that, and the climactic courtroom showdown alternates between dispiriting and heated exchanges with a panel of crusty old men. While hackneyed, the movie’s concluding act provides a window into the punishing work navigated by Ginsburg. Jones bends the material into genuine pathos, even as the British actress is saddled with a loose New Yawk accent that comes and goes. (“My muthuh twold me not to give way to emotions.”) The schematic nature of the screenplay is a different story: As Ginsburg hurdles a wave of legal briefs, debate over the finer details has a wooden quality that even the finest line reading can’t salvage. Told that the prevalent use of “sex” in her briefing comes off as lewd, her aide contemplates a solution: “Maybe try a different word. Maybe…” Wait for it. “Gender?”

You think? As the movie holds its viewers’ hands to a Disneyfied climax, it celebrates Ginsburg’s story with an admirable current of optimism. It’s almost as though Leder were doing penance for the paranoid fantasies of her blockbuster efforts “The Peacemaker” and “Deep Impact,” but the irony is that those 20-year-old apocalyptic scenarios have a lot more in common with the zeitgeist than anything here.

Ginsburg’s resilience has no real historical parallel. She’s held on to her seat through three presidencies and continues to cling on during this terrifying fourth entry, enduring countless health scares (including a very recent one). “On the Basis of Sex” illustrates the roots of that resilience; as the real RBG walks up the steps in a defiant closing shot, “On the Basis of Sex” makes it clear that no fabricated drama can muster the raw power of watching the real deal in action. Long may she reign.

Grade: C

“On the Basis of Sex” premiered at the 2018 AFI Fest. Focus Features releases it theatrically on December 25.