AHHH! The dreaded question, "How hard could it be?" See Dave Nadler's 2020 SSA Convention presentation on motorglider reliability.
https://www.youtube.com/watch?v=R--m0NDR0j8&t=8s
Electric or internal combustion (or jet or warp drive, or....) the problem is lots more complex than it seems. I have been involved with seven jet engine/glider conversions, and everything takes a lot of serious analysis. Hint: start with a glider that already has an engine bay for a fuselage mounted power plant. Or at least check with Emir Sherbi about his Grasshopper electric conversion.
https://www.facebook.com/charlysierragolf/