@font-face {
    font-family: 'Inter';
    src: url("../fonts/inter-latin-wght-normal.woff2") format("woff2-variations");
    font-weight: 100 900;
    font-style: normal;
    font-display: swap;
    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';
    src: url("../fonts/inter-latin-ext-wght-normal.woff2") format("woff2-variations");
    font-weight: 100 900;
    font-style: normal;
    font-display: swap;
    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: 'Source Serif 4';
    src: url("../fonts/source-serif-4-latin-wght-normal.woff2") format("woff2-variations");
    font-weight: 100 900;
    font-style: normal;
    font-display: swap;
    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: 'Source Serif 4';
    src: url("../fonts/source-serif-4-latin-ext-wght-normal.woff2") format("woff2-variations");
    font-weight: 100 900;
    font-style: normal;
    font-display: swap;
    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: 'IBM Plex Mono';
    src: url("../fonts/ibm-plex-mono-latin-400-normal.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'IBM Plex Mono';
    src: url("../fonts/ibm-plex-mono-latin-500-normal.woff2") format("woff2");
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

:root {
    --navy: #0a1826;
    --navy-2: #0f2236;
    --navy-nav: rgba(13, 30, 48, .97);
    --paper: #f7f9fa;
    --white: #ffffff;
    --line: #dde5ea;
    --ink: #17293b;
    --muted: #5a6b7b;
    --accent: #9db8b5;
    --accent-hover: #c2d6d3;
    --accent-ink: #538e98;
    --accent-soft: #3f5d67;
    --focus: #ff2bbe;

    --on-navy: #b9c6d2;
    --on-navy-strong: #c7d3de;
    --on-navy-soft: #aebdcb;
    --on-navy-mute: #9fb0c0;
    --on-navy-dim: #7e90a2;

    --serif: 'Source Serif 4', Georgia, 'Times New Roman', serif;
    --sans: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --mono: 'IBM Plex Mono', 'SFMono-Regular', Consolas, monospace;

    --maxw: 1140px;
    --nav-h: 64px;

    --noise: url("../img/noise-overlay-256.png");
    --photo-tint: var(--accent-soft);
    --photo-wash: transparent;
    --photo-grain: .5;
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--nav-h) + 12px);
}

body {
    font-family: var(--sans);
    font-size: 16.5px;
    line-height: 1.65;
    color: var(--ink);
    background: var(--paper);
}

a {
    color: var(--accent-ink);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

a:focus-visible,
button:focus-visible {
    outline: 3px solid var(--focus);
    outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation: none !important;
        transition: none !important;
    }
}

.wrap {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 0 28px;
}

.skip {
    position: absolute;
    left: -9999px;
    z-index: 200;
    padding: 10px 16px;
    background: var(--accent);
    color: var(--white);
}

.skip:focus {
    left: 0;
    top: 0;
}

nav.top {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: var(--navy-nav);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid rgba(255, 255, 255, .08);
}

.top-inner {
    max-width: var(--maxw);
    height: var(--nav-h);
    margin: 0 auto;
    padding: 0 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.brand {
    flex-shrink: 0;
    margin-right: 20px;
    font-family: var(--serif);
    font-size: 1.05rem;
    font-weight: 600;
    letter-spacing: .01em;
    white-space: nowrap;
    color: var(--white);
}

.brand span,
.name span {
    color: var(--accent);
    font-weight: 700;
}

.top ul {
    display: flex;
    gap: 4px;
    list-style: none;
}

.top ul a {
    display: block;
    padding: 8px 11px;
    border-radius: 6px;
    font-size: .8rem;
    white-space: nowrap;
    font-weight: 500;
    letter-spacing: .01em;
    color: var(--on-navy);
}

.top ul a:hover {
    background: rgba(255, 255, 255, .06);
    color: var(--white);
    text-decoration: none;
}

.top ul a.active {
    background: var(--accent);
    color: var(--navy);
}

.nav-toggle {
    display: none;
    padding: 7px 12px;
    border: 1px solid rgba(255, 255, 255, .25);
    border-radius: 6px;
    background: none;
    font-family: var(--mono);
    font-size: .78rem;
    color: var(--white);
    cursor: pointer;
}

.top ul li.lang {
    margin-left: 10px;
    padding-left: 10px;
    border-left: 1px solid rgba(255, 255, 255, .18);
}

.top ul li.lang a {
    font-family: var(--mono);
    font-size: .74rem;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.lang-hint {
    position: fixed;
    top: var(--nav-h);
    left: 0;
    right: 0;
    z-index: 99;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 8px 18px;
    padding: 10px 28px;
    background: var(--accent);
    color: var(--navy);
    font-size: .85rem;
}

.lang-hint a {
    color: var(--navy);
    font-weight: 600;
    text-decoration: underline;
}

.lang-hint button {
    border: none;
    background: none;
    font: inherit;
    color: var(--navy);
    text-decoration: underline;
    cursor: pointer;
    opacity: .75;
}

.f-legal a {
    color: var(--on-navy-dim);
}

.legal {
    max-width: 720px;
    padding-top: 130px;
}

.legal h2 {
    margin-bottom: 28px;
}

.legal h3 {
    margin: 34px 0 10px;
    font-family: var(--serif);
    font-size: 1.1rem;
    font-weight: 600;
}

.legal p + p,
.legal address {
    margin-top: 12px;
}

.legal address {
    font-style: normal;
}

.legal ul {
    margin-top: 10px;
    padding-left: 20px;
}

.legal .placeholder {
    padding: 2px 6px;
    border-radius: 4px;
    background: #fdf0c8;
    font-family: var(--mono);
    font-size: .85em;
}

.progress {
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
}

header.hero {
    position: relative;
    padding: 150px 0 90px;
    background: var(--navy);
    color: var(--white);
    overflow: hidden;
}

.hero-grid {
    position: relative;
    display: grid;
    grid-template-columns: 1.35fr .65fr;
    gap: 56px;
    align-items: center;
}

h1 {
    font-family: var(--serif);
    font-size: clamp(2.4rem, 5.4vw, 3.7rem);
    font-weight: 700;
    line-height: 1.06;
    letter-spacing: -.01em;
}

.hero .sub {
    margin-top: 16px;
    font-family: var(--serif);
    font-size: clamp(1.1rem, 2vw, 1.35rem);
    font-weight: 400;
    color: var(--on-navy-strong);
}

.hero .roles {
    display: grid;
    gap: 8px;
    margin-top: 26px;
    font-size: .95rem;
    color: var(--on-navy-soft);
}

.hero .roles b {
    color: var(--white);
    font-weight: 600;
}

.hero-cta {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 34px;
}

.btn {
    display: inline-block;
    padding: 12px 22px;
    border-radius: 8px;
    font-size: .9rem;
    font-weight: 600;
    text-decoration: none;
}

.btn:hover {
    text-decoration: none;
}

.btn.primary {
    background: var(--accent);
    color: var(--navy);
}

.btn.primary:hover {
    background: var(--accent-hover);
}

.btn.ghost {
    border: 1px solid rgba(255, 255, 255, .35);
    color: var(--white);
}

.btn.ghost:hover {
    border-color: var(--white);
}

.hero-portrait {
    justify-self: end;
}

.portrait-ph {
    --photo-src: url("../img/portrait.png");
    --photo-under: var(--white);
    width: 250px;
    aspect-ratio: 3 / 4;
    border: 2px solid rgba(255, 255, 255, .35);
    border-radius: 14px;
    rotate: 5deg;
    background: var(--photo-under) var(--photo-src) var(--photo-pos, center) / cover;
}

section {
    padding: 18px 0 75px;
}

section.alt {
    background: var(--white);
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}

.sec-head {
    max-width: 760px;
    margin: 75px 0 44px;
}

.kicker,
.sec-kicker,
.f-h,
.facts dt {
    font-family: var(--mono);
    text-transform: uppercase;
}

.kicker {
    margin-bottom: 18px;
    font-size: .78rem;
    letter-spacing: .14em;
    color: var(--accent);
}

.sec-kicker {
    margin-bottom: 10px;
    font-size: .74rem;
    letter-spacing: .14em;
    color: var(--accent-ink);
}

h2 {
    font-family: var(--serif);
    font-size: clamp(1.7rem, 3.4vw, 2.35rem);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -.01em;
}

.sec-head p {
    margin-top: 14px;
    font-size: 1.02rem;
    color: var(--muted);
}

h3.block {
    margin: 38px 0 16px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--accent-soft);
    font-family: var(--serif);
    font-size: 1.25rem;
    font-weight: 600;
}

h3.block:first-of-type {
    margin-top: 0;
}

.m {
    display: block;
    margin-top: 2px;
    font-size: .8rem;
    color: var(--muted);
}

.note {
    font-size: .94rem;
    color: var(--muted);
}

.note + .note {
    margin-top: 14px;
}

.board {
    width: 100%;
    max-height: 250px;
    aspect-ratio: 2 / 1;
    overflow: visible !important;
}

.profil-grid {
    display: grid;
    grid-template-columns: 1.2fr .8fr;
    gap: 52px;
}

.profil-grid p + p {
    margin-top: 16px;
}

.facts {
    padding: 26px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--white);
    box-shadow: 0 4px 18px rgba(13, 30, 48, .05);
}

.facts dt {
    margin-top: 16px;
    font-size: .7rem;
    letter-spacing: .1em;
    color: var(--muted);
}

.facts dt:first-child {
    margin-top: 0;
}

.facts dd {
    margin-top: 3px;
    font-size: .94rem;
}

.proj-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.proj {
    display: flex;
    flex-direction: column;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--white);
    overflow: hidden;
    transition: box-shadow .2s ease, transform .2s ease;
}

section.alt .proj {
    background: var(--paper);
}

.proj:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(13, 30, 48, .1);
}

.proj .media {
    --photo-src: url("../img/portrait.png");
    aspect-ratio: 3 / 1;
    border-bottom: 1px solid var(--line);
    background: var(--photo-src) var(--photo-pos, center) / cover;
    opacity: .95;
}

.media.air { --photo-src: url("../img/projects/jsxgraph-air.png"); }
.media.quarto { --photo-src: url("../img/projects/quarto.png"); }
.media.focus { --photo-src: url("../img/projects/focus.png"); }
.media.sketchometry { --photo-src: url("../img/projects/sketchometry.png"); }
.media.jsxgraph { --photo-src: url("../img/projects/jsxgraph.png"); }
.media.egbook { --photo-src: url("../img/projects/egbook.png"); }
.media.cmldt { --photo-src: url("../img/projects/cmldt.png"); }
.media.schools { --photo-src: url("../img/projects/schools.png"); }
.media.bayernlab { --photo-src: url("../img/projects/bayernlab.png"); }

.proj .body {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 20px 22px 22px;
}

.proj .meta {
    font-family: var(--mono);
    font-size: .7rem;
    letter-spacing: .06em;
    color: var(--accent-ink);
}

.proj h4 {
    margin: 5px 0 8px;
    font-family: var(--serif);
    font-size: 1.15rem;
    font-weight: 600;
}

.proj p {
    flex: 1;
    font-size: .9rem;
    color: var(--muted);
}

.proj p + p {
    flex: 0;
    margin-top: 10px;
}

.proj .links {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 14px;
    font-size: .82rem;
}

.chip {
    display: inline-block;
    margin-left: 8px;
    padding: 2px 9px;
    border-radius: 999px;
    background: var(--accent);
    font-size: .68rem;
    font-weight: 600;
    letter-spacing: .05em;
    color: var(--navy);
    vertical-align: 2px;
}

.tl {
    position: relative;
    max-width: 820px;
    margin: 0 auto;
}

.tl::before {
    content: "";
    position: absolute;
    left: 117px;
    top: 4px;
    bottom: 4px;
    width: 3px;
    background: var(--line);
}

.tl-item {
    position: relative;
    display: grid;
    grid-template-columns: 96px 1fr;
    gap: 46px;
    padding-bottom: 34px;
}

.tl-item:last-child {
    padding-bottom: 0;
}

.tl-item::before {
    content: "";
    position: absolute;
    left: 110px;
    top: 4px;
    z-index: 1;
    width: 18px;
    height: 18px;
    border: 3px solid var(--accent);
    border-radius: 50%;
    background: var(--paper);
}

section.alt .tl-item::before {
    background: var(--white);
}

.tl-item.key::before {
    background: var(--accent);
}

.tl-year {
    padding-top: 3px;
    font-family: var(--mono);
    font-size: .86rem;
    font-weight: 500;
    text-align: right;
    color: var(--muted);
}

.tl-item h4 {
    font-family: var(--serif);
    font-size: 1.1rem;
    font-weight: 600;
}

.tl-item p {
    max-width: 40em;
    margin-top: 3px;
    font-size: .92rem;
    color: var(--muted);
}

.cols2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
}

ul.clean {
    list-style: none;
}

ul.clean li {
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
    font-size: .95rem;
}

ul.clean li:last-child {
    border-bottom: none;
}

.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag {
    padding: 6px 13px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--white);
    font-size: .78rem;
    font-weight: 500;
    color: var(--ink);
}

section.alt .tag {
    background: var(--paper);
}

.aiz-ein {
    --photo-src: url("../img/aiz-ein.jpg");
    width: 450px;
    max-width: 100%;
    aspect-ratio: 1 / 1;
    margin-bottom: 2rem;
    border: 2px solid rgba(255, 255, 255, .35);
    border-radius: 14px;
    rotate: -5deg;
    background: rgba(255, 255, 255, .04) var(--photo-src) center / cover;
}

.link-note {
    margin-top: 16px;
    font-size: .9rem;
}

.pub-books,
.serie-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}

.serie-row {
    margin-top: 8px;
}

.book,
.serie {
    padding: 16px 18px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--paper);
}

.book {
    font-size: .9rem;
}

.book b,
.serie b,
.award b {
    font-family: var(--serif);
}

.book b {
    font-weight: 600;
}

.book .m {
    font-size: .78rem;
}

.serie {
    border-left: 4px solid var(--accent);
}

.serie.wide {
    grid-column: 1 / -1;
}

.serie .m {
    font-family: var(--mono);
    font-size: .7rem;
}

.serie p {
    margin-top: 6px;
    font-size: .86rem;
    color: var(--muted);
}

.award {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-top: 14px;
    padding: 16px 18px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--paper);
}

.award .medal {
    font-size: 1.5rem;
    line-height: 1;
    color: var(--ink);
}

.award .m {
    margin-top: 0;
}

.conf-feature {
    display: grid;
    grid-template-columns: 1.3fr .7fr;
    gap: 36px;
    align-items: center;
    padding: 34px 36px;
    border-radius: 14px;
    background: var(--navy);
    color: var(--white);
}

.conf-feature h4 {
    font-family: var(--serif);
    font-size: 1.5rem;
    font-weight: 700;
}

.conf-feature p {
    margin-top: 10px;
    font-size: .94rem;
    color: var(--on-navy);
}

.conf-feature strong {
    color: var(--white);
}

.conf-feature .n {
    font-family: var(--serif);
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.25;
    text-align: center;
    color: var(--accent);
}

.conf-feature .nl {
    margin-top: 2px;
    font-size: .8rem;
    text-align: center;
    color: var(--on-navy-mute);
}

.conf-feature + .cols2 {
    margin-top: 44px;
}

footer {
    padding: 70px 0 44px;
    background: var(--navy);
    color: var(--on-navy);
}

footer h2 {
    color: var(--white);
}

footer a {
    color: var(--accent-ink);
}

footer .sec-kicker {
    color: var(--accent);
}

.f-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 40px;
    margin-top: 34px;
}

.f-h {
    margin-bottom: 10px;
    font-size: .7rem;
    letter-spacing: .12em;
    color: var(--on-navy-dim);
}

.contact {
    display: grid;
    grid-template-columns: max-content 1fr;
    gap: 0 1rem;
    align-items: start;
}

.f-meta {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 10px;
    margin-top: 44px;
    padding-top: 22px;
    border-top: 1px solid rgba(255, 255, 255, .12);
    font-family: var(--mono);
    font-size: .74rem;
    color: var(--on-navy-dim);
}

.photo,
.portrait-ph,
.proj .media {
    position: relative;
    isolation: isolate;
    overflow: hidden;
}

.portrait-ph {
    --photo-base: var(--white);
    --photo-tint: #98c5be;
    --photo-wash: rgba(157, 184, 181, .2);
}

.proj .media {
    --photo-tint: var(--accent);
    --photo-wash: rgba(157, 184, 181, .38);
}

.photo img {
    display: block;
    width: 100%;
    height: auto;
}

.photo--mono img,
.photo--tint img {
    filter: grayscale(1) contrast(1.05);
}

.photo--grain::before,
.portrait-ph::before,
.proj .media::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    background: var(--noise) repeat 0 0 / 256px 256px;
    opacity: var(--photo-grain);
    pointer-events: none;
}

.photo--tint::after,
.portrait-ph::after,
.proj .media::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 2;
    pointer-events: none;
}

.photo--tint::after {
    background: var(--photo-tint);
    opacity: .45;
}

.portrait-ph::after,
.proj .media::after {
    background: var(--photo-wash);
}

@supports (mix-blend-mode: multiply) {
    .photo--tint::after {
        opacity: 1;
        mix-blend-mode: multiply;
    }
}

@supports (background-blend-mode: luminosity) {
    .portrait-ph,
    .proj .media {
        background-image:
                linear-gradient(var(--photo-tint), var(--photo-tint)),
                var(--photo-src),
                linear-gradient(var(--photo-base, #808080), var(--photo-base, #808080));
        background-size: auto, cover, auto;
        background-position: var(--photo-pos, center);
        background-repeat: no-repeat;
        background-blend-mode: multiply, luminosity, normal;
    }
}

@media (forced-colors: active) {
    .photo::before,
    .photo::after,
    .portrait-ph::before,
    .portrait-ph::after,
    .proj .media::before,
    .proj .media::after {
        display: none;
    }
}

@media (max-width: 1200px) {
    .f-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 1080px) {
    .nav-toggle {
        display: block;
    }

    .top ul {
        display: none;
        position: absolute;
        top: var(--nav-h);
        left: 0;
        right: 0;
        flex-direction: column;
        gap: 0;
        padding: 8px 0;
        background: var(--navy);
        border-bottom: 1px solid rgba(255, 255, 255, .1);
    }

    .top ul.open {
        display: flex;
    }

    .top ul a {
        padding: 13px 28px;
        border-radius: 0;
    }
}

@media (max-width: 960px) {
    .proj-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 880px) {
    .hero-grid,
    .profil-grid {
        grid-template-columns: 1fr;
    }

    .hero-grid {
        gap: 34px;
    }

    .hero-portrait {
        order: -1;
        justify-self: start;
    }

    .portrait-ph {
        width: 170px;
        rotate: 0deg;
    }
}

@media (max-width: 860px) {
    .cols2 {
        grid-template-columns: 1fr;
    }

    .aiz-ein {
        rotate: 0deg;
    }
}

@media (max-width: 820px) {
    .conf-feature {
        grid-template-columns: 1fr;
        padding: 28px;
    }
}

@media (max-width: 720px) {
    .pub-books,
    .serie-row {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .proj-grid {
        grid-template-columns: 1fr;
    }

    .tl::before {
        left: 8px;
    }

    .tl-item {
        grid-template-columns: 1fr;
        gap: 2px;
        padding-left: 34px;
    }

    .tl-item::before {
        left: 0;
    }

    .tl-year {
        text-align: left;
    }
}