:root{--paper:#f4f1e9;--ink:#414d3c;--sage:#738260;--muted:#8e917e;--line:#dedfd1;--serif:"Songti SC","STSong","SimSun",serif;--sans:"PingFang SC","Microsoft YaHei",system-ui,sans-serif}*{box-sizing:border-box}body{margin:0;background:var(--paper);color:var(--ink);font:13px/1.7 var(--sans);overflow:hidden;-webkit-font-smoothing:antialiased}button,a{-webkit-tap-highlight-color:transparent}button{font:inherit;color:inherit;cursor:pointer;touch-action:manipulation}a{text-decoration:none;color:inherit}button:focus-visible,a:focus-visible,canvas:focus-visible{outline:2px solid #bca672;outline-offset:4px}button{border:0;background:none}button:disabled{cursor:default}[hidden]{display:none!important}svg{width:24px;height:24px;fill:currentColor;flex-shrink:0}.svg-library{position:absolute;width:0;height:0;overflow:hidden}.room-header{height:83px;padding:0 45px;display:flex;justify-content:space-between;align-items:center;border-bottom:1px solid #c4c7b63b;position:relative;z-index:5;background:#f4f1e9d9}.room-brand{display:flex;align-items:center;gap:10px;letter-spacing:1px;font-size:14px;font-weight:550}.room-brand>svg{color:var(--sage);width:28px;height:28px;transform:rotate(-14deg)}.version-tag{font:9px var(--sans);color:#8d987e;border:1px solid #cdd4bf;border-radius:4px;padding:2px 5px;letter-spacing:.4px;margin-left:2px}.header-actions{display:flex;align-items:center;gap:26px;color:#7a816b;font-size:11px}.storybook-link{letter-spacing:.6px}.storybook-link span{margin-left:7px}#sound-toggle{border:1px solid #d9decc;display:flex;gap:7px;align-items:center;border-radius:25px;padding:6px 12px;font-size:10px;min-height:35px}#sound-toggle>span:first-child{font-size:17px;color:var(--sage)}#sound-toggle[aria-pressed=true]{background:#e7ecdc}.room-main{height:calc(100dvh - 83px);min-height:0;position:relative;isolation:isolate}.introduction{position:absolute;top:61px;left:47px;z-index:3;pointer-events:none}.eyebrow{display:flex;align-items:center;gap:7px;font-size:8px;letter-spacing:1.6px;color:#959a82;margin:0 0 19px}.eyebrow>span,.status-dot{display:inline-block;width:5px;height:5px;border-radius:50%;background:#95a278}.introduction h1{font:500 43px/1.5 var(--serif);letter-spacing:2px;margin:0 0 22px;color:#526047}.intro-copy{font-size:12px;line-height:2.1;color:#8b8d7b;letter-spacing:.6px;margin:0}.intro-note{display:flex;align-items:center;gap:7px;color:#9a9d89;font:11px var(--serif);margin-top:24px}.intro-note svg{width:13px;height:13px;transform:rotate(-12deg);color:#a2ad91}.scene-stage{position:absolute;inset:0 0 30px;z-index:1}.scene-stage canvas{display:block;width:100%;height:100%;touch-action:none;cursor:grab}.scene-stage canvas:active{cursor:grabbing}.hotspots{position:absolute;inset:0;pointer-events:none;overflow:hidden}.hotspot{position:absolute;top:0;left:0;pointer-events:auto;display:flex;align-items:center;gap:5px;padding:4px 9px 4px 4px;border:1px solid #fffef3dc;box-shadow:0 3px 12px #68704b19;background:#fffdf4e8;border-radius:24px;font-size:10px;white-space:nowrap;color:#697658;transform:translate(-50%,-50%);opacity:0;transition:background .2s,opacity .3s;backdrop-filter:blur(6px)}.hotspot b{display:grid;place-items:center;width:20px;height:20px;border-radius:50%;background:#dde5cd;font-size:9px;font-weight:500}.hotspot:hover{background:#fffdf7}.hotspot.found{color:#91967f}.hotspot.found b{background:#9cae85;color:white}.hotspot[data-object=cake] b{background:#ecddba}.hotspot::after{content:"";position:absolute;left:50%;top:100%;height:18px;border-left:1px solid #ffffffc4}.scene-badge{position:absolute;top:28px;right:44px;z-index:3;display:flex;align-items:center;gap:8px;color:#879079;font-size:9px;letter-spacing:.5px}.badge-divider{height:9px;border-left:1px solid #c9d0bb;margin:0 4px}.camera-toolbar{position:absolute;right:28px;top:46%;z-index:4;background:#fffdf6d9;border:1px solid #dfdfd1;border-radius:25px;padding:9px 4px;display:flex;flex-direction:column;align-items:center;box-shadow:0 4px 20px #616c3b07;backdrop-filter:blur(8px)}.camera-toolbar button{width:36px;height:34px;display:grid;place-items:center;font-size:21px;color:#7e8a6c}.camera-toolbar button svg{width:19px;height:19px;stroke:currentColor;stroke-width:1.4;fill:none;stroke-linecap:round;stroke-linejoin:round}.camera-toolbar button:hover{color:#495b37;background:#e9eddf;border-radius:50%}.camera-toolbar>span{width:16px;border-top:1px solid #e1e5d6;margin:3px 0}.nono-speech{width:max-content;position:absolute;left:48%;bottom:166px;z-index:4;display:flex;align-items:center;gap:11px;border:1px solid #dddfcf;background:#fffdf4eb;border-radius:15px;padding:11px 15px 11px 10px;max-width:calc(100% - 50px);box-shadow:0 6px 25px #6269430b;transform:translateX(-10%);transition:opacity .3s;backdrop-filter:blur(7px)}.nono-avatar{width:40px;height:40px}.speaker{font-size:9px;letter-spacing:1px;color:#949a80;display:block}.nono-speech p{font-size:11px;letter-spacing:.3px;margin:2px 0 0;white-space:nowrap}#pet-nono{display:grid;place-items:center;min-width:30px;min-height:36px;margin-left:6px;color:#a48f75}#pet-nono svg{width:18px;height:18px}#pet-nono:hover{color:#bb8e83;transform:scale(1.15)}.gift-dock{position:absolute;left:46px;bottom:48px;z-index:4;background:#fffdf7df;border:1px solid #dedfcf;border-radius:13px;box-shadow:0 5px 25px #59664209;backdrop-filter:blur(8px);padding:12px 18px 9px;min-width:337px}.dock-heading{display:flex;align-items:center;justify-content:space-between;font-size:10px;color:#87916f;letter-spacing:.8px;padding:0 3px 7px}.dock-heading>span:last-child{font-size:9px;color:#9da588}.dock-items{display:flex;align-items:center;gap:7px}.dock-items button{width:66px;display:flex;flex-direction:column;align-items:center;position:relative;border-radius:7px;padding:0 3px 3px;color:#8a8e77;font-size:9px;letter-spacing:.3px;transition:background .2s}.dock-items button:hover{background:#edf0e3}.dock-items button>svg{width:58px;height:41px;margin-bottom:2px}.dock-items button.found i{position:absolute;right:3px;top:2px;width:13px;height:13px;border-radius:50%;background:#91a577}.dock-items button.found i::after{content:"✓";color:white;font-size:9px;position:absolute;left:3px;top:-1px}.dock-divider{height:40px;border-left:1px solid #dde1d0;margin:0 5px}.cake-dock-icon{height:41px;width:46px;display:grid;place-items:center;font-size:31px;line-height:1;color:#c0a57a}.cake-dock-icon svg{width:40px;height:40px}.movement-controls{position:absolute;bottom:52px;right:41px;z-index:4;text-align:center}.movement-controls>span{font-size:8px;letter-spacing:.7px;color:#a1a78f;display:block;margin-bottom:8px}.direction-pad{display:grid;grid-template-columns:29px 29px 29px;grid-template-rows:27px 27px 27px;gap:3px}.direction-pad button{border:1px solid #d7ddc9;border-radius:7px;background:#fffdf6a6;color:#8b9776;font-size:17px;display:grid;place-items:center;touch-action:none}.direction-pad button:hover,.direction-pad button:active{background:#e0e7d1}.direction-pad button[data-move=up]{grid-column:2}.direction-pad button[data-move=left]{grid-column:1;grid-row:2}#call-nono{grid-column:2;grid-row:2}.direction-pad button[data-move=right]{grid-column:3;grid-row:2}.direction-pad button[data-move=down]{grid-column:2;grid-row:3}#call-nono svg{width:15px;height:15px}.controls-hint{position:absolute;z-index:3;bottom:25px;left:50%;display:flex;gap:15px;transform:translateX(-18%);font-size:8px;color:#a3a88e;white-space:nowrap}.controls-hint b{font-weight:500;color:#8e977b;margin-right:3px}.loading{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;background:var(--paper);z-index:4;color:#919c7e;font-size:11px;gap:9px;transition:opacity .4s}.loading svg{animation:pulse 1s infinite alternate;transform:rotate(-14deg);width:35px;height:35px}.loading p{letter-spacing:1px}#scene-fallback{position:absolute;inset:0;z-index:6;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;background:var(--paper);color:#7f896b}#scene-fallback>svg{width:42px;height:42px;margin-bottom:12px}#scene-fallback h2{font:25px var(--serif)}#scene-fallback p{font-size:12px;line-height:2}#scene-fallback a,#retry-scene{border:1px solid #adb79b;border-radius:6px;padding:8px 18px;margin:7px;font-size:12px}.no-script{position:fixed;inset:20%;background:var(--paper);padding:40px;z-index:30}
dialog{border:1px solid #dedfcf;border-radius:15px;width:460px;max-width:calc(100vw - 32px);max-height:88dvh;overflow:auto;padding:0;background:#faf8f0;color:var(--ink);box-shadow:0 20px 80px #36462928}dialog::backdrop{background:#34402a53;backdrop-filter:blur(6px)}dialog[open]{animation:arrive .25s ease}.dialog-close{display:grid;place-items:center;padding:0;position:absolute;right:13px;top:13px;border:1px solid #dce1ce;border-radius:50%;width:33px;height:33px;line-height:1;font-size:23px;color:#899278;background:#f9f8ef;z-index:2}.story-content{padding:31px 32px 29px;text-align:center}#story-art{height:139px;display:flex;justify-content:center;align-items:center}#story-art svg{width:190px;height:142px}.story-content>.eyebrow{justify-content:center;margin:13px 0 9px;font-size:9px;letter-spacing:1px}.story-content h2{font:500 28px/1.5 var(--serif);letter-spacing:1px;margin:0 0 14px}#story-body{font-size:12px;line-height:1.95;color:#858976}#story-body .quote{font:20px/1.85 var(--serif);color:#657953;white-space:pre-line;margin:15px 0}#story-body .detail{white-space:pre-line;line-height:1.9}.story-action{display:block;margin:22px auto 0;background:#7a8a61;color:#fffdf6;padding:12px 25px;border-radius:6px;min-height:45px;font-size:12px;letter-spacing:.5px}.story-action:hover{background:#667850}.story-content.letter{text-align:left;padding:43px 37px 30px}.story-content.letter>.eyebrow{justify-content:flex-start;margin-top:0;margin-bottom:23px}.story-content.letter h2{font-size:24px}.story-content.letter #story-art{display:none}.story-content.letter #story-body{font:16px/2 var(--serif);color:#6d785d}.letter-signature{text-align:right;font:14px var(--serif);margin:25px 0;color:#7a8566}.letter-human{border-top:1px dashed #d3dac5;padding-top:20px;font-size:15px}.letter-human small{font:9px var(--sans);color:#9aa18b}.story-content.letter .story-action{margin-top:20px}#celebration{position:fixed;inset:0;pointer-events:none;overflow:hidden;z-index:30}.paper-bit{position:absolute;top:-15px;animation:fall var(--duration) var(--delay) ease-in forwards;border-radius:2px}.heart-pop{font:32px var(--serif);color:#bd8d80}#room-canvas:focus-visible{outline-offset:-3px}@keyframes pulse{to{opacity:.4;transform:translateY(-5px) rotate(-14deg)}}@keyframes arrive{from{opacity:0;transform:translateY(12px)}to{opacity:1;transform:none}}@keyframes fall{0%{transform:translate3d(0,-15px,0) rotate(0);opacity:0}10%{opacity:.85}100%{transform:translate3d(var(--drift),105vh,0) rotate(540deg);opacity:0}}
@media(min-width:1500px){.introduction{left:70px;top:85px}.introduction h1{font-size:49px}.gift-dock{left:70px;bottom:70px}.nono-speech{bottom:190px}.controls-hint{bottom:46px}.movement-controls{bottom:70px}}
@media(max-width:1100px){.room-header{padding:0 28px;height:73px}.room-main{height:calc(100dvh - 73px)}.introduction{top:33px;left:30px}.introduction h1{font-size:34px;letter-spacing:1px;margin-bottom:15px}.introduction .eyebrow{font-size:7px;letter-spacing:1px;margin-bottom:16px}.intro-copy{font-size:11px}.intro-note{font-size:9px;margin-top:17px}.scene-badge{top:24px;right:29px;font-size:8px}.gift-dock{left:28px;bottom:47px;min-width:312px;padding:10px 13px 8px}.dock-items{gap:3px}.nono-speech{left:47%;bottom:167px;padding:9px 12px 9px 8px}.nono-speech p{font-size:10px}.controls-hint{font-size:7px;left:50%;transform:translateX(-10%);gap:8px;bottom:24px}.camera-toolbar{right:17px;top:42%}.movement-controls{right:26px;bottom:54px}.room-brand{font-size:13px}.header-actions{gap:17px}}
@media(max-width:700px){.room-header{height:65px;padding:0 20px}.room-brand{font-size:12px;gap:7px;letter-spacing:.5px}.room-brand>svg{width:23px;height:23px}.version-tag{font-size:8px;padding:1px 4px}.header-actions{gap:11px}.storybook-link{font-size:10px}.storybook-link span{display:none}#sound-toggle{padding:4px 8px;min-height:30px;font-size:9px;gap:4px}.room-main{height:calc(100dvh - 65px);min-height:0}.introduction{top:24px;left:23px}.introduction h1{font-size:28px;line-height:1.45;margin-bottom:10px;letter-spacing:1px}.introduction .eyebrow{font-size:6px;letter-spacing:1px;margin-bottom:11px}.intro-copy{font-size:10px;line-height:1.8}.intro-note{display:none}.scene-stage{inset:132px 0 130px}.scene-badge{top:31px;right:24px;gap:5px;font-size:8px;flex-wrap:wrap;max-width:90px;justify-content:flex-end}.scene-badge .badge-divider{display:none}#time-label{width:100%;text-align:right;font-size:7px}.camera-toolbar{top:178px;right:13px;padding:5px 3px;border-radius:21px}.camera-toolbar button{height:29px;width:29px;font-size:19px}.camera-toolbar button svg{width:17px;height:17px}.camera-toolbar>span{margin:1px}.nono-speech{left:50%;bottom:132px;transform:translateX(-50%);padding:7px 10px 7px 7px;gap:7px;border-radius:12px;max-width:calc(100% - 35px)}.nono-avatar{width:32px;height:32px}.speaker{font-size:8px}.nono-speech p{font-size:10px;white-space:normal;line-height:1.6}.nono-speech #pet-nono{min-width:22px;min-height:26px;padding:0;margin-left:3px}#pet-nono svg{width:16px;height:16px}.gift-dock{left:18px;bottom:32px;padding:8px 9px 6px;min-width:0;width:calc(100% - 101px);max-width:343px;border-radius:10px}.dock-heading{font-size:8px;padding:0 3px 3px}.dock-heading>span:last-child{font-size:8px}.dock-items{gap:0;justify-content:space-between}.dock-items button{width:25%;padding:0 0 1px;font-size:8px;letter-spacing:0}.dock-items button>svg{width:44px;height:33px;margin:0}.dock-divider{height:29px;margin:0 2px}.cake-dock-icon{height:33px;width:35px;font-size:24px}.cake-dock-icon svg{width:30px;height:30px}.movement-controls{right:13px;bottom:32px}.movement-controls>span{font-size:6px;letter-spacing:0;margin-bottom:6px}.direction-pad{grid-template-columns:20px 20px 20px;grid-template-rows:22px 22px 22px;gap:2px}.direction-pad button{font-size:14px;border-radius:5px}.direction-pad #call-nono svg{width:12px;height:12px}.controls-hint{bottom:11px;left:50%;transform:translateX(-50%);font-size:6px;gap:10px}.controls-hint span:last-child{font-size:0}.controls-hint span:last-child b{font-size:0}.controls-hint span:last-child::after{content:'点空地 · 诺诺走走';font-size:6px}.hotspot{font-size:8px;padding:3px 6px 3px 3px;gap:3px}.hotspot b{width:17px;height:17px;font-size:8px}.hotspot::after{height:12px}.story-content{padding:25px 23px}.story-content h2{font-size:25px}#story-body .quote{font-size:18px}.story-content.letter{padding:35px 27px 25px}.story-content.letter #story-body{font-size:15px}.loading p{font-size:10px}}
@media(max-height:650px) and (min-width:701px){.introduction{top:24px}.introduction h1{font-size:31px}.intro-note{display:none}.gift-dock{bottom:31px}.scene-stage{bottom:0}.nono-speech{bottom:146px}.controls-hint{bottom:16px}.camera-toolbar{top:24%}.movement-controls{bottom:34px}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important}.paper-bit{display:none}}

/* A small, warm play space; the handle stays attached to the 3D toy. */
.tug-panel{position:absolute;z-index:7;left:50%;bottom:28px;transform:translateX(-50%);width:390px;max-width:calc(100% - 32px);padding:17px 25px 13px;border:1px solid #d7dccb;border-radius:18px;background:#fffdf5f0;box-shadow:0 9px 35px #65714814;backdrop-filter:blur(10px);text-align:center}.tug-eyebrow{font-size:8px;letter-spacing:1.3px;color:#8c977d;margin:0 0 4px}.tug-panel h2{font:23px/1.5 var(--serif);margin:0;color:#58694b}.tug-panel #tug-status{font-size:11px;line-height:1.7;min-height:19px;margin:5px 0 9px;color:#818973}.tug-exit{display:grid;place-items:center;padding:0;line-height:0;position:absolute;right:10px;top:9px;width:28px;height:28px;border-radius:50%;font-size:22px;color:#8b957c}.tug-exit:hover{background:#edf0e2}.tug-progress{display:flex;align-items:center;gap:9px;color:#919b81;font-size:9px}.tug-progress progress{appearance:none;width:100%;height:6px;border:0;border-radius:8px;overflow:hidden;background:#e9eddf;flex:1}.tug-progress progress::-webkit-progress-bar{background:#e9eddf}.tug-progress progress::-webkit-progress-value{background:#96a97c;border-radius:8px}.tug-progress progress::-moz-progress-bar{background:#96a97c;border-radius:8px}.tug-progress>span:last-child{font-size:16px;color:#bb9180}.tug-actions{display:flex;align-items:center;justify-content:center;flex-wrap:wrap;gap:10px;margin-top:10px}.tug-actions button{min-height:32px;padding:6px 8px;border:0;border-radius:4px;background:transparent;color:#7d8a69;font-size:10px;line-height:1.5}.tug-actions button:hover{color:#445c32;text-decoration:underline;text-underline-offset:4px}.tug-panel small{display:block;font-size:8px;letter-spacing:.4px;color:#a1a68e;margin-top:4px}.tug-grip{position:absolute;z-index:6;display:flex;align-items:center;gap:6px;transform:translate(-50%,-50%);padding:8px 13px 8px 9px;border:1px solid #d1dac0;border-radius:28px;background:#fffdf3ed;box-shadow:0 3px 16px #5d704524;color:#6e8058;white-space:nowrap;font-size:11px;touch-action:none;user-select:none;-webkit-user-select:none;cursor:grab}.tug-grip svg{width:29px;height:29px}.tug-grip::before{content:'';position:absolute;left:50%;bottom:100%;height:17px;border-left:1px dashed #8a9974}.tug-grip[aria-pressed=true]{background:#dfe8d0;box-shadow:0 2px 8px #5d704528;cursor:grabbing;border-color:#9aac82}.tug-mode .gift-dock,.tug-mode .movement-controls,.tug-mode .nono-speech,.tug-mode .controls-hint,.tug-mode .hotspots{visibility:hidden;pointer-events:none}.tug-mode .introduction{opacity:.26}.tug-mode .scene-stage{left:0;bottom:210px}.tug-mode .camera-toolbar{top:24%}
@media(max-width:700px){.tug-mode .introduction{visibility:hidden}.tug-mode .scene-stage{inset:35px 0 220px}.tug-mode .scene-badge{top:12px;right:20px;max-width:none}.tug-mode .camera-toolbar{top:61px;right:8px}.tug-panel{bottom:16px;padding:13px 19px 11px}.tug-panel h2{font-size:21px}.tug-panel #tug-status{font-size:10px}.tug-grip{font-size:10px;padding:6px 10px 6px 7px}.tug-grip svg{width:25px;height:25px}.tug-actions{gap:11px}}
@media(max-height:650px) and (min-width:701px){.tug-panel{left:auto;right:18px;bottom:18px;transform:none;width:310px;padding:12px 19px}.tug-mode .scene-stage{left:0;right:0;bottom:0}.tug-mode .introduction{visibility:hidden}.tug-panel h2{font-size:20px}}

/* Keep the slim scrollbar at the paper edge, clear of its rounded corners. */
#story-dialog:has(.story-content.letter) { overflow: hidden; }
#story-dialog .story-content.letter {
  max-height: calc(88dvh - 22px);
  margin: 10px 0;
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: #b2bca2 transparent;
  padding-top: 33px;
  padding-bottom: 20px;
}
#story-dialog .story-content.letter::-webkit-scrollbar { width: 8px; background: transparent; }
#story-dialog .story-content.letter::-webkit-scrollbar-track { background: transparent; margin-block: 9px; }
#story-dialog .story-content.letter::-webkit-scrollbar-thumb {
  min-height: 44px;
  border: 2px solid #faf8f0;
  border-radius: 20px;
  background: #b2bca2;
  background-clip: padding-box;
}
#story-dialog .story-content.letter::-webkit-scrollbar-thumb:hover { background-color: #97a584; }
#story-dialog .story-content.letter::-webkit-scrollbar-thumb:active { background-color: #7f916c; }
#story-dialog .story-content.letter::-webkit-scrollbar-corner { background: transparent; }
@supports selector(::-webkit-scrollbar) {
  #story-dialog .story-content.letter { scrollbar-width: auto; scrollbar-color: auto; }
}

#story-dialog .story-content.letter:focus { outline: none; }

/* A real envelope opens before the full letter becomes readable. */
.letter-intro { display: none; }
#story-dialog[open].letter-opening {
  overflow: hidden;
  background: transparent;
  border-color: transparent;
  box-shadow: none;
  animation: none;
}
#story-dialog.letter-opening .story-content { visibility: hidden; }
#story-dialog.letter-opening .dialog-close { z-index: 10; }
#story-dialog.letter-opening .letter-intro {
  --unwrap-duration: 3s;
  display: flex;
  position: absolute;
  inset: 0;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  animation: envelope-gift var(--unwrap-duration) ease both;
}
.nono-envelope {
  position: relative;
  width: min(280px, 76vw);
  aspect-ratio: 14 / 9;
  margin-top: 70px;
  isolation: isolate;
  perspective: 900px;
}
.envelope-back {
  position: absolute; inset: 0; z-index: 1;
  background: #dcd1b9; border: 1px solid #d1c5a9; border-radius: 6px;
  box-shadow: 0 18px 35px #3e4b3425;
}
.envelope-pocket { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 3; }
.envelope-flap {
  position: absolute; inset: 0 0 auto; height: 57%; z-index: 5;
  background: linear-gradient(#f5ecd9, #e8dcc2);
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  transform-origin: center top;
  animation: envelope-flap var(--unwrap-duration) ease-in-out both;
}
.envelope-seal {
  position: absolute; z-index: 6; left: calc(50% - 19px); top: 43%;
  width: 38px; height: 38px; display: grid; place-items: center;
  color: #eff2e6; background: #9aa987; border: 3px double #c2cbb3;
  border-radius: 50%; box-shadow: 0 2px 4px #58654420;
  animation: envelope-seal var(--unwrap-duration) ease both;
}
.envelope-seal svg { width: 20px; height: 20px; transform: rotate(-12deg); }
.envelope-signature {
  position: absolute; right: 20px; bottom: 14px; z-index: 4;
  font: 13px var(--serif); color: #9b977e; letter-spacing: 1px;
}
.envelope-sheet {
  position: absolute; top: 7%; left: 7%; width: 86%; height: 88%; z-index: 2;
  padding: 18px 20px; border: 1px solid #e4ddc9; border-radius: 4px;
  background: #fffcf3; box-shadow: 0 2px 10px #5c5a3c16;
  color: #768567; text-align: left;
  animation: envelope-paper var(--unwrap-duration) cubic-bezier(.25,.65,.3,1) both;
}
.envelope-sheet > span { font: 6px var(--sans); letter-spacing: 1.4px; color: #9aa287; }
.envelope-sheet p { font: 15px var(--serif); margin: 12px 0 13px; }
.envelope-sheet i { display: block; height: 1px; background: #dfe3d3; margin: 9px 0; }
.envelope-sheet i:nth-of-type(2) { width: 89%; }
.envelope-sheet i:nth-of-type(3) { width: 68%; }
.envelope-sheet b { display: block; font: 12px var(--serif); text-align: right; margin-top: 12px; }
.envelope-caption { margin: 30px 0 0; color: #faf8ef; font: 15px var(--serif); letter-spacing: 1px; }
#story-dialog[open].letter-ready { animation: letter-read .55s cubic-bezier(.2,.7,.25,1) both; }
@keyframes envelope-gift {
  0% { opacity: 0; transform: translateY(22px) scale(.88); }
  15%, 86% { opacity: 1; transform: none; }
  100% { opacity: 0; transform: translateY(-24px) scale(1.08); }
}
@keyframes envelope-seal {
  0%, 20% { opacity: 1; transform: none; }
  30%, 100% { opacity: 0; transform: translateY(5px) scale(.8); }
}
@keyframes envelope-flap {
  0%, 25% { transform: rotateX(0); z-index: 5; }
  35% { z-index: 5; }
  36% { z-index: 0; }
  48%, 100% { transform: rotateX(180deg); z-index: 0; }
}
@keyframes envelope-paper {
  0%, 45% { transform: none; }
  77%, 86% { transform: translateY(-105%); }
  100% { transform: translateY(-115%) scale(1.04); }
}
@keyframes letter-read {
  from { opacity: 0; transform: translateY(-18px) scale(.92); }
  to { opacity: 1; transform: none; }
}
@media (max-height: 560px) {
  .nono-envelope { width: min(220px, 65vw); margin-top: 65px; }
  .envelope-sheet { padding: 12px 15px; }
  .envelope-sheet p { font-size: 13px; margin: 8px 0; }
  .envelope-sheet i { margin: 6px 0; }
  .envelope-caption { margin-top: 19px; font-size: 13px; }
}
@media (prefers-reduced-motion: reduce) {
  #story-dialog[open].letter-opening { background: #faf8f0; border-color: #dedfcf; }
  #story-dialog.letter-opening .story-content { visibility: visible; }
  #story-dialog.letter-opening .letter-intro { display: none; }
}

.dialog-close > svg, .tug-exit > svg { display: block; width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; }

.fetch-panel{position:absolute;z-index:7;left:50%;bottom:28px;transform:translateX(-50%);width:360px;max-width:calc(100% - 32px);padding:18px 30px 17px;border:1px solid #d7dccb;border-radius:18px;background:#fffdf5f0;box-shadow:0 9px 35px #65714814;backdrop-filter:blur(10px);text-align:center}
.fetch-panel h2{font:23px/1.5 var(--serif);margin:0;color:#58694b}
#fetch-status,#walk-status{font-size:11px;line-height:1.7;margin:6px 0 10px;color:#818973}
.fetch-steps{display:flex;justify-content:center;align-items:center;gap:12px;font-size:10px;color:#a3ab94}
.fetch-steps i{font-style:normal;color:#ccd3bc}
.fetch-panel:is([data-phase=reach],[data-phase=lift],[data-phase=swing],[data-phase=throw]) .fetch-steps span:nth-of-type(1),.fetch-panel[data-phase=chase] .fetch-steps span:nth-of-type(2),.fetch-panel[data-phase=pickup] .fetch-steps span:nth-of-type(2),.fetch-panel[data-phase=return] .fetch-steps span:nth-of-type(3),.fetch-panel:is([data-phase=present],[data-phase=catch]) .fetch-steps span:nth-of-type(3),.fetch-panel[data-phase=putdown] .fetch-steps span:nth-of-type(3),.fetch-panel[data-phase=recover] .fetch-steps span:nth-of-type(3){color:#687d50}
:is(.fetch-mode,.walk-mode) .gift-dock,:is(.fetch-mode,.walk-mode) .movement-controls,:is(.fetch-mode,.walk-mode) .nono-speech,:is(.fetch-mode,.walk-mode) .controls-hint,:is(.fetch-mode,.walk-mode) .hotspots{visibility:hidden;pointer-events:none}
:is(.fetch-mode,.walk-mode) .introduction{opacity:.35}
@media(max-width:700px){.fetch-panel{bottom:19px;padding:16px 22px}.fetch-panel h2{font-size:21px}:is(.fetch-mode,.walk-mode) .scene-stage{inset:90px 0 154px}:is(.fetch-mode,.walk-mode) .introduction{visibility:hidden}}
@media(max-height:650px) and (min-width:701px){.fetch-panel{left:auto;right:18px;bottom:18px;transform:none;width:310px;padding:13px 22px}:is(.fetch-mode,.walk-mode) .introduction{visibility:hidden}}

/* A matching little garden, visited only while the leash is attached. */
.walk-outdoors .introduction{visibility:hidden}
.garden-caption{position:absolute;z-index:3;top:61px;left:47px;pointer-events:none}
.garden-caption h2{font:500 36px/1.55 var(--serif);letter-spacing:1.5px;color:#526047;margin:0 0 17px}
.garden-caption>p:last-child{font-size:11px;line-height:2.1;color:#8b8d7b;letter-spacing:.5px;margin:0}
.walk-transition{position:absolute;inset:0;z-index:6;background:var(--paper);display:flex;align-items:center;justify-content:center;flex-direction:column;color:#87976e;opacity:0}
.walk-transition svg{width:35px;height:35px;transform:rotate(-12deg)}
.walk-transition p{font:18px var(--serif);letter-spacing:1px;margin-top:18px}
@media(max-width:1150px){.garden-caption{top:33px;left:30px}.garden-caption h2{font-size:30px}.garden-caption .eyebrow{font-size:7px;letter-spacing:1px}.garden-caption>p:last-child{font-size:10px}}
@media(max-width:700px){.garden-caption{top:23px;left:23px}.garden-caption .eyebrow{font-size:6px;margin-bottom:8px}.garden-caption h2{font-size:23px;line-height:1.4;margin:0}.garden-caption h2 br{display:none}.garden-caption>p:last-child{display:none}.walk-outdoors .scene-badge{top:12px;right:19px;max-width:none}.walk-outdoors .scene-badge #time-label{display:none}.walk-outdoors .camera-toolbar{top:123px}.walk-outdoors .scene-stage{inset:95px 0 154px}}
@media(max-height:650px) and (min-width:701px){.garden-caption{top:22px}.garden-caption h2{font-size:26px}.garden-caption>p:last-child{display:none}}

/* A little clothbound photo album, opened from the room itself. */
#photo-album{width:860px;max-width:calc(100vw - 32px);max-height:92dvh;padding:24px 28px 16px;overflow-x:hidden;overflow-y:auto;background:#f6f2e7;border:1px solid #dbddcb;border-radius:20px;scrollbar-width:thin;scrollbar-color:#b0bc9c transparent}
#photo-album[open]{animation:arrive .3s ease}
.album-header{position:relative;display:flex;justify-content:space-between;align-items:flex-start;padding:0 46px 18px 3px;text-align:left}
.album-header .dialog-close{right:0;top:0;width:36px;height:36px}
.album-eyebrow{margin:0 0 4px;font-size:9px;letter-spacing:2px;color:#969e86}
.album-header h2{margin:0;font:500 27px/1.5 var(--serif);letter-spacing:1.5px;color:#53634b}
.album-header p:last-child{font-size:11px;margin:4px 0 0;color:#939980;letter-spacing:.5px}
.album-book{position:relative;padding:8px 10px 10px;border-radius:8px 12px 12px 8px;background:#9caa8a;box-shadow:0 3px 0 #7f906f,0 7px 0 -2px #d7ceba,0 15px 28px #58643e22}
.album-pages{position:relative;display:grid;grid-template-columns:1fr 1fr;height:clamp(270px,54dvh,460px);perspective:1700px;isolation:isolate;touch-action:pan-y}
.album-pages:focus-visible{outline:2px solid #bca672;outline-offset:3px;border-radius:3px}
.album-page{position:relative;min-width:0;min-height:0;box-sizing:border-box;padding:25px 25px 20px;background:#fcf9ef;overflow:hidden}
.album-note{border-radius:3px 0 0 3px;background:linear-gradient(90deg,#f8f4e8,#fcf9ef 86%,#e5dfcd);display:flex;flex-direction:column;justify-content:space-between;text-align:left}
.album-note-heading{display:flex;justify-content:space-between;align-items:center;gap:12px;color:#a2ae8d}
.album-kicker{font:9px var(--sans);letter-spacing:1.5px;color:#a1a58f}
.album-note-heading svg{width:33px;height:33px;transform:rotate(-14deg)}
.album-note h3{font:500 clamp(18px,2.5vw,25px)/1.8 var(--serif);letter-spacing:.5px;margin:0 0 22px;color:#61734f}
.album-note-copy{font:15px/2.2 var(--serif);white-space:pre-line;margin:0;color:#858d73}
.album-note-sign{font:11px/1.8 var(--serif);color:#a1a68f;border-top:1px dashed #d9ddc8;padding-top:16px}
.album-photo-page{border-radius:0 4px 4px 0;background:linear-gradient(90deg,#e4ddca,#faf7ec 7%,#fcf9ef 96%,#eae4d4);display:flex;flex-direction:column;gap:12px}
.album-photo{position:relative;display:flex;flex-direction:column;min-height:0;flex:1;margin:0;padding:12px 12px 8px;background:#fffefa;box-shadow:0 3px 12px #7c725322;transform:rotate(1.2deg);border:1px solid #efeadf}
.album-photo::before,.album-photo::after{content:'';position:absolute;z-index:1;top:-5px;width:43px;height:15px;background:#cfb5a388;transform:rotate(-22deg);left:-7px}
.album-photo::after{left:auto;right:-8px;transform:rotate(27deg);background:#bac5a388}
.album-photo-window{position:relative;min-height:0;flex:1;background:white;overflow:hidden}
.album-photo-window>svg{display:block;width:100%;height:100%;position:absolute;inset:0}
.album-photo figcaption{text-align:center;font:12px/1.7 var(--serif);color:#8d927b;padding:10px 0 1px}
.album-page-number{font-size:9px;letter-spacing:1px;text-align:right;color:#a6a992;line-height:1}
.album-mobile-title{display:none}
.album-photo-message{display:none;position:absolute;inset:0;align-items:center;justify-content:center;text-align:center;padding:20px;font-size:12px;color:#9da48e;background:#fffefa}
#photo-album[data-photo-state=loading] .album-photo-message,#photo-album[data-photo-state=error] .album-photo-message{display:flex}
#photo-album[data-photo-state=loading] .album-photo-message::before{content:'诺诺的照片正在打开…'}
#photo-album[data-photo-state=error] .album-photo-message::before{content:'照片暂时没打开，合上相册再试一次。'}
.album-turn-sheet{position:absolute;z-index:4;inset:0 0 0 50%;transform-origin:left center;transform-style:preserve-3d;pointer-events:none}
.album-turn-sheet.is-reverse{inset:0 50% 0 0;transform-origin:right center}
.album-turn-face{position:absolute;inset:0;backface-visibility:hidden;-webkit-backface-visibility:hidden;box-shadow:-5px 0 20px #605a4920}
.album-turn-back{transform:rotateY(180deg)}
.album-opening-cover{position:absolute;inset:0 0 0 50%;z-index:5;transform-origin:left center;backface-visibility:hidden;-webkit-backface-visibility:hidden;background:#a6b491;border:1px solid #8fa37b;border-radius:0 7px 7px 0;display:flex;flex-direction:column;align-items:center;justify-content:center;color:#f4ecd6;box-shadow:0 4px 20px #66704822}
.album-opening-cover::before{content:'';position:absolute;inset:16px;border:1px solid #d5ddba;border-radius:3px;pointer-events:none}
.album-opening-cover svg{width:70px;height:70px;margin-bottom:30px;transform:rotate(-12deg)}
.album-opening-cover strong{font:500 24px/1.7 var(--serif);letter-spacing:2px}
.album-opening-cover>span{font:9px var(--sans);letter-spacing:2px;margin-top:9px}
.album-controls{display:flex;align-items:center;justify-content:center;gap:25px;margin:24px 0 7px}
.album-controls button{display:flex;gap:9px;align-items:center;justify-content:center;min-height:40px;min-width:94px;padding:8px 13px;font-size:12px;color:#697d55;border:1px solid #d3dcc4;background:#fbfaf1;border-radius:24px;transition:background .2s}
.album-controls button:hover:not(:disabled){background:#e5ebd9}
.album-controls button:disabled{opacity:.36}
.album-controls button>span{font-size:18px;line-height:1}
.album-counter{font-size:11px;letter-spacing:1px;color:#939b82;min-width:70px;text-align:center}
.album-hint{text-align:center;font-size:9px;color:#a6ab96;letter-spacing:.6px;margin:6px 0 0}
@media(max-width:640px){
  #photo-album{padding:18px 16px 13px;max-width:calc(100vw - 24px);border-radius:17px}
  .album-header{padding-bottom:15px}.album-header h2{font-size:24px}.album-eyebrow{font-size:8px}.album-header p:last-child{font-size:10px}
  .album-book{padding:7px 8px 9px}.album-pages{grid-template-columns:1fr;height:clamp(260px,52dvh,430px);overflow:hidden}
  .album-pages>.album-note{display:none}.album-page{padding:23px 23px 14px}.album-photo-page{border-radius:3px;background:linear-gradient(90deg,#eae4d3,#fcf9ef 5%,#fcf9ef 97%,#eee7d6);gap:9px}
  .album-mobile-title{display:block;font:15px/1.5 var(--serif);text-align:center;margin:0;color:#718360}.album-photo{padding:10px 10px 7px;transform:rotate(.6deg)}
  .album-photo figcaption{font-size:11px;padding-top:8px}.album-page-number{position:absolute;right:13px;bottom:9px;font-size:8px}
  .album-turn-sheet,.album-turn-sheet.is-reverse,.album-opening-cover{inset:0}.album-opening-cover strong{font-size:23px}
  .album-controls{gap:13px;margin-top:21px}.album-controls button{min-height:42px;min-width:88px;font-size:11px}.album-counter{font-size:10px;min-width:65px}
}
@media(max-height:550px){#photo-album{padding-top:12px;padding-bottom:10px}.album-header{padding-bottom:12px}.album-header h2{font-size:22px}.album-header p:last-child,.album-eyebrow{display:none}.album-pages{height:clamp(180px,53dvh,290px)}.album-page{padding:16px 20px 12px}.album-note h3{font-size:18px;margin-bottom:10px}.album-note-copy{font-size:12px;line-height:1.8}.album-note-sign{display:none}.album-note-heading svg{width:20px;height:20px}.album-controls{margin-top:16px}.album-hint{display:none}}
