/* CSS Variables & Reset */
:root {
    --bg-body: #ffffff;
    /* Pure White for Blog Style */

    --text-main: #111111;
    /* Sharp Black */
    --text-muted: #555555;
    --text-light: #888888;

    --accent: #2563eb;
    --border: #eeeeee;

    --font-heading: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

    --max-width: 680px;
    /* Optimal reading width */
}

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

body {
    background-color: var(--bg-body);
    color: var(--text-main);
    font-family: var(--font-body);
    line-height: 1.7;
    /* Looser line height for reading */
    -webkit-font-smoothing: antialiased;
    padding: 1.5rem 1.5rem;
}

/* Container */
.portfolio-container {
    max-width: var(--max-width);
    margin: 0 auto;
    /* No borders, no shadows - pure content */
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--accent);
}

/* Header */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
}

.logo {
    font-weight: 700;
    font-size: 1.3rem;
    color: var(--text-main);
}

.nav-links {
    display: flex;
    gap: 1.5rem;
}

.nav-links a {
    font-size: 1rem;
    color: var(--text-muted);
}

.btn-download {
    font-size: 0.9rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

/* Typography */
h1 {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    margin-bottom: 1.5rem;
    line-height: 1.2;
    color: var(--text-main);
}

h2 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    /* Larger, like a sub-headline in a post */
    font-weight: 700;
    letter-spacing: -0.03em;
    margin-top: 3rem;
    margin-bottom: 1.5rem;
    color: var(--text-main);
}

h3 {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
    color: var(--text-main);
}

p {
    color: var(--text-muted);
    margin-bottom: 1rem;
}

/* Hero Section */
.hero {
    margin-bottom: 3rem;
}

.subtitle {
    font-size: 1.05rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.contact-links {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    font-size: 0.95rem;
}

.contact-links a {
    color: var(--accent);
    text-decoration: underline;
    text-underline-offset: 4px;
    text-decoration-color: rgba(37, 99, 235, 0.3);
}

.contact-links a:hover {
    text-decoration-color: var(--accent);
}

/* Tech Stack (Definition List Style) */
.tech-stack-list {
    margin-top: 1rem;
}

.tech-row {
    margin-bottom: 1.5rem;
    /* Removed grid, making it flow like text */
}

.tech-row h3 {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-light);
    margin-bottom: 0.25rem;
}

.tech-row p {
    font-size: 1.05rem;
    color: var(--text-main);
}

/* Experience (Blog Post Style) */
.experience-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}



.role-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 0.75rem;
}

.company {
    font-weight: 400;
    color: var(--text-muted);
}

.date {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    color: var(--text-light);
    white-space: nowrap;
}

.job-details li {
    list-style: none;
    margin-bottom: 0.4rem;
    color: var(--text-muted);
    font-size: 1rem;
    padding-left: 0;
}

.job-details li::before {
    content: "•";
    color: var(--text-light);
    margin-right: 0.5rem;
}

/* Projects (Clean Table Style) */
.project-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1.5rem;
}

.project-table td {
    padding: 1rem 1.5rem 1rem 0;
    border-bottom: 1px solid var(--border);
    vertical-align: top;
}

.project-table th {
    text-align: left;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-light);
    padding-bottom: 0.75rem;
    padding-right: 1.5rem;
    border-bottom: 1px solid var(--border);
    font-weight: 600;
}

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

.p-name {
    font-weight: 600;
    color: var(--text-main);
    font-size: 0.95rem;
    padding-right: 1.5rem;
}

.p-desc {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.5;
    padding-right: 2rem;
}

.p-stack {
    font-family: var(--font-heading);
    font-size: 0.85rem;
    color: var(--text-light);
    padding-right: 1rem;
}

.p-link a {
    font-size: 0.85rem;
    color: var(--accent);
    white-space: nowrap;
}

.p-link a:hover {
    text-decoration: underline;
}

/* Mobile Table Adaptation */
@media (max-width: 600px) {

    .project-table,
    .project-table tbody,
    .project-table tr,
    .project-table td {
        display: block;
        width: 100%;
    }

    .project-table thead {
        display: none;
        /* Hide headers on mobile */
    }

    .project-table tr {
        margin-bottom: 1.5rem;
        border-bottom: 1px solid var(--border);
        padding-bottom: 1rem;
    }

    .project-table td {
        padding: 0.25rem 0;
        border: none;
    }

    .p-name {
        font-size: 1.1rem;
        margin-bottom: 0.25rem;
    }

    .p-desc {
        margin-bottom: 0.5rem;
    }

    .p-stack {
        color: var(--text-light);
        margin-bottom: 0.5rem;
    }
}

/* Education */
.education-grid {
    margin-top: 1rem;
}

.edu-item {
    margin-bottom: 1.5rem;
}

/* Footer */
footer {
    margin-top: 6rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    color: var(--text-light);
    font-size: 0.85rem;
}

.socials {
    display: flex;
    gap: 1.5rem;
}

/* Mobile */
@media (max-width: 600px) {
    header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1.5rem;
        margin-bottom: 3rem;
    }

    .nav-links {
        flex-wrap: wrap;
        gap: 1rem;
    }

    h1 {
        font-size: 1.8rem;
    }

    .role-header {
        flex-direction: column;
        gap: 0.25rem;
    }
}