It is easy to construct some alternative history long after the events.
Perhaps it would have been better to drop the first bomb on Mount Fuji, as a demonstration for the Japanese.
However, those who made the decision were under pressures that, as time passes, become less easy to understand, but they made the best and most benevolent decision that they could under the circumstances.
What future generations must remember is how horrible nuclear weapons are.
To remember this is a powerful force for peace and love.
For example: it prevented the Cold War from deteriorating into all-out war, and it finally ended it.
My father's wise, decent, and supremely benevolent brother--a highly successful man, in business and in every other phase of his life--once told me:
This is wise advice on a personal or an international level. In fact, this very principle guided American leaders in their behavior toward Japan.
I'm not absolutely sure what you mean by "if Japan had defeated the United States." There was no possibility of that in August of 1945. I assume you mean if Japan had repelled the invasion by the United States, which was certainly a possibility
I would go further than you. If the USA had successfully invaded Japan, the American casualties would have been so high that the rebuilding of Japan would never have occurred; the American people would not have allowed it.