My goal is to create a button that has multi-line text and an icon next to it that is centered for both lines. Here's a screenshot for better understanding
However, I'm not able to center the button. The icon is always next to the first line of the button, not to the second.
The code of my button
.btn {
position: relative;
overflow: hidden;
transform: translate3d(0, 0, 0);
font-family: "Ubuntu", sans-serif;
font-weight: 600;
border: transparent;
padding: 6px 16px;
transition: background-color 100ms ease;
outline: none !important;
border-radius: 4px;
line-height: 28px;
background-color: #FBBC06;
font-size: 18px;
color: #022753;
box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.35);
}
.btn:before {
font-family: 'Material Icons';
content: 'shopping_cart';
font-feature-settings: 'liga';
font-size: 50px;
}
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
<button class="btn">
<span>von günstigstem Anbieter<br> in den Warenkorb legen</span>
</button>
As you can see the icon is only aligned to the first line in the button, but I want to have it vertically aligned to both of the lines.
I tried it without the span as well but the result was the same.