JPEG has backing from the photographic industry and predates PNG by a half-dozen years or so, while PNG was designed as a replacement for GIF, which was rather zealously protected by CompuServe. People were sued for using GIFs on their websites, for example, simply because they didn't use a program that was licensed by CompuServe to make those images.
From the beginning, JPEG was designed to recover some space by making files smaller, at the expense of pixel-perfect quality. Even setting Q to 100 will cause minor, mostly invisible artifacts-- the damage is done, and each additional time the file is modified and saved, further damage will occur. However, unless you do so many times, you'll probably never notice the effect unless you go looking for it.
PNG, on the otherhand, is perfectly lossless. Every pixel is faithfully reproduced every time, no matter how many times the file is modified and saved. There's a limit to how well you can compress data without loss, however, although PNG employs several tricks to pack as much information into as few bytes of data as possible. A high quality JPEG will probably be about the same size a PNG without optimization or even larger. As PNG begins to optimize, say, by using filters or adjusting window sizes, the file becomes smaller without loss, while JPEG must start discarding visual information to keep up.
So, why is JPEG used? It is, after all, generally inferior in terms of fidelity and storage space. The main reason, of course, is that it is an industry standard and has very broad support. Virtually every camera in the world uses either RAW (literally, the raw data), or JPEG. There are hardware data processors built-in to those cameras to compress the JPEG data as fast as possible, etc.
You'll find this is the same reason why GIF is everywhere still. Most software supports GIF, while PNG enjoys lesser support in older software (e.g. older Internet Explorer versions required a plugin to show PNG files). Even though it has lousy color support, it does support animations, something PNG does not do (there is a related file format, APNG, that never quite took off the way PNG did). GIF still remains the champion of animated images, as it is the only file format that can do so with widespread support.
The cost to change from JPEG to PNG would be prohibitive from a hardware prospective. Cameras would need new processors built to support fast PNG compression, for example, because they're hard-coded to use JPEG right now. Your old cameras would be worthless, because you'd have to buy a new one with a PNG chip built-in. That would also mean you'd have to convince a manufacturer to go against industry standards and start manufacturing such devices, which means there'd have to be enough demand to justify it, and such cameras would initially be more expensive than their JPEG-based counterparts. It's very difficult to change an industry.