From baa8bfce6fc98abc0d1b22633aeb9b7604685e95 Mon Sep 17 00:00:00 2001 From: Himanshu Sardana Date: Tue, 17 Mar 2026 16:34:36 +0000 Subject: feat: new themes --- themes/modern-dark.css | 23 ----------------------- themes/modern-light.css | 22 ---------------------- themes/tufte.css | 37 +++++++++++++++++++++---------------- 3 files changed, 21 insertions(+), 61 deletions(-) diff --git a/themes/modern-dark.css b/themes/modern-dark.css index be8d4f6..645652d 100644 --- a/themes/modern-dark.css +++ b/themes/modern-dark.css @@ -373,29 +373,6 @@ aside strong, margin-bottom: 0.4rem; } -/* ─── Tags / Badges ─────────────────────────────────────── */ -.tag { - display: inline-block; - font-family: var(--mono); - font-size: 0.65rem; - letter-spacing: 0.1em; - text-transform: uppercase; - padding: 0.25rem 0.6rem; - border: 1px solid var(--border); - border-radius: 2px; - color: var(--text-dim); - margin-right: 0.4rem; - text-decoration: none; - border-bottom: none; - transition: all var(--transition); -} - -.tag:hover { - border-color: var(--accent); - color: var(--accent); - background: var(--accent-dim); -} - /* ─── Navigation ───────────────────────────────────────── */ nav { display: flex; diff --git a/themes/modern-light.css b/themes/modern-light.css index 0423a58..7752929 100644 --- a/themes/modern-light.css +++ b/themes/modern-light.css @@ -328,28 +328,6 @@ aside strong, margin-bottom: 0.35rem; } -/* ─── Tags ───────────────────────────────────────────────── */ -.tag { - display: inline-block; - font-family: var(--mono); - font-size: 0.65rem; - letter-spacing: 0.08em; - text-transform: uppercase; - padding: 0.22rem 0.55rem; - border: 1px solid var(--border); - border-radius: 2px; - color: var(--text-dim); - margin-right: 0.35rem; - text-decoration: none; - transition: all var(--transition); -} - -.tag:hover { - background: var(--text); - color: var(--bg); - border-color: var(--text); -} - /* ─── Navigation ─────────────────────────────────────────── */ nav { display: flex; diff --git a/themes/tufte.css b/themes/tufte.css index 2ee64c5..cc5e91d 100644 --- a/themes/tufte.css +++ b/themes/tufte.css @@ -1,13 +1,18 @@ @import url("https://fonts.googleapis.com/css2?family=Libre+Baskerville:wght@400;700&display=swap"); + body { margin: 0; padding: 3rem 2rem; background: #fffff8; color: #111; - font-family: "Libre Baskerville", Georgia, serif; + font-family: Georgia, "Libre Baskerville", serif; line-height: 1.75; font-size: 19px; + + /* Improve text rendering for Lighthouse */ + -webkit-font-smoothing: antialiased; + text-rendering: optimizeLegibility; } body > * { @@ -17,49 +22,43 @@ body > * { } /* Headings */ - h1, h2, h3 { text-align: left; font-weight: 700; line-height: 1.25; + scroll-margin-top: 1rem; /* anchors don't get hidden by fixed headers */ } h1 { font-size: 2.4rem; margin-bottom: 1rem; } - h2 { font-size: 1.6rem; margin-top: 3rem; } - h3 { font-size: 1.3rem; margin-top: 2rem; } /* Paragraphs */ - p { margin: 1.3rem 0; } /* Lists */ - ul, ol { margin: 1.2rem 0 1.2rem 1.6rem; } - li { margin: 0.4rem 0; } -/* Horizontal rule */ - +/* Horizontal rules */ hr { border: none; border-top: 1px solid #ddd; @@ -67,35 +66,31 @@ hr { } /* Tables */ - table { border-collapse: collapse; margin: 1.5rem 0; font-size: 0.95rem; } - th, td { padding: 0.5rem 0.8rem; border-bottom: 1px solid #ddd; } - th { text-align: left; } /* Inline code */ - code { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; background: #f5f5f5; padding: 0.15rem 0.3rem; border-radius: 3px; font-size: 0.9rem; + word-break: break-word; } /* Code blocks */ - pre { background: #f7f7f7; padding: 1rem 1.2rem; @@ -110,19 +105,29 @@ pre code { } /* Links */ - a { color: #222; text-decoration: underline; } - a:hover { color: black; } +/* Responsive */ @media (max-width: 700px) { body { padding: 2rem 1.2rem; font-size: 17px; } } + +/* Accessibility / Lighthouse improvements */ +img { + max-width: 100%; + height: auto; + display: block; +} +abbr[title] { + border-bottom: 1px dotted; + cursor: help; +} -- cgit v1.3.1