@import url("headings.css");
@import url("code.css");

@import url('https://fonts.googleapis.com/css2?family=Geist:ital,wght@0,100..900;1,100..900&display=swap');

:root {
    --primary: #333;
    --accent: inherit;
    --surface: #f2f2f2;
    --selection: hsl(60, 100%, 80%);
}

* {
    box-sizing: border-box;
}

::selection {
    background: var(--selection);
}

body {
    color: var(--primary);
    font-family: "Geist", sans-serif;
    line-height: 1.5;
}

main {
    margin: 0 auto;
    max-width: 540px;
    padding: 3rem 1rem;
    width: 100%;
}

@media only screen and (max-width: 572px) {
    main {
        padding: 1rem;
    }
}


ul {
    padding: 0;
    padding-left: 1rem;
}

a {
    color: var(--accent);
    font-weight: 500;
}

time {
    font-style: italic;
}

.post-list li .grid {
    display: grid;
    grid-template-columns: 10ch 1fr;
}

.post-list time {
    margin-right: 1ch;
}

nav.adjacent-posts {
    margin-top: 2rem;
    display: flex;
}

nav.adjacent-posts:has(.lower):not(:has(.higher)) {
    justify-content: flex-start;
}

nav.adjacent-posts:has(.higher):not(:has(.lower)) {
    justify-content: flex-end;
}

nav.adjacent-posts:has(.lower):has(.higher) {
    justify-content: space-between;
}

