Gambling is a tax for people who don't understand the mathematics of probability. If you understand how probability works, you can't ever rationally gamble. The only reason you would gamble is if you decided, "I am going to lose money; the fun I have while I am losing money is worth it." "I am paying a fee for temporary fun." But most people cannot do that. Once you become drawn into the game, the gambling process triggers these responses. You start getting confirmation bias, selection bias, and survivor bias. These are known cognitive biases. The person who wins thinks they were lucky, but they don't think about all the times they lost. As you are doing this, it is triggering your dopamine centers.
I have also read several articles about the effects of dopamine, the dopamine effect is the effect produced by the happiness hormone, humans usually get dopamine when they climax during sex - using drugs - falling in love - winning gambling - getting big money. People who successfully manage their happiness hormones will usually be very successful, all because they have complete control over themselves and their thoughts. that is the reason why risk management in gambling is important, wise people will not be intimidated by winning, they will definitely be more afraid when they keep winning because they are sure that the time will come when they lose.