Math itself is rational. It works through abstract relationships, definitions, rules, and logical structure. But a statement that uses math can be rational, empirical, or even irrational depending on what the statement is actually claiming.
Take 2 + 2 = 4. By itself, that is rational. It describes a relationship that can apply to rocks, apples, stars, or anything else we choose to count. It does not directly describe any particular thing in the material world. It is an abstract relationship that can be applied to many things.
Now take a statement like:
Those two rocks plus those two shells equal four objects.
That is an empirical statement because it directly describes things in the material world. We can look at the rocks and shells and count them. If we go one step further and say, whenever you add two rocks to two rocks, you get four rocks, we have moved beyond the specific observation into an empirical theory. A direct description that is supported by our repeated experience of the material world.
This distinction also helps explain scientific theories. The theory of evolution is empirical because it describes real processes occurring in populations on Earth and makes claims that can be tested against fossils, genetics, anatomy, and observed change. But scientific theories also contain rational structure: we use logic, models, and inference to connect the observations. By contrast, something like set theory is primarily rational. Its truths follow from definitions, axioms, and logical relationships rather than from directly observing physical sets floating around in nature. The exception, of course, is when you use set theory in statements akin to the two rocks and shells example.