What do we, the United States, gain from Ukraine properly winning this?
First off, Russia has Imperial Ambitions. Putin is on record as thinking that the break-up of the USSR was the greatest tragedy of the 20th century, or something to that effect. He wants to rebuild the Russian Empire, and he wants to rule the world's dominant power.
Everyone and anyone who doesn't want to be a subject of Russia, or part of a tributary state, has a vested interest in seeing the Russian invasion fail.
Second off, economically war is bad. Ukraine is one of the world's major providers of cheap grain and of fertilizer.
Part of the reason for the instability in the ME during the Obama years was because of spikes in the cost of food causing political unrest, which has helped fuel terrorism and the invasion of immigrants into Europe, though that's
far from the only cause. This is just one example of the economic effects and second-order political effects. For America, these consequences are mostly economic, but the political parts hit our allies as well.
Third off, the reason that Iran has been throwing its weight around, is partly because of demonstrated unwillingness to act on America's part, and this also makes the Chinese more likely to try military adventurism. This wouldn't have the direct cost of US deaths and casualties if we didn't have a crap-ton of military bases strewn across the middle east that shouldn't be there, but they'd still be hitting merchant shipping, and this again causes massive economic disruption.
If China hits Taiwan, the global microchip market is properly
screwed, and that will do billions or trillions in economic damages, a significant portion of which will be felt by the US. Displaying an unwillingness to deter adventurism on the part of other would-be world hegemons encourages them to go play conqueror.
Fourth off, when nations with US backing and US military hardware can fend off much larger nations with their own massive military-industrial complex, this highlights the fact that US military power is by far the most potent in the world, and if you are a remotely rational actor,
you do not want to even consider starting a direct fight with the USA. That won't stop crazy Jihadis, but it keeps people like Maduro or Erdogan from making
unwise decisions about who they do and do not want to openly align themselves with or start shooting at.
Whether the USA wants to or not, it is a world where the game of empires is played, and as technology advanced across the 19th and 20th centuries, it became impossible to just opt out. The Atlantic is no longer a moat that takes weeks to cross, isolating us from the rest of the world, and Great Britain isn't capable of taking the world hegemon's mantle back from us and doing a decent job at it. If we don't act as world hegemon, Russia or China
will take up that slot (Russia probably actually
can't anymore, but they're the closest runner-up after China), and if they do they
will wield that power to try and crush us.
Isolationism isn't an option, and until their imperial ambitions are broken, Russia must be fought
somewhere. Better it's in Ukraine now, than in Moldovoa, or Estonia, or somewhere else later. The cost will be lower, and the end will come sooner.