Updating Header typography

This commit is contained in:
Bob den Otter
2021-01-09 13:59:21 +01:00
committed by GitHub
parent 5301fbe90b
commit d31a4b34ec
+19 -10
View File
@@ -5,6 +5,10 @@
--sans-font: -apple-system, BlinkMacSystemFont, "Avenir Next", Avenir, "Nimbus Sans L", Roboto, Noto, "Segoe UI", Arial, Helvetica, "Helvetica Neue", sans-serif;
--mono-font: Consolas, Menlo, Monaco, "Andale Mono", "Ubuntu Mono", monospace;
--base-fontsize: 18.4px;
--header-scale: 1.2; /* Minor third */
--line-height: 1.618; /* Golden ratio */
/* Default (light) theme */
--bg: #fff;
--accent-bg: #F5F7FF;
@@ -39,12 +43,13 @@
font-family: var(--sans-font);
}
/* Make the body a nice central block */
body {
color: var(--text);
background: var(--bg);
font-size: 1.15rem;
line-height: 1.5;
font-size: var(--base-fontsize);
line-height: var(--line-height);
margin: 0;
}
@@ -115,29 +120,33 @@ footer {
/* Format headers */
h1 {
font-size: 2.25rem;
font-size: calc(var(--base-fontsize) * var(--header-scale) * var(--header-scale) * var(--header-scale) * var(--header-scale));
margin-top: calc(var(--line-height) * 1.5rem);
}
h2 {
font-size: 1.85rem;
margin-top: 3rem;
font-size: calc(var(--base-fontsize) * var(--header-scale) * var(--header-scale) * var(--header-scale));
margin-top: calc(var(--line-height) * 1.5rem);
}
h3 {
font-size: 1.55rem;
margin-top: 3rem;
font-size: calc(var(--base-fontsize) * var(--header-scale) * var(--header-scale));
margin-top: calc(var(--line-height) * 1.5rem);
}
h4 {
font-size: 1.25rem;
font-size: calc(var(--base-fontsize) * var(--header-scale));
margin-top: calc(var(--line-height) * 1.5rem);
}
h5 {
font-size: 1.15rem;
font-size: var(--base-fontsize);
margin-top: calc(var(--line-height) * 1.5rem);
}
h6 {
font-size: .9rem;
font-size: calc(var(--base-fontsize) / var(--header-scale));
margin-top: calc(var(--line-height) * 1.5rem);
}
/* Format links & buttons */