LIMA, Peru (AP) — The earthquake all but flattened colonial Lima, the shaking so violent that people tossed to the ground couldn't get back up. Minutes later, a 50-foot (15-meter) wall of Pacific Ocean crashed into the adjacent port of Callao, killing all but 200 of its 5,000 inhabitants. Bodies washed ashore for weeks.
Plenty of earthquakes have shaken Peru's capital in the 266 years since that fateful night of Oct. 28, 1746, though none with anything near the violence.
The relatively long "seismic silence" means that Lima, set astride one of the most volatile ruptures in the Earth's crust, is increasingly at risk of being hammered by a one-two, quake-tsunami punch as calamitous as what devastated Japan last year and traumatized Santiago, Chile, and its nearby coast a year earlier, seismologists say.
Yet this city of 9 million people is sorely unprepared. From densely clustered, unstable housing to a dearth of first-responders, its acute vulnerability is unmatched regionally. Peru's National Civil Defense Institute forecasts up to 50,000 dead, 686,000 injured and 200,000 homes destroyed if Lima is hit by a magnitude-8.0 quake.
"In South America, it is the most at risk," said architect Jose Sato, director of the Center for Disaster Study and Prevention, or PREDES, a non-governmental group financed by the charity Oxfam that is working on reducing Lima's quake vulnerability.
Lima is home to a third of Peru's population, 70 percent of its industry, 85 percent of its financial sector, its entire central government and the bulk of international commerce.
"A quake similar to what happened in Santiago would break the country economically," said Gabriel Prado, Lima's top official for quake preparedness. That quake had a magnitude of 8.8.
Quakes are frequent in Peru, with about 170 felt by people annually, said Hernando Tavera, director of seismology at the country's Geophysical Institute. A big one is due, and the chances of it striking increase daily, he said. The same collision of tectonic plates responsible for the most powerful quake ever recorded, a magnitude-9.5 quake that hit Chile in 1960, occurs just off Lima's coast, where about 3 inches of oceanic crust slides annually beneath the continent.
A 7.5-magnitude quake in 1974 a day's drive from Lima in the Cordillera Blanca range killed about 70,000 people as landslides buried villages. Seventy-eight people died in the capital. In 2007, a 7.9-magnitude quake struck even closer, killing 596 people in the south-central coastal city of Pisco.
A shallow, direct hit is the big danger.
More than two in five Lima residents live either in rickety structures built on unstable, sandy soil and wetlands, which amplify a quake's destructive power, or in hillside settlements that sprang up over a generation as people fled conflict and poverty in Peru's interior. Thousands are built of colonial-era adobe.
Most quake-prone countries have rigorous building codes to resist seismic events. In Chile, if engineers and builders don't adhere to them they can face prison. Not so in Peru.
"People are building with adobe just as they did in the 17th century," said Carlos Zavala, director of Lima's Japanese-Peruvian Center for Seismic Investigation and Disaster Mitigation.
Environmental and human-made perils compound the danger.
Situated in a coastal desert, Lima gets its water from a single river, the Rimac, which a landslide could easily block. That risk is compounded by a containment pond full of toxic heavy metals from an old mine that could rupture and contaminate the Rimac, said Agustin Gonzalez, a PREDES official advising Lima's government.
Most of Lima's food supply arrives via a two-lane highway that parallels the river, another potential chokepoint.
Lima's airport and seaport, the key entry points for international aid, are also vulnerable. Both are in Callao, which seismologists expect to be scoured by a 20-foot (6-meter) tsunami if a big quake is centered offshore, the most likely scenario.
Mayor Susana Villaran's administration is Lima's first to organize a quake-response and disaster-mitigation plan. A February 2011 law obliged Peru's municipalities to do so. Yet Lima's remains incipient.
"How are the injured going to be attended to? What is the ability of hospitals to respond? Of basic services? Water, energy, food reserves? I don't think this is being addressed with enough responsibility," said Tavera of the Geophysical Institute.
By necessity, most injured will be treated where they fall, but Peru's police have no comprehensive first-aid training. Only Lima's 4,000 firefighters, all volunteers, have such training, as does a 1,000-officer police emergency squadron.
But because the firefighters are volunteers, a quake's timing could influence rescue efforts.
"If you go to a fire station at 10 in the morning there's hardly anyone there," said Gonzalez, who advocates a full-time professional force.
In the next two months, Lima will spend nearly $2 million on the three fire companies that cover downtown Lima, its first direct investment in firefighters in 25 years, Prado said. The national government is spending $18 million citywide for 50 new fire trucks and ambulances.
But where would the ambulances go?
A 1997 study by the Pan American Health Organization found that three of Lima's principal public hospitals would likely collapse in a major quake, but nothing has been done to reinforce them.
And there are no free beds. One public hospital, Maria Auxiliadora, serves more than 1.2 million people in Lima's south but has just 400 beds, and they are always full.
Contingency plans call for setting up mobile hospitals in tents in city parks. But Gonzalez said only about 10,000 injured could be treated.
Water is also a worry. The fire threat to Lima is severe — from refineries to densely-backed neighborhoods honeycombed with colonial-era wood and adobe. Lima's firefighters often can't get enough water pressure to douse a blaze.
"We should have places where we can store water not just to put out fires but also to distribute water to the population," said Sato, former head of the disaster mitigation department at Peru's National Engineering University.
The city's lone water-and-sewer utility can barely provide water to one-tenth of Lima in the best of times.
Another big concern: Lima has no emergency operations center and the radio networks of the police, firefighters and the Health Ministry, which runs city hospitals, use different frequencies, hindering effective communication.
Nearly half of the city's schools require a detailed evaluation to determine how to reinforce them against collapse, Sato said.
A recent media blitz, along with three nationwide quake-tsunami drills this year, helped raise consciousness. The city has spent more than $77 million for retention walls and concrete stairs to aid evacuation in hillside neighborhoods, Prado said, but much more is needed.
At the biggest risk, apart from tsunami-vulnerable Callao, are places like Nueva Rinconada.
A treeless moonscape in the southern hills, it is a haven for economic refugees who arrive daily from Peru's countryside and cobble together precarious homes on lots they scored into steep hillsides with pickaxes.
Engineers who have surveyed Nueva Rinconada call its upper reaches a death trap. Most residents understand this but say they have nowhere else to go.
Water arrives in tanker trucks at $1 per 200 liters (52 gallons) but is unsafe to drink unless boiled. There is no sanitation; people dig their own latrines. There are no streetlamps, and visibility is erased at night as Lima's bone-chilling fog settles into the hills.
Homes of wood, adobe and straw matting rest on piled-rock foundations that engineers say will crumble and rain down on people below in a major quake.
A recently built concrete retaining wall at the valley's head lies a block beneath the thin-walled wood home of Hilarion Lopez, a 55-year-old janitor and community leader. It might keep his house from sliding downhill, but boulders resting on uphill slopes could shake loose and crush him and his neighbors.
"We've made holes and poured concrete around some of the more unstable boulders," he says, squinting uphill in a strong late morning sun.
He's not so worried if a quake strikes during daylight.
"But if I get caught at night? How do I see a rock?"
Associated Press writer Franklin Briceno contributed to this report.
Frank Bajak on Twitter: http://twitter.com/fbajak