I have a PNG image that is 500x500 pixels with a transparent background. Unfortunately, the image contains a lot of empty space around it, causing it to appear as if it has excessive margins or padding when used in my HTML.
What I actually need from the image is just the central portion which is 250x250 pixels, leaving 125px of transparent empty space on all sides. Is there a way to use CSS to achieve the appearance of cropping the sides of the image?
Since the images are fetched from an API, cropping the sides using software like Photoshop is not an option.
Check out this example image I'm working with -