FR 5712 then FR 445 at Madrid
Budapest → Madrid → Palermo
Timetable, Madrid time
09:05FR 5712 from Budapest at the gate
22:35FR 445 to Palermo leaves the gate
13 h 30 apart on the timetable
FR 445 leaves 13 h 30 after FR 5712 arrives on the timetable: more than half a day, so not a connection we count.