Reduce HTML’s font-size to (usually) have 1rem = 10px

It is far easier for me to “see” the sizes if they are multiples of 10,
especially given that the designs we do in Penpot use a 10 × 10 pixels
grid.
This commit is contained in:
jordi fita mas 2023-01-22 20:27:43 +01:00
parent 8fa3367f6c
commit 6f2da865c0
1 changed files with 26 additions and 14 deletions

View File

@ -164,11 +164,13 @@ html, body {
html { html {
font-family: var(--numerus--font-family), monospace; font-family: var(--numerus--font-family), monospace;
font-size: 62.5%;
} }
body { body {
color: var(--numerus--text-color); color: var(--numerus--text-color);
background-color: var(--numerus--background-color); background-color: var(--numerus--background-color);
font-size: 1.6rem;
line-height: 1.5; line-height: 1.5;
-webkit-font-smoothing: antialiased; -webkit-font-smoothing: antialiased;
} }
@ -203,17 +205,19 @@ input[type="submit"]:active, button:active {
} }
.web { .web {
margin: 5.3125rem 2.5rem; margin: 8.5rem 4rem;
background-color: var(--numerus--header--background-color); background-color: var(--numerus--header--background-color);
} }
.web h1 { .web h1 {
margin-bottom: 1.875em; padding-bottom: .9375em;
border-bottom: 1px solid var(--numerus--color--black);
margin-bottom: .625em;
} }
#login { #login {
background-color: var(--numerus--color--hay); background-color: var(--numerus--color--hay);
padding: 1.5625em; padding: 1.25em;
} }
#login h2 { #login h2 {
@ -221,7 +225,7 @@ input[type="submit"]:active, button:active {
} }
div[role="alert"].error { div[role="alert"].error {
padding: 1.3125em; padding: 1.25em;
background-color: var(--numerus--color--red); background-color: var(--numerus--color--red);
} }
@ -230,7 +234,7 @@ header {
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
background-color: var(--numerus--header--background-color); background-color: var(--numerus--header--background-color);
padding: .625rem 1.875rem; padding: 1rem 3rem;
} }
nav { nav {
@ -238,8 +242,8 @@ nav {
} }
nav > button { nav > button {
width: 4.375rem; width: 7rem;
height: 4.375rem; height: 7rem;
display: flex; display: flex;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
@ -256,24 +260,32 @@ nav ul {
padding: none; padding: none;
position: absolute; position: absolute;
right: -1.875em; right: -1.875em;
top: calc(100% + .625rem); top: calc(100% + 1rem);
padding: 1rem 2rem;
background-color: var(--numerus--color--white);
}
nav ul li + li {
border-top: 1px solid var(--numerus--color--black);
} }
nav ul button, nav ul a { nav ul button, nav ul a {
height: 5.25rem; font-size: 2rem;
width: 31.25rem; font-style: italic;
padding: 0 1.875rem; height: 8rem;
width: 46rem;
padding-left: 2rem;
display: flex; display: flex;
align-items: center; align-items: center;
border: 0; border: 0;
background-color: var(--numerus--color--white);
color: var(--numerus--text-color); color: var(--numerus--text-color);
text-decoration: none; text-decoration: none;
text-transform: initial;
} }
nav ul i[class^='ri-'] { nav ul i[class^='ri-'] {
font-size: 1.25em; margin-right: 2rem;
margin-right: 1.25rem; color: var(--numerus--color--dark-gray);
} }
nav ul button:hover, nav ul a:hover { nav ul button:hover, nav ul a:hover {