I mean... theoretically speaking, Vietnam was neither bad nor good (well, at least as far as war goes anyways). It just was... and ultimately ended up being a very pointless conflict.
One of many proxy wars that happened in the Cold War, but because they don't educate people on the war properly, our modern day citizenry has no idea why the fuck we lost. They think the Vietnamese just charged us with sharpened bamboo sticks and that just... worked somehow... which while technically not entirely wrong there is so much more to it than that.
Here's possibly the biggest reason: Congress - the only entity of the US government that has the legal power to declare war on behalf of our nation, refused to recognize Vietnam as a war. As such, because it was a "peace action" and not a war, US, Aussie, and New Zealander troops could not cross the 17th Parallel, this border between north and south Vietnam. This meant that the coalition forces were entirely relegated to defensive action - with it's time and effort mostly being spent of search and destroy efforts of Viet Cong insurgents, with the only means of offense being bombing campaigns in the north and small excursions past the border, or into Cambodia and Laos as that's where the Ho Chi Minh trail was located, and where North Vietnam was funneling weapons, supplies, and troops into South Vietnam to aid the Viet Cong, thus bypassing the heavy defenses of the border.
Kind of hard to win a war when you can't cross the fucking border legally.
Second largest reason: South Vietnam was corrupt as fuck. The US regularly gave it aid packages of hundreds of millions of dollars, sometimes in the billions, in order to be used to purchase equipment for their military (ARVN) and prop up their nascent economy which was just barely beginning to industrialize. However, more often than not this money would just end up in the personal off shore bank accounts of those in the South Vietnamese government, and the generals of the military, leaving the ARVN to be woefully underequipped and practically subsistent off of US Army charity and whatever it could spare them. This is why you saw so many ARVN soldiers equipped with US gear, helmets, and weaponry.
Third and Final Reason: Low homefront morale. This one everybody knows about. Believe it or not, when Vietnam originally broke out the military was in fairly high spirits. The US was still undefeated, and regarded as such. But as the war dragged on, the costs and casualties of the war grew ever higher, opinions on the war back on the homefront started to sour. This is attributed to a multitude of things: a government under Nixon would the general public felt couldn't be trusted (and later Watergate would happen), the news media for the very first time in the history of American Press, would report more and more on the war with a negative opinion on the military, civil rights happening back home made Vietnam seem like a pointless endeavor when during a time when we had our own shit going on - and the civil rights movement would in turn lead to the peace movement. Eventually even the most hard core Republicans would turn against Nixon, leading to him getting involved in shady undertakings in attempt to ensure he had the next election secured in the bag.
(Though fun fact: It was actually Kennedy who originally had US troops stationed in Vietnam after the French were defeated by the Viet Minh - predecessors to the VC).
Though the US was still in a strong position by the end of the war, and even the Tet Offensive failed to truly dislodge US troops guarding the border - eventually everybody just collectively got tired of all of the bullshit, of fighting a increasingly pointless war over literal jungles and rice farms with no real resource or strategic value, that the military, citizenry, and government all just collectively issued a "fuck this shit I'm out" note and just kinda packed up and left. The South Vietnamese government was extremely corrupt, was only getting worse, and showed no signs of stopping. With no other purpose to remain in Vietnam other than just to say "that's one less country without Communism in it" (as explained, it help literally no value in terms of resources or even strategic positioning. The US Pacific Fleet already essentially held operational control of the South China Sea by way of naval bases in Japan and South Korea), we simply left.
There are many more smaller reasons, such as the Soviets and partially even the Chinese feeding the Vietnamese massive amounts of weaponry and materiel - the economy of Vietnam was still almost entirely agriculture and thus they did not have the capability to produce the armaments they required themselves.
The US and Soviets had adopted somewhat different policies regarding the Cold War at this stage during the 60's. The US adopted a policy of containment, doing whatever necessary to prevent the spread of Communism further. Once Stalin was out, so was his Socialism in One Country policy and the USSR's views to simply batten down the hatches in East Europe and consolidate control on to what they had, and then Khrushchev was in. Khrushchev, in response to the containment policy pursued a policy of destabilization, the Soviets would work behind the scenes to subvert and supplant US power where possible, and wherever that wasn't possible - destabilization was the next approach.
Though the Soviets would slowly warm up to the US starting with Brezhnev would replaced Khrushchev (Khrushchev drove the economy to stagnation, and then lost the support of the military and KGB apparatus after the Cuban Missile Crisis, which many in the Soviet military and KGB believed made the USSR look bad and as if they backed down. Nevermind the fact that Kennedy agreed to pull missiles out of Turkey in exchange for the Soviets removing missiles from Cuba). Brezhnev pursued a policy of "mutual co-existence", a "the world can exist peacefully with two superpowers" ideal - but despite this the USSR never fully backed away from the policy of destabilization that Khrushchev had put in place.
Thanks for attending my TED talk.