You may have realized your selfishness on a superficial level, but you don't yet understand the depth of it because you are still focusing on what YOU want...getting her back!
She has told you that she needs space...respect her wishes and give her what she is asking you for. Tell her...or better yet, write her...that you are sincerely sorry for what you did, that you love her and would like to keep the door open to resume your relationship, BUT that you respect her need for space and will honor it. Then let go of it!
The chances of her coming around are slim, at best...and it will ONLY happen if you show her how sincere you are by putting her need before your want.
Tough lesson...you're right, it really sucks! Learn it well so that you don't have to repeat it!!!