IB 535 then FR 478 at Lisbon
Madrid → Lisbon → Edinburgh
Timetable, Lisbon time
18:05IB 535 from Madrid at the gate
15:40FR 478 to Edinburgh leaves the gate
21 h 35 apart on the timetable, overnight
FR 478 leaves 21 h 35 after IB 535 arrives on the timetable: more than half a day, so not a connection we count.