Universal first-passage properties of discrete-time random walks and Lévy flights on a line: Statistics of the global maximum and records