/* Self-hosted variable fonts. No external requests: the page contacts no
   third-party server, so visitor IPs are never disclosed to Google. */

@font-face {
    font-family: 'Outfit';
    font-style: normal;
    font-weight: 300 800;
    font-display: swap;
    src: url('assets/fonts/outfit-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: 'Outfit';
    font-style: normal;
    font-weight: 300 800;
    font-display: swap;
    src: url('assets/fonts/outfit-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;
}

@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 300 500;
    font-display: swap;
    src: url('assets/fonts/inter-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: 300 500;
    font-display: swap;
    src: url('assets/fonts/inter-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 {
    /* Sophisticated, photo-inspired pale theme (Option 9) */
    --bg-base: #F8F6F0; /* Cream base */
    --bg-accent: #EBE6DF; /* Slightly darker cream */
    --text-primary: #193833; /* Dark Forest text */
    --text-secondary: #4A6B63;
    
    /* Elegant, natural accents from the photo */
    --accent-1: #DE9E36; /* Bright Mustard/Amber */
    --accent-2: #2C6E63; /* Vibrant Jade */
    --accent-3: #A3B8B8; /* Soft Aqua */
    
    /* Glassmorphism settings for a pale background */
    --glass-bg: rgba(255, 255, 255, 0.45);
    --glass-border: rgba(255, 255, 255, 0.8);
    --glass-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
    --blur: 12px;

    /* Typography */
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
}

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

body {
    background-color: var(--bg-base);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
    min-height: 100vh;
}

/* Background Canvas */
#bg-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
    /* Blur here rather than via ctx.filter, which Safari ignores. The slight
       scale-up hides the feathered edges the blur leaves at the viewport rim. */
    filter: blur(40px);
    transform: scale(1.15);
}

/* Utilities */
.text-center { text-align: center; }
.mb-4 { margin-bottom: 2rem; }
.mt-4 { margin-top: 2rem; }
.mt-2 { margin-top: 1rem; }
.w-100 { width: 100%; }
.m-4 { margin: 2rem; }
.mx-auto { margin-left: auto; margin-right: auto; }

.section-padding {
    padding: 6rem 10% 4rem;
}

/* Glassmorphism Classes */
.glass-effect {
    background: var(--glass-bg);
    backdrop-filter: blur(var(--blur));
    -webkit-backdrop-filter: blur(var(--blur));
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
}

.text-gradient {
    background: linear-gradient(135deg, var(--accent-1), var(--accent-2));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Typography */
h1, h2, h3, h4, .nav-brand {
    font-family: var(--font-heading);
    font-weight: 600;
}

.section-title {
    font-size: 3rem;
    margin-bottom: 3rem;
    position: relative;
    display: inline-block;
    left: 50%;
    transform: translateX(-50%);
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, var(--accent-1), var(--accent-2));
    border-radius: 2px;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1.5rem 10%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;
    border-radius: 0 0 20px 20px;
}

.nav-brand {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-primary);
    background: linear-gradient(45deg, var(--accent-2), var(--accent-1));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 3rem;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 500;
    font-size: 1.1rem;
    position: relative;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: var(--accent-2);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-2);
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

.nav-btn, .primary-btn {
    padding: 0.8rem 1.8rem;
    border-radius: 30px;
    border: none;
    background: linear-gradient(45deg, var(--accent-1), var(--accent-3));
    color: white;
    font-weight: 600;
    font-family: var(--font-heading);
    cursor: pointer;
    text-decoration: none;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.primary-btn:hover, .nav-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(255, 0, 127, 0.4);
}

/* Hero name label */
.hero-name {
    display: block;
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-secondary);
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 1.2rem;
}

/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 10%;
    position: relative;
    overflow: hidden;
}

.hero-content {
    flex: 1;
    max-width: 600px;
    z-index: 10;
}

.hero-title {
    font-size: 4.5rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

.hero-subtitle {
    font-size: 1.4rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.hero-keywords {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2rem;
}

.keyword-badge {
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid var(--accent-3);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    color: var(--accent-2);
    font-weight: 600;
}

.hero-visual {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10;
}

.portrait-container {
    width: 350px;
    height: 450px;
    border-radius: 30px;
    position: relative;
    overflow: hidden;
    padding: 10px;
}

.portrait-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 20px;
    position: relative;
    z-index: 2;
    filter: drop-shadow(0 0 20px rgba(0, 0, 0, 0.5));
}

/* Glow Orbs behind portrait */
.glow-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    z-index: 1;
    animation: floatOrb 8s infinite alternate ease-in-out;
}

.orb-1 {
    width: 250px;
    height: 250px;
    background: var(--accent-1);
    top: -50px;
    left: -50px;
    opacity: 0.6;
}

.orb-2 {
    width: 200px;
    height: 200px;
    background: var(--accent-2);
    bottom: -30px;
    right: -30px;
    opacity: 0.6;
    animation-delay: -4s;
}

@keyframes floatOrb {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(30px, 30px) scale(1.1); }
}

/* MOSAIC Feature Section */
.mosaic-feature {
    padding: 2rem 10% 5rem;
}

.mosaic-inner {
    max-width: 900px;
    margin: 0 auto;
    padding: 3rem 3.5rem;
    border-radius: 24px;
    border-left: 4px solid var(--accent-1);
}

.mosaic-label {
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--accent-1);
    margin-bottom: 1rem;
}

.mosaic-title {
    font-size: 5rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--accent-1), var(--accent-2));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.4rem;
    line-height: 1;
    letter-spacing: -2px;
}

.mosaic-full-name {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    font-style: italic;
    letter-spacing: 0.3px;
}

.mosaic-description {
    font-size: 1.15rem;
    line-height: 1.85;
    color: var(--text-primary);
    max-width: 720px;
    margin-bottom: 2rem;
}

.mosaic-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
}

.mosaic-tag {
    background: rgba(44, 110, 99, 0.08);
    border: 1px solid rgba(44, 110, 99, 0.25);
    color: var(--accent-2);
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

/* Engagement Section - Timeline */
.timeline-group-label {
    max-width: 900px;
    margin: 0 auto 1.5rem;
    padding-left: 60px;
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 600;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--accent-2);
}

.timeline + .timeline-group-label {
    margin-top: 4rem;
}

.timeline {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 20px;
    top: 0;
    height: 100%;
    width: 2px;
    background: linear-gradient(to bottom, var(--accent-2), var(--accent-1), transparent);
}

.timeline-item {
    position: relative;
    margin-bottom: 2.5rem;
    padding: 2rem;
    border-radius: 15px;
    margin-left: 60px;
    transition: transform 0.3s ease;
}

.timeline-item:hover {
    transform: translateX(10px);
    border-color: rgba(255, 0, 127, 0.3);
}

.timeline-dot {
    position: absolute;
    left: -46px;
    top: 30px;
    width: 14px;
    height: 14px;
    background: var(--accent-2);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--accent-2), 0 0 20px var(--accent-2);
}

.timeline-date {
    display: inline-block;
    color: var(--accent-1);
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    letter-spacing: 1px;
}

.timeline-role {
    font-size: 1.5rem;
    margin-bottom: 0.3rem;
    color: var(--text-primary);
}

.timeline-fullname {
    font-size: 0.95rem;
    font-style: italic;
    color: var(--accent-2);
    margin-bottom: 0.4rem;
}

.timeline-org {
    font-size: 1.1rem;
    color: var(--text-secondary);
    font-weight: 400;
    margin-bottom: 1rem;
}

/* Inline links: jade text keeps body-copy contrast, mustard underline ties
   them to the accent used by dates, rules and buttons. */
.timeline-item p a {
    color: var(--accent-2);
    font-weight: 500;
    text-decoration: none;
    border-bottom: 1.5px solid rgba(222, 158, 54, 0.5);
    padding-bottom: 1px;
    transition: border-color 0.3s ease, background 0.3s ease;
}

.timeline-item p a:hover {
    border-bottom-color: var(--accent-1);
    background: rgba(222, 158, 54, 0.14);
}

/* Organization marks on timeline cards */
.org-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem 1rem;
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid rgba(163, 184, 184, 0.4);
}

.org-mark {
    display: inline-flex;
    align-items: center;
    opacity: 0.75;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.org-mark img {
    height: 26px;
    width: auto;
    max-width: 160px;
    object-fit: contain;
    display: block;
}

/* Optical sizing: bare wordmarks read much larger than stacked lockups
   at the same pixel height, so each mark is tuned to match visually. */
.org-mark img[src$="uzh.svg"] { height: 34px; }
.org-mark img[src$="clarin-ch.png"] { height: 32px; }
.org-mark img[src$="tib.svg"] { height: 24px; }
.org-mark img[src$="sdsc.svg"] { height: 26px; }
.org-mark img[src$="ethz.svg"] { height: 19px; }
.org-mark img[src$="optohive.png"] { height: 18px; }
.org-mark img[src$="csem.svg"] { height: 16px; }
.org-mark img[src$="swissuniversities.svg"] { height: 14px; }
.org-mark img[src$="eu-flag.svg"] { height: 20px; }

.org-mark:hover {
    opacity: 1;
    transform: translateY(-2px);
}

.org-chip {
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    padding: 0.35rem 0.8rem;
    border: 1px solid var(--accent-3);
    border-radius: 20px;
    color: var(--accent-2);
    text-decoration: none;
    white-space: nowrap;
    transition: background 0.3s ease, color 0.3s ease;
}

a.org-chip:hover {
    background: var(--accent-2);
    color: var(--bg-base);
}

.org-chip-static {
    border-style: dashed;
    color: var(--text-secondary);
}

.org-more {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-decoration: none;
    border-bottom: 1px dotted var(--accent-3);
    transition: color 0.3s ease;
}

.org-more:hover {
    color: var(--accent-2);
}

.section-lead {
    max-width: 720px;
    margin: -1.5rem auto 3.5rem;
    text-align: center;
    color: var(--text-secondary);
    font-size: 1.1rem;
    line-height: 1.8;
}

/* Publications Section */
.pub-intro {
    max-width: 900px;
    margin: -1.5rem auto 3.5rem;
    text-align: center;
    color: var(--text-secondary);
    font-size: 1.05rem;
    line-height: 2;
}

.pub-asof {
    font-size: 0.85rem;
    opacity: 0.75;
}

.pub-scholar {
    color: var(--accent-2);
    text-decoration: none;
    font-weight: 600;
    border-bottom: 1.5px solid rgba(222, 158, 54, 0.5);
    transition: border-color 0.3s ease, background 0.3s ease;
}

.pub-scholar:hover {
    border-bottom-color: var(--accent-1);
    background: rgba(222, 158, 54, 0.14);
}

.pub-groups {
    max-width: 900px;
    margin: 0 auto;
}

.pub-group {
    display: grid;
    grid-template-columns: 90px 1fr;
    gap: 2rem;
    padding: 1.75rem 0;
    border-top: 1px solid rgba(163, 184, 184, 0.4);
}

.pub-year {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 600;
    letter-spacing: 1px;
    color: var(--accent-1);
    padding-top: 0.15rem;
}

.pub-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.pub-title {
    font-family: var(--font-heading);
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.45;
    margin-bottom: 0.3rem;
}

.pub-title a {
    color: inherit;
    text-decoration: none;
    border-bottom: 1.5px solid rgba(222, 158, 54, 0.5);
    transition: color 0.3s ease, border-color 0.3s ease, background 0.3s ease;
}

.pub-title a:hover {
    color: var(--accent-2);
    border-bottom-color: var(--accent-1);
    background: rgba(222, 158, 54, 0.14);
}

.pub-authors {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

.pub-authors strong {
    color: var(--accent-2);
    font-weight: 600;
}

.pub-venue {
    font-size: 0.85rem;
    color: var(--text-secondary);
    opacity: 0.8;
    font-style: italic;
    margin-top: 0.15rem;
}

.pub-badge {
    display: inline-block;
    font-family: var(--font-body);
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: var(--accent-1);
    border: 1px solid var(--accent-1);
    border-radius: 20px;
    padding: 0.15rem 0.6rem;
    vertical-align: middle;
    margin-left: 0.4rem;
    white-space: nowrap;
}

/* Contact Section */
.contact-form {
    max-width: 600px;
    margin: 0 auto;
}

.form-group {
    margin-bottom: 1.5rem;
    text-align: left;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
    font-family: var(--font-heading);
}

.glass-input {
    width: 100%;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.glass-input:focus {
    outline: none;
    border-color: var(--accent-2);
    box-shadow: 0 0 15px rgba(44, 110, 99, 0.3);
}

/* Animations */
.fade-in {
    opacity: 0;
    transition: opacity 0.8s ease-out;
}
.fade-in.visible {
    opacity: 1;
}

.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}
.fade-in-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Footer */
.footer {
    padding: 2rem;
    background: rgba(0, 0, 0, 0.3);
    color: var(--text-secondary);
    border-top: 1px solid var(--glass-border);
}

/* Responsive */
@media (max-width: 768px) {
    .hero {
        flex-direction: column;
        justify-content: center;
        text-align: center;
        height: auto;
        padding-top: 120px;
        padding-bottom: 40px;
    }
    .hero-keywords {
        justify-content: center;
    }
    .hero-visual {
        margin-top: 3rem;
    }
    .nav-links {
        display: none; /* can add hamburger later */
    }
    .timeline::before {
        left: 10px;
    }
    .timeline-item {
        margin-left: 30px;
        padding: 1.5rem;
    }
    .timeline-dot {
        left: -26px;
    }
    .hero-title {
        font-size: 3rem;
    }
    .pub-group {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
}
