An electric field and a magnetic field hold energy just by existing. The electric share is and the magnetic share is , each going with the square of the field strength.
Squares do not care about sign. The lower curve in the figure is the energy, equally large at a crest and at a trough, vanishing only at the nodes where the field passes through zero. That is why it peaks twice per wavelength.
In an electromagnetic wave holds, which makes the two shares equal at every moment. The energy sits half in one field and half in the other.
How much energy flows and in what direction is given by , the Poynting vector.
Being a cross product, it points at right angles to both fields. In an electromagnetic wave both are already at right angles to the travel, so the only direction left is the travel itself. Energy is carried the way the wave goes.
When both fields flip sign in the figure, the energy arrow does not turn. Flipping both leaves the cross product pointing the same way. There is no back and forth; it is always forward.
Double the amplitude and the energy carried goes up four times. The square is what does it, and the bars in the figure stand at 1 and 4.
What an eye or an instrument actually receives is the average over the fast oscillation. That average is the intensity, and it too goes with the square of the amplitude.
To make light twice as bright, doubling the swing of the electric field is far more than enough. Multiplying it by is what doubles the brightness.
Light leaving a point source spreads in every direction. The total leaving never changes, but the area of the sphere it spreads over grows with the square of the distance.
So a patch of fixed area receives an amount that falls with the square of the distance. Twice as far away is a quarter as much, three times as far is a ninth. The bars in the figure are that ratio.
This law is what lets brightness measure distance. For a star whose true output is known, comparing it with the brightness that arrives gives how far away it is.