I'm trying achieve the following; Rotating the text is not the problem however the line under it is. It is supposed to change according to how long the text is. Meaning if the text changes in length the line shrinks or expands accordingly. The top of the text should remain at the same location.
Any ideas ?
EDIT:
what i've tried so far (disregard the flex):
<section class="slideshow">
<div class="forsale">
<a href="#">te koop</a>
<span></span>
</div>
<img src="./img/project_1.jpg" alt="">
</section>
.forsale {
position: relative;
a {
position: absolute;
transform: rotate(-90deg) translate(0 ,100%;
transform-origin:0% 0%;
background-color: #eee;
display: block;
text-decoration: none;
color: black;
width: 385px;
}
span {
display: block;
width: 1px;
height: 100%;
background-color: black;
position: absolute;
left: 50%;
bottom: 0;
}
}