From your issue - the MacBook is not turning on but the Trackpad works, I can see that your Mac is powered up. You don't need to worry that this problem is caused by a battery issue as the trackpad is still responsive.
To fix your MacBook that won't turn on, you can try the following ways:
1. Force start up your Mac
That is to force shut down your MacBook and then turn it on.
- Press and hold the power button for around 10 seconds to let your MacBook shut down completely.
- Wait for a moment and press the power button for 2-3 seconds to start your computer up.
2. Reset the SMC and NVRAM
Resetting SMC and NVRAM may be useful to resolve startup issues. That's because SMC controls the power functions for your MacBook and NVRAM maintains system settings that influence the machine's startup.
3. Check your MacBook brightness
Sometimes, your MacBook's display may have some issues, making your MacBook boot up but showing a black screen. You can click the increase brightness key on your keyboard to see if the screen brightness is up or connect your MacBook to an external monitor. If you see a display on the external screen, it means that your MacBook's built-in display has problems.
4. Contact the Apple support team
If none of the above ways work to turn on your MacBook, contact the Apple support team to check if it has an unknown error.