Ah, the analytic-synthetic dichotomy for the lose.
It is possible for axioms to be grounded in reality. If the system you're using is based on axioms grounded in reality, mathematics can be scientific.
That wasn't so hard, was it? What was that about being a trivial point for anyone who ever took a philosophy class? Sorry, I adhere to a rational philosophy, not the garbage taught in colleges.
There's something much more wrong here than just your belief that mathematics is necessarily true, yet arbitrary. And that is your belief in the analytic-synthetic dichotomy itself.
The dichotomy arises out of a theory of concepts where the meaning of a concept is its definition. If the meaning of a concept is its definition, then any property of the referent not included in the definition is contingent.
In contrast to this theory, is a much better theory of concepts where the meaning of a concept is its referents. This makes every property that the referents have in common necessary.
Here's an example. We're stating two truths about the nature of ice.
A: Ice is solid water.
B: Ice floats.
If the meaning of a concept is its definition, then A is an analytic truth, and B is a synthetic truth. Ice being solid water is taken to be necessary (since that's part of its definition), but detached from reality. B is taken to be true, but only because we just so happen to be observing it to be so. (Ice floating isn't part of its definition, after all.)
If the meaning of a concept is its referents, then suddenly, both A and B are necessary because they are properties of ice. The nature of ice is such that not only can you be sure it is solid water, but you can be sure it floats (in water). Because that's what ice does. Every referent of the concept "ice", that is, every piece of ice, floats (in water).
You're probably going to rage at me for this, if you aren't already. But this is basically the Objectivist criticism of the analytic-synthetic dichotomy. I am an Objectivist. If you're interested, you can read Introduction to Objectivist Epistemology, by Ayn Rand, to learn her theory of concepts. At the end of the book is an essay, The Analytic-Synthetic Dichotomy, by Dr. Leonard Peikoff, that goes into more detail to explain what I just did, and how Ayn Rand's theory of concepts undercuts the dichotomy.