Please guide me in buying a 2nd hand car, what papers do I need to get from the seller and do I need to register other things in LTO? please help thanks

how about when it comes to maintenance? What are the things that I should fix first after buying?