/* ── Inter variable font (latin + latin-ext only) ── */
@font-face {
    font-family: "Inter";
    font-style: normal;
    font-weight: 100 900;
    font-display: swap;
    src: url("inter-variable-latin-ext.woff2") format("woff2");
    unicode-range:
        U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304,
        U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
        U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
    font-family: "Inter";
    font-style: normal;
    font-weight: 100 900;
    font-display: swap;
    src: url("inter-variable-latin.woff2") format("woff2");
    unicode-range:
        U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
        U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
        U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
    /* Colour palette */
    --blue: #183883; /* close to Primary-140, slightly desaturated & warmer */
    --blue-light: #2e54b5; /* near Primary-100, pulled back from electric blue */
    --blue-bg: #edf1f9; /* much subtler than Primary-20, barely-there tint */
    --text: #2b3144; /* Dark-100 neighbourhood, slightly more neutral */
    --text-light: #5e6d8a; /* Dark-80 zone, more grey-blue than pure blue */
    --border: #c4ccdb; /* soft grey with blue undertone */
    --white: #ffffff;

    /* Type scale — minimum is 1 rem (browser default ≈ 16 px) */
    --font-sm: 1rem;
    --font-md: 1.1rem;
    --font-lg: 1.2rem;
    --font-xl: 1.9rem;
    --lh: 1.65;
    --lh-relaxed: 1.75;

    /* Spacing scale */
    --sp-xs: 0.25rem; /*  4 px */
    --sp-sm: 0.5rem; /*  8 px */
    --sp-md: 1rem; /* 16 px */
    --sp-lg: 1.5rem; /* 24 px */
    --sp-xl: 2rem; /* 32 px */
    --sp-2xl: 2.5rem; /* 40 px */
    --sp-3xl: 3rem; /* 48 px */

    /* Layout */
    --page-width: 820px;
    --h-pad: var(--sp-3xl); /* 3 rem — header & main side padding */
    --indent: 1.2rem; /* list / hanging-indent */
    --radius: 4px;
}

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

body {
    font-family: "Inter", "Segoe UI", sans-serif;
    color: var(--text);
    line-height: var(--lh);
    background-color: #f0f0f0;
    hyphens: auto;
    font-feature-settings: "calt" 1;
}

.page {
    max-width: var(--page-width);
    margin: var(--sp-xl) auto;
    background: var(--white);
    box-shadow: 0 1px 6px rgba(0, 0, 0, 0.08);
    border-radius: var(--radius);
    overflow: hidden;
}

/* ── Header ── */
header {
    background: var(--blue);
    color: var(--white);
    padding: var(--sp-2xl) var(--h-pad);
}

.header-inner {
    display: flex;
    align-items: center;
    gap: var(--sp-xl);
}

.header-photo {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid rgba(255, 255, 255, 0.3);
    flex-shrink: 0;
}

header h1 {
    font-size: var(--font-xl);
    font-weight: 600;
    letter-spacing: 0.02em;
    margin-bottom: var(--sp-xs);
}

header .tagline {
    font-size: var(--font-md);
    font-weight: 300;
    opacity: 0.9;
    margin-bottom: var(--sp-lg);
}

.contact-row {
    display: flex;
    flex-wrap: wrap;
    gap: var(--sp-xs) var(--sp-lg);
    align-items: baseline;
    font-size: var(--font-sm);
    opacity: 0.85;
}

.contact-row > * {
    white-space: nowrap;
}

.contact-address {
    flex-basis: 100%;
}

.contact-row a {
    color: var(--white);
    text-decoration: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

.contact-row a:hover {
    border-bottom-color: var(--white);
}

/* ── Main ── */
main {
    padding: var(--sp-xl) var(--h-pad) var(--sp-3xl);
}

section {
    margin-bottom: var(--sp-xl);
}

section:last-child {
    margin-bottom: 0;
}

h2 {
    font-size: var(--font-lg);
    font-weight: 600;
    color: var(--blue);
    text-transform: uppercase;
    letter-spacing: 0.07em;
    padding-bottom: var(--sp-sm);
    border-bottom: 2px solid var(--blue);
    margin-bottom: var(--sp-lg);
}

/* ── Summary ── */
.summary {
    font-size: var(--font-sm);
    color: var(--text-light);
    line-height: var(--lh-relaxed);
    text-align: justify;
}

/* ── Experience entries ── */
.entry {
    margin-bottom: var(--sp-lg);
}

.entry:last-child {
    margin-bottom: 0;
}

.entry-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    flex-wrap: wrap;
    margin-bottom: var(--sp-xs);
}

.entry-title {
    font-size: var(--font-md);
    font-weight: 600;
}

.entry-date {
    font-size: var(--font-sm);
    color: var(--text-light);
    white-space: nowrap;
}

.entry-org {
    font-size: var(--font-md);
    color: var(--blue-light);
    margin-bottom: var(--sp-sm);
}

.entry-body {
    font-size: var(--font-sm);
    color: var(--text-light);
    text-align: justify;
}

.entry-body p {
    margin-bottom: var(--sp-sm);
}

.entry-body ul {
    margin: var(--sp-sm) 0 var(--sp-sm) var(--indent);
}

.entry-body li {
    margin-bottom: var(--sp-xs);
}

.entry-body .sub-heading {
    font-weight: 600;
    color: var(--text);
    font-size: var(--font-sm);
    margin-top: var(--sp-sm);
    margin-bottom: var(--sp-xs);
}

.results {
    background: var(--blue-bg);
    border-left: 3px solid var(--blue-light);
    padding: var(--sp-sm) var(--sp-md);
    margin-top: var(--sp-sm);
    border-radius: 0 var(--radius) var(--radius) 0;
}

.results strong {
    font-size: var(--font-sm);
    color: var(--blue);
    display: block;
    margin-bottom: var(--sp-xs);
}

.results ul {
    margin-left: var(--indent);
}

/* ── Project box ── */
.project-box {
    background: var(--blue-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: var(--sp-md) var(--indent);
    font-size: var(--font-sm);
    color: var(--text-light);
    text-align: justify;
}

.project-box .project-title {
    font-weight: 600;
    color: var(--blue);
    font-size: var(--font-md);
    margin-bottom: var(--sp-xs);
}

.project-box a {
    color: var(--blue-light);
}

/* ── Publications ── */
.publication {
    font-size: var(--font-sm);
    color: var(--text-light);
    margin-bottom: var(--sp-sm);
    padding-left: var(--indent);
    text-indent: calc(-1 * var(--indent));
    text-align: justify;
}

.publication em {
    font-style: italic;
}

/* ── Skills grid ── */
.skills-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--indent);
}

.skill-group h3 {
    font-size: var(--font-sm);
    font-weight: 600;
    color: var(--blue);
    margin-bottom: var(--sp-sm);
}

.skill-group p,
.skill-group ul {
    font-size: var(--font-sm);
    color: var(--text-light);
}

.skill-group ul {
    list-style: none;
}

.skill-group li {
    margin-bottom: var(--sp-xs);
}

.lang-level {
    display: inline-block;
    font-size: var(--font-sm);
    color: var(--text-light);
    opacity: 0.7;
    margin-left: var(--sp-xs);
}

.tag {
    display: inline-block;
    background: var(--blue-bg);
    color: var(--blue);
    font-size: var(--font-sm);
    padding: var(--sp-xs) var(--sp-sm);
    border-radius: var(--radius);
    margin: var(--sp-xs) var(--sp-xs) var(--sp-xs) 0;
}

/* ── Footer ── */
footer {
    text-align: center;
    padding: var(--sp-lg);
    font-size: var(--font-sm);
    color: var(--text-light);
    border-top: 1px solid var(--border);
}

footer a {
    color: var(--text-light);
}

/* ── Responsive ── */
@media (max-width: 700px) {
    header,
    main {
        padding-left: var(--sp-lg);
        padding-right: var(--sp-lg);
    }

    .entry-header {
        flex-direction: column;
    }

    .skills-grid {
        grid-template-columns: 1fr;
    }
}

/* ── Print ── */
@media print {
    body {
        background: white;
    }
    .page {
        box-shadow: none;
        margin: 0;
    }
    header {
        padding: var(--sp-lg) var(--sp-xl);
    }
    main {
        padding: var(--sp-lg) var(--sp-xl);
    }
}
