By Sudarsan Raghavan

The line at the bank was two blocks long and Abdul bin Naji was once again praying for the doors to open. He desperately needed his $60.

With Libya in the throes of a currency crisis, that was the weekly limit for withdrawals. For the past month, though, the bank hadn’t had any cash. That didn’t stop bin Naji and hundreds of others from arriving every night to get a good spot in line.

On this morning, the unshaven airline employee was third from the door. At 10 a.m., the bank still hadn’t opened. “Thirty-two days and no money,” he sighed.

Excruciatingly long bank lines are the latest misfortune for Libyans trapped in a cycle of war and economic upheaval.

Six years after the revolution that toppled dictator Moammar Gaddafi, the mood in this volatile capital is a meld of hopelessness and gloom. Diplomatic and military efforts by the United States and its allies have failed to stabilize the nation; the denouement of the crisis remains far from clear. Most Libyans sense that the worst is yet to come.

Increasingly, decisions that were once mundane are potentially life-

Is it safe to visit parents in a neighborhood across the city? Which car will kidnappers be less likely to notice? Will a $60 bank withdrawal stretch until the next one is available?

Every day, our future is getting darker and darker,” said bin Naji, 57, leaning against an ATM that hasn’t worked in years.

People line up in front of a bank. Because of a currency crisis, banks limit the amount of cash customers can withdraw, and some days they don’t open at all. (Lorenzo Tugnoli/For The Washington Post)

Under Gaddafi, the oil-producing country was once one of the world’s wealthiest nations. Even as the economy struggled in his last years, Libyans enjoyed free health care, education and other benefits under the eccentric strongman’s brand of socialism.

The insecurity that followed Gaddafi’s death has ripped apart the North African country. Rival governments and an array of armed groups compete for influence and territory. The economy is on the verge of collapse. Criminal gangs prey on the vulnerable.

In Tripoli, parliament and other buildings are concrete carcasses, shattered by heavy artillery fire, rocket-propelled grenades and tank shells. Clashes often erupt suddenly, trapping residents in their homes and creating new no-go zones.

A journey through the city revealed how Libyans are adapting to the vicissitudes of the civil war.

A contest for control

In the southern Tripoli district of Salaheddin, a main thoroughfare bustles during the day but is deserted at night.

Surrounded by what was once a typical middle-class enclave, the street has become a focal point of the contest to control the capital. On one side, militiamen aligned with a self-declared, ­Islamist-leaning government operate checkpoints. The other side is overseen by fighters loyal to a U.N.-installed unity government.

By 9 p.m., many residents have locked themselves inside their homes. Gunfire usually starts around that time, residents said. Those who dare to venture out are careful not to bring any valuables.

I leave my iPhone and carry a cheap Nokia,” said Ibrahim el-Worfali, 31, a shop owner. “All these guys have guns and they can do anything they want to you.”

At the western entrance to the city, fighters with the Knights of Janzour, a militia aligned with the unity government, stop and search cars for weapons being funneled to their rivals.

It’s obvious they want to control the capital,” said Mohammed Bazzaa, 29, the militia’s thickset commander, who wore tan camouflage fatigues and stood next to a pickup truck mounted with a heavy machine gun.

One of the militia’s biggest rivals is a group led by Gen. Khalifa Hifter, whose army controls much of eastern Libya. Hifter, who lived in exile in Northern Virginia for two decades, is aligned with a third government based in the east.

He’s another Gaddafi,” said Bazzaa, who fought in the revolution.

But the militia’s primary threat, Bazzaa said, are the fighters from a rival tribe controlling an enclave less than two miles down the main highway between Tripoli and the city of Zawiyah. Last year, they fought fiercely. Now, they are both aligned with the unity government.

The tensions and mistrust, however, still run deep.

They are motivated only by money,” Bazzaa said of his rivals.

Posters in Tripoli’s Martyrs’ Square express opposition to Gen. Khalifa Hifter. (Lorenzo Tugnoli/For The Washington Post)

Not far from the checkpoint, Sulaiman Abu Hallala was kidnapped.

He was pulled from his car by three masked gunmen and taken to a farm outside the capital. Held there for 19 days, he was deprived of his diabetes medication until his family agreed to pay an $11,000 ransom.

I was so scared,” recalled Hallala, a businessman who is in his 80s. “My nephew was kidnapped three months earlier. He was killed after we paid the ransom.”