Gracia, 54, and his diving partner, Guillem Mascaro, left a rope that day, according to the BBC. But something severed it, leaving them lost and with a dwindling amount of air in their oxygen tanks.
"We can only guess some rocks had fallen on it," Gracia said, noting that the pair spent about an hour searching for the rope to no avail.
Their only saving grace was their knowledge of an air pocket in the cave system that would allow them to regroup and formulate a plan without using all their supplemental oxygen.
And so, with only enough oxygen left to allow one of them to leave, they decided Mascaro would go for help. The two settled on a route that had been previously mapped, but it was long and risky. And because of the frantic searching for the guide rope earlier, a significant amount of silt was kicked up into the water, making it hard to see.
"It was like diving in a bowl of cacao," Mascaro later told Diaro de Mallorca.
After Mascaro took off, Gracia's next challenge was to maintain his sanity while breathing the cave air, which had a much higher proportion of carbon dioxide compared to surface air. According to the National Institute of Health, carbon dioxide acts as an asphyxiant, meaning the more you breathe in, the less it allows your body to absorb the oxygen in the air.
"Exposure can also cause dizziness, headache, sweating, fatigue, numbness and tingling of extremities, memory loss, nausea, vomiting, depression, confusion, skin and eye burns and ringing in the ears," the institute says.
Gracia, who suspects he was breathing air saturated with up to 5 per cent carbon dioxide compared to surface air, which averages just .04 per cent, experienced some of these symptoms, as well as hallucinations, as he struggled to survive.
He told Diario de Mallorca in April that he spent most of his time in complete darkness, using his flashlight only sporadically to save batteries. He needed the light to be able to scoot down the rock where he sat in the 80-by-20-by-12m space to retrieve fresh drinking water that he skimmed from the top of the cave pool's surface. He had trouble sleeping the longer he was down there, preoccupied with thoughts of his 15-year-old son and 9-year-old daughter, as well as the possibility of his own death.
"When [rescue workers] find my corpse, they won't even be able to get it out of here," he recalled thinking at the time. "The pathways around this cave are very convoluted and it will be impossible to handle an inert body. Literally, I was buried alive."
According to the group International Underwater Cave Rescue and Recovery, more than 475 divers have died on cave expeditions worldwide since 1950. The exact number is unknown, however, because not all fatalities are reported.
Fortunately Gracia was not added to that tally as help eventually arrived.
"I thought it was another hallucination," he told the BBC of spotting a light underwater. "But then I realised it was real and I saw a helmet emerging."
Gracia was supplied with more oxygen and led out of the cave, where he met Mascaro, who made it out, too. Suffering from symptoms of hypothermia, Gracia spent a night in the hospital, where he was also given supplemental oxygen to recover from the damage done by breathing so much carbon dioxide.
Gracia didn't remain on land for long, however. When he recovered, he decided to go back into the water, and, in fact, it sounds like he never thought twice about ditching his dangerous hobby.
"Knowing the cave system under Mallorca is an important job," he told Diario de Mallorca shortly after his rescue. "Life goes on and we have to move on."