Updated

This farming village east of Mosul was turned into a bunker during more than two years of Islamic State rule: A network of tunnels and cramped living quarters betrays an extremist group increasingly forced to operate underground by a punishing air campaign and mounting territorial losses.

Wrested from IS control on the first day of the offensive to retake Iraq's second-largest city, Badana offers a glimpse of the battle ahead. Above ground, walls were shredded by airstrikes and artillery, homes were stained black with soot and the buildings still standing had been looted.

Below ground, bags of fresh vegetables lay on the floor of a cooking area and a bowl of eggs sat beside a crude stove, suggesting the fighters managed to maintain supply lines up until days before their defeat.

"They spent their lives in these tunnels," said Tahseen Muhammed Sharif, a 35-year-old Kurdish fighter who said the Kurdish forces who drove the militants out of the village also found ammunition inside the tunnel network, which they seized.

"I can't imagine living like this," he added, sifting through kitchen refuse beside a pot of chickpeas still sitting on the stove. "There is a definite difference between us and them — their behavior, it's outside human behavior."

A small unit of Iraqi Kurdish fighters tasked with holding the territory in and around Badana, were camped Tuesday in a field behind a row of armored vehicles on the village's edge. While free of IS fighters, the area remains littered with dozens of booby-trapped explosives. Kurdish fighters moving along the narrow village roads stuck to paths they had already used and walked in single file.

When Iraqi forces reach Mosul, Patrick Martin of the Institute for the Study of War in Washington said they should expect to see similar complex defenses like the tunnel networks and booby-trapped explosives in Badana, but on a much greater scale.

"They're making sure that whenever the operation to retake the city commences it will be extremely difficult for the security forces to do so," Martin said, adding that while there are reports of some IS fighters fleeing Mosul, the group has also displayed a willingness to defend the city by mobilizing car bombs, suicide bombers and building trenches.

When IS fighters moved into the territory around Mosul more than two years ago, the group attacked with convoys that traversed the open desert and held parades in the city center. Now, faced with punishing airstrikes by the U.S.-led coalition, the fighters have been forced to change tactics, melting into civilian populations and building networks of tunnels under residential areas so they could move without being seen from above.

After a string of victories over the past year, Iraqi ground forces have pushed IS out of more than half the territory the group once held in Iraq, with close support from the U.S.-led coalition. Now, with the launch of the campaign to retake Mosul, the extremists' main stronghold, Iraqi forces are again operating under coalition air cover.

During the first day of the operation, the most complex for Iraq's military since the withdrawal of U.S. troops in 2011, Kurdish forces say they retook nine villages and pushed the frontline back eight kilometers (five miles).

But like Badana, those villages were almost completely empty of civilians, allowing coalition warplanes to largely clear the territory from the air.

In the center of the village on Tuesday, a group of Kurdish fighters gathered around the bodies of two IS militants killed in an airstrike a day earlier, some crouching down to snap selfies.

Lt. Col. Fariq Hama Faraj said he and his men celebrated their victory the day before and have since received orders that they will not advance any further in the Mosul fight.

"Our task if finished," he said, adding that he doesn't believe this will be the last time he fights the Islamic State group.

"They will come back with a new name and they'll be more extreme and more barbaric," he said, ducking a downed power line as he walked through the ruined village back to his camp.

"If you look to the history of these organizations we see that each one is more extreme than the last."