Hopefully this is what you are trying to achieve. From what I understood you want to centre the box in the middle of the image.
The logic I used was calculating the left position of .text-and-image-box2
(100% of parent - own width/2)
Edit: I would also consider going over your css and cleaning it up a little. There is a lot of "unnecessary noise" that can be removed such as object-fit 3xtimes
.text-and-image {
position: relative;
width: 100%;
height: auto;
max-height: 450px;
display: flex;
overflow:hidden;
object-fit: cover;
background: steelblue;
justify-content: center;
align-items: center;
/* background: rgb(156, 156, 156); */
}
.text-and-image-box{
position: relative;
width: 100%;
height: auto;
object-fit: cover;
}
.text-and-image-image{
width: 100%;
max-height: 600px;
height: auto;
background: yellow;
object-fit: cover;
}
.text-and-image-box2{
position: absolute;
left: calc(100% - 17,5%);
width: 35%;
padding: 2%;
height: auto;
background: white;
}
.text-and-image-caption{
position: relative;
height: auto;
background: white;
font-size: 30px;
font-style: oblique;
}
<!DOCTYPE html>
<html lang="en" dir="ltr">
<head>
<meta charset="utf-8" name="Website">
<link rel="stylesheet" href="./fragebeispiel.css">
<title>AMH Solingen</title>
</head>
<body>
<!-- Text neben Bild -->
<div class="text-and-image">
<div class="text-and-image-box">
<img class="text-with-image-image" src="https://images.unsplash.com/photo-1513135065346-a098a63a71ee?ixid=MXwxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHw%3D&ixlib=rb-1.2.1&auto=format&fit=crop&w=1049&q=80">
</div>
<div class="text-and-image-box2">
<p class="text-and-image-caption">Ein schlechtes Messer f?hrt leichter in die Hand als ins Brot.</p>
<p class="text-and-image-text">Jeder Hobby- oder Profikoch braucht gutes Werkzeug. Nur damit macht es Spa? und ist sicher. Solinger Küchenmesser und Stahlwaren bestechen schon seit Jahrhunderten durch ausgezeichnete Qualit?t, hohe Langlebigkeit und innovative L?sungen. Das merkt man und hat seinen Weg schon in Millionen von Küchen in aller Welt gefunden. Unser Statement: </p>
</div>
</div>
</body>
</html>
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…