Set a font-size

Hi everyone I realise a title on my page but I have a problem with th font
<div class="text">
<h1> <span>men</span>fashion </h1>
</div>
<div class="text">
<h1> <span>men</span>fashion </h1>
</div>
my CSS:
h1 {
text-transform: uppercase;
font-size:4em;
line-height: 1;
}

span{
display: block;
font-size: .2em;
}
h1 {
text-transform: uppercase;
font-size:4em;
line-height: 1;
}

span{
display: block;
font-size: .2em;
}
can I get an idea to fix this please thanks.
8 Replies
Jochem
Jochem2y ago
em isn't a good match for font-size, but other than that, what's the problem exactly? Other than the text being illegible on that background, but that's not a size issue
Mannix
Mannix2y ago
i'm guessing what wrong is that men is not inline with the fashion
Jochem
Jochem2y ago
is that the space maybe?
Mannix
Mannix2y ago
maybe text-indent can fix your problem
Jochem
Jochem2y ago
hard to analyse without a working example though
Pat66
Pat66OP2y ago
the problem is font-size
Pat66
Pat66OP2y ago
what I want he title should have the same height
Jochem
Jochem2y ago
use rem for font-size, em can give very unpredictable and unstable results for sizes because it's based on the current element's font size, which is based on the parent and so on. rem is just the font-size of the root element, so 5rem is 5rem everywhere
Want results from more Discord servers?
Add your server