Write an optimized function to detect if a linked list contains a cycle, and if so, find the starting node of the cycle.