The hardware is better because of RnD, funded by high margins due to software lock-in. Not sure why people struggle to see the connection here.
I am sure it made them a rich company, but they were going to be rich anyways. They also hoard money like fucking crazy, so it's not like it's all getting spent on R&D.