html {
font-size: $base-font-size;
}
/**
* Reset some basic elements
*/
body, h1, h2, h3, h4, h5, h6,
p, blockquote, pre, hr,
dl, dd, ol, ul, figure {
margin: 0;
padding: 0;
}
/**
* Set `margin-bottom` to maintain vertical rhythm
*/
h1, h2, h3, h4, h5, h6,
p, blockquote, pre,
ul, ol, dl, figure,
%vertical-rhythm {
margin-bottom: $spacing-unit / 2;
}
/**
* Basic styling
*/
body {
font-family: $base-font-family;
-webkit-text-size-adjust: 100%;
-webkit-font-feature-settings: "kern" 1;
-moz-font-feature-settings: "kern" 1;
-o-font-feature-settings: "kern" 1;
font-feature-settings: "kern" 1;
font-kerning: normal;
display: flex;
min-height: 100vh;
flex-direction: column;
overflow-wrap: break-word;
line-height: $base-line-height;
}
p {
-webkit-hyphens: auto;
-ms-hyphens: auto;
hyphens: auto;
}
hr {
margin-top: $spacing-unit;
margin-bottom: $spacing-unit;
}
/**
* Images
*/
img {
max-width: 100%;
vertical-align: middle;
}
/**
* Figures
*/
figure > img {
display: block;
}
figcaption {
font-size: $small-font-size;
}
/**
* Lists
*/
ul, ol {
margin-left: $spacing-unit;
}
li {
> ul,
> ol {
margin-bottom: 0;
}
}
/**
* Links
*/
a {
text-decoration: none;
&:hover {
text-decoration: underline;
}
}
/**
* Blockquotes
*/
blockquote {
border-left: 4px solid;
padding-left: $spacing-unit / 2;
@include relative-font-size(1.05);
font-style: italic;
> :last-child {
margin-bottom: 0;
}
i, em {
font-style: normal;
}
}
/**
* Code formatting
*/
pre,
code {
font-family: $code-font-family;
font-size: 0.9em;
border-radius: 0.3em;
}
code {
padding: 1px 5px;
}
pre {
border: 1px solid;
padding: 8px 12px;
overflow-x: auto;
> code {
border: 0;
padding-right: 0;
padding-left: 0;
white-space: pre;
word-break: normal;
word-wrap: normal;
}
}
.highlight {
border-radius: 0.3em;
@extend %vertical-rhythm;
}
/**
* Tables
*/
table {
margin-bottom: $spacing-unit;
width: 100%;
border-collapse: collapse;
border: 1px solid;
th, td {
padding: ($spacing-unit / 3) ($spacing-unit / 2);
}
th {
border: 1px solid;
}
td {
border: 1px solid;
}
}
/**
* Wrapper
*/
.wrapper {
max-width: calc(#{$content-width} - (#{$spacing-unit}));
margin-right: auto;
margin-left: auto;
padding-right: $spacing-unit / 2;
padding-left: $spacing-unit / 2;
@media screen and (min-width: $on-large) {
max-width: calc(#{$content-width} - (#{$spacing-unit} * 2));
padding-right: $spacing-unit;
padding-left: $spacing-unit;
}
}