It has backwards compatibility
10.5 eliminated Classic support; little choice in the matter, keeping it would have required emulation within emulation, not pretty. But I still occasionally play Lemmings or Prince of Persia 2 on my TiBook G4 running 10.4, and 10.5 supports 98% of all OSX-era programs.
Refurb Macs can be inexpensive, as this thread shows. If you want a new one you'll have to shell out, though., my PC was cheap,
The biggest challenge to upgrading the components in a Mac is getting into the case. For some models this is very difficult; for others it's easy. The towers just open right up without even a screwdriver. (Or they did----haven't used one in a while.)and I can upgrade components as I wish.
Finding new components for them is slightly harder than for a PC, simply due to limited availability, but they're out there. And installation isn't particularly different once you have the box open. A few years back I upgraded the CPU on an old G3 Blue&White tower from 400MHz to 900Mhz. (That was a bigger change then than it would be now.) It was fairly simple. That was the same machine, incidentally, that I stuck a Voodoo2 card in years ago even though the box claimed it was Windows-only, and it worked fine once I downloaded the Mac drivers from 3Dfx's website.