Ceasefire talks between Hamas and mediators in Egypt have ended without a breakthrough, just days before the start of Ramadan.