Palette compression, explained
A PNG can store up to 16 million colours, but a screenshot or logo usually uses a few hundred. Reducing the palette to 256 well-chosen colours and adding fine dithering where gradients need it shrinks the file dramatically while the image looks the same. This is the same approach tools like TinyPNG and pngquant take.