Baroque.
So yes, you were right about Bach's music being in the general category of classical music; it's just not of the classical era (1730 - 1820).