html - Font size - percentage mess - and workarounds -
i figured out span
not inherit div
's font-size
, consider on 50% 100%. so, following example won't same 100% span
, because 100% is: 16(100%)
-8(50%)
+4(50% of 50%)
= 12px(150% <span>)
. needed 200% same.
my question is: can done that, if want use %
. there workarounds(something css reset - it's different, know)? if not, best alternative making more simple development, yet effective responsiveness styling?
css:
body { font-size: 16px; } div { font-size: 50%; } div > p > span { font-size: 150%; }
html:
<div> p p p <p> <span> span </span> </p> </div>
Comments
Post a Comment