FR 5483 then IB 1019 at Madrid
Porto → Madrid → Granada
Timetable, Madrid time
08:30FR 5483 from Porto at the gate
06:40IB 1019 to Granada leaves the gate
22 h 10 apart on the timetable, overnight
IB 1019 leaves 22 h 10 after FR 5483 arrives on the timetable: more than half a day, so not a connection we count.