Skip to content

Commit 4b502de

Browse files
committed
Fix light mode bugs
1 parent 2d2ec7c commit 4b502de

1 file changed

Lines changed: 38 additions & 1 deletion

File tree

src/_css/theme.css

Lines changed: 38 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,32 @@
33
Theme is set on <html> element to prevent flash
44
============================================ */
55

6+
/* Default/fallback: use system preference */
7+
:root {
8+
--color-bg: #af9b75;
9+
--color-off-white: #cac4a6;
10+
--color-text-body: #2A2A2A;
11+
--color-text-secondary: #6B6B6B;
12+
--color-accent: #993399;
13+
--color-deco-A: #D4A574;
14+
--color-deco-B: #FFB4A2;
15+
--color-deco-C: #8B7355;
16+
}
17+
18+
@media (prefers-color-scheme: dark) {
19+
:root {
20+
--color-bg: #1A1612;
21+
--color-off-white: #2D2620;
22+
--color-text-body: #E8E6E3;
23+
--color-text-secondary: #A8A8A8;
24+
--color-accent: #C97AB8;
25+
--color-deco-A: #8B6F47;
26+
--color-deco-B: #B8755E;
27+
--color-deco-C: #A68B6A;
28+
}
29+
}
30+
31+
/* Explicit theme overrides (set by JS) */
632
:root[data-theme="light"] {
733
--color-bg: #af9b75;
834
--color-off-white: #cac4a6;
@@ -25,7 +51,18 @@
2551
--color-deco-C: #A68B6A;
2652
}
2753

28-
/* Tint black icons to match --color-text-body */
54+
/* Tint black icons to match theme - default to light */
55+
.external-link-icon {
56+
filter: invert(0.25);
57+
}
58+
59+
@media (prefers-color-scheme: dark) {
60+
.external-link-icon {
61+
filter: invert(0.7);
62+
}
63+
}
64+
65+
/* Explicit theme overrides for icons */
2966
:root[data-theme="light"] .external-link-icon {
3067
filter: invert(0.25);
3168
}

0 commit comments

Comments
 (0)