-1
I’m trying to put a text and a button inside an image, but I’m not able to keep them responsive.
.dados {
bottom: 10px;
right: 0;
}
.text {
font-family: "Arial Bold", Arial;
font-weight: 700;
font-size: 22px;
color: #ffffff !important;
}
<!DOCTYPE html>
<html lang="pt-br">
<head>
<title>Teste</title>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="stylesheet" type="text/css" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css" />
<link rel="stylesheet" type="text/css" href="css/style.css" />
</head>
<body>
<div class="container">
<div class="row mt-4">
<div class="col-4">
<div class="position-relative">
<img src="https://via.placeholder.com/300" alt="">
<div class="position-absolute dados">
<h3 class="text-right text">Testes?<br>Teste teste teste teste</h3>
<button class="btn btn-primary float-right">veja detalhes</button>
</div>
</div>
</div>
<div class="col-4">
<div class="position-relative">
<img src="https://via.placeholder.com/300" alt="">
<div class="position-absolute dados">
<h3 class="text-right text">Testes?<br>Teste teste teste teste</h3>
<button class="btn btn-primary float-right">veja detalhes</button>
</div>
</div>
</div>
<div class="col-4">
<div class="position-relative">
<img src="https://via.placeholder.com/300" alt="">
<div class="position-absolute dados">
<h3 class="text-right text">Testes?<br>Teste teste teste teste</h3>
<button class="btn btn-primary float-right">veja detalhes</button>
</div>
</div>
</div>
</div>
</div>
</body>
</html>
I want this information to stay inside the image, in the lower right corner. Someone knows how to do it, so that you stay responsive?