Also a lot of "mainframes" are actually virtual machines running on modern physical hardware. I've also seen companies who have the console output sent to a webapp and commands returned the same way, thus making these 1980s relics seem almost "modern" (as, for example, you can utilise them from an iPad/Smartphone without an app).
I remember being very surprised when I discovered that mainframe capacity is sold in units of MIPS (millions of instructions per second). Like, you literally buy capacity off IBM by the megahertz. They don't really get faster because there are so few suppliers of this kind of exotic hardware nowadays, and it's hard for the banks to port it all to more modern platforms because the original code is often so obscure and only understood by people who are retired/laid off.
And that's the best case. I've heard of at least one bank that has a job running on their mainframe where nobody can find the source and nobody knows what it does, but they're too afraid to shut it down in case it breaks something.