 -- Before "Waterworld," Kevin Costner's biggest gamble was "Dances with Wolves."

That the film -- which was released 25 years ago today -- went on to win seven of the 12 Academy Awards it was nominated for, including best picture and best director for Costner, grossed more than $400 million worldwide and helped revitalize the Western on the big screen, is something of a Hollywood miracle.

By conventional Hollywood standards, "Dances with Wolves," the saga of a Civil War lieutenant who befriends a tribe of Lakota Indians on the Great Plains, should have tanked at the box office. It had so many things going against it.

Here are just a few of the things Costner had to overcome in order to make one of the most phenomenal films of 1990:

The Script

Costner nearly skipped reading friend Michael Blake's manuscript. As the Oscar winner, 60, revealed to Tim Ferriss during a recent podcast, Costner and Blake, who had previously written the screenplay for Costner's film "Stacey's Knights," had a major falling out just before Blake finished writing "Dances With Wolves."

For months, Costner refused to read it, until one day he picked it up and read the entire thing in one night. He then tracked down his friend and said, "I'm going to make this into a movie, and I'm going to pay you" to write it. Blake published his manuscript as a novel and began writing the screenplay with Costner's urging. Two years later, they made the film and Blake went on to win the Oscar for best screenplay.

The Director

Costner went to three "top of the heap" directors, who all said the movie couldn't be done as written, he told Ferriss. One said get rid of the opening Civil War sequence, another said it was too long, and one thought Costner's love interest, Stands With a Fist, shouldn't be a white woman (played by Mary McDonnell) raised by the Sioux.

Thankfully, Costner refused to listen to any of them. "Once I got past them I thought to myself I should direct this," he told Ferriss. "I really had a great script."

The Production

There's an old adage in Hollywood: never work with kids or animals. A novice director, Costner did both.

He oversaw a production that included 3,500 buffalo, 300 horses, two wolves, 42 wagons, 36 tepees, 130 crew members and 500 extras. He explained to Ferriss how he would pull out a chalkboard, like the one from his athlete days, to map out the big action sequences. The film was shot in 27 different South Dakota locations over five months, with temperatures ranging from 100 degrees in summer to 20 degrees in winter. Costner worked round the clock, shooting 16-hour days before going home to make up his shot list for the following day.

The Casting

After casting himself as the star of the film, Costner learned to ride bareback and did most of his own horseback riding in the film. Production nearly came to a halt, though, when he took a spill during the centerpiece bison hunt sequence and almost broke his back.

Costner surrounded himself in "Dances," with a cast of mostly unknowns, many of them Native Americans with no acting experience. To top it off, much of the film's dialogue was spoken in the Lakota Sioux dialect and subtitled in English. Costner even learned to speak rudimentary Lakota. In the end, his decision paid off with the Sioux nation, who adopted him as an honorary member.

The Money

With all those animals and extras and a mostly outdoor shoot, the production soon exceeded its $15 million budget. Costner put in $3 million of his own to complete the film. When word of his money troubles spread, the film was jokingly dubbed "Kevin's Gate," a reference to the Western "Heaven's Gate," which had bombed a decade earlier. A Western hadn't succeeded in Hollywood in more than 20 years.

Costner got the last laugh, though. When "Dances" took off, he received upwards of $40 million in profit and the film not only revived the Western -- Clint Eastwood’s "Unforgiven" would also win Best Picture and Best Director in 1992 -- but it became by far the most successful Western ever made.

The Length

The movie clocked in at three hours -- a death knell in Hollywood. While executives were jittery about how the film would be received, word-of-mouth quickly drew audiences. "That movie was different from a lot of other movies," Costner told Ferris. "It was a journey movie, not a plot movie; you didn't know where the movie was going. I think people were able to go for the ride."

The big-screen version actually left some scenes on the cutting room floor. Costner and producer Jim Wilson restored some of the scenes in an extended cut for the 2003 DVD release that runs 236 minutes.