As far as I know, Horse racing isn't that much a popular game after all, though here in my country, some local casinos used to make the game available to bettors, but right now, it's hard to find a casino to bet on horse racing, this simply means that the game is probably dying off little by little.
And what i do think is that, when horses were a pretty much always available commodity, the game of horse racing was pretty popular and one that was enjoyed by very many people all over the world, but today, horses have become very scarce, and pretty expensive for those who still have it, so instead of spending so much money to host horse racing games, people now refer to spend less to host even games that are more interesting than horse race, as we have a lot of options today when it comes to sports.
I don't think that the scarcity of the game has anything to do with the scarcity of horses, and horses aren't scarce at all, they can be found all around the world, and they are also not so expensive that the sport would start fading away because people can't afford to buy horses. I think it's just that the game was more ancient and vintage people and societies used to like watching the game and since there aren't a lot of people interested in being spectators, the game isn't played that much.
People these days are more interested in modern-day games like football, cricket, baseball, tennis, boxing, and a lot more that are played and liked on a global scale and there is high demand for these sports which is the reason why most countries are interested in having these games instead of those that are fading away with time.
Well, you sure have a point, and speaking of how expensive or not horse have become, let's just say that this probably depends on the region of country where one resides, and my comment saying that horses have become really scarce and expensive is purely based on the country i am from, over here in Nigeria, we don't come by horse like it used to be anymore, rich people today over here sometimes go to big places like the beach, and pay really high amount of money to be allowed to ride a horse around for a specific time, so horses over here are indeed expensive for those who have it now use it to make money for themselves.
But anyways, i understand the point you are coming from, and you are right anyway.