When reconnectLoop fails at waitForHello, sendIdentify, or waitForReady,
the connection is closed but p.wsConn still points to the closed conn.
This leaves a stale reference that Stop() may double-close and that
sendHeartbeat/readLoop may write to if they race with the reconnect.
Reset p.wsConn to nil under the mutex before closing the failed
connection, consistent with how connectGateway and the reconnect
loop prologue handle cleanup.