It seems that Trump won the electoral vote while Clinton won the popular vote. This has happened a few times before as well.
The constitution does not specify how states assign electoral votes. At the moment, two states, Maine and Nebraska, split their electoral votes in some way among the candidates, while all the other states are winner take all.
I don’t think the electoral college itself is a bad idea. Like the way that even low population states have two senators, each state has two “extra” electors, which tends to give a bit more power to low population states versus high population states.
I think that winner-take-all selection of electors is a problem. This removes ANY power from the minority party in winner take all states. There is little point to being a Democrat in Kansas or a Republican in Massachusetts. Such individuals have no say at all in choosing a president, and that isn’t right.
What would be better? According to the the electoral college FAQ, for example, Maine awards an elector for the winner of each congressional district, and awards the to extra electors to the statewide winner. A state that felt strongly about the popular vote could proportionately assign all the electors.
Perhaps it is time for some back-testing of elector selection algorithms against old voting records.
Personally, I think the Maine system runs up against another problem – gerrymandering. In most states, the congressional district boundaries are drawn by whoever controls the state legislature, with the goal of disenfranchising their opponents. At the moment, one of the main reasons the Republican party has a lock on the house of representatives is that they spent a lot of time gaining control of governorships and state legistatures, and as a result used the redistricting after the 2010 census to lock in district boundaries that benefit their own party.