Anne O’Reilly, a lifelong Republican activist, was in the audience here waiting for Donald Trump to arrive Saturday morning. She remains hopeful that Trump can win the presidency but has no doubt what will happen if he doesn’t.

“I think it’s going to be an eggbeater in the Republican Party,” she said. “I think you’re going to see pieces going all over the place.”

Trump came to Gettysburg to deliver what his campaign billed as a closing argument for the presidential campaign, to lay out plans for the first 100 days of a Trump administration and, citing Abraham Lincoln’s famous address here in 1863, to restore a government of, by and for the people.

The speech was a laundry list of familiar promises on the economy, national security, immigration and other issues, though the candidate’s message was muddled by his assertions of coming lawsuits against the women accusing him of sexual misconduct and his pledges to break up media companies that he said are trying to deny him the presidency.

It was ironic that Trump chose Gettysburg, the site of one of the most decisive battles of the Civil War, for his speech. Win or lose, Republicans are probably headed toward a civil war of their own, a period of conflict and turmoil and a reckoning of potentially historic significance. That debate has already begun, as the tension between Trump and House Speaker Paul Ryan has shown throughout the year. It will only intensify after Nov. 8.

At the site of one of the Civil War’s key battles, Republican presidential candidate Donald Trump told an estimated crowd of 500 that today’s America is nearly as divided as it was then. The Washington Post asked supporters about the future of the Trump movement. (Jorge Ribas/The Washington Post)

Unless Trump reverses his fortunes over the next 16 days, the Republicans face defeat — a potentially sizable one — in the presidential race, along with the possible loss of control of the Senate and the prospect of a smaller majority in the House. Trump’s future is in his hands. Saving the Senate and protecting the House are the priority of GOP leaders.

The Republican presidential nominee has not only failed to unify the GOP; but his candidacy has also intensified long-standing hostility toward the party establishment among the grass-roots forces backing him. That tension has made it harder to find a solution to a major problem: T he Republican coalition now represents growing shares of the declining parts of the electorate — the inverse of what an aspiring majority party should want.

The Pew Research Center recently charted the changing fortunes of the two major parties with an examination of party identification over the past quarter-century. Its title summed up the state of things: “The Parties on the Eve of the 2016 Election: Two Coalitions, Moving Farther Apart.”

The major demographic changes are well known. The United States is becoming more diverse racially and ethnically, better educated overall and with a population that is aging. Pew’s analysis found the following: “The Democratic Party is becoming less white, less religious and better-educated at a faster rate than the country as a whole, while aging at a slower rate. Within the GOP, the pattern is the reverse.”

By putting together the demographic shifts with changes in party allegiance, the Pew study underscored two big changes — one talked about for some years, the other an ongoing issue for Republicans that Trump’s candidacy has highlighted. Both bode poorly for the Republicans if they cannot adjust their appeal rapidly.

In 1992, non-Hispanic whites made up 84 percent of registered voters. Today, they represent 70 percent of registered voters. The percentage of Hispanics has nearly doubled to 9 percent. Mixed race or others have risen from 1 percent to 5 percent, and blacks have ticked up from 10 percent to 12 percent.

Both parties have become less white in their makeup, but the changes have moved at significantly different rates. In 1992, whites accounted for 76 percent of Democrats or Democratic-leaning independents. Today, whites make up 57 percent. Meanwhile, whites made up 93 percent of Republicans a quarter-century ago. Today, they’re still 86 percent. In other words, there’s been a 19-point shift inside the Democratic Party and only a seven-point shift in the GOP coalition.

Republican presidential nominee Donald Trump delivered a speech in Gettysburg, Pa., on Oct. 22 laying out his vision for his first 100 days in office if elected president, including immigration enforcement, creating at least 25,000 million new jobs through massive tax cuts and repeal of the Affordable Care Act (The Washington Post)

As the baby-boom generation retires, the overall age of the population increases. Over the past quarter-century, the median age of registered voters, according to the Pew report, has risen from 46 to 50. What’s happened to the parties? In 1992, the Republican Party had a slightly younger cohort than the Democrats. Today, the GOP is significantly older in its makeup than the Democrats — and older by two years than the median age.

The other big shift is the education levels of the two party’s followers. When Bill Clinton was elected president, Republican voters were in general much better educated than Democratic voters. Today’s Democratic Party followers have somewhat higher education levels than Republicans.

Trump’s candidacy has drawn its strongest support from white voters who lack college degrees. He has taken advantage of what has been a major movement of these blue-collar voters from their historic home in the Democratic Party. Trump did not trigger the shift toward the Republicans; it began some time ago, though it has accelerated over the past few years.

In 1992, whites without college degrees accounted for 63 percent of all registered voters. Today, because of more diversity and higher levels of education, white, non-college-educated voters account for 45 percent in 2016 Pew surveys. Meanwhile, whites with college degrees have increased from a fifth of the electorate to a quarter today.

Writing in The Hill recently, Democratic pollster Mark Mellman observed: “While Republicans are, and have been, making gains with non-college whites, they are suffering continuing — albeit smaller — defections from whites who hold a college degree. In the long run, that’s bad news for the GOP.”

These are root problems for the Republicans, things that remain as long-term challenges no matter the outcome of this election. But Trump’s candidacy complicates finding a solution. His call to blow up the status quo in Washington enjoys a strong following. His supporters believe the GOP establishment has treated him badly.

Lee Solesha was among those who attended Trump’s event here Saturday. She was partial to former Florida governor Jeb Bush during the primaries but thinks Trump won the nomination fair and square and deserves the support of the rest of the party, and especially of those other Republican candidates.

“I’m kind of disgusted with all of them,” she said. “They made such a big deal out of it . . . to promise and sign the pledge because they were worried about Donald Trump, and then none of them followed through with what they said they were going to do. . . . It’s kind of disheartening.”

Trump’s loyalists want a future Republican Party in which the Paul Ryans and others in the current establishment play a reduced role. Those in the party who have openly opposed or resisted Trump want just the opposite.

Some fear the party will split apart. Others, like O’Reilly, think the divisions will eventually be overcome, but only after a period of pain. “I think it’s going to be nasty until it melds,” she said. “I shouldn’t say ‘nasty.’ Extremely interesting. I truly believe it will be more interesting than the first 100 days of a Clinton presidency.”