I have heard the supposed difference between democracies and republics "explained" to me numerous times over the years, and by "explained" I mean "shouted at me", usually with an admonition to "educate myself". For these people a Democracy is nothing more or less than a Direct Democracy, i.e. "Mob Rule", while a Republic is a government by elected representatives who are guided by a constitution. This is
partially true.
"Republic" comes from the Latin Res Publica, "a matter of the people", whereby the government is a public matter and not the private property of a monarch. In other words, in the strictest interpretation, a republic is simply "not a monarchy". The form that a republic can take is quite varied. In the United States, most people who refer to republics are talking about a representative-constitutional government, whereby the executive and legislators are elected by the people for fixed terms and are guided by laws, in our case, a constitution. However who "the people" are can be circumscribed quite broadly. In the early days of the United States only adult, white, male, landowners were permitted to vote. This eventually gave the way to voting rights for all adults, except some felons. In a Socialist, or Communist, Republic, the will of "the people" is assumed to reside in the ruling party, which has elections, but decides ahead of time who may run. In an Islamic Republic, the Quran and the clergy empowered to interpret it decide what's good for the people. Ancient Greek republics limited voting to a citizen class. But even if we accept that the correct or true form of a republic is an elected representative government bound by a constitution, that does not makes democracies and republics mutually exclusive.
"Democracy" comes from demokratia, Greek for "power by the people". "Democracy" therefore literally means power or rule of the people. The simplest form of this is Direct Democracy, often referred to as "Mob Rule", where every decision is voted upon by everyone. Obviously this could only work in very limited situations, such as (very) small towns, or people in small isolated groupings. Direct Democracy almost never exists. A less "pure" form of democracy would involve an elected administrator and/or hired technical people who would keep things running, while important decisions would be voted on. The other end of the democracy continuum would be a system indistinguishable from what we defined above as a representative, constitutional, republic: you elect representatives for fixed terms, who are then responsible to run the government according to a constitution. Those who are careful about their words refer to this as a democratic republic, or just a democracy for short. Nobody who calls the United States a democracy really believes that it is a direct democracy or thinks that a direct democracy is a good thing for a large nation.
Nothing about being a republic guarantees that a tyranny of the majority, the mob rule that detractors of the term democracy so fear, cannot take root. Majorities can still elect representatives that will abuse minorities, and the representatives can be cowed by fear of not being re-elected. What gives the minority rights and protections are the rights and protections that we wrote into our laws early on, such as the Bill of Rights and separation of powers.
Nothing about a democratic republic, whether you emphasize "democracy" or "republic", guarantees that a system like the Electoral College has to exist. Various representative democracies/democratic republics use different methods for choosing their head of government, or head of state. Most directly elect their president or prime minister through popular vote. In some countries, notably in the United Kingdom, the Prime Minister is the leader of the party which wins a majority of seats in the House of Commons. We have the system that we do, not because we're a republic, or even strictly because we have a federal system, but because of various compromises arising from competing priorities among the various states. Predominant issues included slavery, small state versus larger states and the tendency for the states to view themselves as sovereign.
There are several undemocratic features that were built into our framework of government. One has been eliminated: the indirect election of Senators. While today Senators are elected directly by the voters in each state, originally they were selected by each state government. Since gerrymandering was just as prevalent back then as it is now, a non-representative state legislature could appoint someone who represented their interests, which might not align with the interests of the voters. The founders did not trust "the people" to reliably choose their own Senators. Even today the Senate is an undemocratic institution. Small population states, like Wyoming, Vermont and the Dakotas have the same representation as large states like New York, Florida, California and Texas. This made sense in the early days of the nation when states (or at least their leaders) still viewed themselves as sovereign entities and jealously guarded their respective rights and perquisites, but is the culture really noticeably different when you cross a state border these days? The election of a president had several undemocratic features. The electoral college itself, where votes were weighted in favor of smaller states was originally even more undemocratic by the insertion of a second layer of voting between the people and the president - the electors. Unlike today, where the electors for the most part are required to vote in accordance with the voters in their state or district, originally electors were conceived as a way to overturn the vote of the majority of voters in a state if the voters voted for the "wrong" candidate.
Today's Republican Party, and not just the predominant Trumpist faction, is fixating on these undemocratic aspects of our system and amplifying them in order to retain power. It's not just the lie of the stolen election either. Attempts are being made all across the country, not only in Congress but in state and local election boards, to find ways to "legally" reverse or overturn election results. Roadblocks and speed bumps continue to be put in place to make it more difficult to register or to actually vote. Polling places are moved or eliminated, early or absentee voting is curtailed and unnecessary steps are added to mail-in ballots (how many times do we need to sign or initial the ballots and envelopes?) Voter rolls are purged weeks before an election, referenda to allow felons who have served their time eligible to vote have been neutered by byzantine rules, gubernatorial powers are curtailed by Republican state legislatures just before a Democratic governor is sworn in, legislatures slow walk or refuse to implement or fund petition initiatives...the list goes on and on.
Today's Republican Party, as the cliche goes, talks out of both sides of their collective mouth. They claim that their candidate, Donald Trump has the support of the majority of the country, yet they do all that they can to make the will of the majority irrelevant.