From ddfde7ccd8054c3f3f4e085e829e00c93ff09749 Mon Sep 17 00:00:00 2001 From: Alvie Rahman Date: Tue, 12 Apr 2022 16:43:24 +0100 Subject: [PATCH] more dark mode stuff --- base.css | 35 +++++++++++++++++++++++++++-------- 1 file changed, 27 insertions(+), 8 deletions(-) diff --git a/base.css b/base.css index fdfe363..df1d897 100644 --- a/base.css +++ b/base.css @@ -3,6 +3,10 @@ --bg-light-mode: #fefefe; --fg-dark-mode: #ccc; --bg-dark-mode: #111; + --a-light-mode: #07a; + --a-visited-light-mode: #941352; + --a-dark-mode: #07a; + --a-visited-dark-mode: #aa346d; } body { @@ -17,14 +21,8 @@ body { background-color: var(--bg-light-mode); } -@media (prefers-color-scheme: dark) { - color: var(--fg-dark-mode); - background-color: var(--bg-dark-mode); - -} - -a { color: #07a; } -a:visited { color: #941352; } +a { color: var(--a-light-mode); } +a:visited { color: var(--a-visited-light-mode); } .tableWrapper { max-width: 100%; @@ -104,3 +102,24 @@ kbd { margin-left: 0.2em; margin-right: 0.2em; } + + +@media (prefers-color-scheme: dark) { + body { + color: var(--fg-dark-mode); + background-color: var(--bg-dark-mode); + } + img, video { + opacity: .75; + transition: opacity .5s ease-in-out; + } + img:hover, video:hover { + opacity: 1; + } + a { + color: var(--a-dark-mode); + } + a:visited { + color: var(--a-visited-dark-mode); + } +}