267 lines
4.6 KiB
CSS
Executable file
267 lines
4.6 KiB
CSS
Executable file
@import url("https://necolas.github.io/normalize.css/8.0.1/normalize.css");
|
|
|
|
/* Document form */
|
|
|
|
:root {
|
|
--base-scale: 16px;
|
|
|
|
--background-color: hsl(0, 0%, 15%);
|
|
--color: hsl(0, 0%, 85%);
|
|
--accent-color: #808080;
|
|
--accent-color-fg: hsl(0, 0%, 95%);
|
|
--font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
|
|
Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji",
|
|
"Segoe UI Symbol";
|
|
--document-width: 40em;
|
|
|
|
--border-style: calc(1em / 16) solid var(--color);
|
|
}
|
|
|
|
body {
|
|
width: 100vw;
|
|
max-width: var(--document-width);
|
|
margin: auto;
|
|
padding-inline: 0.5em;
|
|
padding-block: 0.5em;
|
|
}
|
|
|
|
html.base {
|
|
--background-color: #fff !important;
|
|
--color: #000 !important;
|
|
--accent-color: #000 !important;
|
|
--accent-color-fg: #fff !important;
|
|
--font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
|
|
Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji",
|
|
"Segoe UI Symbol" !important;
|
|
--document-width: 40em;
|
|
|
|
--border-style: calc(1em / 16) solid var(--color);
|
|
transition: none;
|
|
}
|
|
|
|
html.base body {
|
|
margin: 0;
|
|
}
|
|
|
|
html.base * {
|
|
transition: none;
|
|
}
|
|
|
|
/* Size and type normalize */
|
|
|
|
html {
|
|
font-size: var(--base-scale);
|
|
line-height: 1em;
|
|
background-color: var(--background-color);
|
|
color: var(--color);
|
|
}
|
|
|
|
main {
|
|
margin-block: 1em;
|
|
}
|
|
|
|
h1 {
|
|
font-size: 2em;
|
|
line-height: 1.5em;
|
|
margin: 0;
|
|
margin-block: 0.125em;
|
|
}
|
|
|
|
h2 {
|
|
font-size: 1.5em;
|
|
line-height: 1.25em;
|
|
margin: 0;
|
|
margin-block: 0.25em;
|
|
}
|
|
|
|
h3 {
|
|
font-size: 1.1em;
|
|
line-height: 1.25em;
|
|
margin: 0;
|
|
margin-block: 0.25em;
|
|
}
|
|
|
|
p {
|
|
font-size: 1em;
|
|
line-height: 1.25em;
|
|
margin-inline: 0;
|
|
margin-block: 0.5em;
|
|
}
|
|
|
|
ul,
|
|
ol {
|
|
padding: 0;
|
|
padding-inline-start: 1em;
|
|
margin: 0;
|
|
margin-block: 0.5em;
|
|
}
|
|
|
|
li {
|
|
margin-inline: 0;
|
|
margin-block: 0.5em;
|
|
}
|
|
|
|
small {
|
|
font-size: 0.75em;
|
|
}
|
|
|
|
big {
|
|
font-size: 1.5em;
|
|
}
|
|
|
|
code {
|
|
font-size: 1em;
|
|
line-height: 1.25em;
|
|
font-family: monospace;
|
|
}
|
|
|
|
hr {
|
|
border: none;
|
|
border-top: var(--border-style);
|
|
background-color: transparent;
|
|
margin-inline: 0;
|
|
margin-block: 0.25em;
|
|
}
|
|
|
|
/* Form normalize */
|
|
|
|
html {
|
|
font-family: var(--font-family);
|
|
}
|
|
|
|
* {
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
*:focus {
|
|
outline: 2px solid var(--accent-color-fg);
|
|
}
|
|
|
|
fieldset {
|
|
border: var(--border-style);
|
|
padding-inline: 0.5em;
|
|
padding-block: 0.25em;
|
|
margin-inline: 0;
|
|
margin-block: 0.5em;
|
|
font-size: 1em;
|
|
background-color: var(--background-color);
|
|
color: var(--color);
|
|
}
|
|
|
|
/* Interactive normalize */
|
|
|
|
a {
|
|
color: var(--accent-color);
|
|
}
|
|
|
|
a:hover,
|
|
a:focus {
|
|
opacity: 0.8;
|
|
}
|
|
|
|
a:active {
|
|
opacity: 0.5;
|
|
}
|
|
|
|
input,
|
|
select,
|
|
textarea {
|
|
font-family: inherit;
|
|
border: var(--border-style);
|
|
padding-inline: 0.5em;
|
|
padding-block: 0.25em;
|
|
margin-inline: 0;
|
|
margin-block: 0.25em;
|
|
font-size: 1em;
|
|
background-color: var(--background-color);
|
|
color: var(--color);
|
|
}
|
|
|
|
input:disabled {
|
|
opacity: 0.5;
|
|
}
|
|
|
|
button,
|
|
input[type="button"],
|
|
input[type="submit"],
|
|
input[type="reset"] {
|
|
border: var(--border-style);
|
|
padding-inline: 0.5em;
|
|
padding-block: 0.25em;
|
|
margin-inline: 0;
|
|
margin-block: 0.25em;
|
|
font-size: 1em;
|
|
line-height: 1.25em;
|
|
font-family: inherit;
|
|
background-color: var(--accent-color);
|
|
color: var(--accent-color-fg);
|
|
}
|
|
|
|
button[data-outlined],
|
|
input[type="button"][data-outlined],
|
|
input[type="submit"][data-outlined],
|
|
input[type="reset"][data-outlined] {
|
|
border: var(--border-style);
|
|
background-color: var(--background-color);
|
|
color: var(--accent-color);
|
|
}
|
|
|
|
button:hover,
|
|
input[type="button"]:hover,
|
|
input[type="submit"]:hover,
|
|
input[type="reset"]:hover,
|
|
button:focus,
|
|
input[type="button"]:focus,
|
|
input[type="submit"]:focus,
|
|
input[type="reset"]:focus {
|
|
opacity: 0.8;
|
|
}
|
|
button:active,
|
|
input[type="button"]:active,
|
|
input[type="submit"]:active,
|
|
input[type="reset"]:active {
|
|
opacity: 0.5;
|
|
}
|
|
|
|
/* -- Checkbox styling */
|
|
|
|
label.checkbox {
|
|
display: inline-block;
|
|
position: relative;
|
|
margin-inline: 0;
|
|
margin-block: 0.25em;
|
|
}
|
|
|
|
label.checkbox input[type="checkbox"] {
|
|
/* visibility: hidden; */
|
|
opacity: 0;
|
|
width: 0;
|
|
height: 0;
|
|
position: absolute;
|
|
top: 0;
|
|
left: 0;
|
|
}
|
|
|
|
label.checkbox input[type="checkbox"] + span.checkbox {
|
|
display: inline-block;
|
|
width: 1em;
|
|
height: 1em;
|
|
line-height: 1em;
|
|
padding-inline: 0.25em;
|
|
padding-block: 0.25em;
|
|
box-sizing: content-box;
|
|
border: var(--border-style);
|
|
color: transparent;
|
|
text-align: center;
|
|
user-select: none;
|
|
}
|
|
|
|
label.checkbox input[type="checkbox"]:focus + span.checkbox {
|
|
outline: 2px solid var(--accent-color-fg);
|
|
}
|
|
|
|
label.checkbox input[type="checkbox"]:checked + span.checkbox {
|
|
background-color: var(--accent-color);
|
|
border: var(--border-style);
|
|
color: var(--accent-color-fg);
|
|
}
|