Actually, it’s because Thailand, the US, and most other countries are parties to UN anti-drug treaties.
Even in the US, they won’t legalize at the federal level because they would have to ignore those treaties and the second they do that, any country that is an exporter of drugs calls them out for being a hypocrite and just starts shipping heroin, meth, cocaine, etc and tells the US to pound sand if they complain.
BTW, if you’re asking how the US gets away with it, the individual states didn’t sign those agreements. The federal government did.
So, if California quits enforcing cannabis laws, and the federal government keeps it illegal but looks the other way, they’re still, technically, in compliance.
Back when Thailand first said they were legalizing cannabis in 2018, they explicitly said they will not violate those agreements.
They don’t want meth from Myanmar flooding the local market because they’re seen as violating these agreements.
So they say they’re legalizing “medicinal use” but they let everyone self-diagnose.
That technically complies with those agreements while effectively legalizing recreational use.
It should also be noted that when Thailand first announced legalizing cannabis, they also declared that they refuse to recognize patents on strains of cannabis for 5 years.
That’s because Thailand feels slighted that they did what the US pressured them to do under Nixon and now the US is making huge advancements in growing and medical research while Thailand is treating cannabis as a Category 5 narcotic.
Thailand feels like it should be the leader because cannabis has been a part of Thai culture for several hundred years until Nixon’s war on drugs forced Thailand to crack down on drugs.
Yes, there are ultra-conservative elements in Thailand that would like to see everything from tobacco to cannabis made illegal but they’re an insignificant minority.
if you look at everything Thailand has said and done, it’s 100% clear that they are trying to adhere to their international agreements while also making it clear that they won’t be cheated out of becoming a major player in this huge market.