I actually had the same misconception about light when studying it in highschool. I though that the up/down things that the teacher was drawing on the board was not literally how it worked (transverse wave) but that it was a measurement of the longitudinal wave. I think because I knew how sound worked, and I was thinking that way.
It turns out that it actually is a transverse wave in the electric field with another transverse wave in the magnetic field offset by 90 degrees. There is a good diagram of how it 'looks' here: