President Trump’s official rationale for initiating the first American airstrikes against the Assad regime in Syria struck humanitarian notes, complete with reference to the “beautiful babies” who “were cruelly murdered in this very barbaric attack.” Mark Landler of the New York Times reports that “Trump’s heart came first” in ordering the attack. On its face, that’s a striking turnaround from a campaign season track record that was not only generally supportive of Bashar al-Assad but much more broadly dismissive of humanitarian considerations in general.

This is the Trump who once mocked the very notion of international concern about poison gas attacks. "Saddam Hussein throws a little gas,” he said at a December 2015 rally, “everyone goes crazy, 'oh he's using gas!'"

But Trump’s sudden conversion reflects less of a turnabout on the question of humanitarianism than the president finally accepting the logic of his broader strategic worldview. Since taking office, Trump has repeatedly readjusted rhetoric and policy to create closer alignment with America’s traditional allies among authoritarian Sunni regimes in the Middle East — Saudi Arabia, Egypt, the United Arab Emirates, etc.

The change we have seen, thus far, has mostly been relatively subtle, reflecting in part the fact that President Obama’s efforts to distance the United States from these regimes were, themselves, quite equivocal. And Trump has not yet gone full-tilt against Iran in a way that would signal a true reversal from Obama’s approach, which Gulf allies saw as too soft on Tehran and too quick to turn a blind eye to Iranian aggression throughout the region.

Still, the overall pattern is unmistakable and represents critical context with which to understand Trump’s turn against Assad. Embracing the Gulf states’ worldview would dramatically improve Washington’s relationship with some of its closest regional allies. That's the good news. The bad news is that it risks drawing the United States deeper into a series of conflicts around the region.

Obama was ambivalent about Sunni authoritarians, Trump enthusiastic

In a practical sense, the United States under Barack Obama remained a fairly steadfast and loyal ally of the traditional Persian Gulf monarchies and their allies in the Egyptian military. But Obama’s diplomatic engagement with Iran profoundly worried these allies, who saw in his nuclear diplomacy inklings of a broader strategic goal of shifting the United States away from its traditional alliances with Gulf powers and closer to Tehran. Egypt, meanwhile, felt slighted by Obama’s fixation on human rights abuses there; the president’s refusal to give an Oval Office meeting to Egypt’s leader infuriated many in Cairo.

Conversely, Obama was often quite rhetorically critical of America’s allies, telling Jeffrey Goldberg that the Saudis had to “find an effective way to share the neighborhood” with Iran and speaking famously of a desire to “pivot to Asia” and have less American engagement in the Middle East. Members of his team liked to grouse off the record that the Washington think tank community was “Arab-occupied territory,” implying that Gulf state money was exerting a systematic distorting influence over the Washington foreign policy elite.

The late-term blowup over Ben Rhodes’s dismissive attitude toward “the Blob” of Washington foreign policy commentators was part of this tension, and Gulf diplomats were generally enthusiastic about the prospect of Obama being replaced in office by Hillary Clinton, who they thought would lack Obama’s ambivalence.

Like everyone else, they were taken aback by Trump’s win, but during the transition they found him surprisingly amiable. America’s traditional Middle Eastern allies notably refrained from criticizing Trump’s travel ban, even while his domestic political opponents and several federal judges slammed it as anti-Muslim discrimination. And while Trump’s bilateral meetings with democratically elected leaders of American allies in Europe and Asia have generally been awkward, he’s gotten along swimmingly with Sunni authoritarians, who appreciate his relaxed attitude on human rights and his anti-Iranian instincts.

Trump has shifted toward the Gulf states

Trump’s shifts toward the Gulf states’ worldview have been multifaceted.

On the one hand, he has dropped some of his own campaign rhetoric on Israel to bring his policies more in line with the longstanding American status quo. The US Embassy is not moving to Jerusalem anytime soon, if ever, and Trump is putting pressure on the Israelis to show restraint in terms of settlement building. The Gulf states are increasingly comfortable with Israel on a geopolitical level as a tacit ally against Iran, but still see these kind of symbolically resonant issues as critical to the domestic viability of their own pro-American policy orientation.

At the same time, Trump has changed American policy more in the direction of Gulf preferences in several directions. He's ended Obama’s symbolic refusal to host Egypt’s military regime at the White House (Borzou Daragahi reports for BuzzFeed that though the shift here is entirely rhetorical, the practical consequences for Egyptian activists are quite real), intensified American military support for a brutal Saudi-led war in Yemen against what the Saudis see as an Iranian proxy force, and lifted human rights conditions on sales of military jets to Bahrain.

The missile strikes in Syria, which on one level is narrowly about chemical weapons use, fit more broadly into this story of realignment.

Gulf states have long urged the US to strike Assad

The Gulf states have long been the main backers of the armed opposition to the Assad regime, seeing the Syrian civil war as part of the larger regional conflict with Iran and perhaps implicitly viewing a proxy war against the regime in Damascus as a useful outlet for domestic discontent.

Throughout the years-long conflict, the Gulf states have been not only the main source of material support for anti-Assad forces but also key drivers of political pressure inside the United States and other Western countries for anti-Assad strikes.

Obama, typically, took an ambivalent viewpoint on the conflict, signaling conceptual agreement with the Gulf states on the need for regime change and providing logistical support to rebel groups while resisting the tug toward direct military involvement. That tug, in turn, is precisely one reason Obama was always reluctant to engage in even limited anti-Assad strikes, which he feared would lead to mission creep and steady escalation of American involvement.

Trumpism: short-term gain, long-term pain

In the short term, Trump’s shifts toward the anti-Assad position of the US’s Sunni allies have quieted talk that the president would radically reshape American foreign policy to build closer ties with Russia. Moscow is Assad’s primary foreign ally, and has already harshly condemned the US strike and promised new military aid to Assad.

It’s true that abandoning human rights priorities in Egypt, Yemen, and Bahrain will earn Trump criticism from some aid groups and Democrats, but Obama’s halfhearted efforts in those areas essentially earned him criticism from both sides.

Trump, by taking some action against Assad, is at least making some people happy. US military commanders, meanwhile, are glad that the Trump administration is relaxing White House oversight of military strikes against terrorist targets in Yemen and Somalia while simultaneously seeming to endorse more forceful military action in Iraq.

The risks of this approach are, however, considerable on two different fronts.

On the one hand, there’s the risk of pulling the United States deeper into a regional conflict with Iran that reflects Gulf states’ interests more than America’s.

On the other hand, there’s the long-term viability of a violence-first counterterrorism strategy. Aggressive use of military force plus unvarnished backing for unpopular and corrupt authoritarian regimes is the simplest approach to combating terrorism but also the one most likely to fuel new feelings of militancy and eventually a new generation of terrorists.

That aligns perfectly well with the “counter-jihad” school of thought popular in the Trump administration that views conflict as inevitable and domestic Muslim populations in the United States and Europe as critical sources of weakness.

But it also points to a much darker and more dangerous direction for American policy — one more aligned with Trump’s various efforts at a Muslim ban and his years of Islamophobic rhetoric — than the rosy glow of humanitarianism in which he tried to cloak Thursday night’s strikes.