I currently have a vanilla website with numerous posts, each of which has a banner feature image set to "top aligned" as the default setting. This results in an unappealing layout. I am looking for a way to vertically center align all banner featured images.
I attempted to use the following .css code from a post, but unfortunately it did not work when added to style.css. It seems to only affect the main landing page.
.banner {
overflow: hidden;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
}
If anyone has a straightforward solution that does not require plugins, I would greatly appreciate your help. Thank you.