How to prevent PHP fatal error if plugin hasn’t been enabled and a method is called in theme file?

A plugin is a PHP include in its most elementary sense. You cannot call a function if it’s not registered in PHP. If a plugin is not activated, it is therefore not included, and the function is unknown. You cannot call it. I would recommend that you use this as a must-use plugin so that it’s availability is consistent and predictable.