Down the deep and dark passageways of Mexico's mysterious underwater labyrinth, known for preserving incredible Maya relics, dwells a staggering wealth of microbial life.

For the first time, researchers have sampled some of the more inaccessible extremes of these mapped cave systems, which cover 1,500 kilometers (932 miles). They found thriving microbial metropolises within the layers of freshwater sitting on top of the saltwater intruding from the Gulf of Mexico.

Mexico's Yucat√°n carbonate aquifer is one of the most extensive groundwater systems on Earth and only some of it has been properly mapped. Its numerous sinkholes, some of which are toxic, as well as its complex web of subterranean tunnels, and its massive caves, provide drinking water for ten million visitors each year and two million locals.

"These are incredibly special samples of underground rivers that are particularly difficult to obtain," notes geobiologist Matthew Selensky, who worked on the research while at Northwestern University.

As well as a significant salt gradient, life in these natural water catchments must contend with stratified levels of temperature, acidity, light, and different concentrations of nutrients.

Using 78 water samples collected by a daring team of cave divers, who are part of the local dive center, Under The Jungle, the geobiologist Magdalena Osburn from Northwestern University and her team sequenced genes to establish the abundance of different microbe species.

The researchers found 4,183 unique sequences representing 917 different families of microbes, with unique patterns of species in different areas.

"The microbial communities form distinct niches," says Osburn. "There is a varying cast of characters that seem to move around, depending on where you look. But when you look across the whole data set, there's a core set of organisms that seem to be performing key roles in each ecosystem."

Wherever they looked across the 12 sites they sampled, the researchers observed the same family of bacteria: Comamonadaceae.

These tiny, rod-shaped organisms are well known in soil and water environments. They require oxygen and use swishy tail-like flagella to move about.

"It seems that Comamonadaceae performs slightly different roles in different parts of the aquifer, but it's always performing a major role," explains Osburn. "Depending on the region, it has a different partner. Comamonadaceae and its partners probably have some mutualistic metabolism, maybe sharing food."

These partners include nitrogen-eating bacteria like Gemmataceae and other species like Methyloparacoccus, which make use of methane as well as the more familiar organic-eating microbes, depending on the immediate environmental conditions.

In turn, these players likely influence the distinct water chemistry seen in the different areas of the aquifer.

"This underground river system provides drinking water for millions of people," notes Osburn. "So, whatever happens with the microbial communities there has the potential to be felt by humans."

Due to its isolated nature, much of the aquifer's ecosystems remain relatively untouched compared to more exposed environments above. Yet pollutants are still seeping into this complex system, including fertilizers, pesticides, drugs and personal care products.

A recent review discovered only 13 of the 173 examined naturally formed sinkholes were free of pollutants, highlighting this unique place is also vulnerable to human activity, despite its isolation.

This research was published in Applied and Environmental Microbiology.