Every second of every day it flows: a river of poison gushing from the hillsides.

SAN JOSE, Calif. — Every second of every day it flows: a river of poison gushing from the hillsides.

Forty gallons a minute, 21 million gallons a year. It bubbles and gurgles across the landscape, a bright orange toxic brew, nearly as corrosive as battery acid, teeming with mercury, aluminum, iron and nickel, the legacy of a long-abandoned mine, relentlessly pouring into nearby streams.

For 120 years, the mining town of New Idria in the rugged back country of southern San Benito County, Calif., was a colorful California outpost, a Wild West community frequented by prospectors and speculators, stagecoaches and famous bandits like Joaquin Murrieta, known as the "Mexican Robin Hood." Herbert Hoover even owned part of the claim at one point.

Today, after decades of neglect, this remote landscape with so much history may finally have a future. In September, the U.S. Environmental Protection Agency declared New Idria a Superfund site, placing it among the most polluted properties in the nation. Since then, workers with hard hats and heavy machinery have combed the landscape — once North America's second largest mercury mine, but today a ghost town — on the first phase of a cleanup that could ultimately cost $10 million and take five years or more to complete.

"It is a toxic hell," said Jared Blumenfeld, regional administrator for the EPA in San Francisco. "It epitomizes what Superfund is for."

EPA officials say New Idria, whose polluted runoff may threaten San Francisco Bay, has more mercury pollution than any of the 96 Superfund sites in California, and possibly the United States.

"It really is like a movie set," Blumenfeld said. "There's all the old housing, the mercury, the San Andreas fault. When you look at it, you know it's dangerous, and it begs for cleaning up. It's really hard to believe something like this exists in California today."

The mine, which closed in 1972, is now little more than a collection of rusting machinery and crumbling cabins a two-hour drive south of Hollister through a landscape that looks like Wyoming. But in its heyday, New Idria's story reads like a Zane Gray dime-store novel. Its first prospectors in the early 1850s were members of the gang of bandits run by Murrieta, a Gold Rush-era outlaw believed by some to have inspired the fictional character Zorro. After Murrieta was killed in 1853, one of the earliest miners with a claim on the land, Peter Collins, was found with his throat slashed when he wouldn't sell out to new investors. An early New Idria treasurer absconded to Chile with company funds.

At its peak, New Idria had a company store, a post office and a school, with about 600 miners and their families from as far away as Mexico, Britain and the Far East living there by the 1880s.

The miners earned $3 a day and carried candles for light.

"It was extremely difficult work," said Fresno historian Ray Iddings, author of "The New Idria Story: Told as it Happened." "They would work in tunnels and take the ore out by drills and dynamite and picks, and shovels and sledgehammers. They'd put the ore in carts, and mules would pull the carts out. Around 1890, the mules were replaced by engines."

The only mercury mine in North America that was more productive was the New Almaden quicksilver mine, 12 miles south of downtown San Jose.

While New Idria was named for the Idrija mines in Slovenia, New Almaden, named for the Almaden mines in Spain, had 2,000 miners at its peak. Both sites were leading centers of industry in the region, with New Almaden providing the inspiration in 1860 for the naming of the San Jose Mercury News.

The mercury from both places was used during the Gold Rush to separate gold from ore, and later for thermometers, switches, medicines and explosives. Eventually, the mines even had the same owner. The New Idria Chemical and Mining Co. owned both when they closed in the early 1970s due to declining demand for mercury and increased concern over its health effects.

What's left today at New Idria is a toxic mess. The EPA has measured mercury in San Carlos Creek, which flows through the area, at levels that are toxic to fish and other wildlife species for more than 20 miles. Although nobody drinks the creek's water, it contains mercury at five times the safe level for human consumption. Mercury is a potent toxin that can affect the nervous system and harm the brain, heart, kidneys, lungs and immune system.

EPA officials are concerned about rain and natural spring water, which flows into the mine as pure water, then washes around the 30 miles of old tunnels, and comes out as a dangerous liquid known as acid mine drainage. As it pours out of the mine entrance, the runoff washes across a 75-foot high pile of waste rock called tailings, where it picks up more mercury and toxic metals.

Bright orange from iron sulfide, the caustic liquid then flows into San Carlos Creek, which meanders through cattle ranches and wetlands full of wildlife, some endangered. During rainy months, the creek system connects with the San Joaquin River in Fresno County, which flows to San Francisco Bay and its delta, a source of drinking water for two-thirds of California's population.

Critics have pressured the EPA and the state for more than 15 years for a cleanup.

"The reason New Idria was not an early priority was that it is so very remote," said Blumenfeld, named to the job two years ago. "But certainly during wet weather, there is a risk of mercury and acid mine drainage getting into the San Joaquin River and into the Delta and the bay."

In recent weeks, EPA crews have performed a triage operation.

First, they dug two long ditches and lined them with plastic to route rainwater around the tailings pile. They also installed a pipe from the mine's entrance to catch the toxic drainage and send it to a pond where metals can settle out. That should reduce by half the mercury going into the creek, now estimated at 700 pounds a year, said Kelly Manheimer, EPA's project manager on the site. After that, there will be at least two years of testing streams to see how far the pollution has spread, along with engineering studies and public meetings to devise a final cleanup plan.

As part of the final cleanup, crews might try to block the mine opening. But a similar attempt at Iron Mountain Mine, a Superfund site near Redding, showed the power of chemistry.

"They plugged it with a 6-foot concrete and metal wall," Manheimer said. "But the acid in the water just ate right through it."

Generations ago, the New Idria mine was considered so valuable that armed soldiers were sent to guard it in World War I. By the 1930s, a company run by Theodore Hoover, former dean of engineering at Stanford University, owned the mine. His brother, former President Herbert Hoover, owned 3 percent, and visited. But more recently, the story is less grand. After the mine closed in 1972, a group of speculators bought the 880-acre site and promised investors there was significant gold there. They were charged later with mail fraud. By 1991, a San Jose drug program called the Futures Foundation bought the land and took drug abuse patients there as part of their treatment. After clashes with nearby residents, the company was fined by state officials for dumping garbage, junk vehicles and construction debris there. The foundation still owns the land. But its president, Sylvester Herring, died last year, and the foundation is all but defunct, owing $134,000 in unpaid property taxes.

Although the New Idria Chemical and Mining Co. no longer exists, federal officials hope to recoup some of the cost of cleanup from Myers Industries, an Ohio-based company that later acquired its assets and helped pay for a 1990s cleanup at New Almaden.

Iddings, the Fresno historian, has tried for years to convince San Benito County or the federal Bureau of Land Management to protect the remaining buildings, without luck. A fire in July 2010 burned 13 of them. About 50 remain.

"There are many, many stories that are preserved out there in the landscape," Iddings said. "If we don't make an active effort to preserve it, it will simply be lost to neglect."

The main property was put up for tax auction in 2009, but got no takers. The county says it can't afford to buy or restore it.

"There is no easy solution. It is stuck in time, isolated and contaminated," said Reb Monaco, a retired teacher and former San Benito County supervisor.

So the orange water flows. And each year, a few more vandals shoot the old buildings, a few more curious motorcycle riders zoom by, and New Idria slowly fades away.

"California's entire history has been boom and bust, starting with the Spaniards," Monaco said. "It was cattle and hides, then gold, then early Hollywood, then defense, then Silicon Valley. We have always been a boom-and-bust state. New Idria is part of that."