I'm trying to center align the title, description, and button over the image on my site. Is there an efficient way of doing this? Maybe some custom CSS that would group them together and center them within the container?
Any help would be greatly appreciated, thanks.
.text-container {
position: relative;
}
.text-container .btn {
background-color: #FFFFFF;
color: #181818;
transition: 0.3s;
}
.text-container:hover .btn {
background-color: #545454;
color: #FFFFFF;
transition: 0.3s;
}
.overlay-header-first {
color: #FFFFFF;
font-size: 1.8rem;
position: absolute;
bottom: 25%;
left: 20%;
text-align: center;
}
.overlay-description-first {
color: #FFFFFF;
font-size: 1rem;
position: absolute;
bottom: 17%;
left: 20%;
text-align: center;
}
.overlay-button-first {
position: absolute;
bottom: 11%;
left: 20%;
}
<section id="tiles" data-sequence="100">
<div class="container-fluid">
<div class="row no-gutters align-items-center pt-4 animatedParent animateOnce">
<div class="col-md-6 pb-4 pb-lg-0 overlay text-container animated fadeIn slowest" data-id="1">
<a href="#"><img src="tree.png" class="img-fluid"></a>
<a href="#"><h2 class="overlay-header-first mb-4">TITLE ONE</h2></a>
<p class="overlay-description-first">Lorem ipsum dolor sit amet, consectetur adipiscing.<br>Elit ut ultrices pulvinar tristique.</p>
<a href="#"><btn class="btn btn-dark overlay-button-first">SHOP NOW</btn></a>
</div>
<div class="col-md-6 pb-4 pb-lg-0 overlay text-container animated fadeIn slowest" data-id="2">
<a href="#"><img src="tree.png" class="img-fluid"></a>
<a href="#"><h2 class="overlay-header-first mb-4">TITLE TWO</h2></a>
<p class="overlay-description-first">Lorem ipsum dolor sit amet, consectetur adipiscing.<br>Elit ut ultrices pulvinar tristique.</p>
<a href="#"><btn class="btn btn-dark overlay-button-first">SHOP NOW</btn></a>
</div>
</div>
</div>
</section>
