The term literally references lightning, a phenomenon that usually occurs during a dark sky (rain clouds). When such an event occurs when it is not supposed to (blue sky, no clouds), it has a tendency to catch you off guard.