:root {
    --accent: #2D9CDB;
    --grey: #444;
}

html {
    font-size:  100%;
    scroll-behavior: smooth;
}

body {
    font-family: Inter, sans-serif;
    line-height: 1.65;
    
    display: flex;
    flex-direction: column;
    min-height: 100vh;

    margin: 0 24px;
}

@media only screen and (max-width: 468px) {
    .page-header {
        flex-direction: column;
    }
}

.page-header {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
}

.page-header nav a:not(:hover):not(:focus) {
    color: currentColor;
    text-decoration: none;
}

nav a {
    margin: 0 12px;
    font-size: 1.25em;
}

main {
    flex-grow: 1;
    max-width: 60ch;
    width: 100%;
    margin: 0 auto;
}

.page-footer {
    text-align: center;
    margin-bottom: 8px;
}

a[href] {
    color: var(--accent);
}

a[href]:hover {
    text-decoration: none;
}

a[href]:focus {
    outline: 2px solid var(--accent);
    outline-offset: 4px;
}

.footnotes {
    font-size: 0.8em;
}

/* Typography */
p {margin-bottom: 1.15rem;}

h1, h2, h3, h4, h5 {
  margin: 2.75rem 0 1.05rem;
  font-weight: 400;
  line-height: 1.15;
}

h1 {font-size: 3.052em;}

h2 {font-size: 2.1em;}

h3 {font-size: 1.953em;}

h4 {font-size: 1.563em;}

h5, .larger {font-size: 1.25em;}

small {font-size: 0.8em;}

/* backlinks */
.backlinks-title {
    margin-bottom: 0;
}

.backlinks-container {
    margin-top: 0;
}

.backlinks-default {
    margin-top: 0;
    margin-left: 16px;
    color: var(--grey);
}

.backlink__preview {
    display: none;
    
    position: absolute;
    bottom: 8px;
    left: 100%;
    background-color: #fff;
    border-radius: 4px;
    padding: 4px;
    box-shadow: 0 0 4px 2px rgba(0, 0, 0, 0.25);
    width: 348px;
    max-height: 148px;
    overflow: hidden;
}
.backlink__preview::after {
    content: "";
    position: absolute;
    bottom: 0;
    background: linear-gradient(transparent, white);
    width: 100%;
    height: 24px;
}

.backlink__preview h1 {
    font-size: 1.2rem;
    margin-top: 8px;
    font-weight: bold;
}

.backlink {
    width: fit-content;
    position: relative;
}

.backlink:hover {
    padding-right: 4px; /* Allow mouse to travel between link and modal */
}

.backlink:hover .backlink__preview {
    display: block;
}

/*Modified*/
blockquote{
    border-left: 2px solid #3483eb;
    padding-left: 10px;
    margin-left: 10px;
    font-style: italic;
}

.sideimg{
    float: right;
    clear: right;
    margin-right: -60%;
    width: 50%;
    margin-top: 0;
    margin-bottom: 0;
    vertical-align: baseline;
    position: relative; 
}

/* Posts styling - bulletin board style */
.posts-list {
    margin-top: 1.5rem;
}

.post-item {
    display: flex;
    gap: 1rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid #f0f0f0;
    align-items: flex-start;
}

.post-item:last-child {
    border-bottom: none;
}

.post-item:hover {
    background-color: #fafafa;
    margin: 0 -0.5rem;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
}

.post-meta {
    flex-shrink: 0;
    width: 5rem;
}

.post-date {
    font-size: 0.8em;
    color: var(--grey);
    font-variant-numeric: tabular-nums;
}

.post-content {
    flex-grow: 1;
    min-width: 0;
}

.post-title {
    margin: 0 0 0.25rem 0;
    font-size: 1rem;
    font-weight: 400;
    line-height: 1.3;
}

.post-title a {
    color: currentColor;
    text-decoration: none;
}

.post-title a:hover {
    color: var(--accent);
    text-decoration: underline;
}

.post-excerpt {
    color: var(--grey);
    margin: 0;
    font-size: 0.9em;
    line-height: 1.4;
}
