Last active
August 12, 2020 01:53
-
-
Save alexmustin/dc3317e189626854797061db2b17b1b1 to your computer and use it in GitHub Desktop.
CSS - Responsive Body and Header font sizes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
body { | |
-webkit-font-smoothing: antialiased; | |
-moz-osx-font-smoothing: grayscale; | |
font-size: calc(.35vw + 1rem); | |
line-height: 1.8; | |
} | |
h1 { | |
font-size: calc(2.0vw + 1rem); | |
} | |
h2 { | |
font-size: calc(1.66vw + 1rem); | |
line-height: 1.3216; | |
} | |
h3 { | |
font-size: calc(.8vw + 1rem); | |
} | |
h4 { | |
font-size: calc(.66vw + 1rem); | |
} | |
h5 { | |
font-size: calc(.5vw + 1rem); | |
} | |
h6 { | |
font-size: calc(.4vw + 1rem); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment