keep it covered so you keep infection out. same thing happened to me when i was younger- i was getting out of my mom's car for track practice and when i hoped out i turned around quickly (hand still in door) my bag flew around and slamed the door shut on my left pointer finger. It broke it from the nail down. (painful! but i bet not as bad as yours though
) Anyways after a few weeks the nail fell off and it looked and felt REALLY weird- my doctor told me to keep it a big layer of neosporin on it at all times and to keep it bandaged to try and keep infection out. (once the nail started to grow back enough he said i didn't have to keep it bandaged all the time and could let some fresh air get to it.) It took several months for it to grow back -but now it's all good and you couldn't tell it ever fell off!
I'm sure yours will be just fine in a couple of months!
Also- one thing i noticed- the longest part that took to heal was the cuticle- it got really damaged when it happened- so that took the longest to grow back right/heal- but it finally did! Now i can paint that nail and do everything with it that i can with the other ones.