Begin line detection