A 45-year-old woman was killed by an alligator as she walked her dog Monday morning at a Hilton Head Island resort community, authorities said.

Cassandra Cline's death in Sea Pines Plantation marked the second fatal alligator attack in South Carolina in a little more than two years.

Cline was walking her dog by a lagoon near Wood Duck Road about 9:30 a.m. when an alligator attacked her and pulled her under the water's surface, according to the Beaufort County Sheriff's Office. Her body was found inside the lagoon.

The Associated Press reported that she was trying to protect her dog, which was not hurt.

A maintenance worker saw the attack and reported it, Capt. Robert McCullough of the S.C. Department of Natural Resources said.

A forensic autopsy will be done at Charleston's Medical University Hospital in the coming days to determine Cline's cause of death, county coroner officials said.

The roughly 8-foot-long alligator believed to be involved was captured by 11 a.m. and euthanized, McCullough added.

Sea Pines sits on 5,000 acres of Hilton Head Island and includes marshes, forests and 5 miles of beach. Its website says homes there are designed to blend into the area environment that includes 133 bird species and 37 different reptiles.

Officials from Sea Pines Community Services Associates alerted residents about the attack through Facebook, saying neighborhood officials were "extremely saddened by this news." They said Cline was a property owner.

"We are shocked and heartbroken over this loss and are praying for Ms. Cline's family and loved ones during this difficult time," Sea Pines President Bret Martin added in a statement.

Fatal attacks involving alligators are rare in South Carolina; Cline's death was the second in the state's history, McCullough said.

The first recorded fatality happened in July 2016, after 90-year-old Bonnie Walker wandered away from an assisted-living facility, Brookdale Charleston, in West Ashley.

Investigators think that Walker, who had dementia, fell into a nearby pond, drawing the attention of an alligator that killed her. The county coroner attributed her fatal wounds to the animal.

The Department of Natural Resources noted that single bites are usually made by alligators less than 8 feet long, but most incidents occur in Florida.

"Alligators usually are not aggressive toward humans (and) unprovoked attacks by alligators smaller than 5 feet are rare," the department's website says.

Although the attacks are not common, DNR officials said potential prey are most vulnerable to an attack while in bodies of water or at the water's edge. But the incidents are not limited to areas close to water as gators have been known to "occasionally make forays over land in search of new habitat, mates or prey."

Correction: An earlier version of this story incorrectly stated who initially saw the attack. A maintenance worker witnessed it, authorities said.

Reach Michael Majchrowicz at 843-607-1052. Follow him on Twitter @mjmajchrowicz.

Michael Majchrowicz is a reporter covering crime and public safety. He previously wrote about courts for the Daily Hampshire Gazette in Northampton, Massachusetts. A Hoosier native, he graduated from Indiana University with a degree in journalism.