/* sarzi.co, world3. Black and white, Henry-sparse: the room is the site, leo os is the one reading surface.
   Geist + Geist Mono only. No accent colour. */
@font-face{font-family:Geist;src:url(../fonts/Geist.woff2) format("woff2");font-weight:100 900;font-display:swap}
@font-face{font-family:"Geist Mono";src:url(../fonts/GeistMono.woff2) format("woff2");font-weight:100 900;font-display:swap}

:root{
  --bg:#d6d6d6; --ink:#0a0a0a; --ink-2:#3d3d3d; --ink-3:#6e6e6e; --ink-4:#9a9a9a;
  --paper:#fafafa; --rule:#e6e6e6; --black:#0a0a0a; --white:#fafafa;
  --ease:cubic-bezier(.2,.8,.2,1);
  --mono:"Geist Mono",ui-monospace,Menlo,monospace;
  --safe-b:env(safe-area-inset-bottom,0px); --safe-t:env(safe-area-inset-top,0px);
}
*{box-sizing:border-box;margin:0;padding:0}
html,body{height:100%;background:var(--bg)}
body{font-family:Geist,-apple-system,BlinkMacSystemFont,"Helvetica Neue",sans-serif;color:var(--ink);
  -webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;overflow:hidden;overscroll-behavior:none;
  -webkit-tap-highlight-color:transparent;letter-spacing:-.005em}
a{color:inherit;text-decoration:none}
button{font:inherit;color:inherit;background:none;border:0;cursor:pointer}
img,video{display:block;max-width:100%}
:focus-visible{outline:2px solid var(--ink);outline-offset:3px}

/* ---------------------------------------------------------------- stage */
#poster,#gl{position:fixed;inset:0;width:100%;height:100%}
#poster img{width:100%;height:100%;object-fit:cover}
#gl{opacity:0;transition:opacity .9s var(--ease);touch-action:none}
body.live #gl{opacity:1}
body.live #poster{opacity:0;transition:opacity .9s .2s var(--ease)}
body.hover-obj #gl{cursor:pointer}

/* ---------------------------------------------------------------- room chrome: a name, three links, one hint */
.hud{position:fixed;left:0;right:0;top:0;z-index:20;display:flex;justify-content:space-between;align-items:baseline;gap:16px;
  padding:calc(22px + var(--safe-t)) 26px 0;pointer-events:none;transition:opacity .4s var(--ease)}
.hud a{pointer-events:auto}
.name{font-size:15px;font-weight:620;letter-spacing:-.015em}
.links{display:flex;gap:22px;font-size:14px;font-weight:480;color:var(--ink-2)}
.links a:hover,.name:hover{color:var(--ink);text-decoration:underline;text-underline-offset:4px;text-decoration-thickness:1px}
.hint{position:fixed;left:50%;bottom:calc(30px + var(--safe-b));transform:translateX(-50%);z-index:20;display:flex;align-items:center;gap:6px;
  padding:11px 15px 11px 16px;background:var(--black);color:var(--white);font-family:var(--mono);font-size:13px;letter-spacing:0;
  border-radius:3px;transition:opacity .4s var(--ease);white-space:nowrap}
.hint i{width:8px;height:15px;background:var(--white);animation:blink 1.06s steps(1) infinite}
@keyframes blink{50%{opacity:0}}
body.in-os #labels,body.in-focus #labels{opacity:0}
body.in-os .hud{opacity:0;pointer-events:none}
body.nogl .hint{display:none}
body.dark .hud{color:var(--white)} body.dark .links{color:#c8c8c8}
body.dark .hint{background:var(--white);color:var(--black)} body.dark .hint i{background:var(--black)}

/* object labels: black boxes, like the hint */
#labels{position:fixed;inset:0;pointer-events:none;z-index:12;transition:opacity .3s var(--ease)}
.lbl{position:absolute;left:0;top:0;display:flex;flex-direction:column;gap:2px;padding:8px 11px 9px;background:var(--black);color:var(--white);border-radius:3px;
  opacity:0;transform:translate(-50%,calc(-100% - 8px));transition:opacity .2s var(--ease),transform .2s var(--ease);white-space:nowrap}
.lbl b{font-size:14px;font-weight:600;letter-spacing:-.01em}
.lbl span{font-family:var(--mono);font-size:11.5px;color:#bdbdbd;letter-spacing:0}
.lbl.on{opacity:1;transform:translate(-50%,calc(-100% - 12px))}

/* ---------------------------------------------------------------- the wall label (CSS3D, in the room) */
#card{position:absolute;width:380px;max-height:620px;display:flex;flex-direction:column;background:#fff;color:var(--ink);border-radius:4px;
  box-shadow:0 18px 50px rgba(0,0,0,.16),0 2px 6px rgba(0,0,0,.08);opacity:0;transition:opacity .45s var(--ease);visibility:hidden}
#card.on{opacity:1}
body.os-ready #card{visibility:visible}
.card-body{overflow-y:auto;padding:26px 26px 26px;scrollbar-width:none;overscroll-behavior:contain}
.card-body::-webkit-scrollbar{display:none}
.card-body .project{gap:14px}
.card-body .project h2{font-size:34px}
.card-body .project .big b{font-size:56px}
.card-body .project .lede{font-size:16px}
.card-body .project p{font-size:14px}
.card-body .project .stats b{font-size:22px}
.card-body .project .stats span{font-size:12.5px}
.card-back{flex:0 0 auto;margin:10px 26px 22px;align-self:flex-start;font-family:var(--mono);font-size:12.5px;color:var(--ink-3);padding:8px 0}
.card-back:hover{color:var(--ink)}
html:not(.js) #card{display:none}

/* ---------------------------------------------------------------- Leo's agent: a black terminal, Henry style */
.chat{background:var(--black);color:var(--white);border-radius:6px;padding:16px 16px 12px;font-family:var(--mono);font-size:13.5px;line-height:1.55;letter-spacing:0;display:flex;flex-direction:column;gap:12px}
.chat-log{display:flex;flex-direction:column;gap:10px;max-height:300px;overflow-y:auto;overscroll-behavior:contain;scrollbar-width:none}
.chat-log::-webkit-scrollbar{display:none}
.chat .m{margin:0;font-size:13.5px;color:var(--white);white-space:pre-wrap}
.chat .m.u{color:#9a9a9a}
.chat .m.u::before{content:"> "}
.chat .m.a.wait::after{content:"▌";animation:blink 1.06s steps(1) infinite}
.chat-try{display:flex;flex-direction:column;align-items:flex-start;gap:2px}
.chat-try .try{font-family:var(--mono);font-size:12.5px;color:#9a9a9a;text-align:left;padding:3px 0}
.chat-try .try::before{content:"→ "}
.chat-try .try:hover{color:var(--white)}
.chat-form{display:flex;gap:8px;align-items:center;border-top:1px solid #2a2a2a;padding-top:10px}
.chat-form input{flex:1;min-width:0;background:none;border:0;outline:0;color:var(--white);font:16px/1.4 var(--mono);caret-color:var(--white)}
.chat-form input::placeholder{color:#6e6e6e}
.chat-form button{width:34px;height:34px;border-radius:4px;background:var(--white);color:var(--black);font-size:16px}
.project .chat-note{font-size:12.5px;color:var(--ink-3)}
.project .chat-note a{text-decoration:underline;text-underline-offset:3px}
.os-index .os-ask b{font-size:40px}
#os.compact .os-index .os-ask b{font-size:72px}

/* interim still mode: the Cycles still is the room, hotspots are real buttons projected from its camera */
#hot{position:fixed;inset:0;z-index:11}
.hot{position:absolute;border-radius:4px}
.hot:focus-visible{outline:2px solid var(--ink)}
body.still #poster{opacity:1 !important}
body.still:not(.os-full) #os{display:none}
body.still #card{display:none}
body.still #card.still-card{display:flex;visibility:visible;position:fixed;left:50%;top:50%;transform:translate(-50%,-50%);z-index:30;width:min(420px,calc(100vw - 24px));max-height:min(78vh,680px)}
body.still.in-focus #hot{background:rgba(214,214,214,.55)}

/* ---------------------------------------------------------------- project articles (leo os windows + no-JS page) */
.project{display:flex;flex-direction:column;gap:18px}
.project .kicker{font-family:var(--mono);font-size:12.5px;color:var(--ink-3);letter-spacing:0}
.project h2{font-size:44px;line-height:1;font-weight:650;letter-spacing:-.04em}
.project .big{display:flex;flex-direction:column;gap:8px;padding:6px 0 4px}
.project .big b{font-size:76px;line-height:.92;font-weight:660;letter-spacing:-.05em;font-variant-numeric:tabular-nums}
.project .big span{font-size:15px;color:var(--ink-3)}
.project .big.mail a{font-size:32px;font-weight:620;letter-spacing:-.03em;text-decoration:underline;text-underline-offset:6px;text-decoration-thickness:2px}
.project .lede{font-size:17px;line-height:1.5}
.project p{font-size:15px;line-height:1.55;color:var(--ink-2)}
.project .stats{list-style:none;display:grid;grid-template-columns:repeat(auto-fit,minmax(130px,1fr));gap:0 22px}
.project .stats li{padding:14px 0 4px;border-top:1px solid var(--rule)}
.project .stats b{display:block;font-size:26px;font-weight:650;letter-spacing:-.035em;margin-bottom:4px}
.project .stats span{display:block;font-size:13px;line-height:1.4;color:var(--ink-3)}
.project .media{border-radius:6px;overflow:hidden;background:#111;aspect-ratio:16/10}
.project .media.tall{aspect-ratio:4/5}
.project .media video{width:100%;height:100%;object-fit:cover;filter:grayscale(1) contrast(1.05)}
.project .flow{list-style:none;display:grid;grid-template-columns:1fr 1fr;gap:0 22px;counter-reset:f}
.project .flow li{counter-increment:f;padding:14px 0 6px;border-top:1px solid var(--rule);font-size:16px;font-weight:580}
.project .flow li::before{content:"0" counter(f);display:block;font-family:var(--mono);font-size:12px;color:var(--ink-3);font-weight:400;margin-bottom:4px}
.project .links{display:flex;gap:10px;flex-wrap:wrap}
.go{display:inline-flex;align-items:center;gap:10px;height:42px;padding:0 16px;border-radius:6px;background:var(--black);color:var(--white) !important;font-size:14.5px;font-weight:560}
.go::after{content:"↗";font-size:13px}
.go:hover{background:#2a2a2a}
.links .go+.go{background:#ececec;color:var(--ink) !important}
.links .go+.go:hover{background:#e0e0e0}

html.js #work{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
#stash{position:fixed;left:0;top:0;width:0;height:0;overflow:hidden}
html:not(.js) body{overflow:auto;background:var(--paper)}
html:not(.js) #work{max-width:720px;margin:0 auto;padding:96px 24px 80px;display:flex;flex-direction:column;gap:88px}

/* ---------------------------------------------------------------- leo os: 1600x1000 on the display */
#os{position:fixed;left:0;top:0;width:1600px;height:1000px;overflow:hidden;background:var(--paper);color:var(--ink);
  visibility:hidden;pointer-events:none;font-size:16px;z-index:5}
body.os-ready #os{visibility:visible}
.os-bar{position:relative;z-index:2;height:42px;display:flex;align-items:center;gap:24px;padding:0 22px;background:#fff;font-size:15px;font-weight:520;
  box-shadow:0 1px 0 var(--rule)}
.os-bar b{font-weight:700;letter-spacing:-.02em}
.os-menu{color:var(--ink-2);font-size:15px}
.os-menu:hover{color:var(--ink)}
.os-r{margin-left:auto;display:flex;align-items:center;gap:14px;color:var(--ink-3);font-family:var(--mono);font-size:13.5px}
.os-leave{font-family:Geist,sans-serif;font-size:14px;font-weight:560;color:var(--ink);padding:6px 12px;border-radius:6px;background:#efefef;margin-left:8px}
.os-leave:hover{background:#e4e4e4}
.os-icons{position:absolute;left:26px;top:66px;display:flex;flex-direction:column;gap:6px;width:104px}
.os-icons a{display:flex;flex-direction:column;align-items:center;gap:7px;padding:11px 4px 9px;border-radius:10px;transition:background .2s var(--ease)}
.os-icons a:hover{background:rgba(0,0,0,.05)}
.os-icons svg{width:36px;height:36px;fill:none;stroke:var(--ink);stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round}
.os-icons span{font-size:13px;font-weight:520;color:var(--ink-2)}
.os-hello{position:absolute;left:220px;top:108px;right:120px}
.os-hello h1{font-size:132px;line-height:.92;font-weight:650;letter-spacing:-.055em}
.os-index{list-style:none;margin-top:58px;max-width:1080px}
.os-index a{display:grid;grid-template-columns:400px 1fr auto;align-items:baseline;gap:24px;padding:20px 8px 18px;border-top:1px solid var(--rule);transition:background .2s var(--ease)}
.os-index li:last-child a{border-bottom:1px solid var(--rule)}
.os-index a:hover{background:#f0f0f0}
.os-index b{font-size:72px;line-height:.9;font-weight:660;letter-spacing:-.05em;font-variant-numeric:tabular-nums}
.os-index span{font-size:22px;color:var(--ink-2);letter-spacing:-.015em}
.os-index em{font-style:normal;font-family:var(--mono);font-size:14px;color:var(--ink-3)}
.os-foot{margin-top:30px;font-family:var(--mono);font-size:14px;color:var(--ink-3)}
.os-win{position:absolute;right:56px;top:74px;bottom:56px;width:680px;z-index:3;border-radius:12px;background:#fff;overflow:hidden;
  box-shadow:0 40px 100px rgba(0,0,0,.18),0 3px 10px rgba(0,0,0,.08);display:flex;flex-direction:column}
.os-win[hidden]{display:none}
.os-tb{flex:0 0 46px;display:flex;align-items:center;padding:0 16px;gap:12px;cursor:default;user-select:none;box-shadow:0 1px 0 var(--rule)}
.os-x{width:14px;height:14px;border-radius:50%;background:var(--ink);position:relative}
.os-x:hover::after{content:"";position:absolute;inset:3px;background:linear-gradient(45deg,transparent 42%,#fff 42% 58%,transparent 58%),linear-gradient(-45deg,transparent 42%,#fff 42% 58%,transparent 58%)}
.os-title{flex:1;text-align:center;margin-right:26px;font-family:var(--mono);font-size:13px;color:var(--ink-3)}
.os-app-body{flex:1;overflow-y:auto;padding:28px 40px 44px;scrollbar-width:thin;overscroll-behavior:contain}

/* compact leo os: phones, still on the 3D display. Huge type only; rows fly to the exhibit. */
#os.compact .os-icons,#os.compact .os-menu,#os.compact .os-foot{display:none}
#os.compact .os-bar{height:84px;font-size:34px;padding:0 40px}
#os.compact .os-r{font-size:30px}
#os.compact .os-leave{font-size:30px;padding:12px 24px;border-radius:12px}
#os.compact .os-hello{left:60px;right:60px;top:130px}
#os.compact .os-hello h1{font-size:150px}
#os.compact .os-index{margin-top:40px;max-width:none}
#os.compact .os-index a{grid-template-columns:1fr auto;padding:26px 8px 22px}
#os.compact .os-index b{font-size:110px}
#os.compact .os-index span{display:none}
#os.compact .os-index em{font-family:Geist,sans-serif;font-size:44px;color:var(--ink-2);font-weight:520}

/* full-screen leo os: only the no-WebGL emergency page */
body.os-full #os{position:fixed !important;inset:0 !important;width:100% !important;height:100% !important;transform:none !important;
  visibility:visible;pointer-events:auto;overflow-y:auto;z-index:25;-webkit-overflow-scrolling:touch}
body.os-full #os{display:flex;flex-direction:column}
body.os-full .os-hello{order:1} body.os-full .os-icons{order:2;margin-bottom:24px} body.os-full .os-foot{order:3}
body.os-full .os-bar{position:sticky;top:0;padding-top:var(--safe-t);height:calc(46px + var(--safe-t))}
body.os-full .os-bar>.os-menu{display:none}
body.os-full .os-hello{position:static;padding:40px 20px 0}
body.os-full .os-hello h1{font-size:clamp(48px,13.5vw,132px)}
body.os-full .os-index{margin-top:32px}
body.os-full .os-index a{grid-template-columns:1fr auto;gap:4px 12px;padding:16px 2px 14px}
body.os-full .os-index b{font-size:clamp(40px,11vw,72px);grid-column:1/-1}
body.os-full .os-index span{font-size:16px}
body.os-full .os-index em{font-size:12px}
body.os-full .os-icons{position:static;width:auto;display:grid;grid-template-columns:repeat(3,1fr);gap:4px;padding:28px 12px 0}
body.os-full .os-foot{padding:0 20px calc(40px + var(--safe-b))}
body.os-full .os-win{position:fixed;inset:calc(8px + var(--safe-t)) 8px calc(8px + var(--safe-b));width:auto;border-radius:14px}
body.os-full .os-app-body{padding:22px 22px 44px}
@media (min-width:701px){
  body.os-full .os-hello{max-width:1100px;margin:0 auto;padding:80px 32px 0}
  body.os-full .os-index a{grid-template-columns:minmax(260px,400px) 1fr auto}
  body.os-full .os-index b{grid-column:auto}
  body.os-full .os-icons{max-width:1100px;margin:0 auto;grid-template-columns:repeat(9,1fr);padding:48px 24px 0}
  body.os-full .os-foot{max-width:1100px;margin:0 auto;padding:32px 32px 80px}
  body.os-full .os-win{left:50%;right:auto;width:min(720px,calc(100vw - 16px));transform:translateX(-50%);top:24px;bottom:24px}
}
body.os-full.nogl .os-leave{display:none}

/* ---------------------------------------------------------------- phones */
@media (max-width:700px){
  .hud{padding:calc(16px + var(--safe-t)) 16px 0;flex-direction:column;gap:6px}
  .name{font-size:16px}
  .links{gap:16px;font-size:13px}
  .hint{bottom:calc(22px + var(--safe-b));font-size:12.5px}
  .project h2{font-size:38px}
  .project .big b{font-size:60px}
}
@media (prefers-reduced-motion:reduce){*{transition-duration:.01ms !important;animation-duration:.01ms !important}}
