/* NormalizeCSS */
html {
    box-sizing: border-box;
    font-size: 16px;
}

*,
*:before,
*:after {
    box-sizing: inherit;
}

body,
h1,
h2,
h3,
h4,
h5,
h6,
p,
ol,
ul,
figure {
    margin: 0;
    padding: 0;
    font-weight: normal;
}

ol,
ul {
    list-style: lower-greek;
    margin-left: 1rem;
}
ul li {
    margin-left: 1.5rem;
    margin-bottom: 0.5rem;
}

img {
    max-width: 100%;
    height: auto;
}

a,
a:visited {
    all: unset;
    color: #bf3b36;
}
a:hover {
    text-decoration: underline;
    text-decoration-thickness: 2px;
    background-color: #f8f8f6;
}

@font-face {
    font-family: "DepartureMono";
    src: url("../fonts/DepartureMono-Regular.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
}

@font-face {
    font-family: "GeistMono";
    src: url("../fonts/GeistMono-UltraLight.woff2") format("woff2");
    font-weight: 200;
    font-style: normal;
}

@font-face {
    font-family: "GeistMono";
    src: url("../fonts/GeistMono-UltraBlack.woff2") format("woff2");
    font-weight: 900;
    font-style: normal;
}

@font-face {
    font-family: "GeistMono";
    src: url("../fonts/GeistMono-Thin.woff2") format("woff2");
    font-weight: 300;
    font-style: normal;
}

@font-face {
    font-family: "GeistMono";
    src: url("../fonts/GeistMono-SemiBold.woff2") format("woff2");
    font-weight: 600;
    font-style: normal;
}

@font-face {
    font-family: "GeistMono";
    src: url("../fonts/GeistMono-Regular.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
}

@font-face {
    font-family: "GeistMono";
    src: url("../fonts/GeistMono-Medium.woff2") format("woff2");
    font-weight: 500;
    font-style: normal;
}

@font-face {
    font-family: "GeistMono";
    src: url("../fonts/GeistMono-Light.woff2") format("woff2");
    font-weight: 300;
    font-style: normal;
}

@font-face {
    font-family: "GeistMono";
    src: url("../fonts/GeistMono-Bold.woff2") format("woff2");
    font-weight: 700;
    font-style: normal;
}

@font-face {
    font-family: "GeistMono";
    src: url("../fonts/GeistMono-Black.woff2") format("woff2");
    font-weight: 800;
    font-style: normal;
}

@font-face {
    font-family: "Apple Garamond";
    src: url("../fonts/applegaramondcyr_regular.ttf") format("truetype");
    font-weight: 400;
    font-style: normal;
}

body {
    background-color: #e8e6e1;
    font-family: "DepartureMono", sans-serif;
    max-width: 960px;
    width: 100%;
    margin: 5rem 10rem 0;
    padding: 0 2rem;
    color: #121216;
    /* letter-spacing: -0.1px; */
}

@media (max-width: 768px) {
    body {
        margin-left: 2rem;
        padding: 1rem;
    }
}
@media (max-width: 1440px) {
    body {
        margin-left: 5rem;
    }
}

h1 {
    margin: 1rem 0;
}
h2 {
    font-size: 2rem;
}
h3 {
    font-size: 1.5rem;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: "Apple Garamond";
    letter-spacing: -0.2px;
}

header {
    margin-bottom: 2rem;
}

main {
    max-width: 900px;
}

main > section {
    margin-bottom: 2rem;
}

section {
    margin-top: 1rem;
}

nav {
    font-weight: 500;
    display: flex;
    align-items: center;
    height: auto;
}

nav a,
nav a:visited {
    display: block;
    margin-right: 0.875rem;
    color: #121216;
}
nav a.active {
    color: #bf3b36;
    font-weight: 600;
    /* text-decoration: underline; */
}
nav h1 {
    margin-right: 2rem;
    margin: 0;
}

footer {
    margin-top: 2rem;
}

footer nav {
    border-top: 2px solid #121216;
    padding-top: 0.5rem;
    margin-left: auto;
    width: fit-content;
}

footer nav a {
    opacity: 0.66;
}
footer nav a:hover {
    opacity: 1;
}

.ascii {
    padding: 0;
    white-space: pre;
    font-size: 3px;
    line-height: 3px;
    letter-spacing: unset;
    transform: unset;
    overflow-y: hidden;
    scroll-snap-align: center;
    margin: 0;
    /* color: #bf3b36; */
}

.ascii-wrap {
    max-width: 300px;
}

.row {
    display: flex;
    width: 100%;
    align-items: start;
}
.row > * {
    margin-right: 1.5rem;
    /* width: 100%; */
}
.row > *:last-child {
    margin-right: 0;
}

.max-w {
    max-width: 520px;
}

.card {
    border: 2px solid #121216;
    background-color: #f8f8f6;
    padding: 1rem;
    width: fit-content;
}
.card > div {
    margin-bottom: 1rem;
}
.card > div:last-child {
    margin-bottom: 0;
}
.flex {
    display: flex;
    gap: 1rem;
}

p {
    margin-bottom: 1rem;
}
p:last-child {
    margin-bottom: 0;
}

dl > dt {
    font-weight: bold;
}

dl > dd {
    margin-left: 0;
    margin-bottom: 1rem;
}
dl > dd:last-child {
    margin-bottom: 0;
}

time {
    opacity: 0.5;
}

form {
    max-width: 550px;
}

label {
    display: flex;
    align-items: center;
    margin-bottom: 0.25rem;
}

input, button {
    font-family: 'Geist Mono', monospace;
}

input, textarea {
    display: block;
    border: 2px solid #121216;
    font-size: 1rem;
    padding: 0.25rem 0.5rem;
    /* border-radius: 0.25rem; */
    width: 100%;
    font-family: inherit;
}

input[type="checkbox"], input[type="radio"] {
    margin-bottom: 0;
    margin-right: 0.25rem;
    display: inline-flex;
    width: 20px;
    border: 0;
    height: 20px;
    accent-color: #121216;
}

input:focus {
    /* outline: #bf3b36; */
}

button {
    border: 2px solid #121216;
    background-color: #f8f8f6;
    padding: 0.25rem 0.5rem;
    font-size: 1rem;
    /* border-radius: 0.25rem; */
}

button:hover {
    background-color: #eaeaea;
}

fieldset {
    background: lightgray;
}
fieldset > div {
    margin-bottom: 1rem;
}
