:root {
    color-scheme: dark;
    font-family: -apple-system, BlinkMacSystemFont, "Microsoft YaHei", Roboto, sans-serif;
    background: var(--bg-base, #0c0d12);
    color: var(--text-primary, #f5f6fa);
    font-synthesis: none;
    -webkit-font-smoothing: antialiased;
    scrollbar-color: var(--text-muted) var(--bg-base);
}

* { box-sizing: border-box; }
body { margin: 0; }
::selection { background: var(--accent); color: var(--bg-base); }

.bio-page {
    width: min(100% - 96px, 864px);
    margin: clamp(64px, 13vh, 144px) auto 64px;
}

.intro {
    display: flex;
    align-items: baseline;
    gap: 24px;
    padding-bottom: 28px;
    border-bottom: 1px solid var(--border);
}

h1 {
    margin: 0;
    font-size: clamp(4rem, 10vw, 6rem);
    font-weight: 700;
    letter-spacing: -0.04em;
    line-height: 1;
}

h1 span { color: var(--accent); }
.tagline { margin: 0; color: var(--text-muted); font-size: 1rem; }

.about {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 180px;
    gap: clamp(40px, 7vw, 96px);
    padding-top: 44px;
}

.bio { font-size: 1.125rem; line-height: 1.8; }
.bio p { margin: 0 0 24px; text-wrap: pretty; }
.bio .hello { margin-bottom: 28px; font-size: 1.5rem; font-weight: 500; line-height: 1.4; }
.aside { color: var(--text-muted); }

a {
    color: inherit;
    text-decoration-color: var(--accent);
    text-underline-offset: 5px;
    text-decoration-thickness: 1px;
}

a:hover { color: var(--accent); text-decoration-thickness: 2px; }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 6px; border-radius: 2px; }
.portrait { width: 160px; height: 160px; margin-bottom: 32px; }
.avatar { display: block; width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }

.avatar-fallback {
    display: grid;
    width: 100%;
    height: 100%;
    place-items: center;
    border: 1px solid var(--border);
    border-radius: 50%;
    color: var(--accent);
    font-size: 4rem;
    letter-spacing: -0.04em;
}

.links h2 { margin: 0 0 8px; color: var(--text-muted); font-size: 0.875rem; font-weight: 400; }
.links a {
    display: flex;
    align-items: center;
    gap: 6px;
    min-height: 44px;
    padding-block: 10px;
    border-bottom: 1px solid var(--border);
    text-decoration: none;
    font-size: 0.9375rem;
}

.link-detail { color: var(--text-muted); }
.links svg {
    width: 16px;
    height: 16px;
    margin-left: auto;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.5;
    flex-shrink: 0;
}

@media (max-width: 600px) {
    .bio-page { width: calc(100% - 48px); margin-top: 48px; margin-bottom: 40px; }
    .intro { gap: 18px; padding-bottom: 24px; }
    .about { grid-template-columns: 1fr; gap: 24px; padding-top: 32px; }
    .bio { font-size: 1.0625rem; }
    .bio p:last-child { margin-bottom: 0; }
    .sidebar {
        display: grid;
        grid-template-columns: 80px minmax(0, 1fr);
        align-items: center;
        gap: 28px;
        padding-top: 28px;
        border-top: 1px solid var(--border);
    }
    .portrait { width: 80px; height: 80px; margin: 0; }
    .avatar-fallback { font-size: 2.5rem; }
}

@media (prefers-reduced-motion: no-preference) {
    .about { animation: arrive 450ms cubic-bezier(0.16, 1, 0.3, 1) both; }
    @keyframes arrive {
        from { opacity: 0.65; transform: translateY(8px); }
        to { opacity: 1; transform: translateY(0); }
    }
}
