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

:root {
    --page: #f7f9fc;
    --surface: #ffffff;
    --surface-alt: #eef4fb;
    --primary: #243b78;
    --secondary: #6a98cc;
    --secondary-soft: #dce9f7;
    --text: #334a76;
    --heading: #23356b;
    --muted: #63759b;
    --border: #d6e1f0;
    --border-strong: #b9cbe3;
    --content-width: 1180px;
    --radius-lg: 18px;
    --radius-md: 12px;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: "Manrope", sans-serif;
    line-height: 1.7;
    color: var(--text);
    background: var(--page);
}

.skip-link {
    position: absolute;
    left: 1rem;
    top: -3rem;
    z-index: 1000;
    padding: 0.8rem 1rem;
    background: var(--heading);
    color: var(--surface);
    text-decoration: none;
    font-weight: 700;
}

.skip-link:focus {
    top: 1rem;
}

a {
    color: inherit;
}

.container {
    max-width: var(--content-width);
    margin: 0 auto;
    padding: 0 24px;
}

.site-nav-wrap {
    position: sticky;
    top: 0;
    z-index: 999;
    padding: 0.9rem 1rem 0;
    pointer-events: none;
}

.site-nav-backdrop {
    display: none;
}

.hero {
    position: relative;
    padding: 1.35rem 2rem 1.5rem;
    background: var(--surface);
}

.header-bg,
.hero-wave {
    display: none;
}

.hero-inner {
    max-width: var(--content-width);
    margin: 0 auto;
}

.site-nav {
    max-width: var(--content-width);
    margin: 0 auto;
    display: flex;
    flex-wrap: nowrap;
    gap: 0.75rem 1.4rem;
    align-items: center;
    padding: 1rem 1.3rem;
    border: 1px solid rgba(214, 225, 240, 0.7);
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: 0 16px 34px rgba(35, 53, 107, 0.08);
    transition: padding 0.28s ease, background-color 0.28s ease, box-shadow 0.28s ease, transform 0.28s ease, border-color 0.28s ease;
    pointer-events: auto;
}

.site-nav-brand {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.6rem;
    height: 2.6rem;
    margin-right: auto;
    border-radius: 999px;
    background: var(--primary);
    color: var(--surface) !important;
    font-size: 0.92rem;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.site-nav-toggle {
    display: none;
}

.site-nav-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem 1.4rem;
    align-items: center;
}

.site-nav a {
    color: var(--primary);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    transition: color 0.2s ease, transform 0.2s ease;
}

.site-nav a:hover,
.site-nav a:focus-visible {
    color: var(--secondary);
    transform: translateY(-1px);
}

body.is-scrolled .site-nav-wrap {
    padding-top: 0.35rem;
}

body.is-scrolled .site-nav {
    padding: 0.72rem 1.05rem;
    background: rgba(255, 255, 255, 0.92);
    border-color: rgba(185, 203, 227, 0.95);
    box-shadow: 0 14px 30px rgba(35, 53, 107, 0.12);
}

.hero-card {
    position: relative;
    padding-top: 1.15rem;
}

.hero-card::before {
    content: "";
    display: block;
    width: 220px;
    height: 10px;
    margin-bottom: 2rem;
    background: var(--secondary);
}

.hero-grid {
    display: grid;
    grid-template-columns: 320px minmax(0, 1fr);
    gap: 2.5rem;
    align-items: start;
}

.hero-left {
    display: flex;
    justify-content: center;
}

.avatar {
    position: relative;
    width: 100%;
    max-width: 320px;
    aspect-ratio: 4 / 5;
    background: var(--surface-alt);
    border: 1px solid var(--border);
    overflow: hidden;
}

.avatar::before {
    content: "";
    position: absolute;
    inset: auto 0 0 0;
    height: 16px;
    background: var(--secondary);
    z-index: 2;
}

.profile-pic {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 24%;
    transform: scale(0.92);
    transform-origin: center center;
    display: block;
}

.hero-right {
    display: grid;
    gap: 1.35rem;
}

.label,
.section-kicker,
.stat-label,
.timeline-meta,
.contact-kicker {
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: 0.78rem;
    font-weight: 800;
    color: var(--secondary);
}

.hero-heading {
    display: grid;
    gap: 0.4rem;
}

.hero-right h1,
section h2,
.highlight-panel h3,
.timeline-item h3,
.skill-category h3,
.project-card h3 {
    font-family: "Cormorant Garamond", serif;
    color: var(--heading);
    line-height: 1.05;
}

.hero-right h1 {
    font-size: clamp(3rem, 5vw, 4.5rem);
    margin: 0;
}

.role {
    font-size: 1.35rem;
    line-height: 1.45;
    color: var(--text);
}

.hero-badge {
    display: none;
}

.hero-summary {
    max-width: 62ch;
    font-size: 1.02rem;
    color: var(--text);
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem 1.5rem;
    padding: 1.2rem 0;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.info-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.2rem;
}

.info-label {
    font-size: 0.84rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--primary);
}

.info-value {
    font-weight: 500;
    color: var(--text);
}

.specialties {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 0.6rem 1rem;
    border-radius: 999px;
    border: 1px solid var(--border-strong);
    background: var(--surface);
    color: var(--primary);
    font-size: 0.9rem;
    font-weight: 600;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.9rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0.8rem 1.35rem;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 700;
    transition: background-color 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

.btn-primary {
    background: var(--secondary);
    color: #fff;
    border: 1px solid var(--secondary);
}

.btn-primary:hover {
    background: #598bbc;
    border-color: #598bbc;
}

.btn-secondary {
    background: var(--surface);
    color: var(--primary);
    border: 1px solid var(--border-strong);
}

.btn-secondary:hover {
    background: var(--surface-alt);
}

.contact-bar {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}

.contact-item {
    display: grid;
    gap: 0.35rem;
    padding: 1rem 1.1rem;
    border: 1px solid var(--border);
    background: var(--surface-alt);
}

.contact-item a {
    text-decoration: none;
    color: var(--primary);
    font-weight: 700;
}

.profile-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem 1rem;
}

.contact-item a:hover,
.contact-info a:hover {
    text-decoration: underline;
}

.hero-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
    margin-top: 1.5rem;
}

.stat-card {
    padding: 1.25rem 1.3rem;
    background: var(--surface);
    border: 1px solid var(--border);
}

.stat-card strong {
    display: block;
    margin: 0.35rem 0 0.45rem;
    color: var(--heading);
    font-size: 1.02rem;
}

main {
    max-width: var(--content-width);
    margin: 0 auto;
    padding: 0 2rem 3rem;
}

.content-card {
    background: var(--surface);
    border: 1px solid var(--border);
    padding: 2.5rem;
}

section {
    padding: 2rem 0;
    border-top: 1px solid var(--border);
    scroll-margin-top: 6.5rem;
}

section:first-child {
    padding-top: 0;
    border-top: 0;
}

.section-heading {
    display: grid;
    gap: 0.45rem;
    margin-bottom: 1.3rem;
}

section h2 {
    font-size: clamp(2.2rem, 4vw, 3rem);
    max-width: 18ch;
}

.split-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.55fr) minmax(280px, 0.9fr);
    gap: 2rem;
}

.prose-block {
    display: grid;
    gap: 1rem;
    max-width: 68ch;
}

.highlight-panel,
.timeline-item,
.skill-category,
.project-card,
.contact-panel {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 0;
    box-shadow: none;
}

.highlight-panel {
    padding: 1.5rem;
    align-self: start;
}

.highlight-panel h3 {
    font-size: 1.9rem;
    margin-bottom: 0.9rem;
}

.highlight-list {
    list-style: none;
    display: grid;
    gap: 0.9rem;
}

.highlight-list li {
    position: relative;
    padding-left: 1.2rem;
}

.highlight-list li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.8rem;
    width: 6px;
    height: 6px;
    background: var(--secondary);
    border-radius: 50%;
}

.timeline {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.timeline-item {
    padding: 1.5rem;
    border-top: 5px solid var(--secondary);
}

.timeline-item h3 {
    font-size: 1.9rem;
    margin: 0.4rem 0 0.55rem;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}

.skill-category {
    padding: 1.5rem;
    border-top: 5px solid var(--secondary);
}

.skill-category h3 {
    font-size: 1.9rem;
    margin-bottom: 1rem;
}

.skill-category ul {
    list-style: none;
    display: grid;
    gap: 0.85rem;
}

.skill-category li {
    padding-bottom: 0.85rem;
    border-bottom: 1px solid var(--border);
}

.skill-category li:last-child {
    padding-bottom: 0;
    border-bottom: 0;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.project-card {
    padding: 1.5rem;
    display: grid;
    grid-template-rows: auto auto 1fr auto;
    gap: 0.9rem;
    border-left: 5px solid var(--secondary);
}

.publication-year {
    justify-self: start;
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.65rem;
    background: var(--secondary-soft);
    color: var(--primary);
    font-size: 0.8rem;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.project-card h3 {
    font-size: 1.85rem;
}

.project-card .btn {
    width: 100%;
    min-height: 52px;
    align-self: end;
}

.contact-section {
    padding-bottom: 0;
}

.contact-panel {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(280px, 0.95fr);
    gap: 1.25rem;
    padding: 1.5rem;
    border-top: 6px solid var(--secondary);
    background: var(--surface-alt);
}

.contact-info {
    display: grid;
    gap: 0.9rem;
}

.contact-info p {
    padding: 1rem 1.05rem;
    background: var(--surface);
    border: 1px solid var(--border);
}

.contact-info a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 700;
}

footer {
    padding: 2rem 0 2.6rem;
    text-align: center;
    color: var(--muted);
}

@media (max-width: 980px) {
    .hero-grid,
    .split-layout,
    .timeline,
    .skills-grid,
    .projects-grid,
    .contact-panel,
    .hero-stats {
        grid-template-columns: 1fr;
    }

    .avatar {
        max-width: 380px;
    }
}

@media (max-width: 720px) {
    body {
        font-size: 0.97rem;
    }

    .hero {
        padding: 1.5rem 1rem 1rem;
    }

    .site-nav-wrap {
        padding: 0.45rem 0.65rem 0;
    }

    main {
        padding: 0 1rem 2.5rem;
    }

    .content-card {
        padding: 1.5rem;
    }

    section {
        padding: 1.65rem 0;
        scroll-margin-top: 5.75rem;
    }

    .hero-grid {
        grid-template-columns: 1fr;
        gap: 1.2rem;
    }

    .hero-left {
        justify-content: flex-start;
    }

    .avatar {
        max-width: 280px;
    }

    .site-nav {
        position: relative;
        gap: 0.75rem;
        justify-content: space-between;
        padding: 0.72rem 0.85rem;
        z-index: 2;
    }

    .js .site-nav-links {
        position: absolute;
        top: calc(100% + 0.55rem);
        left: 0;
        right: 0;
        display: grid;
        gap: 0.45rem;
        padding: 0.7rem;
        border: 1px solid rgba(185, 203, 227, 0.95);
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(18px);
        -webkit-backdrop-filter: blur(18px);
        box-shadow: 0 24px 44px rgba(35, 53, 107, 0.16);
        transform-origin: top center;
        opacity: 0;
        visibility: hidden;
        transform: translateY(-10px) scale(0.98);
        transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s ease;
    }

    .js .site-nav-links a {
        display: block;
        padding: 0.9rem 1rem;
        background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
        border: 1px solid var(--border);
        font-size: 0.85rem;
        white-space: nowrap;
    }

    .site-nav-brand {
        width: 2.35rem;
        height: 2.35rem;
        margin-right: 0;
    }

    .js .site-nav-toggle {
        display: inline-grid;
        gap: 0.28rem;
        width: 2.5rem;
        height: 2.5rem;
        padding: 0.55rem;
        border: 1px solid var(--border);
        background: var(--surface);
        color: var(--primary);
        cursor: pointer;
    }

    .js .site-nav-backdrop {
        display: block;
        position: fixed;
        inset: 0;
        border: 0;
        background: rgba(35, 53, 107, 0.12);
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.22s ease, visibility 0.22s ease;
        pointer-events: none;
    }

    .site-nav-toggle span {
        display: block;
        width: 100%;
        height: 2px;
        background: currentColor;
        transition: transform 0.22s ease, opacity 0.22s ease;
    }

    .js body.nav-open .site-nav-links {
        opacity: 1;
        visibility: visible;
        transform: translateY(0) scale(1);
    }

    .js body.nav-open .site-nav-backdrop {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

    .js body.nav-open .site-nav-toggle span:nth-child(1) {
        transform: translateY(6px) rotate(45deg);
    }

    .js body.nav-open .site-nav-toggle span:nth-child(2) {
        opacity: 0;
    }

    .js body.nav-open .site-nav-toggle span:nth-child(3) {
        transform: translateY(-6px) rotate(-45deg);
    }

    .hero-card::before {
        width: 160px;
        height: 8px;
        margin-bottom: 1rem;
    }

    .hero-right {
        gap: 0.95rem;
    }

    .hero-heading {
        gap: 0.2rem;
    }

    .info-grid,
    .contact-bar {
        grid-template-columns: 1fr;
    }

    .hero-right h1 {
        font-size: 2.45rem;
        line-height: 0.98;
    }

    .role {
        font-size: 1rem;
        line-height: 1.4;
    }

    .hero-summary,
    .prose-block,
    .timeline-item p,
    .skill-category li,
    .project-card p,
    .contact-panel p,
    .contact-info p,
    .stat-card p {
        font-size: 0.97rem;
        line-height: 1.65;
    }

    .info-grid {
        gap: 0.75rem 1rem;
        padding: 1rem 0;
    }

    .section-kicker,
    .stat-label,
    .timeline-meta,
    .contact-kicker {
        font-size: 0.72rem;
        letter-spacing: 0.12em;
    }

    .info-label {
        font-size: 0.76rem;
    }

    .info-value,
    .contact-item,
    .profile-links a {
        font-size: 0.95rem;
    }

    .pill {
        min-height: 38px;
        padding: 0.5rem 0.85rem;
        font-size: 0.82rem;
    }

    .specialties {
        gap: 0.55rem;
    }

    .hero-actions {
        gap: 0.7rem;
    }

    .btn {
        min-height: 44px;
        font-size: 0.95rem;
        padding: 0.75rem 1.05rem;
    }

    .stat-card,
    .highlight-panel,
    .timeline-item,
    .skill-category,
    .project-card,
    .contact-panel,
    .contact-item,
    .contact-info p {
        padding: 1.2rem;
    }

    .stat-card strong {
        font-size: 0.98rem;
    }

    .publication-year {
        font-size: 0.74rem;
    }

    .project-card {
        gap: 0.75rem;
    }

    section h2,
    .highlight-panel h3,
    .timeline-item h3,
    .skill-category h3,
    .project-card h3 {
        font-size: 1.72rem;
        line-height: 1.02;
    }

    .project-card p {
        font-size: 0.92rem;
        line-height: 1.58;
    }

    .project-card .btn {
        min-height: 48px;
        font-size: 0.92rem;
    }
}

@media (max-width: 480px) {
    body {
        font-size: 0.95rem;
    }

    .site-nav {
        padding: 0.68rem 0.75rem;
    }

    .site-nav-links a {
        font-size: 0.8rem;
        padding: 0.8rem 0.85rem;
    }

    .content-card {
        padding: 1.2rem;
    }

    section {
        padding: 1.4rem 0;
    }

    .hero-right h1 {
        font-size: 2.15rem;
        max-width: 10ch;
    }

    .avatar {
        max-width: 235px;
    }

    .role {
        font-size: 0.94rem;
    }

    .hero-summary,
    .prose-block,
    .timeline-item p,
    .skill-category li,
    .project-card p,
    .contact-panel p,
    .contact-info p,
    .stat-card p {
        font-size: 0.94rem;
        line-height: 1.62;
    }

    .hero-grid {
        gap: 1rem;
    }

    .hero-right {
        gap: 0.85rem;
    }

    .info-grid {
        padding: 0.85rem 0;
    }

    section h2,
    .highlight-panel h3,
    .timeline-item h3,
    .skill-category h3,
    .project-card h3 {
        font-size: 1.5rem;
    }

    .project-card h3 {
        font-size: 1.34rem;
        line-height: 1.08;
    }

    .project-card p {
        font-size: 0.9rem;
        line-height: 1.55;
    }

    .publication-year {
        font-size: 0.7rem;
        padding: 0.22rem 0.55rem;
    }

    .timeline-item,
    .skill-category,
    .project-card,
    .highlight-panel,
    .contact-panel,
    .stat-card,
    .contact-item,
    .contact-info p {
        padding: 1rem;
    }

    .hero-actions {
        flex-direction: column;
    }

    .btn {
        width: 100%;
    }
}
