/* ── Reset & Base ──────────────────────────────────── */

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

html {
    font-family: 'Montserrat', 'Helvetica Neue', 'Segoe UI', Helvetica, Arial, sans-serif;
    font-size: 16px;
    overflow-y: auto;
    scroll-behavior: smooth;
}

body {
    background-color: #000;
    color: #edf7ff;
    padding: 1rem;
}

/* ── Typography ───────────────────────────────────── */

h1 {
    font-size: 9rem;
    line-height: 1;
    letter-spacing: -0.03em;
}

h2 {
    font-size: 3rem;
    font-weight: 400;
}

h3 {
    font-size: 2rem;
    font-weight: 400;
}

a {
    color: #edf7ff;
    text-decoration: none;
    transition: color 0.25s ease, transform 0.25s ease;
}

a:hover {
    color: #ffba82;
}

/* ── Layout ───────────────────────────────────────── */

main {
    max-width: 1100px;
    margin: 0 auto;
}

section {
    display: flex;
}

.portrait-col {
    flex: 1;
    text-align: end;
}

.text-col {
    flex: 1;
}

/* ── Intro section ────────────────────────────────── */

.intro {
    min-height: 100vh;
    align-items: center;
    justify-content: center;
    animation: fadeUp 0.8s ease both;
}

.portrait {
    border-radius: 50%;
    border: 8px solid #edf7ff;
    margin: 2em 3em;
    width: 100%;
    height: auto;
    max-width: 280px;
    max-height: 280px;
    object-fit: cover;
    transition: border-color 0.4s ease, transform 0.4s ease;
}

.portrait:hover {
    border-color: #ffba82;
    transform: scale(1.03);
}

.intro .text-col {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.text-col h1 {
    margin-left: -8px;
    margin-bottom: 0.3em;
}

/* ── Social links ─────────────────────────────────── */

.links {
    margin-top: 1rem;
    display: flex;
    gap: 0.75rem;
}

.links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 2px solid transparent;
    transition: color 0.25s ease, border-color 0.25s ease, transform 0.25s ease;
}

.links a:hover {
    color: #ffba82;
    border-color: #ffba82;
    transform: translateY(-3px);
}

.links svg {
    width: 24px;
    height: 24px;
}

/* ── Projects section ─────────────────────────────── */

.projects {
    margin-top: 2rem;
    padding-bottom: 6rem;
}

.projects h3 {
    margin-bottom: 1.5rem;
}

.project-list {
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.project {
    display: grid;
    grid-template-columns: 140px 1fr auto;
    gap: 1rem;
    padding: 1rem 0;
    border-bottom: 1px solid rgba(237, 247, 255, 0.08);
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.5s ease, transform 0.5s ease, background 0.3s ease;
}

.project.visible {
    opacity: 1;
    transform: translateY(0);
}

.project:hover {
    background: rgba(237, 247, 255, 0.03);
}

.project:last-child {
    border-bottom: none;
}

.project-name {
    font-weight: 700;
    font-size: 1rem;
}

.project-desc {
    font-size: 0.9rem;
    opacity: 0.7;
    line-height: 1.5;
}

.project-meta {
    text-align: right;
    white-space: nowrap;
    font-size: 0.85rem;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.25rem;
}

.years {
    opacity: 0.5;
}

.status {
    opacity: 0.4;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.status--active {
    opacity: 0.9;
    color: #ffba82;
}

/* ── Animations ───────────────────────────────────── */

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Stagger the project card reveals */
.project:nth-child(1) { transition-delay: 0s; }
.project:nth-child(2) { transition-delay: 0.08s; }
.project:nth-child(3) { transition-delay: 0.16s; }
.project:nth-child(4) { transition-delay: 0.24s; }

/* ── Responsive ───────────────────────────────────── */

@media screen and (max-width: 768px) {
    h1 {
        font-size: 16vw;
    }

    h2 {
        font-size: 2.2rem;
    }

    section {
        flex-direction: column;
    }

    .intro {
        margin-top: 2rem;
        min-height: auto;
    }

    .portrait-col {
        text-align: center;
    }

    .portrait {
        margin: 0 auto 1.5rem;
        max-width: 200px;
        max-height: 200px;
    }

    .text-col h1 {
        margin-left: 0;
    }

    .text-col h2 {
        margin-left: 0;
    }

    .project {
        grid-template-columns: 1fr;
        gap: 0.25rem;
    }

    .project-meta {
        flex-direction: row;
        align-items: center;
        gap: 0.75rem;
        text-align: left;
    }

    .projects .portrait-col {
        display: none;
    }
}
