By Missy Ryan
FORWARD OPERATING BASE SHARANA, Afghanistan (Reuters) - The United States and its allies are winning in Afghanistan, the U.S. defense chief said on Wednesday, despite spreading violence, a resilient insurgency and uncertain prospects for a peace deal the West had hoped might end a decade of war.
"I really think that for all the sacrifice that you're doing, the reality is that it's paying off," Defense Secretary Leon Panetta told U.S. soldiers at Forward Operating Base Sharana, an outpost in Afghanistan's eastern Paktika province.
"We're moving in the right direction and we're winning this very tough conflict in Afghanistan."
Panetta struck an optimistic tone during much of his two-day pre-Christmas visit to Afghanistan, where U.S. commanders are charting a course to withdraw most Western forces by 2014 and, they hope, finally conclude a long and costly war.
Panetta's visit to Paktika came as the country's rugged east, where insurgents cross back and forth from lawless areas of western Pakistan, takes on increasing importance following the weakening of the Taliban in its southern heartland over the past 18 months.
"Are there challenges out there? You're damn right there are challenges," Panetta said. "Are we able to take on those challenges? You're damn right we are."
U.S. commanders such as Lieutenant General Curtis Scaparrotti say that President Barack Obama's decision to deploy more than 30,000 extra troops to Afghanistan helped reverse deteriorating security and handed the advantage to NATO forces.
"In the south I believe we have delivered a tactical defeat" to the Taliban, Scaparrotti, who heads day-to-day Afghan operations, told reporters in Kabul. "We still have to consolidate that gain."
Yet many observers see the situation in Afghanistan very differently. The Taliban and their affiliates remain a potent enemy and poor governance, widespread poverty and rampant corruption raise questions about stability.
As the West withdraws, the Obama administration has embraced a political solution to the war. Officials are seeking a peace deal between the government in Kabul and the Taliban, but it is unclear whether the embryonic initiative will flourish.
MORE WORK TO DO
Speaking later in the day at a news conference with Afghan President Hamid Karzai, Panetta said high-profile attacks and other violence were likely to continue, but the security trajectory remained positive.
"We have not won; we have not completed this (mission), but I do believe we are in the process of making significant progress here. Clearly we have seen reduced violence ... We have seen our ability to weaken the Taliban significantly," he said.
"The cooperation of the U.S. and NATO forces with the Afghans has brought Afghanistan stability overall... What we have not done fully yet is to provide individual security to the Afghan people," Karzai said following a bilateral meeting.
U.S. officials are hoping to conclude a strategic partnership agreement with Afghanistan that would lay out, in principle, a U.S. military presence after 2014. But that document has been held up by disagreement over military night raids - which Karzai wants to end but which Western military officials say are critical - and other issues.
Perhaps the biggest challenge to the U.S. strategy in Afghanistan lies in Pakistan, where there is heavy insurgent activity along the colonial-era border.
Military officials in places like Paktika say insurgents are weaker than they once were, but their frustration is palpable as they grapple with a flow of fighters and weapons from across the long, mountainous border.
Tension between Pakistan and the United States has spiked since NATO aircraft killed two dozen Pakistani soldiers along the border last month in an attack NATO described as a "tragic, unintended incident." Pakistan shut down a key NATO supply route in retaliation and refused to cooperate with an investigation.
That is unwelcome news for the likes of Colonel Edward Bohnemann, who commands U.S. troops seeking to secure Paktika province's 380-km (236-mile) border with Pakistan.
Because they cannot entirely choke off insurgent traffic across the unmarked, remote frontier, they have set up layers of defenses including Afghan border guards and NATO soldiers.
"There are too many goat trails, too many small roads to say we're going to put a hard stop (to insurgents) at the border," he said.
(Editing by Robert Birsel and Mark Trevelyan)