By Mukesh Gupta and Krista Mahr

PATHANKOT, India/NEW DELHI (Reuters) - Indian security forces battled into Sunday evening to secure an air base near the border with Pakistan, a day after a militant attack that has killed seven military personnel and wounded another 20.

As night fell, it was unclear whether two or more militants were still at large after Saturday's pre-dawn raid on the Pathankot air base in northwestern Punjab state. Four attackers have been confirmed killed.

"The area cannot be declared fully sanitized," Air Marshal Anil Khosla told a news briefing in New Delhi.

Home Secretary Rajiv Mehrishi told reporters he hoped the two believed still to be at large would be "neutralized" overnight. Without recovering their bodies they could not be confirmed dead.

That contradicted earlier statements by home ministry and army officials who, speaking on condition of anonymity, said the two holdouts had been killed.

The attack by gunmen disguised as soldiers came a week after Prime Minister Narendra Modi made an unscheduled visit to Pakistani counterpart Nawaz Sharif in an effort to revive talks between the nuclear-armed neighbors.

Officials said the attack bore the hallmarks of previous suspected assaults by Pakistan-based militant groups, underscoring the fragility of recent efforts to revive bilateral talks between the often uneasy neighbors.

There was no immediate claim of responsibility.

Pakistan has condemned the attack and said it wanted to continue to build on the goodwill created by the impromptu meeting between Modi and Sharif last month.

MORE SHOOTING

Gunfire continued into the evening as security forces hunted the remaining attackers in the Indian Air Force base, a sprawling compound that lies just 25 km (16 miles) from the border with Pakistan.

In a TV briefing from Pathankot, Air Commodore J.S. Dhamoon said the attackers had burst into a guards' mess at the air base, where they were preparing breakfast on Saturday morning.

Story continues

A guard chased after one of the attackers and killed him in the struggle, only to be shot dead by a gunman's bullet. The other three attackers were neutralized in the late afternoon, said Dhamoon.

Indian leaders had already praised the armed forces for their heroism in Saturday's shootout, with Modi saying they did not let the "enemies of humanity" who attacked the base succeed.

But that appeared premature on Sunday, as shooting broke out after midday, sparking a renewed manhunt on the base, from which Indian Air Force MiG-21 fighter jets and attack helicopters fly.

Modi returned from a tour of southern India to chair a high-level meeting with his national security adviser and foreign policy team, the government press office said.

Military trucks were seen entering and exiting the walled compound throughout the day, including a demining vehicle. Dozens of security guards continued their vigil, while protesters shouted slogans and burned a Pakistani flag nearby.

One of the Indian security men killed in the attack was Subedar Fateh Singh, who won gold and silver medals in the first Commonwealth Shooting Championships held in 1995, the National Rifle Association of India said.

BORDER SECURITY

The breaching of the base's defenses has raised questions about lax security on the international border in Punjab, which is a known route for drug smugglers and is less closely guarded than the disputed frontier running through Kashmir.

Five of the seven Indian military reported killed served in the Defence Security Corps, a unit staffed by veterans no longer in active service.

"The casualties were unacceptably high," said Nitin Gokhale, a defense analyst and journalist who said that intelligence on a possible attack had not been passed on in time to alert sentries at the base.

Police have said the gunmen had earlier hijacked a police officer's car and driven it to the base. It took 12 hours for information on the hijacking to be circulated, according to news reports, allowing the attackers to keep the initiative.

In New Delhi, two trains were delayed early on Sunday amid heightened security concerns after officials received information about a possible bomb threat on an intercity train, railways spokesman Neeraj Sharma said.

Trains were deemed safe and were running on schedule by mid-morning, Sharma said.

(Reporting by Mukesh Gupta in Pathankot, and Krista Mahr, Paritosh Bansal and Rupam Jain Nair in New Delhi; Writing by Douglas Busvine; Editing by Christopher Cushing and Susan Thomas)