This has been an amazing few days. The recent government shutdown may have been the most public and embarrassing defeat for Democrats since election night in 2016.

First, Senate Minority Leader Chuck Schumer, D-N.Y., took on President Trump and Senate Majority Leader Mitch McConnell, R-Ky., and forced the United States government to partially shut down. Then, within three days, Schumer collapsed and accepted the Republican terms for reopening the government.

It is worth exploring what happened and why.

Let me start by stipulating that Sen. Schumer is very smart. In fact, his 2007 book, “Positively American: Winning Back the Middle-Class Majority One Family at a Time,” includes an exceptional explanation of the key management role the Contract with America played in modernizing the House Republican Party. I was so impressed with his insights that I joined him in a National Press Club event to help launch his book.

Schumer is head and shoulders above any other Senate Democrat as a mature national leader. That is why the last weekend has been so fascinating and so informative.

Much of the challenge Schumer will face of the next three years will be in balancing strategies to re-elect moderate Democrats in Trump-supporting states with strategies to mobilize Democratic voters in liberal states.

The activist left of the Democratic Party convinced Schumer that closing the government to force a deal on the “Dreamers” was a clever strategy. They were convinced it would strengthen their popularity with Hispanics to such a degree that they would have a huge advantage in the November midterm elections.

The radical activists were convinced that the elite media’s hostility to President Trump and the emotional support for the Dreamers would guarantee them favorable coverage of their efforts.

What the Democrats had not counted on was President Trump’s ability to brand this as the “Schumer Shutdown.” As Republicans and conservative commentators piled on with the constant repetition of “Schumer Shutdown” on air and on social media, it became impossible for the Democrats to blame the Republicans.

When even members of the elite media began to acknowledge that the Democrats were responsible, the tide was clearly turning.

The second big failure was the inability of liberals to understand how strongly most Americans feel about the United States military and their families.

Schumer would have been far better off to move a one-year appropriation for the Defense Department, thereby protecting our military and their communities.

However, liberal Democrats seem to find it difficult to empathize with those who risk their lives defending America. As a result, the Democrats appeared tone deaf about the American people’s concerns, once it was clear our military was being hurt by the Democratic shutdown.

A narrowly focused effort to help the “Dreamers” would have had a pretty broad majority favoring it. However, pitting the Dreamers against the men and women who serve in our military created an impossible emotional choice for Americans. The Republicans stated their choice quickly, with great intensity.

In fact, one of the things that may have surprised the Democrats was the speed at which the Republican National Committee, the National Republican Senatorial Committee, and others began running ads on social media hammering incumbent Democrats for abandoning the U.S. service members to help non-citizens.

By Sunday, Republicans were convinced the shutdown was playing to their advantage. In the Senate, there are currently 10 Democrats up for re-election in states President Trump carried in 2016. Incumbent senators in places such as Indiana, Missouri, Montana, North Dakota and West Virginia simply could not defend Schumer or their party.

Schumer was facing a crisis. His party was about to split, the president and Republicans were resolute, and the news media was focusing more and more on military families and military preparedness.

Schumer surrendered because there was no realistic path to a better outcome.

His surrender led to a prompt outburst from the radical left-wing of the Democratic Party. Even House Minority Leader Nancy Pelosi, R-Calif., who should have understood the pressure Senate Democrats were facing, spoke out against backing down.

In the House, only 45 Democratic members supported the resolution to reopen the government, while 144 voted against it.

The Democrats are now getting caught up in the same problem the Republicans faced when they were the opposition party. House Democrats come from districts that are much more liberal and much more partisan than the statewide seats Schumer has to win for Democrats to gain the majority in the Senate.

House Democrats can afford to be more liberal and more tone deaf to average Americans because they exist in a much more liberal world than their Democratic Senate colleagues.

Senators, on the other hand, have to run statewide. For the November elections, that means Senate Democrats have to worry about appealing to states that are much more conservative than the typical left-leaning House districts that elected Democrats.

Furthermore, the potential 2020 Democratic presidential candidates who are now serving in the Senate – like Bernie Sanders of Vermont, Elizabeth Warren of Massachusetts, Cory Booker of New Jersey and Kirsten Gillibrand of New York – do not value winning control of the Senate.

These senators value winning control of an increasingly left-wing Democratic base. For them, there is no middle ground. They are always going to publicly oppose moderate or cooperative policies and working with President Trump or Republicans. Their future is with the estimated million people who mobilized for the women’s marches over the weekend and believe in the concept of “resistance” to Trump under all circumstances.

Much of the challenge Schumer will face of the next three years will be in balancing strategies to re-elect moderate Democrats in Trump-supporting states with strategies to mobilize Democratic voters in liberal states.

Meanwhile, Democratic presidential candidates will have to be constantly aware of two emerging patterns that are defining their party.

First, their liberal activist base is becoming more radical and more intense. Note supportive comments for the Antifa movement made by Democratic National Committee Deputy Chair and Rep. Keith Ellison of Minnesota.

Second, the Democratic Party is increasingly factional. There is an environmental faction, a sexual-gender identity faction, a series of ethnic factions, a socialist-intellectual faction, an open borders faction, and an anti-Islamophobia faction.

Each of these tribes has its own identity and its own niche issues. They are all militant and energetic, and they have almost no interest in working with others or compromising. Each is laser-focused on what it wants and when it wants it.

I think Schumer will think about all this and conclude that he has to follow a much more cautious strategy. Any effort to directly confront President Trump is likely to force his incumbents in Trump states to disagree. Any effort by Schumer to collaborate with President Trump will spark opposition by the potential presidential candidates.

Schumer now finds himself leading the Senate Democrats in an ideological-partisan minefield in which bold strategies may lead to bold defeats.

There is a lot to be learned from the last few days.