I think Amazon would be fine because of the money it makes on other products, but I agree paying the author directly is a more principled approach than just paying nobody.
Worth noting though that it’s not just Amazon and the author in the picture - you would be stiffing the publishers in this scenario, and they paid to get the book printed (and edited, and designed, and shipped to physical stores, and maybe some publicity, and probably gave the author an advance).
You might think “who cares?”, but if the author didn’t (traditionally) sell any of the books they published then they wouldn’t ever get another publishing deal, so you’re harming their career. They could self-publish, sure, but worth keeping in mind the author doesn’t necessarily want that, because of the benefits publishers bring (if they didn’t bring any benefits, people wouldn’t use them - they’re not idiots).
It’s very complicated, and I would argue that people using shadow libraries “for authors’ benefit” ought to be speaking to more authors about whether they want that kind of help. But I agree your plan is much more honest than paying nobody, even if it has some potentially negative effects at scale without more coordinated action.