/* Responsive finishing layer: safe-area aware controls, fitted phone content. */
:root{--phone-safe-top:env(safe-area-inset-top,0px);--phone-top:env(safe-area-inset-top,0px);--phone-bottom:env(safe-area-inset-bottom,0px)}
.header-controls{display:flex;align-items:center;gap:8px}
.nav{display:grid;grid-template-columns:auto 1fr auto;gap:32px}.nav nav{justify-self:end}
.mobile-menu-toggle{display:none}
.timeline-disclosure{font:inherit;letter-spacing:inherit;line-height:inherit;color:inherit;background:none;border:0;padding:0;text-align:left;pointer-events:none}
.timeline-chevron{display:none}
@media(max-width:700px){
 html{-webkit-text-size-adjust:100%;text-size-adjust:100%}
 .nav,.window-enlarged .nav{height:calc(64px + var(--phone-top));padding:var(--phone-top) 20px 0;grid-template-columns:1fr auto;grid-template-rows:64px;gap:12px;background:var(--bg,#f1f2f5);align-content:start}
 .nav .wordmark,.window-enlarged .nav .wordmark{font-size:23px;align-self:center}
 .header-controls{grid-column:2;grid-row:1;gap:8px}
 .nav #theme-toggle,.nav .mobile-menu-toggle{width:44px;height:44px;min-height:44px;padding:11px;border:0;border-radius:8px;background:none;color:var(--ink);display:grid;place-items:center}
 .mobile-menu-toggle svg{width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round}
 .nav nav,.window-enlarged .nav nav{display:none;position:absolute;top:calc(64px + var(--phone-top));left:12px;right:12px;width:auto;max-height:calc(100svh - 88px);overflow-y:auto;margin:0;padding:12px;background:var(--paper,#fff);border:1px solid var(--line);border-radius:12px;box-shadow:0 12px 30px #101c2c24}
 .nav.menu-open nav{display:flex;flex-direction:column;align-items:stretch;gap:4px}
 .nav nav a{display:flex;align-items:center;min-height:48px;font-size:16px;padding:10px 14px;border-radius:6px}
 .nav nav a[aria-current=page]{background:var(--soft,#e5eaf0);text-decoration:none}
 .nav nav .nav-label-compact{display:none}.nav nav .nav-label-full{display:inline}
 /* Stable small viewport: browser toolbar expansion must not move the casing. */
 .window-stage-only .cabin{height:100svh}
 .window-stage-only main,.window-stage-only .flight{height:100svh}
 .window-glass{inset:14% 10% 8%;border-radius:46% 46% 41% 41% / 29% 29% 25% 25%}
 .window-glass .portal-landscape.day-sky{transform:none;object-position:center}
 .window-shade{touch-action:none;-webkit-user-select:none;user-select:none}
 .window-actions .window-explore{min-height:48px}.window-actions .window-explore span{font-size:14px}
 .window-about .opening-copy-left{left:24px;right:24px;max-width:none}
 #next-slide .room-interface{top:calc(80px + var(--phone-top));left:20px;right:20px;bottom:calc(76px + var(--phone-bottom))}
 .room-heading h2{font-size:30px}.room-project-picker button{min-height:44px}
 #next-slide .room-project{padding:16px}.room-project h3{font-size:21px;line-height:1.2}
 .project-context-tags li{font-size:12px}.room-project .project-decision{font-size:16px;line-height:1.6}
 #next-slide .project-preview{flex:1;min-height:82px;max-height:220px;height:auto;aspect-ratio:auto;margin:0 0 16px}
 #next-slide .room-project-open{min-height:44px;font-size:14px}
 .room-render-note{bottom:calc(6px + var(--phone-bottom));font-size:9px;padding:0 14px}
 .portfolio-stage .stage-next,.portfolio-stage .stage-previous,#next-slide .stage-next,#experience #photography-next,#experience .stage-previous{position:absolute;top:auto;bottom:calc(18px + var(--phone-bottom));transform:none;display:flex;flex-direction:row;gap:7px;font-size:12px;min-height:44px;padding:0}
 .portfolio-stage .stage-next,#next-slide .stage-next{right:20px}.portfolio-stage .stage-previous,#experience .stage-previous{left:20px;right:auto}
 .stage-next .stage-arrow-circle,.stage-previous .stage-arrow-circle,#experience #photography-next .stage-arrow-circle{width:36px;height:36px}
 #next-slide .stage-next{bottom:calc(25px + var(--phone-bottom))}
 #experience.portfolio-stage{padding:calc(80px + var(--phone-top)) 20px calc(78px + var(--phone-bottom))}
 #experience .section-head{padding:0;align-items:center;margin-bottom:12px}
 #experience .section-head h2{font-size:28px;line-height:1.2}
 #experience .section-head .text-link{font-size:12px;min-height:44px}
 .experience-picker{margin-bottom:12px}.experience-picker button{min-height:40px;font-size:13px}
 #experience .experience-timelines{flex:0 1 auto;overflow:auto;overscroll-behavior:contain;border-radius:14px;scrollbar-width:thin}
 #experience .timeline-panel{height:auto;padding:12px 16px;flex:none;gap:0}
 #experience .timeline-entry{grid-template-columns:40px minmax(0,1fr);gap:10px;padding:10px 0;align-items:start;flex:none}
 #experience .timeline-logo{width:40px;height:44px;padding:4px}
 #experience .timeline-entry h4{font-size:16px;line-height:1.3;margin:0}
 #experience .timeline-role{font-size:14px;line-height:1.4;margin:0}
 #experience .timeline-meta,#experience .timeline-meta time{font-size:12px;line-height:1.4}
 #experience .timeline-summary{font-size:16px;line-height:1.45;margin-top:8px}
 .timeline-disclosure{width:100%;display:flex;align-items:center;justify-content:space-between;gap:6px;min-height:30px;pointer-events:auto}
 .timeline-chevron{display:inline;font-size:18px;color:var(--muted);flex:none}
 .details-open .timeline-chevron{transform:rotate(180deg)}
 #experience .timeline-entry:not(.details-open) .timeline-summary{display:none}
 #experience .timeline-affiliation{font-size:12px;display:inline-block}
 .photography-stage,.community-stage{padding:calc(84px + var(--phone-top)) 20px calc(78px + var(--phone-bottom))}
 .photography-stage .section-head,.community-stage .section-head{margin-bottom:16px}
 .photography-stage .section-head h2,.community-stage .section-head h2{font-size:28px}
 .photography-layout{display:flex;flex-direction:column;justify-content:flex-start;gap:20px;min-height:0}
 .photography-copy{max-width:none;flex:none}.photography-copy p{font-size:16px;line-height:1.5}
 .photography-copy .text-link{margin-top:12px;min-height:44px;font-size:13px}
 .photography-stage .photo-column{width:min(100%,calc((100svh - 406px - var(--phone-top) - var(--phone-bottom))/1.12));max-width:none;align-self:center;flex:none}
 .photography-stage figcaption{font-size:10px;line-height:1.4;margin-top:8px}.photography-theme-switch{font-size:11px;line-height:1.4;min-height:44px;margin-top:4px}
 .community-layout{gap:20px}.community-copy h3{font-size:23px}.community-copy p:not(.eyebrow){font-size:16px}
 .community-photo img{max-height:calc(100svh - 425px - var(--phone-top) - var(--phone-bottom));object-position:left center}
 .contact-stage{padding:calc(94px + var(--phone-top)) 24px calc(70px + var(--phone-bottom))}
 .contact-stage h2{font-size:34px}.contact-stage>p:not(.eyebrow){font-size:15px;line-height:1.6}
 .contact-stage .email{font-size:clamp(22px,5.6vw,30px);overflow-wrap:anywhere;max-width:100%}
 .contact-stage .contact-bottom{gap:12px 24px;margin-top:32px}.contact-bottom a,.contact-bottom button{min-height:44px}
 .project-folder{width:calc(100vw - 24px);height:calc(100svh - 24px - var(--phone-top) - var(--phone-bottom));max-height:calc(100dvh - 24px);margin:auto;padding:0}
 .folder-bar{min-height:54px;height:54px;padding:8px 12px;gap:8px}.folder-bar strong{font-size:13px;line-height:1.3}.folder-bar>svg{flex:none;width:18px}#folder-close{width:44px;min-width:44px;height:44px}
 .folder-workspace{height:calc(100% - 54px);min-height:0}.folder-sidebar{overflow-x:auto;flex-wrap:nowrap;gap:4px;padding:8px;min-height:60px;-webkit-overflow-scrolling:touch}
 .folder-sidebar button{min-height:44px;flex:none;max-width:140px;font-size:12px;white-space:normal;padding:8px 12px}
 .folder-content{padding:20px;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;scroll-padding:20px}
 .folder-content.comparison-visual{padding:20px;gap:12px}
 .folder-content.comparison-visual>h3{font-size:23px}
}

@media(prefers-reduced-motion:reduce){.mobile-menu-toggle,.timeline-chevron{transition:none}}
/* A clearer idle invitation; direct manipulation stops both animations. */
.window-assembly.is-idle{animation:window-invitation 3.6s .6s 3}
.window-shade.is-idle{animation:shade-invitation 3.6s .6s 3}
@keyframes window-invitation{0%,28%,100%{translate:0 0}46%{translate:0 -14px}61%{translate:0 0}73%{translate:0 -6px}84%{translate:0 0}}
@keyframes shade-invitation{0%,28%,100%{transform:translateY(0)}46%{transform:translateY(-11%)}61%{transform:translateY(0)}73%{transform:translateY(-4%)}84%{transform:translateY(0)}}
@media(prefers-reduced-motion:reduce){.window-assembly.is-idle,.window-shade.is-idle{animation:none!important}}

/* Side columns never intrude into the window at desktop or laptop sizes. */
@media(min-width:951px){
 .intro,.window-about .opening-copy-left{box-sizing:border-box;max-width:none}
 .intro h1{font-size:clamp(24px,2.3vw,37px);overflow-wrap:break-word}
 .intro .hero-identity{max-width:100%}
}
.cabin.short-landscape .intro{top:50%;transform:translateY(-50%);text-align:left}
.cabin.short-landscape .intro h1{font-size:clamp(17px,2.5vw,24px)}
.cabin.short-landscape .hero-identity{align-items:flex-start;margin-top:14px}
.cabin.short-landscape .hero-name{font-size:18px}.cabin.short-landscape .hero-role{font-size:13px}
.cabin.short-landscape .opening-copy-left{top:50%!important;transform:translateY(-50%);right:auto;text-align:left}
.cabin.short-landscape .opening-copy-left h2{font-size:20px}.cabin.short-landscape .opening-copy-left p{font-size:12px;line-height:1.5}
@media(min-width:701px) and (max-height:600px){
 .portfolio-stage .room-interface{top:82px;bottom:65px}
 .room-heading h2{font-size:28px}.room-heading{margin-bottom:16px}
 .room-project{padding:14px}.room-project h3{font-size:19px}
 .project-context-tags li{font-size:10px;padding:4px 6px}
 .room-project .project-decision{font-size:12px}.room-project .project-preview{min-height:60px;height:100px;max-height:24vh}
 .portfolio-stage .room-dock{margin-top:16px}
}

/* Short landscape windows retain readable content in an internal stage viewport. */
@media(max-height:500px){
 .portfolio-stage{overflow-y:auto!important;overscroll-behavior:contain}
 #experience .experience-timelines{overflow:auto;min-height:0}
 .photography-stage,.community-stage{padding-top:84px;padding-bottom:78px}
 .photography-layout,.community-layout{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:24px;align-items:start;flex:none}
 .photography-stage .photo-column{width:min(100%,240px);max-width:240px}
 .photography-copy p{font-size:16px;line-height:1.5}.photography-copy .text-link{font-size:13px;margin-top:14px}
 .community-photo img{max-height:185px}.community-copy h3{font-size:22px}.community-copy p:not(.eyebrow){font-size:13px}
 .photography-stage .stage-next,.photography-stage .stage-previous,.community-stage .stage-next,.community-stage .stage-previous{top:auto;bottom:14px;transform:none}
}

/* iOS browser chrome leaves less vertical room than an edge-to-edge preview. */




/* A continuous view from the cabin. Overscan hides every edge during the drift.
   The inner photos keep their existing day/night crop and the zoom freezes this layer. */
.window-portal > .sky-flight{position:absolute;inset:0;transform:scale(1.22);transform-origin:center;animation:sky-flight-drift 18s ease-in-out -4.5s infinite alternate;animation-play-state:paused;pointer-events:none}
/* Playback is owned by syncSkyMotion, including partial shade positions. */
@keyframes sky-flight-drift{
 from{transform:translate3d(-8%,1%,0) scale(1.22)}
 to{transform:translate3d(8%,-1%,0) scale(1.22)}
}
.sky-motion-toggle{position:absolute;right:-48px;bottom:0;z-index:8;width:44px;height:44px;display:grid;place-items:center;padding:0;border:0;border-radius:50%;background:transparent;color:var(--muted,#53657a);cursor:pointer;visibility:hidden}
.window-assembly.is-open:not(.is-expanding) .sky-motion-toggle{visibility:visible}
.sky-motion-toggle svg{fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round}
.sky-motion-toggle .sky-play,.sky-motion-toggle[aria-pressed="true"] .sky-pause{display:none}
.sky-motion-toggle[aria-pressed="true"] .sky-play{display:block}
.sky-motion-toggle:hover{background:color-mix(in srgb,currentColor 7%,transparent)}
.sky-motion-toggle:focus-visible{outline:2px solid currentColor;outline-offset:2px}
@media(prefers-reduced-motion:reduce){
 .window-portal > .sky-flight{animation:none;transform:none}
 .sky-motion-toggle{display:none}
}

/* Give the overview the same context as its project card, before the detailed case. */
.folder-project-summary{display:grid;grid-template-columns:minmax(0,.9fr) minmax(0,1.1fr);gap:24px;align-items:start;margin:0 0 28px;padding-bottom:24px;border-bottom:1px solid var(--line)}
.folder-project-summary .project-preview{width:100%;height:auto;aspect-ratio:12/7;margin:0;overflow:hidden;border:1px solid var(--line);border-radius:8px;background:var(--soft)}
.folder-project-summary .project-preview img{display:block;width:100%;height:100%;object-fit:contain}
.folder-content .folder-project-summary h3{font-size:24px;line-height:1.25;margin:0 0 14px;letter-spacing:-.035em}
.folder-project-summary .project-context-tags{margin:0 0 12px;min-height:0}
.folder-content .folder-project-summary .project-decision{margin:0;font-size:14px;line-height:1.6}
.project-folder{overflow:visible}
.folder-workspace{overflow:hidden;border-radius:0 0 10px 10px}
.folder-project-navigation{position:absolute;inset:0;pointer-events:none}
.folder-project-navigation button{pointer-events:auto;position:absolute;top:calc(50% - 22px);width:44px;height:44px;display:grid;place-items:center;border:1px solid var(--line);border-radius:50%;background:var(--paper);color:var(--ink);padding:10px;cursor:pointer;box-shadow:0 4px 16px #00000014}
.folder-project-previous{left:-56px}.folder-project-next{right:-56px}
.folder-project-navigation svg{width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round}
.folder-project-navigation button:hover{background:var(--soft)}
.folder-project-navigation button:focus-visible{outline:2px solid var(--accent);outline-offset:3px}
.folder-project-position{display:none}
@media(max-width:1100px){
 .folder-project-navigation{top:auto;bottom:0;height:58px;background:var(--paper);border-top:1px solid var(--line);border-radius:0 0 10px 10px;display:flex;align-items:center;justify-content:center}
 .folder-project-navigation button{top:7px;box-shadow:none}
 .folder-project-previous{left:16px}.folder-project-next{right:16px}
 .folder-project-position{display:block;color:var(--muted);font-size:13px;font-variant-numeric:tabular-nums}
 .folder-workspace{height:calc(100% - 120px);border-radius:0}
}
@media(max-width:650px){
 .folder-workspace{height:calc(100% - 116px)}
 .folder-project-summary{grid-template-columns:1fr;gap:20px;margin-bottom:24px;padding-bottom:24px}
 .folder-project-summary .project-preview{max-height:190px}
 .folder-content .folder-project-summary h3{font-size:24px}
}
.folder-project-summary>div{min-width:0}
.folder-content .research-links{flex-wrap:wrap;gap:8px 20px}
.folder-content .research-links a{margin-right:0}
[data-theme=dark] .folder-project-summary .project-preview img{filter:brightness(.8)}

/* The home invitation remains available while the optional camera panel is open. */
@media(min-width:951px){.gesture-panel-open .gesture-invitation{visibility:visible!important}}

/* Readability audit: content may scroll inside a stage, rather than shrink to fit. */
.hero-work-link{display:inline-flex;align-items:center;gap:12px;min-height:44px;margin-top:20px;font-size:15px}
.folder-content .case-role{font-size:14px;line-height:1.7;color:var(--muted);margin:0 0 24px}
.folder-content .case-role strong{color:var(--ink);font-weight:600}
@media(max-width:700px){
 #next-slide{overflow-y:auto;overscroll-behavior:contain;padding:calc(84px + var(--phone-top)) 20px calc(28px + var(--phone-bottom))}
 #next-slide .room-interface{position:relative;inset:auto;width:100%;height:auto;min-height:0;overflow:visible}
 #next-slide .room-dashboard{flex:none;height:auto;min-height:0}
 #next-slide .room-project-column{height:auto;min-height:0}
 #next-slide .room-project{height:auto;min-height:0;flex:none}
 #next-slide .project-preview{flex:none;aspect-ratio:12/7;min-height:0;height:auto;max-height:none}
 #next-slide .room-project h3{font-size:23px;line-height:1.3}
 #next-slide .room-project .project-decision{font-size:16px;line-height:1.6}
 #next-slide .project-context-tags li{font-size:12px;line-height:1.5}
 #next-slide .stage-next{position:relative;inset:auto;transform:none;margin:24px 0 0 auto;width:max-content}
 #next-slide .room-render-note{position:static;margin:20px 0 0;font-size:12px;line-height:1.5}
 .portfolio-stage.photography-stage,.portfolio-stage.community-stage,.portfolio-stage.contact-stage{overflow-y:auto;overscroll-behavior:contain}
 .photography-stage .photography-layout{gap:32px;flex:none}
 .photography-stage .photo-column{width:100%;max-width:none;align-self:stretch}
 .photography-stage .collage-row img{width:100%;height:auto;object-fit:contain}
 .photography-copy p,.community-copy p:not(.eyebrow),.contact-stage>p:not(.eyebrow){font-size:16px;line-height:1.65}
 .photography-copy .text-link,.photography-theme-switch{font-size:14px;min-height:44px}
 .photography-stage figcaption{font-size:12px;line-height:1.5;flex-wrap:wrap;gap:8px 20px}
 .photography-stage .stage-next,.photography-stage .stage-previous,.community-stage .stage-next,.community-stage .stage-previous{position:relative;inset:auto;transform:none;margin-top:28px;flex:none}
 .photography-stage .stage-next,.community-stage .stage-next{align-self:flex-end;margin-top:-44px}
 .community-photo img{max-height:none;width:100%;height:auto}
 #experience .timeline-panel{padding:16px;align-content:start;justify-content:flex-start}
 #experience .timeline-entry{padding:16px 0;flex:none;align-content:start}
 #experience .timeline-role{font-size:14px;line-height:1.5}
 #experience .timeline-meta,#experience .timeline-meta time{font-size:12px;line-height:1.5}
 #experience .timeline-summary{font-size:16px;line-height:1.6}
 #experience .timeline-disclosure{min-height:44px}
 .folder-content p,.folder-content .case-bullets li,.folder-content .case-reflection p,.folder-content .project-points li,.folder-content .project-skill-group li,.folder-content .case-role,.folder-content .folder-project-summary .project-decision{font-size:16px;line-height:1.65}
 .folder-content h4{font-size:16px}.folder-sidebar button{font-size:14px}
 .folder-content{padding:24px 20px;overflow-wrap:break-word}
 .folder-project-summary .project-preview{max-height:none}
}
@media(min-width:701px) and (max-height:650px){
 #next-slide{overflow-y:auto;padding-bottom:36px}
 #next-slide .room-interface{position:relative;top:auto;bottom:auto;min-height:0;margin-top:84px;height:auto}
 #next-slide .room-project .project-decision{font-size:15px;line-height:1.6}
 .portfolio-stage .room-dock{margin-top:28px}
}
/* The scene shell must never become a hidden scroll container when focus moves. */
@supports(overflow:clip){.window-stage-only .cabin{overflow:clip}}

@media(max-width:700px){
 .photography-stage .stage-previous,.community-stage .stage-previous{align-self:flex-start;margin-top:28px}
 .photography-stage .stage-next:not(.stage-previous),.community-stage .stage-next:not(.stage-previous){align-self:flex-end;margin-top:-44px}
 .photography-stage .photo-column{flex:none}
}

/* Keep the invitation and arrow together even in a narrow mobile aperture. */
.window-actions .window-explore{white-space:nowrap;flex-wrap:nowrap}
.window-actions .window-explore span{white-space:nowrap}
@media(max-width:950px){
 .window-portal{container-type:inline-size}
 .window-actions{width:calc(100% - 12px);max-width:none}
 .window-actions .window-explore{max-width:100%;gap:6px;padding-inline:0}
 .window-actions .window-explore span{font-size:clamp(10px,6cqw,14px)}
 .window-actions .window-explore svg{width:16px;height:16px}
}

/* Navigation owns a real row after the full photograph and caption. */
.stage-navigation-row{display:contents}
@media(max-width:700px){
 .portfolio-stage .stage-navigation-row{display:flex;justify-content:space-between;align-items:center;gap:16px;flex:none;width:100%;margin:28px 0 0;padding:0}
 .portfolio-stage .stage-navigation-row .stage-next{position:static!important;inset:auto!important;transform:none!important;align-self:auto!important;margin:0!important;min-height:44px;padding:0}
 .community-stage .community-layout{flex:none}
 .photography-stage,.community-stage{padding-bottom:calc(28px + var(--phone-bottom))}
}
@media(max-width:700px){
 #experience .stage-navigation-row{order:4}
 #experience .experience-timelines{flex:none}
}

/* One page-title scale across all portfolio destinations. */
body.window-stage-only :is(#room-title,#experience .section-head h2,#photography-title,#community-title,#contact h2){font-size:42px;line-height:1.15;font-weight:500;letter-spacing:-.045em}
@media(max-height:760px){body.window-stage-only :is(#room-title,#experience .section-head h2,#photography-title,#community-title,#contact h2){font-size:30px}}
@media(max-width:700px){body.window-stage-only :is(#room-title,#experience .section-head h2,#photography-title,#community-title,#contact h2){font-size:28px}}

/* Keep the shell centred independently of theme and cached pixel widths. */
.window-stage-only .window-assembly{left:50%;margin:0;transform-origin:50% 50%}
.sky-motion-toggle{width:auto;min-width:44px;right:-76px;gap:2px;padding:4px 8px;grid-template-rows:16px auto}
.sky-motion-label{font-size:10px;line-height:1.4;white-space:nowrap}
