mirror of
https://github.com/harvard-edge/cs249r_book.git
synced 2026-05-06 17:49:07 -05:00
feat(epub): enhance footnote styling and typography
- Add comprehensive footnote styling with Harvard Crimson theme colors - Style footnote reference links with hover effects and proper superscript - Improve footnote content typography with better spacing and readability - Add visual separator line above footnotes section - Style footnote numbers with crimson color and proper weight - Enhance back-reference links with subtle hover effects - Add special styling for code within footnotes - Ensure footnotes are properly formatted and visually distinct
This commit is contained in:
@@ -516,6 +516,101 @@ figcaption {
|
||||
line-height: 1.4;
|
||||
}
|
||||
|
||||
/* ==========================================================================
|
||||
Footnotes and References
|
||||
========================================================================== */
|
||||
|
||||
/* Footnote reference links (superscript numbers in text) */
|
||||
a[href^="#fn-"],
|
||||
.footnote-ref {
|
||||
font-size: 0.75em;
|
||||
vertical-align: super;
|
||||
text-decoration: none;
|
||||
color: var(--crimson);
|
||||
font-weight: 600;
|
||||
padding: 0 2px;
|
||||
border-radius: 2px;
|
||||
transition: background-color 0.2s ease;
|
||||
}
|
||||
|
||||
a[href^="#fn-"]:hover,
|
||||
.footnote-ref:hover {
|
||||
background-color: rgba(165, 28, 48, 0.1);
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
/* Footnote content styling */
|
||||
.footnotes,
|
||||
div[id^="fn-"],
|
||||
.footnote {
|
||||
margin-top: 2rem;
|
||||
padding-top: 1rem;
|
||||
border-top: 2px solid var(--border-light);
|
||||
font-size: 0.85rem;
|
||||
line-height: 1.5;
|
||||
color: var(--text-secondary);
|
||||
}
|
||||
|
||||
/* Individual footnote entries */
|
||||
.footnotes ol,
|
||||
.footnotes ul {
|
||||
padding-left: 1.5rem;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.footnotes li {
|
||||
margin-bottom: 0.75rem;
|
||||
padding-left: 0.25rem;
|
||||
}
|
||||
|
||||
/* Footnote numbers */
|
||||
.footnotes li::marker {
|
||||
color: var(--crimson);
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
/* Back-reference links in footnotes */
|
||||
a[href^="#fnref-"],
|
||||
.footnote-back {
|
||||
font-size: 0.8em;
|
||||
color: var(--text-muted);
|
||||
text-decoration: none;
|
||||
margin-left: 0.5rem;
|
||||
padding: 2px 4px;
|
||||
border-radius: 2px;
|
||||
transition: all 0.2s ease;
|
||||
}
|
||||
|
||||
a[href^="#fnref-"]:hover,
|
||||
.footnote-back:hover {
|
||||
color: var(--crimson);
|
||||
background-color: rgba(165, 28, 48, 0.05);
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
/* Footnote separator styling */
|
||||
.footnotes::before {
|
||||
content: "";
|
||||
display: block;
|
||||
width: 60px;
|
||||
height: 1px;
|
||||
background-color: var(--crimson);
|
||||
margin: 0 0 1rem 0;
|
||||
}
|
||||
|
||||
/* Enhanced footnote typography */
|
||||
.footnotes p {
|
||||
margin-bottom: 0.5rem;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
.footnotes code {
|
||||
font-size: 0.8em;
|
||||
background-color: rgba(165, 28, 48, 0.05);
|
||||
padding: 1px 3px;
|
||||
border-radius: 2px;
|
||||
}
|
||||
|
||||
/* ==========================================================================
|
||||
Lists and Navigation
|
||||
========================================================================== */
|
||||
|
||||
Reference in New Issue
Block a user