Going back to the legal diagram of offer and acceptance, I think unless there are more facts missing, you have a case. When you gave them the deposit, it was in response to their rescinded offer (and you can argue whether or not it was properly rescinded considering you were the one who called them and not the other way around when they told you the class was full), and unless they specifically told you paying the deposit would be considered paying a deposit to be held on the waitlist, they did not make you a new offer. It does not sound like they told you this. Therefore, you made them an offer:
Offer: You pay the deposit, in exchange for an immediate acceptance. (important that it's contingent on immediate, because it sounds like they later tried to offer you a spot)
Acceptance: None.
They didn't accept your offer, so there was no contract and they should return the deposit. Again, an oversimplification, but I think this is a fair argument on your side.
I sympathize with you and why you paid, because I have also dealt with paperwork errors in my daughter's school, including them thinking an application I submitted for my child was for an entire year earlier than it was supposed to be (hence them sending me a letter right after I applied saying the class was full and I was on the waitlist). Since you had both a confirmation letter and confirmation email, I might have assumed, as you did, that the person on the phone was just a confused receptionist and decided to go with the official paperwork/email.