But seriously though, yes, but useless isn't the same as pointless. Art by some definitions is useless, but it can still have a point, even if that point it just to be fun.
I agree. I'm pretty sure a bunch of stuff that Euler did was considered useless until it actually was used hundreds of years later. I'm pretty sure topology had a lot of people wondering what the hell to use it for until it was rediscovered multiple times.
I imagine it like this: First we do the useful stuff as much as we can. But at some point it slows down and halts. Then with that knowledge doing useless stuff is easier. So we widen the search. Maybe most of them are really useless but few that can make a breakthrough is enough. Now back to useful stuff. This process is not discrete of course it's more dynamic and fluid. Does this make sense?
Theories can be a stepping stone to other theories. Until we explore those chains, we don't know if there is anything useful at the end.
E.g. initially, lasers were a solution looking for a problem. An interesting quirk possible due to some interesting bit of physics.
Maths explores idea spaces. Much of that is purely of interest to other mathematicians. However, it sometimes intersects with areas of interest to other scientists, at which point it becomes extremely useful.
Theory without application is often the entire point in certain academic circles and if someone comes along and finds a practical use for their mathematically based philosophical musings they delve deeper looking for the pureness