Removing cursor reset as it breaks default user agent styles on some browsers. Fixes #412

Fixes #371
Do not allow infinite recursion searching for layout. Credits to @algimantas