For generations, biology textbooks treated life and death as a clean binary: an organism was either functioning or finished.