Currently, I am working on designing a business card that features the name and title at the center, with the email and phone number positioned on the extreme left and right sides of the card.
Below is the code snippet I have been using:
.business-card {
position: relative;
border: 1px solid black;
width: 200px;
}
.business-card section {
display: flex;
flex-flow: column;
align-items: center;
}
.email {
position: absolute;
right: 0;
}
<div class="business-card">
<section>
<span>
Name: ABC
</span>
<span>
Title: XYZ
</span>
</section>
<footer>
<span class="phone">
123-123-123
</span>
<span class="email">
<a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="e5848786a5848786cb868a88">[email protected]</a>
</span>
</footer>
</div>
.business-card {
position: relative;
border: 1px solid black;
width: 200px;
}
.business-card section {
display: flex;
flex-flow: column;
align-items: center;
}
.email {
position: absolute;
right: 0;
}
<div class="business-card">
<section>
<span>
Name: John Doe
</span>
<span>
Title: Manager
</span>
</section>
<footer>
<span class="phone">
123-456-789
</span>
<span class="email">
<a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="2f4e4d4c6f4e4d4c014c4042">[email protected]</a>
</span>
</footer>
</div>
If anyone can offer assistance in resolving this issue, it would be greatly appreciated. Please find attached a sample screenshot of the desired business card design: https://i.sstatic.net/a1TRO.jpg