Switch to media logic for themes and misc fixes

This commit is contained in:
Jonas Tobias Hopusch 2021-07-19 00:06:57 +02:00
parent 6a63b32199
commit b57b53554e
Failed to generate hash of commit

View file

@ -11,29 +11,54 @@ header, footer {
.globalnav{
display: flex;
flex-direction: row;
border-collapse: collapse;
border: none;
}
.globalnav-element {
display: inline-block;
border-width: 1px;
border-style: solid;
flex-grow: 1;
padding: 0.5em 0;
margin: 0 1px;
}
body.dark-theme a {
code {
display: inline-block;
background-color: lightgray;
color: green;
padding: 0 0.5em;
}
@media (prefers-color-scheme: dark) {
html {
background-color: black;
color: white;
}
.globalnav-element {
background-color: #222;
}
code {
background-color: #444;
color: lawngreen;
}
a {
color: lightskyblue;
}
}
body.dark-theme .globalnav-element {
border-color: black;
}
@media (prefers-color-scheme: light) {
html {
background-color: white;
color: black;
}
body.light-theme .globalnav-element {
border-color: white;
}
.globalnav-element {
background-color: #ddd;
}
pre, code {
background-blend-mode: darken;
color: lightgreen;
code {
color: green;
}
}