Golden Ray, a 656-foot ship that caught fire off the Georgia coast, overturned with 24 crew onboard

All 24 crew members of an overturned cargo ship that caught fire off the Georgia coast over the weekend have been rescued, with the final four pulled out by Monday evening after being trapped for more than a day, the U.S. Coast Guard said.

Amid the initial chaos before sunrise Sunday, the Coast Guard was able to rescue 20 of the 24 people on board the Golden Ray, a 656-foot ship that was leaving the Port of Brunswick in St. Simons Sound with 4,000 vehicles when it listed to one side and tipped over.

But the fire on board, as well as the instability of the Golden Ray's cargo, made conditions too risky for additional rescue missions until Monday.

In a video the Coast Guard posted to Twitter, rescuers clapped and cheered as the final man emerged from the ship, climbing up a ladder while secured with ropes.

#BreakingNews Salvage crews have have made contact with crew members in the #GoldenRay. Conditions unknown. Extraction being planned. #HappeningNowpic.twitter.com/wPdKfgqBdN - USCGSoutheast (@USCGSoutheast) September 9, 2019

"Operations will now shift fully to environmental protection, removing the vessel and resuming commerce," the Coast Guard's Seventh District tweeted after announcing that the last four South Korean members of the crew were safe. The ship had 10 South Korean and 13 Filipino crew members and an American pilot, The Associated Press reported, citing South Korea's foreign ministry.

The Golden Ray is owned by South Korean firm Hyundai Glovis, the AP reported.

On Monday afternoon the Coast Guard rescued three more people but a final crew member was stuck behind glass in an engineering control room.

Coast Guard Sector Charleston's Capt. John Reed said the three rescued crew members, who were receiving medical care and in "relatively good" shape, spent about 35 hours trapped amid temperatures that Reed said were "a lot hotter" than the 120-plus degrees teams experienced outside the vessel, which was smoking and had visible flames as rescuers arrived. Two were able to crawl out of the ship onto a boat, Reed said.

Authorities made the rescue after hearing "tapbacks" from the trapped crew throughout the night - signs of life that gave officials new motivation and helped them pinpoint the crew's location on the large ship, according to Reed.

"Knowing that the people were alive made all the difference," Reed said.

The South Koreans were in a propeller shaft room near the ship's stern, Coast Guard Lt. Lloyd Heflin told the Associated Press.

Complicating matters was the lack of power to the ship and its maze of compartments and watertight doors, Coast Guard Petty Officer 1st Class Luke Clayton told CNN. And a language barrier made it difficult for the initial rescue team to communicate with the trapped crew members, Heflin told AP. But Reed said Monday afternoon that an engineer was able to speak with them in Korean.

Teams drilled a two-by-three-foot hold in three-inch increments and were able to pass food and fresh water to the three now rescued, according to the Coast Guard.

Reed said authorities are still working to address ongoing threats to the environment and the Port of Brunswick near the overturned ship.

The 20 people initially evacuated from the ship - 19 crew members and a U.S. harbor pilot - were lifted from the tilting ship by helicopter and lowered into boats using fire hoses, officials told CNN.

The National Transportation Safety Board said two of its investigators have been assigned to review the circumstances that led to the ship overturning.

