We make associations. A lot of those associations are based on delivered experiences, i.e. if every picture of a space alien you see is green, then it will be harder to accept an image where the alien is red. Never mind that it's all speculation.
Drug makers may be pushing a subliminal narrative of wholesomeness... or white dye might just be cheaper. White also relates to lab coats and cleanliness.
Business tends to correlate to blue, but that's based on men wearing navy blue suits. Women tend to wear suits with a lot more color variations, so the correlation may also be unconsciously sexist, that it's only a man's uniform that feels "right" for business.
Pink is perceived as girly these days. That wasn't always the case.
Sometimes color relates directly to something found in nature. While green can mean aliens, it can also mean freshness. But does red mean roses, blood, strawberries, or something else?
Human intelligence tends to be associative. We link things together all the time. The more we see our linkages confirmed, the stronger they become --- confirmation bias in a nutshell.