Files
wahyd4.github.com/source/_data/styles.styl
T
Hermes Bot 232ecd7c22 Rebuild blog source from GitHub Pages artifact
- 308 posts reverse-extracted from wahyd4.github.com (Hexo 6.3.0 + NexT 8.25)
- Hexo project with NexT theme, reading-experience custom styles
- publish-post.sh: write post -> hexo build -> PR (master untouched)
2026-08-04 09:44:07 +10:00

162 lines
2.9 KiB
Stylus

// =========================================================
// Custom styles reading experience (微信读书 style)
// injected by NexT custom_file_path.style
// =========================================================
// Reading width & typography
.post-body {
font-size: 1.05em;
line-height: 1.9;
letter-spacing: 0.02em;
color: #333;
p {
margin: 1.1em 0;
text-align: justify;
text-justify: inter-ideograph;
}
h1, h2, h3, h4, h5, h6 {
line-height: 1.4;
margin-top: 1.6em;
margin-bottom: 0.8em;
font-weight: 600;
color: #222;
&::before {
content: '';
display: inline-block;
width: 4px;
height: 0.9em;
background: #4a90d9;
border-radius: 2px;
margin-right: 10px;
vertical-align: -0.08em;
}
}
img {
border-radius: 8px;
box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
margin: 0.6em auto;
display: block;
max-width: 100%;
}
blockquote {
border-left: 4px solid #4a90d9;
background: rgba(74, 144, 217, 0.06);
margin: 1.4em 0;
padding: 0.8em 1.2em;
border-radius: 0 8px 8px 0;
color: #555;
p { margin: 0.4em 0; }
}
a {
color: #2d6cdf;
border-bottom: 1px solid rgba(45, 108, 223, 0.3);
transition: color 0.2s, border-color 0.2s;
&:hover {
color: #1a4fae;
border-bottom-color: #1a4fae;
}
}
code {
background: rgba(0, 0, 0, 0.05);
border-radius: 4px;
padding: 2px 6px;
font-size: 0.9em;
color: #c7254e;
}
table {
border-collapse: collapse;
margin: 1.2em auto;
font-size: 0.95em;
th, td {
border: 1px solid #ddd;
padding: 8px 14px;
}
th {
background: #f5f7fa;
font-weight: 600;
}
tr:nth-child(even) { background: #fafbfc; }
}
ul, ol {
padding-left: 1.6em;
margin: 0.8em 0;
li { margin: 0.35em 0; }
}
hr {
border: none;
border-top: 1px dashed #ccc;
margin: 2em auto;
width: 60%;
}
}
// Dark mode adjustments
.darkmode {
.post-body {
color: #c8cdd3;
h1, h2, h3, h4, h5, h6 { color: #e8eaed; }
blockquote {
background: rgba(74, 144, 217, 0.1);
color: #9aa5b1;
}
code {
background: rgba(255, 255, 255, 0.1);
color: #e88388;
}
table {
th, td { border-color: #3a3f45; }
th { background: #2d3238; }
tr:nth-child(even) { background: #262a2f; }
}
}
}
// Post title
.posts-expand .post-title, .post-block .post-title {
font-size: 1.7em;
font-weight: 700;
letter-spacing: 0.01em;
}
// Post meta
.post-meta {
color: #999;
font-size: 0.9em;
}
// Main content container comfortable reading width
.post-block, .posts-expand .post-block {
max-width: 760px;
}
// Reading progress bar top
// (NexT reading_progress handles it; nothing extra needed)
// Smooth scroll
html { scroll-behavior: smooth; }
// Selection color
::selection {
background: rgba(74, 144, 217, 0.25);
}