Recovering lost files from a MacBook Pro 2018 that won't turn on is quite challenging since it is configured with a T2 chip, which hardware-encrypts the SSD soldered with the motherboard. You can try this post to see if data recovery succeeds:
How to Recover Lost Data from MacBook Pro/Air 2018/2019/2020?
Or, you can see whether a professional data recovery service such as Drive Saver can recover your files. Note that the data on this SSD is hardware encrypted and can be decrypted only if the T2 chip works well.
Furthermore, always back up everything crucial to an external hard drive or cloud storage to avoid loss caused by data loss or so on.