First, you can't use "Control" on a Z-Wave device unless you're running the latest alpha software.
You need 2 programs.
Program1:
if
status z sensor is switched on
then
Run (if) Program2
else
set kitchen lights off
Program2:
if
status z sensor < 50 lux
then
set kitchen lights on
You should set Program2 to disabled.
Either the Then or Else will be interrupted if anything in the "If" changes, if you have a Wait or Repeat statement in the body of the program.