It's always wrong to assume you are getting a good deal based on what the price was originally at. You HAVE to know what the current value of the car is at, not what the price difference from new. Also, a loaded exl 4wd stickers just shy of 35k. Technically, that 5k is far from 40K, or he would't be asking if this was a good deal.
In my opinion, this is just shy of being an average deal. You traded your car for about 4k less than what they are currently going for. The used car sale market is exploding with demand of efficient, reliable, and good cars, used honda's don't stay on the lot that long anymore. An '05 EXL 4-door sells easily for 15.5k, assuming it is in "good" condition. You also dealt with a CT that is technically viewed as being 2 years old in terms of negotiating. At current dealer incentives, they have the ability to sell you a brand new CT 3xl 4wd for 30900 out the door...if you are willing to negotiate. I got that price, though I dealt with them for while because I knew they COULD sell it at that price do to extra factory to dealer incentives not offered to customers. So, you think them asking 29999 for a '10 demo is good? No! I would start maybe at 27.5k-28k. Factor in an average $2.7k extra for you car, and I would not take that car for less than about $23.5k. Keep in mind, this is assuming that it is 4wd. I hope yours is 4wd too for that price!
As all general deals go, it can only be viewed as a good deal if you enjoy the car enough for you to pay whatever you are willing to pay to get it. I assume you like the car enough to get it, so you should have answered your own question. Numbers can easily be forgotten if you enjoy your car!