Consider yourself very lucky. I still suspect that when you set your bag down, the books were weighing down on your lid.
As for shaking your computer, I hope you are not doing that with the system up and running. You should avoid shaking a HDD...this obviously does not apply to SSD.
Speaking of, since you shook your system, you should run a full diagnostic to make sure everything on your mother boards and system didn't shake loose or caused irreparable damage....yes.