New study reveals how corals teach their offspring to beat the heat