It’s mistaken to conflate legality with morality. Morality has (more consciously in the past than now) always influenced the law. The law should determine morality only to the extent that we do have a reasonable moral duty to obey the sovereign. In other words, we do have a duty to obey laws that prohibit “malum prohibitum” (wrong only because something is prohibited) unless doing so is “malum in se” (inherently wrong).
One of the worst aspects of our current society is that too many don’t see a difference. Just because something like abortion on demand is not malum prohibitum, it does not mean that it isn’t malum in se. Never should a Catholic support something that’s malum in se just because it isn’t presently malum prohibitum. And a Catholic should always politically oppose something that’s malum in se.
That’s really basic. It’s even acknowledged in the secular world. But, as Nietzsche pointed out, when a society rejects God, the two become confused, and ultimately, power determines outcomes, and power acts subjectively. (“You must do this because I want you to do it.”) And it’s inherently totalitarian. If this today, then what tomorrow?
And, in the case of abortion, that’s exactly what happened. Two people (yes, two it is

) imposed their subjective morality on the entire nation and declared something that had always been regarded as malum in se (and, to a Catholic, necessarily is) to be a good instead. They were able to do it solely because they had the power to do it. And so, “principles” (objective: that which is true) were abandoned in favor of “values” (subjective: that which I want)
And the more subjective “values” determine how the laws are constructed, the more arbitrary and unnatural the latter become.
I’m not one who criticizes Vatican II. But I am critical of the subjectivity that grew out of the bogus “spirit of Vatican II”, which is simply willfulness. The last century was, many predicted, to be the “Catholic century” in which Catholic moral teachings in many spheres (yes, and in social justice too) were predicted to prevail in this society because of the number of Catholics in the society and their increasing wealth and influence.
But it miscarried, and Catholics were misled into moral relativism (“Modernism” if you will) which denies that anything is really “true”; and affirms that all things are merely relative (50 shades of Gray). If Catholics without exception opposed, politically, those whose subjective mores can be enforced on the populace by power, it would not take but two national elections to cure the evil that twists the Dem party. If it loses catastrophically enough times, it will abandon its core evils, and Catholics alone could get it done.
But we don’t. Instead (and as Pope St. Pius XII warned) we adopted the relativism that both he and Nietzsche saw coming a hundred and more years ago, along with the enslavement that comes with it. Instead, we adopt relativism ourselves and find ways to justify ourselves in participating in the evil.