Dark-mode for index.html

This commit is contained in:
Eric Kilmer
2026-01-23 17:51:57 -05:00
parent cd6078bb22
commit 0664b5c545
+28 -7
View File
@@ -75,15 +75,36 @@ jobs:
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Sleigh Documentation</title>
<style>
:root {
--bg-color: #f5f5f5;
--text-color: #333;
--text-muted: #666;
--card-bg: white;
--card-shadow: rgba(0,0,0,0.1);
--card-shadow-hover: rgba(0,0,0,0.15);
--link-color: #0066cc;
}
@media (prefers-color-scheme: dark) {
:root {
--bg-color: #1a1a1a;
--text-color: #e0e0e0;
--text-muted: #a0a0a0;
--card-bg: #2d2d2d;
--card-shadow: rgba(0,0,0,0.3);
--card-shadow-hover: rgba(0,0,0,0.4);
--link-color: #4da6ff;
}
}
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
max-width: 800px;
margin: 0 auto;
padding: 2rem;
background: #f5f5f5;
background: var(--bg-color);
color: var(--text-color);
}
h1 {
color: #333;
color: var(--text-color);
}
.cards {
display: flex;
@@ -92,23 +113,23 @@ jobs:
}
.card {
flex: 1;
background: white;
background: var(--card-bg);
border-radius: 8px;
padding: 1.5rem;
text-decoration: none;
color: inherit;
box-shadow: 0 2px 4px rgba(0,0,0,0.1);
box-shadow: 0 2px 4px var(--card-shadow);
transition: box-shadow 0.2s;
}
.card:hover {
box-shadow: 0 4px 8px rgba(0,0,0,0.15);
box-shadow: 0 4px 8px var(--card-shadow-hover);
}
.card h2 {
margin-top: 0;
color: #0066cc;
color: var(--link-color);
}
.card p {
color: #666;
color: var(--text-muted);
margin-bottom: 0;
}
</style>