ISTANBUL — It was a dream gig for a young guy from an economically depressed part of southwest Iran: Live in cosmopolitan Istanbul and guide tourists from busy Ataturk Airport to their hotels. Just before 10 p.m. on Tuesday night, Radmehr Sepantan was standing outside the arrivals hall waiting for another routine batch of arrivals from Tehran. That’s when the first bomb struck.

“It exploded outside the exit door,” said Radmehr Sepantan, a 31-year-old from the Iranian city of Abadan. “I went toward it because I saw some people covered in blood and wanted to help.”

It was an impulse that may have saved his life during an attack that involved three suicide bombers and plunged Europe’s third busiest airport into a night of death, chaos, and terror.

As the bloodstains were washed away from the floors and broken glass and debris hauled off in the morning hours, the human toll rose to at least 41 killed and 239 injured.

For Turkey, the attack marked a new watershed for violence in a year that has turned a country once known for its thriving economy into a logistics hub and battlefield for all the Middle East’s wars — driven by politics, tinged with sectarian and ethnic animosities — as well as a magnet for terrorism. In the last year, at least 671 people were killed and 1,719 people were wounded in 434 terrorist attacks by Kurdish separatist and Islamist extremists, according to statistics compiled by Verisk Maplecroft, a risk management consultancy.

No one has claimed responsibility for the airport attack yet. But Turkish officials and security experts said it bore all the hallmarks of ISIS, which is fighting a U.S.-led coalition that includes Turks to hold onto its self-proclaimed caliphate straddling northern Syria and Iraq. The high-profile attack puts Turkey under increased pressure at a time when it grapples with multiple threats and also demonstrated what many officials and security experts consider ISIS’s continued potency even as it loses operatives to arrests and territory to the U.S.-led coalition.

"It's probably true that it was committed by ISIS,” said Menderes Cinar, a political scientist at Istanbul’s Baskent University. “We notice a shift. Before, they were targeting Kurds. Now, since the government has finally turned on ISIS, they target the state and the Turks."

Defne Karadeniz / Getty Images

A relative of a victim waits dejectedly outside a hospital in Istanbul.

Sepantan and the large collegial crowd of tour guides, travel agents, and drivers who make their living off off the passengers at the arrivals lounge of Ataturk rushed to help those hurt in the bombing outside the terminal. “We were dragging the bodies one by one, wounded, dead,” he said.

That’s when the second bomb hit, this time inside the terminal. “It was very terrifying,” he recalled.

Elsewhere in the gleaming terminal, a third suicide bomber had somehow entered, firing off an assault rifle at passengers before he was shot by one or more security officials, according to a video posted online. The extraordinary sequence, captured on closed-circuit television, showed him lying on the ground, his weapon fallen from his hands as a security official approached him, shot him several times, and scampered off before he blew himself up. Turkish officials say the heroic security official survived the attack.

Iraqi journalist Steve Nabil and his wife were transiting through Istanbul on their honeymoon when the attack took place.

“My wife was sitting at Nero cafe while I went to the third floor to get food from Sbarro,” he wrote in an account on Twitter. “Heard shots. Ran fast toward her. Came down the stairs to see the court empty and the terrorist firing toward us.”

The two managed to break into a hair salon and find shelter inside a closet. “The screams of the victims and the blood everywhere didn’t allow us to sleep,” he wrote. “This child stared at the blood in shock. Longest 45 minutes ever.”

Other passengers, including a Western diplomat who had arrived in the city from the capital, Ankara, described panic as they were hustled from one section of the massive airport to another by confused Turkish security officials.

“These attacks, they are a failure of Turkish policy.”

"Everything was OK, and then all of a sudden there was an explosion and everyone panicked, and then there was another explosion and then everyone really panicked,” said Trice, 36, a businessman from the Democratic Republic of Congo traveling to Istanbul with his brother. “We didn't know which way to go, because we were afraid there would be more explosions.”

In recent years, Ataturk has become a symbol of Turkey’s global ambitions, hosting one of the fastest-growing airlines in the world, with connections spanning Europe, Africa, Asia, and North America. Named after the secular founder of Turkey, Mustafa Kemal Ataturk, who dissolved the caliphate in 1924, the airport must have made an enticing target for ISIS. Last August ISIS released a video calling on Turks to rise up against President Recep Tayyip Erdogan and help conquer Istanbul.

“The Islamic State is at war with the Turkish state,” said Anthony Skinner, a Turkey specialist at Verisk Maplecroft. “The Turkish government and Istanbul, the former capital of the Ottoman Empire, have immense symbolic value to the fanatical armed group.”

Ataturk is one of the most well-guarded airports in the world. Passengers and visitors are searched and their bags scanned by x-rays even before entering either the arrivals or departures halls. As the U.S. experience in Iraq has shown, adding layers of security guards and checkpoints does little to protect civilians from terrorists determined to inflict maximum harm.

“The Istanbul Ataturk Airport attack could have been far more lethal had it not been for existent security measures and the response of airport security,” said Skinner. “No security apparatus would be able to effectively contain and neutralize the threat faced by Turkey today.”

Ozan Kose/AFP / Getty Images

Ataturk Airport in Istanbul.

But security experts pointed to broader intelligence and political failures that may have contributed to the security threats now engulfing the country. On Wednesday, Turkey announced it had shelled 15 ISIS positions in Syria a day earlier. But Turkey originally turned a blind eye to foreign fighters transiting through the country to join rebel groups fighting Bashar Assad’s regime in Syria. Some of those fighters later joined what became ISIS.

“These attacks, they are a failure of Turkish policy,” said Cinar. “At the beginning, they focused on other issues instead of focusing on ISIS.”

Turkey finds itself in a uniquely vulnerable geographic and strategic position. This week, faced with multiple threats, it announced resolutions to a longstanding dispute with Israel and appeared to make amends with Russia over the downing of a plane in Syria last year. Turkish officials described the moves as part of an effort to signal to the world that Ankara was seeking to minimize tensions with other countries.

“There was an assessment that the regional situation was going to continue to be dire,” said Sinan Ulgen, a Turkey specialist at the Carnegie Endowment for International Peace. “For the foreseeable future, the region is going to continue to generate instability and insecurity. So Turkey could little continue to have these damaged relations.”

Some analysts suggested the attack was linked to the recent Turkish–Israeli diplomatic rapprochement after years of tension over the deaths of nine Turkish activists on a humanitarian mission to Gaza in 2010. Likelier, it was the other way around: The deal with Israel was probably spurred by Turkey’s need for friends during dire times.

What’s more, ISIS likely spent weeks or more planning the airport operation. It required identifying and training three bombers to complete the mission, establishing multiple safe houses for the bombers and logistical supporters, procuring or manufacturing explosives and the automatic weapons used in the attack, and transporting both the bombers and the equipment to Istanbul.

Once the pieces were in place, the cell would have to manufacture the bombs and suicide devices — consistent and effective bomb-making requires substantial skills and effort as well as a safe place that's generally separate from the bombers themselves.

Scholars have puzzled over ISIS’s refusal to take credit for attacks in Turkey while it constantly boasts of other operations across the globe, even dubiously taking credit for killings in which it likely had no operational role. Aymenn al Tamimi, a blogger and a leading expert on ISIS said the group likely wants to punish Ankara for its role in the anti-ISIS coalition, but without forcing the government to pursue a widespread crackdown on the significant assets the group appears to still have inside Turkey.

"They don't want to provoke a more direct Turkish intervention by taking credit for such large-scale attacks," he said in an interview. But the group still conducts a number of attacks in order to "stir up paranoia and fear in Turkey.”

Borzou Daragahi is a Middle East correspondent for BuzzFeed News and is based in Istanbul.