Motion Light back to previous stage

Hi, I'm very new in Hubitat, And just learning a lot about Rule Machine, I'm getting stuck in a basic option, that is when my lights turn on with a specific color acordingly with the mode, I whant that when they turn off the go to previous stage, it they were off then off if not to the previous colors.

IF (CorridorHall Sensor motion active(F) AND Illuminance of CorridorHall Sensor(0) < 40(T) [FALSE]) THEN
Cancel Delayed Actions
Color temperature per mode: Corridor
Day: 4292 -> Level: 100
Evening: 2890 -> Level: 100
Night: 2237 -> Level: 56
Color per mode: Corridor
Dark Night: Custom HSB color Hue: 10 Sat: 99 Level: 35
IF (CorridorHall Sensor motion inactive(T) AND Corridor(off) is on(F) [FALSE]) THEN
Adjust: Corridor by -25 --> fade: 1 --> delayed: 0:00:20(cancelable)
Off: Corridor --> delayed: 0:00:30(cancelable)
Restore: Corridor

can someone help me?

Could you post a screenshot of your full rule?