Inequality has been part of humanity for a long time, the relevant question is what is the trend on inequality, both recently and historically, and why.
One of the key insights here IS from Marx, and it has to do with surplus profits. Basically almost every commercial interaction operates with surplus profits for both sides -- in that the same deal could be arrived at with a range of prices. If either party would walk away if the price point moved by a small amount in the wrong direction, that party has no surplus profit from the deal.
Surplus profits gives all parties flexibility -- they can grant favors in a deal, or outright gifts to others. Those with NO excess profits, are unable to be generous. The rest of us are able to be generous, because excess profits appear in almost everything we do.
The first appearance of significant inequality was with the development of agriculture. With that development, humans became settled, our population grew dramatically, and we developed a ruling class, who granted to themselves the "ownership" of land, which was the major source of wealth. The ruling class became far more wealthy than working farmers. Whether this was due to "ownership" or "ruling" is hard to decouple. Most agricultural societies used law to force the working farmers to negotiate at a disadvantage (serf laws, etc) so that the owners/rulers could maximize how much of that excess profit they could pocket. Note, profitability had a weak relationship to competence -- inherited landowners had no particular competence, but were inordinately wealthy due to the laws of ownership, and serfdom.
There were a few factories where artisans made pottery, cloth, dye, etc en mass before the industrial age, but those organizations were rare. A few merchants also became wealthy, basically due to a large return on risk from moving goods place/place. These were anomalies. These merchants and artisans were an exception to meritless wealth. Until recently, the wealthy were landowners and/or rulers, and were not wealthy due to merit.
Note, some commentators claim that humans solely work to maximize profit, but this was not the case for the owner/rulers, who used their surplus profits to be generous to their offspring and relatives, and other "people like us". The channeling of generosity to a class or ethnicity, creates an inherited advantaged society, and is typical of human behavior.
With the industrial age, the ability to make lots of stuff much more inexpensively than before created a lot more wealth, and therefore the potential for a large amount of excess profits, far more than the world had ever seen before. The development of farming mechanization, with the mechanisms built in these factories simultaneously created a large excess of working farmers who were now unemployed. The numbers of farmers vs factory owners meant that the factory owners had a massive advantage in negotiation how much of that excess profit each won in wage negotiations -- leading to a huge spike in the return on factory ownership. An astonish wealthy class of factory owners developed, the era of the "Robber Barons". Most were actually wealthy due to merit (they were mostly competent workaholics), but their accumulation of wealth was massively in excess of their relative merit.
These early "Robber Barons" followed the landowner/rulers into controlling government for their own benefit. Anti-union, anti-education, etc laws were common, in both democracies and aristocracies. This pattern reflects a Marxist insight that government is purchasable -- it tends to act to skew markets in the interest of those with wealth. The institutional and legal advantages of ownership and rulership, plus selective generosity, then permanently advantaged their NON-meriting relatives and offspring.
In the first few decades of the 20th century, the farms were drained of most of their excess workers, leading to less of a labor surplus in the industrialized countries, and a gradual increase in the negotiating power of workers, and relative increase in wages. Simultaneously, "leftist" governments reversed course, and benefitted workers over owners. Unions often were made mandatory, maximum work days and weeks were legislated, and workplace safety rules were regulated. Many Social Democrat leftists cite these rules as the reason for the increase in wealth of workers in this era. Marxist reasoning would argue the causation went the other way, the newly wealthy workers used that wealth to capture the government from the Robber Barons, and then used the government for some additional marginal advantaging.
Note, for most of the 20th century, economic disparity DECREASED in industrialized countries, in contradiction of the premise of this question.
That trend of decreasing disparity reversed in the 1980s. Simultaneously, governments across the industrialized world began "deregulating". Social Democratic leftists argue the deregulation caused the disparity. Marxist thinking is that the increasing disparity lead to the wealthy class being more wealthy, so they could recapture government, and use it to advantage themselves more.
If the Marxist approach is correct, then we need some other explanation for the increasing disparity, besides just "capitalism". So what changed?
My answer -- the 1980s were the start of the digital era. This was the first decade of microchips. Prior to the microchip revolution, the high cost of N American or N European workers was more than compensated for by lower transport costs from their factories. Microchips allow the most value-added products to be small and easily transportable, so that suppliers don't have much of an advantage being co-located with final product factories. A days worth of production no longer needed several trains to be transported, but instead could fit in one jet. The microchip revolution started a landslide of relocation of factories to places that did not have worker shortages, but instead had worker surpluses because the farmers were still on the land. This destroyed the bargaining advantage of workers vs factory owners, and the owners recaptured most of the excess profit from their workers.
The software revolution has just amplified this trend. Now, it is not just blue collar factory work that can be relocated to low cost countries, but all labor. Worker wages, and fraction of excess profits worldwide, are in steep decline. And worldwide, "rightist" parties are suddenly more wealthy, and are capturing control of governments.
There is a limit to this rebound into inequality. Once the world is roughly equally industrialized, there will be no steady supply of new places to export factories to, and inequality will start to decrease again.