An ancient species of flying pterosaur with a bizarre, butterfly-like head has been unearthed in Brazil in a mass "graveyard" of 50 winged reptiles, according to a new study.

The newfound dinosaur species, Caiuajara dobruskii, lived about 80 million years ago during the Cretaceous period, sporting wingspans from two to eight feet (65 to 235cm).

Led by study author Paulo Manzig from Universidade do Contestado, Brazil, the research team discovered the bones of nearly 50 of these reptiles in a single bone bed, providing the strongest evidence that these flying dinosaurs were social animals. The mass grave of bones - crammed into an area of just 215 square feet (20 square meters) - could also indicate that hundreds of young and adult individuals perished at the site.

"Based on the available information, we conclude that Caiuajara dobruskii lived in colonies around an inland lake situated in a desert," co-author Dr. Alexander Kellner, from Federal University of Rio de Janeiro, said, according to Mail Online.

"The presence of three main levels of accumulation in a section of less than one meter suggests that this region was home to pterosaur populations for an extended period of time," he added.

Though pterosaur fossils have previously been found in northern Brazil, this is the first indication that they lived in the southern part of the country.

C. dobruskii also have several facial features that differentiate it from all other members of the pterosaur clade. It had a large bony crest on the top of its head that changed from being small when it was young, to large and steep in adults.

According to the authors, the bone analysis suggests this species was gregarious, lived in colonies and may have been able to fly at a very young age.

Researchers aren't quite sure how these dinosaurs died, but speculate that weather conditions and storms are to blame.

"The causes of death remain unknown, although similarities with dinosaur drought-related mortality are striking," Kellner said. "However, it is also possible that desert storms could have been responsible for the occasional demise of these pterosaurs."

The study findings were published in the journal PLOS ONE.