X-Men: The Last Stand is a 2006 superhero film based on the X-Men superhero team introduced in Marvel Comics. It is the sequel to 2003's X2, as well as the third installment in the X-Men film series, and was directed by Brett Ratner and written by Simon Kinberg and Zak Penn. It features an ensemble cast including Hugh Jackman, Halle Berry, Ian McKellen, Famke Janssen, Anna Paquin, Kelsey Grammer, James Marsden, Rebecca Romijn, Shawn Ashmore, Aaron Stanford, Vinnie Jones and Patrick Stewart. The film's script is loosely based on two X-Men comic book story arcs: "The Dark Phoenix Saga" by writer Chris Claremont and artist John Byrne, and "Gifted" by writer Joss Whedon and artist John Cassaday, with a plot that revolves around a "mutant cure" that causes serious repercussions among mutants and humans, and on the resurrection of Jean Grey.