* {
    box-sizing: border-box;
}

@font-face {
    font-family: "Comic Code";
    src: url("/Comic-Code-Medium.otf") format("opentype");
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

html,
body,
button,
input,
textarea,
select,
code,
pre {
    font-family: "Comic Code", monospace !important;
}

:root {
    --main-fg: #000;
    --main-bg: #fff;
    --strong: #000;
    --subtle: #666;
    --border: #dbdbdb;
    --link: #0066d6;
    --code-bg: #eee;
    --accent: #0066d6;

    --font-sans: "Comic Code", sans-serif;
    --font-mono: "Comic Code", monospace;

    --max-width: 65rem;
    --header-height: auto;
}

@media (prefers-color-scheme: dark) {
    :root {
        --main-fg: #fffdf9;
        --main-bg: #2d2d2d;
        --strong: #fff;
        --subtle: #a09f93;
        --border: #393939;
        --link: #7fbfff;
        --code-bg: #272822;
        --accent: #7fbfff;
    }
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: var(--font-sans);
    background: var(--main-bg);
    color: var(--main-fg);
    font-size: 12px;
    line-height: 1.5;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    text-decoration: none;
    color: var(--link);
}
a:hover {
    text-decoration: underline;
}

img {
    max-width: 100%;
    height: 1000px;
    object-fit: cover; /* Fills the 1000px area without distorting, but clips overflow */
    display: block;
}

:focus-visible {
    outline: 2px solid var(--link);
    outline-offset: 2px;
}

::selection {
    background: var(--link);
    color: var(--main-bg);
}

.app {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 1.5rem 2rem;
    max-width: var(--max-width);
    margin: 0 auto;
    width: 100%;
}

.site-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-mono);
    font-size: 1rem;
    font-weight: 700;
    color: var(--strong);
    letter-spacing: -0.02em;
}

.site-brand__mark {
    display: grid;
    place-items: center;
    width: 28px;
    height: 28px;
    font-size: 0.7rem;
    font-weight: 800;
    color: var(--link);
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 4px;
}

.site-nav a {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 12px;
    font-size: 0.875rem;
    color: var(--subtle);
    border-radius: 4px;
}
.site-nav a:hover {
    color: var(--link);
    text-decoration: none;
}
.site-nav a[aria-current="page"] {
    color: var(--link);
}
.site-nav .btn-primary {
    color: var(--link);
    padding: 4px 12px;
}

main {
    flex: 1;
    padding: 0 2rem 2rem;
    max-width: var(--max-width);
    margin: 0 auto;
    width: 100%;
}

.section {
    padding: 2rem 0;
}

.container {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
