Why didn’t I get Ranni’s ending?

Did I pick the wrong option after beating the final boss?