:root {
    color-scheme: light;
    --paper: #fafaf9;
    --paper-2: #f5f5f4;
    --ink: #1c1917;
    --muted: #78716c;
    --line: #e7e5e4;
    --line-strong: #d6d3d1;
    --dark: #1c1917;
    --dark-soft: #292524;
    --accent: #ef4444;
    --orange: #f97316;
    --green: #16a34a;
    --green-dark: #166534;
    --green-soft: #dcfce7;
    --blue-note: #dbeafe;
    --yellow-note: #fedfa9;
    --green-note: #d9f99d;
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--paper);
    color: var(--ink);
}

* {
    box-sizing: border-box;
}

html {
    overflow-x: hidden;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-width: 280px;
    overflow-x: hidden;
    background: var(--paper);
    color: var(--ink);
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    color: inherit;
    font: inherit;
}

.loader {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: flex;
    flex-direction: column;
    pointer-events: none;
}

.loader__panel {
    height: 50%;
    background: var(--dark);
    transition: transform 0.7s cubic-bezier(0.76, 0, 0.24, 1);
}

.loader__content {
    position: fixed;
    top: 50%;
    left: 50%;
    z-index: 101;
    display: grid;
    grid-template-columns: auto 180px 3ch;
    gap: 14px;
    align-items: center;
    color: var(--paper);
    transform: translate(-50%, -50%);
    transition: opacity 0.3s ease;
}

.loader__mark {
    font-size: 2rem;
    font-weight: 300;
    letter-spacing: 0.28em;
}

.loader__bar {
    height: 2px;
    overflow: hidden;
    background: rgba(250, 250, 249, 0.18);
}

.loader__bar span {
    display: block;
    width: 0;
    height: 100%;
    background: var(--paper);
    transition: width 0.12s linear;
}

.loader__percent {
    color: rgba(250, 250, 249, 0.62);
    font-family: "JetBrains Mono", monospace;
    font-size: 0.75rem;
    text-align: right;
}

body.is-loaded .loader__panel--top {
    transform: translateY(-100%);
}

body.is-loaded .loader__panel--bottom {
    transform: translateY(100%);
}

body.is-loaded .loader__content {
    opacity: 0;
}

body.loader-gone .loader {
    display: none;
}

.nav {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 50;
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 28px;
    align-items: center;
    width: 100%;
    min-height: 60px;
    padding: 0 7vw;
    background: rgba(250, 250, 249, 0.84);
    border-bottom: 1px solid rgba(214, 211, 209, 0.72);
    backdrop-filter: blur(18px);
}

.nav__brand {
    font-weight: 800;
    letter-spacing: 0.04em;
}

.nav__links,
.nav__actions,
.hero__tags,
.lang-switch {
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav__links a,
.hero__tags span,
.lang-switch button,
.back-link {
    min-height: 32px;
    padding: 9px 13px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.64);
    font-family: "JetBrains Mono", monospace;
    font-size: 0.72rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.nav__links a {
    border-color: transparent;
    background: transparent;
}

.nav__links a:hover {
    border-color: var(--line-strong);
    background: #fff;
}

.lang-switch {
    gap: 3px;
    padding: 3px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: rgba(245, 245, 244, 0.92);
    box-shadow: inset 0 1px 2px rgba(28, 25, 23, 0.05);
}

.lang-switch button {
    min-height: 28px;
    padding: 6px 10px;
    color: var(--muted);
    border-color: transparent;
    border-radius: 7px;
    background: transparent;
    cursor: pointer;
    transition:
        color 0.2s ease,
        border-color 0.2s ease,
        background-color 0.2s ease,
        box-shadow 0.2s ease;
}

.lang-switch button[aria-pressed="true"] {
    color: #fff;
    border-color: var(--orange);
    background: var(--orange);
    box-shadow: 0 3px 10px rgba(249, 115, 22, 0.28);
}

.lang-switch button:not([aria-pressed="true"]):hover,
.lang-switch button:not([aria-pressed="true"]):focus-visible {
    color: var(--orange);
    border-color: rgba(249, 115, 22, 0.28);
    background: #fff7ed;
}

.hero {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(360px, 0.95fr);
    min-height: 100vh;
    padding: 16vh 7vw 7vh;
    overflow: hidden;
}

.hero__grid {
    position: absolute;
    inset: 60px 0 0;
    overflow: hidden;
    mask-image: linear-gradient(to bottom, #000 82%, transparent);
}

.hero__grid::before {
    position: absolute;
    inset: -56px;
    content: "";
    background-image:
        linear-gradient(var(--line) 1px, transparent 1px),
        linear-gradient(90deg, var(--line) 1px, transparent 1px);
    background-size: 28px 28px;
    will-change: transform;
    animation: grid-drift 5s linear infinite;
}

@keyframes grid-drift {
    from {
        transform: translate3d(0, 0, 0);
    }
    to {
        transform: translate3d(56px, 28px, 0);
    }
}

.hero__copy,
.hero__stage {
    position: relative;
    z-index: 1;
}

.physics-layer {
    position: absolute;
    inset: 0;
    z-index: 30;
    overflow: hidden;
    pointer-events: none;
}

.pixel-layer {
    position: absolute;
    inset: 0;
    z-index: 28;
    overflow: hidden;
    pointer-events: none;
}

.physics-letter,
.physics-note {
    position: absolute;
    left: 0;
    top: 0;
    will-change: transform;
    transform-origin: center;
}

.physics-letter {
    display: inline-block;
    white-space: pre;
}

.physics-note {
    overflow: hidden;
}

.physics-source-hidden {
    opacity: 0 !important;
}

.pixel-source-hidden {
    opacity: 0 !important;
}

.pixel-letter {
    position: absolute;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    overflow: visible;
    font-family: "JetBrains Mono", monospace;
    font-style: normal;
    letter-spacing: 0;
    text-transform: none;
    text-shadow:
        0.045em 0 0 rgba(255, 106, 0, 0.8),
        -0.045em 0 0 rgba(37, 99, 235, 0.72),
        0 0.07em 0 rgba(22, 163, 74, 0.55);
    transform: translate3d(0, 0, 0);
    animation:
        pixel-enter 0.32s steps(4, end) both,
        pixel-jitter 0.72s steps(2, end) infinite;
    animation-delay: var(--pixel-delay, 0s), var(--pixel-delay, 0s);
    image-rendering: pixelated;
}

.pixel-letter::before,
.pixel-letter::after {
    position: absolute;
    inset: 0;
    content: "";
    pointer-events: none;
}

.pixel-letter::before {
    background:
        linear-gradient(90deg, rgba(0, 0, 0, 0.18) 1px, transparent 1px),
        linear-gradient(rgba(0, 0, 0, 0.16) 1px, transparent 1px);
    background-size: 7px 7px;
    mix-blend-mode: multiply;
    opacity: 0.22;
}

.pixel-letter::after {
    left: -0.05em;
    right: -0.05em;
    border-top: 0.08em solid rgba(255, 106, 0, 0.28);
    border-bottom: 0.08em solid rgba(37, 99, 235, 0.24);
    transform: translateY(0.1em);
    opacity: 0.52;
}

.hero h1.is-pixelated {
    filter: contrast(1.25);
}

.falling-css {
    animation: fall-away 1.5s cubic-bezier(0.33, 0.01, 0.67, 1) forwards;
}

.physics-layer--css .physics-letter,
.physics-layer--css .physics-note {
    animation: css-physics-fall 1.75s cubic-bezier(0.32, 0.02, 0.68, 1) forwards;
    animation-delay: var(--fall-delay, 0s);
    transform: translate3d(var(--start-x), var(--start-y), 0) rotate(var(--start-r, 0deg));
}

@keyframes fall-away {
    to {
        opacity: 0;
        transform: translate3d(0, 58vh, 0) rotate(22deg);
    }
}

@keyframes css-physics-fall {
    0% {
        opacity: 1;
        transform: translate3d(var(--start-x), var(--start-y), 0) rotate(var(--start-r, 0deg));
    }
    28% {
        transform: translate3d(
                calc(var(--start-x) + var(--fall-x-step)),
                calc(var(--start-y) - var(--lift-y)),
                0
            )
            rotate(calc(var(--start-r, 0deg) + var(--fall-r-step)));
    }
    100% {
        opacity: 0;
        transform: translate3d(
                calc(var(--start-x) + var(--fall-x)),
                calc(var(--start-y) + var(--fall-y)),
                0
            )
            rotate(calc(var(--start-r, 0deg) + var(--fall-r)));
    }
}

@keyframes pixel-enter {
    0% {
        opacity: 0;
        transform: translate3d(-3px, 2px, 0) scale(0.96);
    }
    100% {
        opacity: 1;
        transform: translate3d(0, 0, 0) scale(1);
    }
}

@keyframes pixel-jitter {
    0%,
    100% {
        clip-path: inset(0 0 0 0);
        transform: translate3d(0, 0, 0);
    }
    25% {
        clip-path: inset(0 0 28% 0);
        transform: translate3d(2px, -1px, 0);
    }
    50% {
        clip-path: inset(24% 0 0 0);
        transform: translate3d(-2px, 1px, 0);
    }
    75% {
        clip-path: inset(12% 0 18% 0);
        transform: translate3d(1px, 0, 0);
    }
}

.status-pill {
    display: inline-flex;
    gap: 8px;
    align-items: center;
    padding: 8px 14px;
    margin: 0 0 34px;
    border: 1px solid rgba(22, 163, 74, 0.34);
    border-radius: 999px;
    background: rgba(220, 252, 231, 0.82);
    color: var(--green-dark);
    font-family: "JetBrains Mono", monospace;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.07em;
    text-transform: uppercase;
}

.status-pill span:first-child {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: var(--green);
    box-shadow: 0 0 0 5px rgba(22, 163, 74, 0.14);
}

.hero h1 {
    margin: 0;
    font-size: clamp(3.4rem, 6.2vw, 7.5rem);
    font-weight: 400;
    line-height: 0.98;
    letter-spacing: 0;
}

.hero h1 em {
    color: rgba(28, 25, 23, 0.43);
    font-style: italic;
    font-weight: 300;
}

.hero__lead {
    max-width: 650px;
    margin: 38px 0;
    color: var(--muted);
    font-size: clamp(1.05rem, 1.35vw, 1.35rem);
    line-height: 1.6;
}

.hero__lead a {
    color: var(--orange);
    font-weight: 700;
    text-decoration: none;
}

.hero__lead a:hover,
.hero__lead a:focus-visible {
    text-decoration: underline;
    text-decoration-thickness: 2px;
    text-underline-offset: 3px;
}

.hero__tags {
    flex-wrap: wrap;
    align-items: flex-start;
}

.hero__stage {
    min-height: 560px;
}

.postit {
    position: absolute;
    z-index: 4;
    display: block;
    width: 245px;
    min-height: 165px;
    padding: 22px;
    color: var(--ink);
    border: 0;
    box-shadow: 0 18px 34px rgba(28, 25, 23, 0.16);
    font-family: Caveat, cursive;
    font-size: 1.45rem;
    line-height: 1.08;
    text-align: left;
    cursor: grab;
    user-select: none;
    touch-action: none;
    transform-origin: center;
}

.postit:active {
    cursor: grabbing;
}

.postit.is-dragging {
    z-index: 10;
    box-shadow: 0 24px 46px rgba(28, 25, 23, 0.22);
}

.postit::after {
    position: absolute;
    inset: 0;
    content: "";
    background:
        radial-gradient(circle at 20% 10%, rgba(255, 255, 255, 0.42), transparent 24%),
        repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.12) 1px, transparent 1px, transparent 8px);
    mix-blend-mode: soft-light;
    pointer-events: none;
}

.postit--blue {
    top: 20px;
    right: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 210px;
    min-height: 136px;
    background: var(--blue-note);
    text-align: center;
    transform: rotate(-3deg);
}

.postit--blue .note-heading {
    display: block;
    color: #1d4ed8;
    font-family: Inter, sans-serif;
    font-size: 0.78rem;
    line-height: 1.35;
}

.postit--blue .note-line {
    display: block;
    font-size: 1.25rem;
    line-height: 1.35;
}

.postit--yellow {
    top: 332px;
    bottom: auto;
    left: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 265px;
    min-height: 168px;
    background: var(--yellow-note);
    text-align: center;
    transform: rotate(2.5deg);
}

.postit--cat {
    top: 168px;
    left: 0;
    width: 305px;
    min-height: 130px;
    background: #dcfce7;
    transform: rotate(-1.5deg);
}

.postit--computer {
    top: 330px;
    right: 0;
    bottom: auto;
    width: 235px;
    min-height: 230px;
    background: #fbcfe8;
    transform: rotate(1.8deg);
}

.ascii-label {
    display: block;
    margin-bottom: 12px;
    color: #57534e;
    font-family: "JetBrains Mono", monospace;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.ascii-art {
    margin: 0;
    overflow: visible;
    font-family: "JetBrains Mono", Consolas, monospace;
    font-size: 0.38rem;
    line-height: 1.16;
    white-space: pre;
}

.postit .note-body {
    display: block;
    margin-top: 18px;
    white-space: pre-line;
}

.postit:not(.is-revealed) .note-line,
.postit:not(.is-revealed) .note-body {
    display: none;
}

.postit--yellow .note-body {
    font-size: 1.28rem;
}

.postit--yellow.is-revealed {
    display: block;
    min-height: 230px;
    text-align: left;
}

.postit--yellow.is-revealed .note-body {
    margin-top: 10px;
    padding-bottom: 26px;
    font-family: "JetBrains Mono", monospace;
    font-size: 0.76rem;
    line-height: 1.55;
}

.postit--blue.is-revealed .note-line {
    margin-top: 14px;
    color: #1e3a8a;
    font-weight: 600;
}

.postit--blue.is-revealed {
    display: block;
    text-align: left;
}

.postit strong {
    display: block;
    font-family: Inter, sans-serif;
    font-size: 1rem;
}

.postit small {
    display: block;
    margin-bottom: 14px;
    color: var(--muted);
    font-family: Inter, sans-serif;
    font-size: 0.72rem;
}

.read-more {
    position: absolute;
    right: 18px;
    bottom: 15px;
    font-family: "JetBrains Mono", monospace;
    font-size: 0.7rem;
}

.system-board {
    position: absolute;
    top: 7vh;
    right: 0;
    z-index: 2;
    width: min(42vw, 560px);
    height: 420px;
}

.board-lines {
    position: absolute;
    inset: 0;
    z-index: 1;
    width: 100%;
    height: 100%;
    overflow: visible;
}

.board-line {
    fill: none;
    stroke: rgba(28, 25, 23, 0.42);
    stroke-dasharray: 9 10;
    stroke-width: 2;
    animation: path-flow 4s linear infinite;
}

@keyframes path-flow {
    to {
        stroke-dashoffset: -76;
    }
}

.board-card {
    position: absolute;
    z-index: 5;
    display: grid;
    gap: 8px;
    width: 170px;
    min-height: 108px;
    padding: 18px;
    border: 1px solid rgba(214, 211, 209, 0.9);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.78);
    box-shadow: 0 18px 46px rgba(28, 25, 23, 0.1);
    backdrop-filter: blur(12px);
}

.board-card span {
    color: var(--orange);
    font-family: "JetBrains Mono", monospace;
    font-size: 0.72rem;
}

.board-card strong {
    font-size: 1.3rem;
}

.board-card--one {
    top: 64px;
    left: 22px;
}

.board-card--two {
    top: 166px;
    left: 220px;
}

.board-card--three {
    top: 274px;
    right: 0;
    background: var(--green-note);
}

.intro,
.track,
.projects,
.beliefs,
.publications {
    padding: 96px 7vw;
}

.intro {
    display: grid;
    grid-template-columns: minmax(280px, 0.8fr) minmax(320px, 1fr);
    gap: 8vw;
    background: var(--dark);
    color: var(--paper);
}

.intro__body,
.beliefs p {
    color: rgba(250, 250, 249, 0.68);
    font-size: 1.05rem;
    line-height: 1.75;
}

.intro__details {
    display: grid;
    gap: 44px;
    align-content: start;
    min-width: 0;
}

.intro__body {
    margin: 0;
}

.language-profile {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    border: 1px solid rgba(250, 250, 249, 0.58);
}

.language-profile > div {
    display: grid;
    gap: 12px;
    min-width: 0;
    padding: 20px 18px;
    text-align: center;
}

.language-profile > div + div {
    border-left: 1px solid rgba(250, 250, 249, 0.38);
}

.language-profile strong {
    overflow-wrap: anywhere;
    font-size: 1rem;
    line-height: 1.3;
}

.language-profile span {
    color: var(--orange);
    font-family: "JetBrains Mono", monospace;
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    line-height: 1.4;
    text-transform: uppercase;
}

.eyebrow {
    margin: 0 0 18px;
    color: var(--orange);
    font-family: "JetBrains Mono", monospace;
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.intro h2,
.section-heading h2,
.case-hero h1 {
    max-width: 940px;
    margin: 0;
    font-size: clamp(2rem, 4vw, 4.8rem);
    font-weight: 400;
    line-height: 1.05;
}

.track,
.publications {
    background: #fff;
    border-top: 1px solid var(--line);
}

.projects {
    background:
        linear-gradient(rgba(250, 250, 249, 0.96), rgba(250, 250, 249, 0.96)),
        linear-gradient(var(--line) 1px, transparent 1px),
        linear-gradient(90deg, var(--line) 1px, transparent 1px);
    background-size: auto, 28px 28px, 28px 28px;
}

.section-heading {
    margin-bottom: 56px;
}

.split-track {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 42px;
    align-items: start;
}

.split-track h3 {
    margin: 0 0 22px;
    font-size: 1.1rem;
}

.track__table {
    display: grid;
    grid-auto-rows: minmax(156px, auto);
    border-top: 1px solid var(--line-strong);
}

.track__row,
.publication-row {
    position: relative;
    display: grid;
    grid-template-columns: 130px minmax(170px, 0.7fr) minmax(240px, 1fr) 34px;
    gap: 24px;
    align-items: start;
    padding: 28px 0;
    border-bottom: 1px solid var(--line);
}

.track__row span,
.project-card span,
.publication-row span,
.award-card > span {
    color: var(--muted);
    font-family: "JetBrains Mono", monospace;
    font-size: 0.76rem;
    letter-spacing: 0.09em;
    text-transform: uppercase;
}

.track__row h4,
.project-card h3,
.award-card h3 {
    margin: 0;
    font-size: 1.18rem;
}

.track__row p,
.project-card p,
.publication-row p {
    margin: 0;
    color: #57534e;
    font-size: 1rem;
    line-height: 1.65;
}

.link-card {
    isolation: isolate;
}

.link-card i,
.link-card svg {
    display: inline-grid;
    place-items: center;
    width: 18px;
    height: 18px;
    color: var(--orange);
    font-style: normal;
    transition: transform 0.25s ease;
}

.link-card i::before {
    content: "->";
    font-family: "JetBrains Mono", monospace;
    font-size: 0.8rem;
    font-weight: 700;
}

.link-card::before {
    position: absolute;
    inset: 0;
    z-index: -1;
    content: "";
    border: 1px solid transparent;
    border-radius: 8px;
    opacity: 0;
    transform: scale(1);
    transition:
        opacity 0.25s ease,
        border-color 0.25s ease,
        background 0.25s ease;
}

.link-card:hover::before,
.link-card:focus-visible::before {
    opacity: 1;
    border-color: rgba(249, 115, 22, 0.34);
    background: rgba(255, 247, 237, 0.72);
}

.link-card:hover svg,
.link-card:focus-visible svg,
.link-card:hover i,
.link-card:focus-visible i {
    transform: translate(4px, -4px) rotate(6deg);
}

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

.split-track .track__row {
    grid-template-columns: 96px minmax(0, 1fr) 28px;
    min-height: 156px;
}

.split-track .track__row--static {
    grid-template-columns: 96px minmax(0, 1fr);
}

.split-track .track__row p {
    grid-column: 2;
}

.split-track .track__row svg,
.split-track .track__row i {
    grid-column: 3;
    grid-row: 1;
}

.project-card {
    position: relative;
    display: grid;
    min-height: 280px;
    padding: 28px;
    border: 1px solid var(--line-strong);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.82);
    box-shadow: 0 18px 42px rgba(28, 25, 23, 0.06);
}

.project-card.link-card::before {
    display: none;
}

.project-card:hover,
.project-card:focus-visible {
    border-color: rgba(249, 115, 22, 0.5);
    background: rgba(255, 247, 237, 0.82);
}

.project-card svg {
    align-self: end;
}

.beliefs {
    background: var(--dark);
    color: var(--paper);
}

.beliefs__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1px;
    background: rgba(250, 250, 249, 0.14);
    border: 1px solid rgba(250, 250, 249, 0.14);
}

.award-card {
    --award-color: #78716c;
    position: relative;
    display: grid;
    grid-template-rows: auto auto 1fr;
    gap: 0;
    min-height: 270px;
    padding: 34px;
    background: var(--dark);
    box-shadow: inset 0 3px 0 transparent;
    transition:
        background-color 0.25s ease,
        box-shadow 0.25s ease;
}

.award-card--gold {
    --award-color: #facc15;
}

.award-card--silver {
    --award-color: #d6d3d1;
}

.award-card--bronze {
    --award-color: #d97706;
}

.award-card--finalist {
    --award-color: #a8a29e;
}

.award-card:hover,
.award-card:focus-visible {
    background: var(--dark-soft);
    box-shadow: inset 0 3px 0 var(--award-color);
    outline: none;
}

.award-card h3 {
    margin-top: 36px;
}

.award-card p {
    margin: 18px 0 0;
}

.award-card svg,
.award-card i {
    position: absolute;
    top: 30px;
    right: 30px;
    width: 18px;
    height: 18px;
    color: var(--award-color);
    transition: transform 0.25s ease;
}

.award-card:hover svg,
.award-card:focus-visible svg,
.award-card:hover i,
.award-card:focus-visible i {
    transform: translate(3px, -3px);
}

.publication-list {
    border-top: 1px solid var(--line-strong);
}

.publication-row strong {
    font-size: 1.1rem;
}

.footer {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    align-items: center;
    justify-content: space-between;
    padding: 28px 7vw;
    color: var(--muted);
    border-top: 1px solid var(--line);
    font-family: "JetBrains Mono", monospace;
    font-size: 0.72rem;
    text-transform: uppercase;
}

.footer__signature {
    display: inline-flex;
    gap: 8px;
    align-items: center;
}

.footer__signature svg,
.footer__signature i {
    width: 16px;
    height: 16px;
    color: var(--orange);
}

.case-body {
    background:
        linear-gradient(rgba(250, 250, 249, 0.96), rgba(250, 250, 249, 0.96)),
        linear-gradient(var(--line) 1px, transparent 1px),
        linear-gradient(90deg, var(--line) 1px, transparent 1px);
    background-size: auto, 28px 28px, 28px 28px;
}

.case-page {
    padding: 118px 7vw 80px;
}

.back-link {
    display: inline-flex;
    gap: 8px;
    align-items: center;
    margin-bottom: 54px;
}

.back-link svg {
    width: 16px;
    height: 16px;
}

.case-hero {
    max-width: 1000px;
    margin-bottom: 54px;
}

.case-hero > p[data-case="summary"] {
    max-width: 740px;
    color: var(--muted);
    font-size: 1.2rem;
    line-height: 1.65;
}

.award-celebration[hidden] {
    display: none;
}

.award-celebration {
    --medal-color: #78716c;
    --medal-shine: #d6d3d1;
    display: inline-flex;
    gap: 20px;
    align-items: center;
    min-width: min(100%, 440px);
    margin-top: 24px;
    padding: 18px 22px;
    border: 1px solid color-mix(in srgb, var(--medal-color) 55%, var(--line));
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.88);
    box-shadow: 0 18px 44px color-mix(in srgb, var(--medal-color) 14%, transparent);
}

.award-celebration--gold {
    --medal-color: #d99a00;
    --medal-shine: #facc15;
}

.award-celebration--silver {
    --medal-color: #78716c;
    --medal-shine: #d6d3d1;
}

.award-celebration--bronze {
    --medal-color: #9a4f13;
    --medal-shine: #d97706;
}

.award-celebration--finalist {
    --medal-color: #57534e;
    --medal-shine: #a8a29e;
}

.award-medal {
    position: relative;
    display: grid;
    flex: 0 0 78px;
    width: 78px;
    height: 78px;
    place-items: center;
    color: var(--medal-color);
    border: 8px solid var(--medal-shine);
    border-radius: 50%;
    background: color-mix(in srgb, var(--medal-shine) 24%, #fff);
    box-shadow:
        inset 0 0 0 2px rgba(255, 255, 255, 0.86),
        0 8px 18px color-mix(in srgb, var(--medal-color) 20%, transparent);
}

.award-medal svg {
    width: 34px;
    height: 34px;
}

.award-medal strong {
    position: absolute;
    right: -7px;
    bottom: -7px;
    display: grid;
    min-width: 32px;
    height: 32px;
    padding: 0 5px;
    place-items: center;
    color: #fff;
    border-radius: 50%;
    background: var(--medal-color);
    font-family: "JetBrains Mono", monospace;
    font-size: 0.68rem;
}

.award-celebration > span:last-child {
    display: grid;
    gap: 5px;
}

.award-celebration small {
    color: var(--medal-color);
    font-family: "JetBrains Mono", monospace;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.award-celebration > span:last-child > strong {
    font-size: 1.05rem;
    line-height: 1.35;
}

.confetti-layer {
    position: fixed;
    inset: 0;
    z-index: 90;
    overflow: hidden;
    pointer-events: none;
}

.confetti-piece {
    position: absolute;
    top: 29vh;
    left: 50%;
    width: 8px;
    height: 13px;
    background: var(--confetti-color);
    opacity: 0;
    animation: confetti-burst var(--confetti-duration) var(--confetti-delay) cubic-bezier(0.18, 0.7, 0.24, 1) forwards;
}

.confetti-piece:nth-child(3n) {
    width: 11px;
    height: 7px;
    border-radius: 50%;
}

.confetti-piece:nth-child(4n) {
    width: 6px;
    height: 16px;
}

@keyframes confetti-burst {
    0% {
        opacity: 1;
        transform: translate3d(0, 0, 0) rotate(0) scale(0.4);
    }
    24% {
        opacity: 1;
        transform: translate3d(var(--confetti-mid-x), var(--confetti-rise), 0) rotate(calc(var(--confetti-turn) * 0.35)) scale(1);
    }
    100% {
        opacity: 0;
        transform: translate3d(var(--confetti-end-x), var(--confetti-fall), 0) rotate(var(--confetti-turn)) scale(0.82);
    }
}

.case-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 34px;
    align-items: start;
}

.case-gallery {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.photo-slot {
    display: grid;
    min-height: 240px;
    overflow: hidden;
    place-items: center;
    border: 1px dashed rgba(120, 113, 108, 0.5);
    border-radius: 8px;
    background:
        linear-gradient(135deg, rgba(219, 234, 254, 0.8), rgba(254, 223, 169, 0.72)),
        linear-gradient(var(--line) 1px, transparent 1px),
        linear-gradient(90deg, var(--line) 1px, transparent 1px);
    background-size: auto, 24px 24px, 24px 24px;
    color: #57534e;
    font-family: "JetBrains Mono", monospace;
    font-size: 0.74rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.photo-slot.has-image {
    min-height: 0;
    aspect-ratio: 4 / 3;
    border-style: solid;
    background: var(--dark);
}

.photo-slot--large.has-image {
    aspect-ratio: 3 / 2;
}

.photo-slot img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    cursor: zoom-in;
    animation: case-image-in 0.65s ease both;
}

.photo-slot img:focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: -4px;
}

.photo-slot--contain img {
    object-fit: contain;
}

@keyframes case-image-in {
    from {
        opacity: 0;
        transform: scale(1.015);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.photo-slot--large {
    grid-column: 1 / -1;
    min-height: 420px;
}

body.is-image-viewer-open {
    overflow: hidden;
}

.image-viewer {
    position: fixed;
    inset: 0;
    width: 100vw;
    max-width: none;
    height: 100dvh;
    max-height: none;
    margin: 0;
    padding: 0;
    overflow: hidden;
    border: 0;
    background: rgba(18, 18, 18, 0.96);
    color: #fff;
}

.image-viewer[open] {
    display: grid;
    place-items: center;
}

.image-viewer::backdrop {
    background: rgba(18, 18, 18, 0.96);
}

.image-viewer figure {
    display: grid;
    width: min(88vw, 1500px);
    height: calc(100dvh - 80px);
    margin: 0;
    padding: 24px 64px 16px;
    place-items: center;
}

.image-viewer figure img {
    display: block;
    width: auto;
    max-width: 100%;
    height: auto;
    max-height: calc(100dvh - 150px);
    object-fit: contain;
}

.image-viewer figcaption {
    max-width: 920px;
    margin-top: 10px;
    color: #d6d3d1;
    font-size: 0.82rem;
    line-height: 1.45;
    text-align: center;
}

.image-viewer button {
    position: fixed;
    z-index: 2;
    display: grid;
    width: 44px;
    height: 44px;
    padding: 0;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, 0.36);
    border-radius: 4px;
    background: rgba(18, 18, 18, 0.78);
    color: #fff;
    cursor: pointer;
}

.image-viewer button:hover,
.image-viewer button:focus-visible {
    border-color: var(--accent);
    color: var(--accent);
}

.image-viewer button svg {
    width: 22px;
    height: 22px;
}

.image-viewer__close {
    top: 18px;
    right: 18px;
}

.image-viewer__nav {
    top: 50%;
    transform: translateY(-50%);
}

.image-viewer__nav--previous {
    left: 18px;
}

.image-viewer__nav--next {
    right: 18px;
}

.case-meta {
    border: 1px solid var(--line-strong);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.86);
}

.case-meta dl {
    margin: 0;
}

.case-meta div {
    padding: 22px;
    border-bottom: 1px solid var(--line);
}

.case-meta div:last-child {
    border-bottom: 0;
}

.case-meta dt {
    margin-bottom: 8px;
    color: var(--muted);
    font-family: "JetBrains Mono", monospace;
    font-size: 0.72rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.case-meta dd {
    margin: 0;
}

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

.collaborator-link {
    display: inline-flex;
    align-items: center;
    min-height: 36px;
    padding: 7px 10px;
    color: var(--orange);
    border: 1px solid color-mix(in srgb, var(--orange) 38%, transparent);
    border-radius: 8px;
    background: color-mix(in srgb, var(--orange) 7%, #fff);
    font-family: "JetBrains Mono", monospace;
    font-size: 0.82rem;
    font-weight: 700;
}

.collaborator-link:hover,
.collaborator-link:focus-visible {
    color: #fff;
    background: var(--orange);
}

.tool-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tool-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 36px;
    padding: 6px 10px 6px 7px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(250, 250, 249, 0.82);
}

.tool-icon {
    position: relative;
    display: inline-grid;
    width: 24px;
    height: 24px;
    place-items: center;
    color: var(--tool-color);
    border: 1px solid color-mix(in srgb, var(--tool-color) 35%, transparent);
    border-radius: 6px;
    background: #fff;
    font-family: "JetBrains Mono", monospace;
    font-size: 0.58rem;
    font-weight: 700;
}

.tool-icon img {
    position: absolute;
    width: 15px;
    height: 15px;
    object-fit: contain;
    background: #fff;
}

.tool-icon span {
    line-height: 1;
}

.tool-label {
    font-size: 0.92rem;
}

.case-text {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1px;
    margin-top: 44px;
    background: var(--line-strong);
    border: 1px solid var(--line-strong);
}

.case-text article {
    min-height: 250px;
    padding: 30px;
    background: #fff;
}

.case-text h2 {
    margin: 0 0 18px;
    font-size: 1.15rem;
}

.case-text p {
    margin: 0;
    color: #57534e;
    line-height: 1.7;
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

@media (max-width: 1100px) {
    .nav {
        grid-template-columns: auto 1fr;
        padding: 0 22px;
    }

    .nav__links {
        display: none;
    }

    .nav__actions {
        justify-content: end;
    }

    .hero {
        grid-template-columns: 1fr;
        min-height: auto;
        padding: 128px 22px 72px;
    }

    .hero h1 {
        font-size: clamp(3.2rem, 12vw, 5.8rem);
    }

    .hero__stage {
        min-height: 620px;
        margin-top: 42px;
    }

    .system-board {
        position: relative;
        top: auto;
        right: auto;
        width: min(92vw, 560px);
        height: 420px;
        margin: 0 auto;
    }

    .postit--blue {
        top: 4vh;
        right: 5vw;
    }

    .postit--yellow {
        left: 0;
        bottom: 8vh;
    }

    .postit--cat {
        top: 170px;
        left: 0;
        width: min(86vw, 330px);
    }

    .postit--computer {
        right: 0;
        bottom: 0;
        width: min(82vw, 285px);
    }

    .intro,
    .split-track,
    .case-layout,
    .case-text {
        grid-template-columns: 1fr;
    }

    .project-grid,
    .beliefs__grid {
        grid-template-columns: 1fr;
    }

    .track__row,
    .publication-row {
        grid-template-columns: 1fr 28px;
    }

    .track__row span,
    .publication-row span,
    .track__row h4,
    .publication-row strong,
    .track__row p,
    .publication-row p {
        grid-column: 1;
    }

    .track__row svg,
    .publication-row svg {
        grid-column: 2;
        grid-row: 1;
    }
}

@media (max-width: 640px) {
    .lang-switch {
        gap: 4px;
    }

    .hero {
        padding: 104px 22px 58px;
    }

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

    .hero__stage {
        display: none;
    }

    .hero__lead {
        margin: 24px 0;
        font-size: 1rem;
        line-height: 1.65;
    }

    .hero__tags {
        flex-wrap: wrap;
    }

    .status-pill {
        max-width: 100%;
        font-size: 0.64rem;
        line-height: 1.4;
    }

    .section-heading {
        margin-bottom: 36px;
    }

    .section-heading h2,
    .intro h2,
    .case-hero h1 {
        font-size: 2rem;
        line-height: 1.08;
        overflow-wrap: anywhere;
    }

    .board-card {
        width: 145px;
        min-height: 94px;
        padding: 14px;
    }

    .board-card--two {
        top: 164px;
        right: auto;
        left: 132px;
    }

    .board-card--three {
        top: 294px;
        right: 4vw;
        bottom: auto;
    }

    .intro,
    .track,
    .projects,
    .beliefs,
    .publications {
        padding: 72px 22px;
    }

    .split-track {
        gap: 48px;
    }

    .intro__details {
        gap: 32px;
    }

    .language-profile > div {
        gap: 9px;
        padding: 16px 7px;
    }

    .language-profile strong {
        font-size: 0.78rem;
    }

    .language-profile span {
        font-size: 0.68rem;
        letter-spacing: 0.03em;
    }

    .track__table {
        grid-auto-rows: auto;
    }

    .split-track .track__row {
        grid-template-columns: minmax(0, 1fr) 28px;
        gap: 10px 14px;
        min-height: 0;
        padding: 24px 0;
    }

    .split-track .track__row--static {
        grid-template-columns: minmax(0, 1fr);
    }

    .split-track .track__row span,
    .split-track .track__row h4,
    .split-track .track__row p {
        grid-column: 1;
        min-width: 0;
    }

    .split-track .track__row span {
        grid-row: 1;
    }

    .split-track .track__row h4 {
        grid-row: 2;
        padding-right: 6px;
        font-size: 1.06rem;
        line-height: 1.35;
        overflow-wrap: anywhere;
    }

    .split-track .track__row p {
        grid-row: 3;
        font-size: 0.94rem;
        line-height: 1.6;
        overflow-wrap: anywhere;
    }

    .split-track .track__row svg,
    .split-track .track__row i {
        grid-column: 2;
        grid-row: 1 / span 2;
        justify-self: end;
    }

    .publication-row {
        gap: 10px 14px;
        padding: 24px 0;
    }

    .publication-row strong,
    .publication-row p {
        min-width: 0;
        overflow-wrap: anywhere;
    }

    .publication-row strong {
        font-size: 1rem;
        line-height: 1.4;
    }

    .project-card,
    .award-card {
        min-height: 0;
        padding: 26px;
    }

    .project-card {
        gap: 20px;
    }

    .award-card h3 {
        margin-top: 28px;
        padding-right: 26px;
        line-height: 1.4;
        overflow-wrap: anywhere;
    }

    .award-card svg,
    .award-card i {
        top: 25px;
        right: 25px;
    }

    .case-page {
        padding: 104px 22px 64px;
    }

    .case-hero {
        margin-bottom: 36px;
    }

    .case-hero p:last-of-type,
    .case-text p,
    .case-meta dd {
        overflow-wrap: anywhere;
    }

    .case-layout {
        gap: 24px;
    }

    .photo-slot--large {
        min-height: 300px;
    }

    .case-gallery {
        grid-template-columns: 1fr;
    }

    .photo-slot--contain.has-image {
        aspect-ratio: 3 / 4;
    }

    .image-viewer figure {
        width: 100vw;
        height: 100dvh;
        padding: 64px 14px 78px;
    }

    .image-viewer figure img {
        max-height: calc(100dvh - 170px);
    }

    .image-viewer__nav {
        top: auto;
        bottom: 18px;
        transform: none;
    }

    .image-viewer__nav--previous {
        left: calc(50% - 52px);
    }

    .image-viewer__nav--next {
        right: calc(50% - 52px);
    }

    .case-text {
        gap: 16px;
        margin-top: 28px;
        border: 0;
        background: transparent;
    }

    .case-text article {
        min-height: 0;
        padding: 24px;
        border: 1px solid var(--line-strong);
        border-radius: 8px;
        background: rgba(255, 255, 255, 0.94);
        box-shadow: 0 12px 30px rgba(28, 25, 23, 0.05);
    }

    .award-celebration {
        gap: 16px;
        width: 100%;
        min-width: 0;
        padding: 16px;
    }

    .award-medal {
        flex-basis: 66px;
        width: 66px;
        height: 66px;
        border-width: 7px;
    }

    .award-medal svg {
        width: 28px;
        height: 28px;
    }

    .award-celebration > span:last-child {
        min-width: 0;
    }

    .award-celebration > span:last-child > strong {
        overflow-wrap: anywhere;
        font-size: 0.96rem;
    }

    .footer {
        align-items: flex-start;
        justify-content: flex-start;
    }

    .footer__signature {
        width: 100%;
    }

    .loader__content {
        grid-template-columns: 1fr;
        justify-items: center;
    }

    .loader__bar {
        width: 180px;
    }
}
