Skip to content

Instantly share code, notes, and snippets.

@carlfriess
Created March 3, 2021 15:00
Show Gist options
  • Save carlfriess/812cb903dd793cee84ae08206c6f56e2 to your computer and use it in GitHub Desktop.
Save carlfriess/812cb903dd793cee84ae08206c6f56e2 to your computer and use it in GitHub Desktop.
A beautiful Markdown CSS Theme for scientific documents
html, body {
padding: 2.5em;
margin: auto;
max-width: 48em;
}
body {
font: 0.8em Palatino, Times;
color: #333;
line-height: 1.3;
text-align: justify;
}
img {
max-width: 100%;
}
table {
border-collapse: collapse;
margin-block-end: 1em;
}
th, td {
padding: 0.5em 0.5em 0.25em;
border: 1px solid #DDD;
}
th {
border-bottom-width: 1.5px;
}
h1, h2, h3, h4, h5, h6 {
page-break-after: avoid;
}
/* Typography
-------------------------------------------------------- */
h1 {
margin-top: 0;
font-weight: normal;
text-align: center;
}
h2 {
font-weight: normal;
margin-top: 3em;
}
h3 {
font-weight: normal;
font-style: italic;
margin-top: 3em;
}
p {
margin-top: 0;
-webkit-hypens: auto;
-moz-hypens: auto;
hyphens: auto;
}
ul {
list-style: square;
padding-left: 1.2em;
}
ol {
padding-left: 1.2em;
}
blockquote {
margin-left: 1em;
padding-left: 1em;
border-left: 1px solid #DDD;
}
code {
font-family: "Consolas", "Menlo", "Monaco", monospace, serif;
font-size: .9em;
}
a {
color: #2484c1;
text-decoration: none;
}
a:hover {
text-decoration: underline;
}
a img {
border: none;
}
h1 a, h1 a:hover {
color: #333;
text-decoration: none;
}
hr {
color: #DDD;
height: 1px;
margin: 2em 0;
border-top: solid 1px #DDD;
border-bottom: none;
border-left: 0;
border-right: 0;
}
/* Small screens
-------------------------------------------------------- */
@media only screen and (max-width: 576px) {
html, body {
padding-left: 1.2em;
padding-right: 1.2em;
}
body {
text-align: left;
}
}
/* Code Formatting
-------------------------------------------------------- */
pre[class*="language-"] {
overflow-wrap: break-word;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment