As night slipped over the wheat fields and sandy hills, the blasts and gunfire of the last week had fallen silent. The security guard eased into bed with a faint sense of relief.
From his room near the Doctors Without Borders hospital compound in the center of this bustling northern city, the guard did not hear any sign of hostilities between Afghan forces and Taliban insurgents. The charity hospital was humming, with more than 80 Afghan and foreign staff members treating 105 patients, including a few wounded Taliban fighters.
"Everyone inside the compound was working confidently," recalled the guard, who spoke on condition he be identified only by his middle name, Suhrab. "There wasn't any fighting that night at all. The city was all calm."
Shortly after 2 a.m., Suhrab heard a scream overhead — the unmistakable sound of a warplane — followed by an explosion at the main hospital building, whose white-columned portico sat just a few yards away.
Diving under a desk, he counted 20 more blasts and heard the loud, dull crackling that told him the building was on fire.
Somewhere inside the burning compound, Khaled, a nurse, placed a desperate call to his cousin Abdul Rahim.
"I am dying in a flower bed," Khaled said. "Pray for me."
In the distance, Abdul Rahim could see a faint red glow coming from the hospital complex.
"The Americans are bombing the hospital," a Taliban fighter told him. "Don't go."
The American military's Oct. 3 bombing of the hospital in Kunduz, the only trauma center of its kind in northeastern Afghanistan, killed 22 people and wounded 37.
It has touched off an international outcry, three government and military investigations and, on Wednesday, an apology from President Obama to Doctors Without Borders and Afghan President Ashraf Ghani.
Obama said the facility was "mistakenly struck." But he and other senior officials have left key questions unanswered, chiefly, how American troops on the ground and aboard an AC-130 gunship failed to realize that they were repeatedly bombarding a hospital, one of the best-known landmarks in a city of 300,000 people.
The Nobel Peace Prize-winning medical charity — also known by its French name, Medecins Sans Frontieres, or MSF — established the hospital in August 2011 in a compound formerly occupied by a textile company. The campus of low-slung, whitewashed buildings occupies an area roughly the size of two football fields and is surrounded mostly by empty land, except for a few houses across the road to the east.
As is standard practice in the conflict zones where MSF operates, the group had passed on the hospital's GPS coordinates to military officials in Kabul and Washington multiple times, most recently about four days before the bombing.
As the attack began Saturday, the group again contacted the U.S. and Afghan military personnel with whom they had shared the hospital's location, said Jason Cone, MSF's executive director in the United States.
"We were under the impression that it was being passed up the chain of command," Cone said.
Yet the bombing went on for at least 30 minutes more.
Until then, the trauma center had avoided the worst of the previous week's fighting.
Five days earlier, Taliban militants had launched a swift, multi-pronged assault on Kunduz, the provincial capital, raising their white flag in the central square of Afghanistan's fifth-largest city. It was a triumphal moment for the resurgent militant group, its first takeover of an urban center in the nearly 14 years since the 2001 U.S.-led military invasion drove the Taliban from power.
Advocacy groups have accused the Taliban of storming civilian homes, raiding the offices of local and international aid agencies and abusing residents. As the militants besieged the city Sept. 28, most of the MSF staff hunkered down inside the hospital.
"We were scared," said Suhrab, the security guard. "Everyone was concerned about what the Taliban would do to us."
That afternoon, Taliban fighters reached the hospital gate. Suhrab was among a group of MSF staffers who greeted them at the entrance.
"We opened the door, but they said they didn't have permission to go inside," he said. "They told us to go back in, that it wasn't safe, and that we should continue doing our jobs."
The hospital treated 22,000 patients and performed more than 5,900 surgeries last year, MSF says. It enjoys an excellent reputation in Kunduz, where the only other major medical facility, a 200-bed hospital, is ill-equipped and short-staffed. MSF has a policy of admitting all patients, even combatants, as long as they shed their weapons at the hospital gate. Both Afghan soldiers and Taliban militants have received care, the group says.
"Once a combatant is wounded, they are a civilian," Cone said. "We treat anyone who is a victim of a conflict, regardless of politics, religion, ethnicity. That's what we do."
MSF staff in Kunduz said that several wounded Taliban fighters were brought to the hospital during the course of the clashes, but without weapons. They would be handed over by colleagues at the front gate and, like other patients, received occasional visitors, including Taliban elders.
"A few times some of their elders would come inside to visit patients and meet with doctors," said Rahimullah, an Afghan doctor at the hospital, who, like many Afghans, has only one name.
"They assured us, 'No one can harm you, you will be safe here,' so we were confident. Everyone was feeling safe inside the compound."
The presence of insurgents in the hospital has sometimes rankled Afghan security forces. In early July, Afghan special operations soldiers entered the facility, reportedly to look for a militant who was being treated there. MSF lodged a protest with the Afghan government.
"It's not the first time we've had issues in various places in Afghanistan," Cone said. "It's always been a challenge to just maintain respect for our medical facilities, and for other organizations as well. ... Absolutely they knew what we were doing."
Sediq Sediqqi, spokesman for the Afghan Interior Ministry, which oversees the police, said security forces are instructed to respect international law.
"Anyone who is wounded has the right to be treated," Sediqqi said. "We've tried to ensure that everyone in our forces understands this."
The bombings occurred at about 15-minute intervals and lasted about an hour, MSF staff members said. The main building, housing the intensive-care unit and emergency rooms, appeared to be the target of the strikes; surrounding buildings sustained less damage.
Some staffers and patients retreated to safe rooms in the compound. In one of them, nurse Lajos Zoltan Jecs helped treat a colleague who staggered in covered with blood.
"In the safe room, we have a limited supply of basic medical essentials, but there was no morphine to stop his pain," said Jecs, in an account provided by MSF. "We did what we could."
About half an hour after the airstrikes stopped, sometime after 3 a.m., staff members slowly ventured outside and began to absorb what had happened.
Jecs peeked into the ICU and saw "six patients were burning in their beds."
Omer, an Afghan doctor who had been in an adjacent building, saw the main hospital building charred black, with fires burning inside. Patients and nurses had suffered severe burns, he said.
"It was a horrible moment," he said. "I couldn't save my own colleagues."
"One of our doctors died on an improvised operating table — an office desk — while his colleagues tried to save his life," MSF International President Joanne Liu said.
Survivors tried to carry the wounded and dead out of the compound. Among those killed were three children who had been admitted the previous evening, after they and their parents had come under fire in their vehicle as they tried to drive out of the city.
Into the carnage walked Abdul Rahim, who had finally gotten past the Taliban checkpoint and come to find his cousin Khaled. He saw dozens of bodies, their eyes closed and heads wrapped in bandages, lying in two rooms as three doctors tried desperately to help.
"You couldn't tell who was alive and who was dead," Abdul Rahim said.
He found the bloodied Khaled, who had been wounded as he tried to run from the pharmacy to the main building during a pause in the bombings. Shrapnel had lodged in his back.
Hospital staffers were able to stop the bleeding, but he needed further treatment. Abdul Rahim called another relative who had a rickshaw, and the three piled in and drove toward the city's other hospital.
Along the way, Afghan security forces stopped them, asking why they were transporting a wounded man in the middle of the night, and accused Abdul Rahim of being a member of the Taliban. When they finally reached the main hospital, Abdul Rahim was shocked again.
The facility was abandoned, with barely a doctor or nurse in sight.
In the days since the attack, one of the single deadliest civilian casualty incidents in 14 years of U.S. combat in Afghanistan, the American military has added to the confusion by changing its account of what happened.
Officials initially said American troops in Kunduz, deployed to help Afghan soldiers retake the city from the Taliban, called in the airstrike because they were under direct fire from insurgents.
Gen. John F. Campbell, the top commander of U.S. and NATO forces in Afghanistan, later revised that account to say that Afghan forces caught in fighting had requested the airstrike, which was approved and carried out by the U.S. military.
Hamdullah Danishi, the acting governor of Kunduz, was quoted as saying that Taliban fighters had been firing rockets from inside the MSF compound.
But if there was firing near the hospital when the U.S. attacked, witnesses and hospital staff members said, they did not hear anything.
"At the time of airstrike there hadn't been any fighting near the hospital at all," said Omer, the doctor. "The night was very calm compared to other nights."
The incident came as a deep blow not just to the victims, their families and MSF, but also to the Afghan government, which had overcome a huge tactical embarrassment and nearly regained control of Kunduz.
"We thought the operation was going well. We were very excited here in Kabul about the partnership with our U.S. friends," said a senior security official in the Afghan capital, who requested anonymity because of the sensitivity of the matter. "This was really unfortunate."
MSF has categorically denied that fighters had infiltrated the compound and has demanded that Afghan officials end the "false charges." The group this week called for an inquiry by an independent commission established under the Geneva Convention, the international laws of war.
"We're not an investigative body. That's why we need this," Cone said. "And we need it to be done by an independent party. We are doctors and we treat patients. That's it."
Khaled, the wounded nurse, was eventually taken to an Italian-run charity hospital in Kabul, where he is recovering. He was one of the first staff members to join the hospital in 2011, his cousin said. MSF closed the facility the day after the bombing; it is unclear whether it will reopen.
"He was so devoted to his work," Abdul Rahim said. "I can't remember a single Eid" — the two holiest celebrations on the Muslim calendar — "where he wasn't at the hospital working."
Special correspondent Latifi reported from Kabul and Times staff writer Bengali from Mumbai, India. Special correspondent Matt Hansen in New York and a special correspondent in Kunduz, who cannot be named for security reasons, contributed to this report.