This article is from the archive of our partner National Journal

The words were important. But the music and the tone were the most striking parts of Tuesday's White House meeting between President Obama and Afghan President Ashraf Ghani. In stark contrast to the last time an American president met with an Afghan leader, Ghani hit all the right notes, thanking U.S. taxpayers, lauding the sacrifice of U.S. troops, and pledging that he is ready to take the lead and assure that all that America has done was not in vain.

The result was a crucial relationship back on track and lots of smiles at the White House, where officials are still struggling to forget Ghani's mercurial and difficult predecessor, Hamid Karzai.

At the beginning of his 14 years in office, Karzai took the West by storm. His colorful tribal tunic and lambskin cap had a Gucci official dub him "the chicest man on the planet today." A London paper called him a "style icon." But his act wore thin with the West.

It was Karzai in 2010 who stormed out of a meeting with top U.S. officials, calling the United States one of three enemies of his country and exclaiming, "If I had to choose sides today, I'd choose the Taliban." And it was Karzai that same year who came to Washington to see Obama and dramatically presented the president with a photo of a poor Afghan woman and her children crouching in terror during a nighttime American air raid. The same Karzai who told The Washington Post last year that his farewell message to the United States was "my anger, my extreme anger."

(RELATED: Obama's Afghanistan Reset)

Tuesday, all that was put in the past. It was time, Obama said, "to begin a new chapter between our two nations." And Ghani was up to the task. Twice, he cited the precise number of American deaths in his country—2,215—as well as the toll of Americans wounded in action—more than 22,000. He brought no pictures of Afghan children cowering in fear from American attacks. Instead, he met with the daughter of an American soldier. "I want to thank her and the fathers of all other American children for ... helping us and standing next to us," he said as Obama nodded.

In a blue-pinstriped suit, white shirt, and subdued gray tie, he could have been any businessman or bureaucrat. But he didn't need Karzai's fashion flair. He knew the right words to say. To all Americans, he said, "You stood shoulder to shoulder with us, and I'd like to say thank you."

And in a remarkable note rarely heard from any foreign leader, Ghani added, "I would also like to thank the American taxpayer for his and her hard-earned dollars that have enabled us."

In case his words were not enough to get the message across, Ghani made sure there were also powerful pictures of him visiting the graves at Arlington National Cemetery as well as meeting with the widow of the only general killed in a combat zone since Vietnam, Army Maj. Gen. Harold Greene, who was slain by an Afghan soldier in 2014. Ghani said the message from Greene's widow is, "She would like the memory of her husband to be preserved by a sustainable Afghanistan that is secure. The 2,215 Americans that have died must not die in vain."

(RELATED: Obama Won't Hear Cheers in India on Afghanistan Policy)

Then Ghani went even further, becoming perhaps the first foreign head of state to publicly state that he was glad his own people were now dying instead of Americans. He said his "most horrible reading of the day" is the Afghan casualty reports. "But, thank God, they're no longer American or European casualties."

Obama could barely contain his satisfaction with the way the talks with Ghani had gone, no doubt recalling the tension that characterized all his meetings with Karzai.

The president spoke of "our reinvigorated partnership with Afghanistan," praised Ghani for his "bold leadership," and was quick to grant Ghani's request for a slowdown in the withdrawal of U.S. troops from his country.

Wednesday, Ghani takes his act to the House chamber, addressing a Joint Meeting of Congress. Again, he is shadowed by Karzai, who charmed the legislators when he addressed them in 2004. But, as it did with the White House, the charm and the wardrobe stopped working with the lawmakers. So Ghani has repair work to do there as well. If he succeeds on Capitol Hill as well as he did with the president, Afghanistan could enjoy critical backing for upcoming aid requests and the impending peace talks with the Taliban.

CORRECTION: The original version of this article misstated the year of Hamid Karzai's address to a Joint Meeting of Congress.

This article is from the archive of our partner National Journal.

We want to hear what you think about this article. Submit a letter to the editor or write to letters@theatlantic.com.