HOW long can a story stay ahead of its time? “Ghost in the Shell”, Mamoru Oshii’s much-admired Japanese anime, was shockingly futuristic when it was released in 1995. Its half-shiny, half-grimy mega-city setting may have resembled the noirish metropolises of “Blade Runner” (1982) and “Brazil” (1985), and its cyborg heroine could have come from the same production line as “Robocop” (1987) and “The Terminator” (1984). But its combination of hand-drawn and digital animation was revolutionary, and its vision of a populace connected telepathically to the internet was prophetic. “Ghost in the Shell” went on to influence any number of cyber-punk films, including James Cameron’s “Avatar” (2009) and, especially, the Wachowskis’ “The Matrix” (1999). But 22 years is a long time in science fiction, so the live-action remake, starring Scarlett Johansson, feels like a late arrival at the party: if Hollywood had waited any longer, it would have risked becoming a historical drama. It’s impossible to watch “Ghost in the Shell” without counting echoes of the other films which have come out since the original anime.

Ms Johansson plays the Major, a woman who was almost killed in a terrorist bombing, but whose brain was transplanted into an artificial, almost invulnerable body by a motherly scientist (Juliette Binoche). She now works for an elite counter-terrorism task force alongside the steadfast Batou (Pilou Asbaek). But as well as tracking cyber-criminals through mean streets and virtual realities, she tries to recover memories of her own pre-bionic life.

As an amnesiac secret agent who suspects her employers of knowing more about her than they’re letting on, the Major has an awful lot in common with Jason Bourne in the “Bourne” franchise. Her time-bending, gravity-defying fight scenes, meanwhile, can’t help but recall “The Matrix”. And Ms Johansson herself has already played superhumans with identity crises in “Lucy”, “The Avengers” and “Under the Skin”. When she swan-dives off the top of a tower block, jumps through a plate-glass window in slow-motion, and shoots a roomful of people while running along the ceiling, it’s possible to be awestruck by the fantastic visuals at the same time as thinking, well, yes, it’s Scarlett doing her thing again. “Ghost in the Shell” makes some deliberate, gruesome references to “Frankenstein”, and the film itself is a kind of Frankenstein’s Monster: an entity that has been cobbled together from bits and pieces.

Still, like Frankenstein’s Monster, it is an overpowering and fearsome creation. There isn’t much subtlety to the debates about human consciousness and artificial intelligence, nor is there much complexity to the gruffly violent characters, but the film has a nightmarish atmosphere all of its own. Directed by Rupert Sanders, “Ghost in the Shell” uses all sorts of surreally grotesque imagery—both computer-generated and practical—and an ominous electronic score to make the rain-lashed Los Angeles of “Blade Runner” look like Disneyland on a summer’s day. There is no winking humour to lighten the mood, no contemporary brand names or historical references to anchor the story in a recognisable time or place. As the Major and Batou stalk between mountainous skyscrapers and down crumbling concrete alleys, the viewer is cast adrift in a spectacular but suffocating urban dystopia which feels both eastern and western, ultra-modern and lived-in, authentic and outrageous, familiar and jarringly strange.

One disorientating element is the pointedly international cast, which includes actors of numerous nationalities, colours and accents. In a nod to the film’s origins, The Major’s boss is played by a legend of Japanese action cinema, “Beat” Takeshi Kitano (pictured, with Ms Johansson), who speaks all of his lines in Japanese.

Not everyone is happy about the “rainbow casting”. When Ms Johansson was announced as the Major, the film was condemned online as another example of “white-washing”, that is, the Hollywood tendency to take Asian roles and hand them to white actors. You could argue, as Mr Oshii has, that the new “Ghost in the Shell” is separate from the old one, and that there is no pressing reason why an American film should be identical to a Japanese one, or why a cyborg should be Japanese in the first place. (In the manga comic that inspired the first film, Major is called Motoko Kusanagi, but has blue hair and pink eyes). And while that argument hasn’t won over the detractors, the fact is that its racial diversity is one of its most distinctive and laudable aspects. A mono-cultural city just doesn’t make sense in science fiction anymore. The “Ghost in the Shell” remake may not be as pioneering as the anime was, but its mix-and-match casting is the most truly futuristic thing about it.

“Ghost in the Shell” is screening in cinemas worldwide now