Hi @ticktickatick this sounds like it might a specificity issue in your CSS. It is possible that somewhere else in your stylesheet you have some additional padding / margin that is being applied to an <a>
tag.
Depending on how specific that styling is, it could be overwriting your styles. For example:
a img.alignnone {
margin: 5px 20px 20px 0;
}
Is less specific than:
.post-entry figure a .alignnone {
margin: 5px 50px 50px 0;
}
The first example is nested 3 levels deep, but the second is 4 levels deep which makes it more specific. Or additional padding / margins could be applied to the <a>
tag as well. For example:
.post-entry a {
margin: 5px 50px 50px 0;
}
Would also apply to your image.
In these cases you probably need to make your CSS slightly more specific to make sure your styles override any others written in the stylesheet.
There is a couple of ways you can check what is being applied and what is not. In Chrome you could use Chrome devtools to right click on the image, select inspect from the menu and then in the elements panel click the <img />
tag and the <a>
tag to see what styles are being applied to each html element in the styles panel. Often you will see your styles further down the list and crossed out, at the top is whatever is overwriting them.
Next to Styles on the second panel is a tab for Computed. This will show you exactly what is being applied so this is where you can see exactly what the browser is using. Firefox’s inspector is also really here if you prefer that.
If neither of these work, I like to try to do a reduced test case in codepen.io or jsFiddle to try to recreate the error there without all of the rest of the theme styles affecting it. That way you can often find a fix more easily.
I hope that helps! ??