:root {
  --paper: #e1e2e6;
  --ink: #070303;
  --yellow: #ebcc41;
  --accent: color-mix(in srgb, var(--yellow) 80%, var(--paper));
  --quiet: hsl(from var(--paper) h 0% calc(l - 9.2));
  --unit: min(.0694444444vw, 1.4px);
  --gap: calc(30 * var(--unit));
  --mast-top: calc(58.72 * var(--unit));
  --head-height: calc(95.28 * var(--unit));
  --mascot-width: min(calc(140 * var(--unit)), 19svh);
  --mascot-gap: calc(24 * var(--unit));
  --foot: max(12px, 6.6667svh, env(safe-area-inset-bottom));
  --panel-height: max(0px, calc(100svh - var(--mast-top) - var(--head-height) - var(--mascot-gap) - var(--mascot-width) * 122 / 140 - var(--foot)));
  --ease: cubic-bezier(.22,.8,.18,1);
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 1rem/1.375 "Times New Roman", Times, serif; }
button, a { color: inherit; -webkit-tap-highlight-color: transparent; }
a { text-underline-offset: .11em; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
h1,h2,p { margin: 0; }
.sr { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip-path:inset(50%); white-space:nowrap; }
main { min-height: 100vh; min-height: 100svh; display: flex; flex-direction: column; }
.masthead { padding: var(--mast-top) var(--gap) 0; display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:var(--gap); align-items:start; }
.column { min-width:0; }
h2 { font-family: Oswald, sans-serif; height:var(--head-height); position:relative; z-index:1; }
.trigger { display:block; width:100%; height:100%; padding:0; cursor:pointer; border:0; background:none; text-align:left; font:inherit; }
.wordmark { display:block; position:absolute; left:0; top:var(--top); width:var(--width); aspect-ratio:var(--shape); background-color:var(--quiet); mask:var(--art) left center / contain no-repeat; transition:background-color .22s; pointer-events:none;
  animation:title-in .72s var(--ease) var(--intro-delay,0s) both; }
.phenomen { --art:url("phenomen.svg"); --width:100%; --shape:440/97; --top:calc(.28 * var(--unit)); }
.stefan { --intro-delay:.10s; --art:url("stefan.svg"); --width:53.409%; --shape:235/30; --top:calc(68.72 * var(--unit)); }
.contact { --intro-delay:.20s; --art:url("contact.svg"); --width:86.136%; --shape:379/100; --top:0; }
@keyframes title-in {
  from { clip-path:inset(100% 0 0); opacity:0; }
  to { clip-path:inset(0); opacity:1; }
}
@media (min-width:761px) {
  .stefan h2,.contact h2 { height:auto; }
  .stefan .trigger,.contact .trigger { height:auto; padding-top:var(--top); }
  .stefan .wordmark,.contact .wordmark { position:relative; top:auto; }
}
.column.open .wordmark { background-color:var(--accent); }
.drawer { display:grid; grid-template-rows:0fr; visibility:hidden; transition:grid-template-rows .55s var(--ease),visibility 0s .55s; }
.open .drawer { grid-template-rows:1fr; visibility:visible; transition-delay:0s; }
.drawer[inert] .sheet > * { visibility:hidden; }
.clip { min-height:0; overflow:hidden; }
.sheet { background:var(--accent); padding:var(--sheet-pad); display:flex; align-items:center; font-size:clamp(.85rem,calc(16 * var(--unit)),1.25rem); line-height:1.375; letter-spacing:-.01em; }
.masthead { --sheet-pad:calc(10 * var(--unit)); }
/* Reveal a sheet of constant size. Only the outer window changes height. */
.phenomen .drawer { display:block; height:0; overflow:clip; transition:height .55s var(--ease),visibility 0s .55s; }
.phenomen.open .drawer { height:var(--panel-height); transition-delay:0s; }
.phenomen .sheet {
  height:var(--panel-height); overflow-y:auto; overscroll-behavior:contain;
  flex-direction:column; align-items:stretch;
}
.phenomen .history { margin-block:auto; flex:none; }
.stefan .sheet { min-height:calc(212 * var(--unit)); }
.contact .sheet { min-height:calc(143 * var(--unit)); }
.stefan .sheet,.contact .sheet { align-items:flex-start; }
.history,.group,.links { display:grid; width:100%; }
.history { gap:calc(30 * var(--unit)); }
.group { gap:calc(5 * var(--unit)); }
.row { display:flex; justify-content:space-between; gap:.4em; align-items:baseline; }
.row > span:last-child { flex-shrink:0; }
.education { padding:var(--sheet-pad); background:var(--paper); }
.bio p + p { margin-top:1.375em; }
.links { gap:10px; }
.links a { width:fit-content; }
.fragment { opacity:0; }
.open .fragment { animation:appear .45s both; animation-delay:var(--delay); }
@keyframes appear { from {opacity:0} to {opacity:1} }
.home-slot { padding-top:var(--mascot-gap); width:fit-content; }
.home { display:block; width:var(--mascot-width); }
.creature { display:block; width:100%; height:auto; overflow:visible; transform-origin:43% 84%; animation:breathe 3.1s ease-in-out infinite; }
.creature > .body { transform-box:fill-box; transform-origin:center; }
@keyframes breathe { 0%,100% {transform:translateY(0) scale(1,1)} 50% {transform:translateY(-4px) scale(.985,1.026)} }
.works { position:absolute; left:50%; transform:translateX(-50%); bottom:var(--foot); white-space:nowrap; text-decoration:none; visibility:hidden; opacity:0; animation:work-link .85s ease 5s forwards; }
.works:hover,.works:focus-visible { text-decoration:underline; }
@keyframes work-link { from {visibility:visible;opacity:0} to {visibility:visible;opacity:1} }
@media (max-width:760px) {
  :root {
    --gap:clamp(12px, calc(25vw - 67.5px), 30px); --mast-top:min(45px,11.54vw,6svh);
    --head-height:max(44px,calc(100 * var(--unit)));
    --mascot-width:clamp(56px,15.5vw,76px); --mascot-gap:24px;
  }
  .masthead { grid-template-columns:minmax(0,111fr) minmax(0,103fr) minmax(0,96fr); gap:0 clamp(6px,2.55vw,14px); --sheet-pad:10px; }
  .column { display:contents; }
  h2,.contact h2 { grid-row:1; height:var(--head-height); }
  .phenomen h2 { grid-column:1; }
  .stefan h2 { grid-column:2; }
  .contact h2 { grid-column:3; }
  .wordmark { top:auto; bottom:0; }
  .phenomen,.stefan,.contact { --width:100%; }
  .contact .wordmark { left:auto; right:0; }
  .drawer { grid-column:1/-1; grid-row:2; align-self:start; }
  .drawer:not(.open .drawer) { pointer-events:none; }
  .open .drawer { z-index:2; }
  .sheet { padding:14px 10px; font-size:1rem; line-height:1.35; }
  .history { gap:14px; }
  .group { gap:5px; }
  .bio br { display:none; }
  .stefan .sheet,.contact .sheet { max-height:var(--panel-height); overflow:auto; display:block; }
  .phenomen .drawer,.phenomen.open .drawer {
    display:grid; height:auto; transition:grid-template-rows .55s var(--ease),visibility 0s .55s;
  }
  .phenomen.open .drawer { transition-delay:0s; }
  .phenomen .sheet { height:auto; min-height:0; max-height:none; overflow:visible; }
  .stefan .sheet { display:flex; min-height:min(212px, var(--panel-height)); }
  .contact .sheet { min-height:0; }
  .bio p + p { margin-top:1em; }
  .row { gap:.3em; }
  .hero:has(.masthead) { min-height:100dvh; display:flex; flex-direction:column; }
  .hero .works { position:static; align-self:stretch; text-align:center; transform:none; margin-top:auto; padding-top:12px; margin-bottom:var(--foot); }
  .education { padding:8px; }
  .home-slot { grid-column:1; grid-row:3; }

}
@media (min-width:761px) and (max-width:1199px),
       (min-width:1200px) and (max-width:1366px) and (pointer:coarse) {
  :root {
    --gap:clamp(20px, 2.93vw, 40px);
    --mast-top:clamp(32px, 5.76vw, 79px);
    --head-height:6.6vw;
    --mascot-width:9vw;
    --mascot-gap:1vw;
  }
  .masthead { column-gap:2.05vw; padding-right:2.73vw; --sheet-pad:max(7px,.68vw); }
  .masthead .column h2 { height:var(--head-height); aspect-ratio:auto; }
  .masthead .trigger { height:100%; padding:0; }
  .masthead .wordmark { position:absolute; top:auto; bottom:0; }
  .sheet { font-size:clamp(.75rem,1.2vw,1rem); line-height:1.375; max-height:var(--panel-height); overflow-y:auto; }
  .phenomen .drawer,.phenomen.open .drawer {
    display:grid; height:auto; transition:grid-template-rows .55s var(--ease),visibility 0s .55s;
  }
  .phenomen.open .drawer { transition-delay:0s; }
  .phenomen .sheet { height:auto; min-height:min(36.85vw,var(--panel-height)); }
  .history { gap:2.05vw; }
  .group { gap:.34vw; }
  .bio br { display:none; }
  .stefan .sheet { min-height:min(14.5vw,var(--panel-height)); }
  .contact .sheet { min-height:min(9.8vw,var(--panel-height)); }

}
@media (prefers-reduced-motion:reduce) {
  .creature,.creature > .body,.wordmark { animation:none; }
  .drawer,.phenomen .drawer,.wordmark { transition:none; }
  .open .fragment { opacity:1; animation:none; }
  .works { animation-duration:.001s; }
}

.hero { position:relative; min-height:100svh; }
.stefan.open .drawer,.contact.open .drawer { position:relative; top:-1.5px; }
.home { border-radius:50%; }
.home:focus:not(:focus-visible) { outline:0; }
.work-row { position:relative; overflow:hidden; }
.work-row picture { position:absolute; display:block; }
.work-row img { display:block; width:100%; height:100%; object-fit:cover; }
.more { display:block; width:fit-content; margin:0 auto; padding:30px 0; }
@media (prefers-reduced-motion:no-preference) { html { scroll-behavior:smooth; } }
.error-page { min-height:100svh; display:grid; place-items:center; }
.error-group { display:flex; align-items:center; gap:26px; text-align:center; }
.error-group img { display:block; max-width:32vw; height:auto; }

/* Keep the yellow sheet slightly inside the glyphs' painted baseline. */
.phenomen .drawer { position:relative; top:-2px; }
@media (min-width:761px) {
  .phenomen h2 { height:auto; aspect-ratio:440/95; }
}
.home-slot { width:var(--mascot-width); height:calc(var(--mascot-gap) + var(--mascot-width) * 122 / 140); }
.home.pinned { position:fixed; top:var(--gap); left:var(--gap); z-index:5; }
.film { position:absolute; overflow:hidden; border-radius:0; container-type:size; }
.film picture { inset:0; }
.film iframe {
  position:absolute; top:50%; left:50%; transform:translate(-50%,-50%);
  width:max(100%, calc(100cqh * var(--film-ratio)));
  height:max(100%, calc(100cqw / var(--film-ratio)));
  display:block; border:0; border-radius:0; pointer-events:none;
}

/* The palette captions sit against the left edge of the source video. */
.palette-film img { object-position:left center; }
.palette-film iframe { left:0; transform:translateY(-50%); }

/* Overlap adjacent film tiles across fractional device pixels. */
.work-row > .film + .film { margin-left:-1px; padding-right:1px; box-sizing:content-box; }
.film iframe { scale:1.012; transform-origin:0 0; }

.mobile-break { display:none; }
@media (max-width:760px) { .bio br:is(.keep-break,.mobile-break) { display:revert; } }


@media (max-width:760px) {
  .bio br:is(.keep-break,.mobile-break) { display:none; }
  .bio p { text-wrap:pretty; }
}
@media (max-width:480px) { .bio br:is(.keep-break,.mobile-break) { display:revert; } }
@media (min-width:761px) and (max-width:1366px) { .bio br { display:none; } .bio p { text-wrap:pretty; } }
.film video { position:absolute; inset:0; width:100%; height:100%; object-fit:cover; border-radius:0; display:block; }
.palette-film video { object-position:left center; }
.film .play-film { position:absolute; inset:0; border:0; background:transparent; color:white; cursor:pointer; font:32px serif; text-shadow:0 1px 5px black; }
