From 56c867b5bb460755480e3ba95f6f028e7cd35a6a Mon Sep 17 00:00:00 2001 From: Filip Wandzio Date: Sun, 28 Sep 2025 20:55:35 +0200 Subject: Change background color to smoky black in dark mode Signed-off-by: Filip Wandzio --- src/app.css | 137 +++++++++++++++++++++++++++++------------------------------- 1 file changed, 67 insertions(+), 70 deletions(-) (limited to 'src/app.css') diff --git a/src/app.css b/src/app.css index 829967c..f99121b 100644 --- a/src/app.css +++ b/src/app.css @@ -11,11 +11,49 @@ @media (prefers-color-scheme: dark) { :root { - --bg-color: #000c18; + --bg-color: #100c08; --text-color: #b7b8b9; } } +.sr-only { + position: absolute; + width: 1px; + height: 1px; + margin: -1px; + padding: 0; + overflow: hidden; + clip: rect(0 0 0 0); + border: 0; +} + +a { + color: var(--accent-color); + font-weight: 700; + text-decoration: underline; + text-decoration-color: transparent; + text-underline-offset: 4px; + text-decoration-thickness: 2px; + transition: color 0.3s, text-decoration-color 0.3s; +} + +a:hover, +a:focus { + color: var(--accent-hover); + text-decoration-color: currentColor; +} + +a:focus-visible { + outline: 3px solid var(--accent-color); + outline-offset: 4px; + border-radius: 3px; +} + +.highlight { + background: var(--accent-hover); + color: #fcfdfe; +} + body { margin: 0; font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, @@ -42,17 +80,17 @@ h2 { } @media (max-width: 768px) { - h1 { + h1, h2 { font-size: 1.75rem; } +} - h2 { - font-size: 1.75rem; - } +section { + margin-bottom: 3em; + padding: 0 2%; } -header, -footer { +header { padding: 0.5em; text-align: center; background: var(--bg-color); @@ -63,30 +101,6 @@ header h1 { padding-left: 1rem; } -main { - flex-grow: 1; - max-width: 900px; - margin: 0 auto; - padding: 2em; -} - -@media (max-width: 768px) { - main { - padding: 1.5em; - } -} - -footer { - text-align: center; - font-size: 1.05rem; - color: var(--text-color); -} - -section { - margin-bottom: 3em; - padding: 0 2%; -} - .header-top { display: flex; justify-content: center; @@ -99,6 +113,13 @@ section { justify-content: space-between; text-align: left; } + + header { + position: sticky; + top: 0; + z-index: 1000; + background: var(--bg-color); + } } nav ul { @@ -140,49 +161,25 @@ nav a { nav ul.open { display: flex; } - - header { - position: sticky; - top: 0; - z-index: 1000; - background: var(--bg-color); - } -} - -.sr-only { - position: absolute; - width: 1px; - height: 1px; - margin: -1px; - padding: 0; - overflow: hidden; - clip: rect(0 0 0 0); - border: 0; } -a { - color: var(--accent-color); - font-weight: 700; - text-decoration: underline; - text-decoration-color: transparent; - text-underline-offset: 4px; - text-decoration-thickness: 2px; - transition: color 0.3s, text-decoration-color 0.3s; -} - -a:hover, -a:focus { - color: var(--accent-hover); - text-decoration-color: currentColor; +main { + flex-grow: 1; + max-width: 900px; + margin: 0 auto; + padding: 2em; } -a:focus-visible { - outline: 3px solid var(--accent-color); - outline-offset: 4px; - border-radius: 3px; +@media (max-width: 768px) { + main { + padding: 1.5em; + } } -.highlight { - background: var(--accent-hover); - color: #fcfdfe; +footer { + padding: 0.5em; + text-align: center; + font-size: 1.05rem; + color: var(--text-color); + background: var(--bg-color); } -- cgit v1.2.3