Reolink cameras with home assistant might work for you. They can record nonstop, or only when they spot a person, animal, or car (you decide). It’s a do-it-yourself setup, but for around $200, you could have it all working.
You’d probably need a camera hooked up to a recorder for continuous recording. Here’s an example: link to recorder setup.
Using just an SD card won’t cut it for constant recording. A proper system with a DVR and hard drive would save you from having to constantly empty the card.