:root {
    color-scheme: light dark;

    --bg: #f3f5f6;
    --paper: #fbfbfa;
    --text: #22303a;
    --muted: #5e6a73;
    --rule: #ced5da;
    --link: #2d5f94;
    --link-hover: #1f476e;
    --soft-accent: #e6edf3;
    --shadow: rgba(24, 37, 48, 0.08);

    --max-width: 46rem;
    --radius: 14px;
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg: #182026;
        --paper: #1e282f;
        --text: #e4ebf0;
        --muted: #a7b4be;
        --rule: #34424d;
        --link: #7fb0e4;
        --link-hover: #a7cbef;
        --soft-accent: #22303a;
        --shadow: rgba(0, 0, 0, 0.28);
    }
}

html {
    font-size: 18px;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: Georgia, "Palatino Linotype", Palatino, "Book Antiqua", serif;
    line-height: 1.7;
    text-rendering: optimizeLegibility;
}

.page {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 4rem 1.5rem 5rem;
}

.masthead {
    margin-bottom: 3rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid var(--rule);
}

.kicker {
    margin: 0 0 0.5rem 0;
    font-size: 0.8rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted);
}

h1 {
    margin: 0;
    font-size: clamp(2.1rem, 4vw, 3.2rem);
    font-weight: 400;
    line-height: 1.1;
    letter-spacing: -0.01em;
}

.tagline {
    margin-top: 0.8rem;
    font-size: 1.05rem;
    color: var(--muted);
    max-width: 34rem;
}

h2 {
    margin: 0 0 1rem 0;
    font-size: 1.08rem;
    font-weight: 600;
    color: var(--text);
}

.intro-grid {
    display: grid;
    grid-template-columns: 180px 1fr;
    gap: 2rem;
    align-items: start;
    margin-bottom: 3rem;
}

.portrait-block {
    margin: 0;
}

.portrait {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 5;
    object-fit: cover;
    border-radius: var(--radius);
    background: var(--soft-accent);
    box-shadow: 0 8px 24px var(--shadow);
}

.intro-text p {
    margin-top: 0;
    margin-bottom: 1rem;
}

.lede {
    font-size: 1.1rem;
}

.content {
    margin-bottom: 2.75rem;
}

.link-list,
.work-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.link-list li {
    margin: 0.55rem 0;
}

.work-item {
    padding: 0.9rem 0;
    border-top: 1px solid var(--rule);
}

.work-item:last-child {
    border-bottom: 1px solid var(--rule);
}

.work-title {
    font-size: 1rem;
}

.work-description {
    margin: 0.35rem 0 0 0;
    color: var(--muted);
    font-size: 0.96rem;
}

a {
    color: var(--link);
    text-decoration-thickness: 0.08em;
    text-underline-offset: 0.14em;
}

a:hover,
a:focus {
    color: var(--link-hover);
}

.footer {
    margin-top: 4rem;
    padding-top: 1rem;
    border-top: 1px solid var(--rule);
    color: var(--muted);
    font-size: 0.95rem;
}

.footer p {
    margin: 0 0 0.5rem 0;
}

.copyright {
    margin-top: 1rem;
}

@media (max-width: 720px) {
    html {
        font-size: 17px;
    }

    .page {
        padding-top: 2.5rem;
        padding-bottom: 3rem;
    }

    .intro-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .portrait-block {
        max-width: 220px;
    }
}

.site-nav {
    margin: -1.5rem 0 2.5rem 0;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--rule);
}

.site-nav a {
    margin-right: 1rem;
    text-decoration: none;
}

.site-nav a:hover,
.site-nav a:focus {
    text-decoration: underline;
}

.error-page {
    padding: 1.5rem 0 3rem;
}

.error-page .lede {
    max-width: 32rem;
}
