So the solution is to first change the empty div (styled inline with a background-image) to a div containing an img tag. Then change the .portfolio__project__preview > img
class from:
width: 100%
height: auto;
to:
max-width: 100%;
object-fit: cover;
this works and now shows the complete image at all times. Thanks everyone for helping.
Moving on to sort out the responsive images srcset business now.