*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --bg: #0d0d0d;
    --surface: #141414;
    --border: #262626;
    --muted: #505050;
    --accent: #e0e0e0;
    --radius: 12px;
    --fold: #333333;
    --font-sans: 'IBM Plex Sans', sans-serif;
    --font-mono: 'IBM Plex Mono', monospace;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    background: var(--bg);
    color: var(--accent);
    min-height: 100vh;
    padding: 48px 16px 80px;
    transition: background 0.4s ease, color 0.4s ease;
}

.page {
    max-width: 860px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 40px;
}

/* ── Profile Card ── */
.profile-card {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px;
    display: flex;
    gap: 28px;
    align-items: center;
    background: var(--surface);
    transition: border-color 0.4s, background 0.4s;
}

.avatar-wrap {
    flex-shrink: 0;
    position: relative;
    border-radius: 10px;
    transition: transform 0.15s ease;
}

.avatar-wrap:hover {
    transform: scale(1.015);
}

.avatar-wrap::after {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 11px;
    border: 2px solid transparent;
    pointer-events: none;
    transition: border-color 0.25s;
}

.avatar-wrap:hover::after {
    border-color: var(--accent);
}

.avatar-box {
    width: 160px;
    height: 160px;
    border-radius: 8px;
    background: var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 72px;
    transition: background 0.4s;
    overflow: hidden;
    user-select: none;
}

.profile-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.profile-name {
    font-size: 2rem;
    font-weight: 600;
    letter-spacing: -0.025em;
    line-height: 1.1;
}

.profile-bio {
    font-size: 0.9rem;
    text-align: justify;
    line-height: 1.7;
    color: var(--accent);
    opacity: 0.82;
}

.profile-bio a {
    color: var(--accent);
    text-decoration: none;
    font-weight: 500;
}

.social-links {
    display: flex;
    gap: 10px;
}

.social-btn {
    width: 44px;
    height: 44px;
    border: 1px solid var(--border);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    color: var(--accent);
    text-decoration: none;
    transition: border-color 0.2s, color 0.2s, background 0.4s;
}

.social-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.social-btn svg {
    width: 18px;
    height: 18px;
    stroke: currentColor;
    fill: none;
    stroke-width: 1.75;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* ── Posts Section ── */
.section-label {
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: -0.015em;
}

.posts {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* ── Post Card ── */
.post-card {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    display: flex;
    overflow: hidden;
    background: var(--surface);
    position: relative;
    transition: border-color 0.2s, background 0.4s, transform 0.15s ease;
    animation: rise 0.3s ease;
}

.post-card:hover .post-date {
    color: var(--accent);
}

@keyframes rise {
    from {
        opacity: 0;
        transform: translateY(8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.post-card:hover {
    border-color: var(--accent);
    transform: scale(1.015);
}

.post-card:active {
    transform: scale(0.985);
}

/* Fold corner — GitHub link indicator */
.post-card.linkable {
    cursor: pointer;
}

.post-card.linkable::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 0 26px 26px 0;
    border-color: transparent var(--fold) transparent transparent;
    transition: border-color 0.2s;
}

.post-card.linkable:hover::after {
    border-color: transparent var(--accent) transparent transparent;
}


.post-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    min-width: 64px;
    font-size: 1.6rem;
    border-right: 1px solid var(--border);
    background: var(--surface);
    transition: border-color 0.2s;
}

.post-card:hover .post-icon {
    border-color: var(--accent);
}

.post-body {
    flex: 1;
    padding: 22px 26px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.post-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.post-name {
    font-size: 1.2rem;
    font-weight: 400;
    letter-spacing: -0.01em;
    line-height: 1.3;
}

.post-abouts {
    font-size: 0.875rem;
    text-align: justify;
    line-height: 1.7;
    color: var(--accent);
    opacity: 0.72;
    flex: 1;
}

.post-date {
    font-family: var(--font-mono);
    font-size: 0.78rem;
    color: var(--muted);
    white-space: nowrap;
}

/* ── Responsive ── */
@media (max-width: 600px) {
    body {
        padding: 24px 12px 60px;
    }

    .page {
        gap: 28px;
    }

    .profile-card {
        flex-direction: column;
        align-items: center;
        text-align: center;
        padding: 24px 20px;
        gap: 20px;
    }

    .avatar-box {
        width: 120px;
        height: 120px;
    }

    .profile-name {
        font-size: 1.5rem;
    }

.social-links {
        justify-content: center;
    }

    .post-body {
        padding: 16px 18px;
    }

    .post-name {
        font-size: 1.05rem;
    }

    .post-header {
        flex-wrap: wrap;
        gap: 6px;
    }

    .section-label {
        font-size: 1.2rem;
    }

    .post-abouts,
    .post-date {
        display: none;
    }
}