Being stuck is part of being a mathematician. Being stuck isn't bad. It's just part of the process. You may have been told in the past (implicitly or explicitly) that doing math quickly is what counts. You may have been told in the past that being stuck is bad. But that's all wrong! Problem solving takes time, and getting good at problem solving requires problem solving skills, which you are developing now.
Developing the ability to do proofs reminds me of something from science. When ice turns into water, there is a transition period where the temperature stays constant. The energy is going into the transformation of states, so the temperature stays the same during the transformation. Your efforts may not appear to be making a change, since you are often stuck on a problem. The message here is that the energy you are exerting is going into your own, personal transformation. You may not see the differences in the usual ways, and the results may take a while. Giving up in the middle of the process is perhaps the biggest disservice you can do to yourself. Keep pushing the rock...
Dr. Y
