Dear Quiller if I understand correctly this "it was known by ancient civilizations so it must be discovered" principle :
if it's independantly "invented" then it's just discovered. I agree but there are also examples of discoveries you can point to, that can't be checked by your principle.
The current content of mathematics is extremely intertwined with the civilization that took over.
Many mathematicians believe in Descartes.
Leibniz is of astonishing influence, it's hard to exxagerate his importance.
Poincaré and much after him were Kantian.
As you can see there is a lot of mathematical gurus.
You can go very far with structures in your mind.
Just starting from Numbers, triangles and inventing things... You can prove many geometric truths like that.
You discover that there are two different things and then there can be three, etc. . boom numbers. You see three lines in generic position (intersecting at 3 points) boom triangles.
However advances in geometry have more than just starting from number and the ideas of static figures in the plane or in space + a bunch of gurus.
Say explaining spacetime motion or simply the flow of a fluid.
The mathematical apparatus needed for that (some of it named after an ancient symbol called nabla meaning "Harp")
doesn't draw from pure speculation, this is the opposite.
I don't thinkt there is any mathematical theory that doesn't draw from nature, if you dig deep. Even information. It literally builds on thermodynamical experiments done in the 19th century. Of course it has come to a state of synthesis so everything is inter-related, like every part of human culture.
One should also factor in
Industrial development, fulfilling of human needs.
It has a big influence in mathematics. Euler worked for the navy and from there came differential geometry.
He tried to figure out life in the city (what bridges to walk on) and from there came topology and graph theory.
Elliptic integrals were introduced to solve astronomy questions.