My recipe panels have photos and titles, but the titles are too long to fit in the designated size. Despite using word-break: break-word, it doesn't seem to be working as intended. This example illustrates my issue:
https://i.sstatic.net/HbKuI.png
Here is a snippet of my code:
<div class="recipe-container">
<div class="recipe-window">
<a href="https://www.bbcgoodfood.com/recipes/easy-millionaires-shortbread"><img src="https://images.immediate.co.uk/production/volatile/sites/30/2020/08/millionaires-shortbread-52587dd.jpg?quality=90&webp=true&resize=300,272"></a>
<p class="recipe-title">Millionare's Shortbread</p>
</div>
<div class="recipe-window">
<a href="https://www.bbcgoodfood.com/recipes/classic-white-loaf"><img src="https://images.immediate.co.uk/production/volatile/sites/30/2020/08/recipe-image-legacy-id-559666_11-b53071d.jpg?quality=90&webp=true&resize=300,272"></a>
</div>
</div>
.recipe-container {
margin: 0px;
padding: 10px;
display: inline-flex;
}
.recipe-window {
margin: 10px;
padding: 10px;
border: 1px solid #ffffff;
background-color: #ffffff;
word-break: break-word;
width: auto;
}
.recipe-title {
color: black;
margin-top: 5px;
padding: 0px;
font-size: 40px;
}
Any suggestions on how I can resolve this issue?