/* The last frame is a personal photo print, with an optional local editor. */
.theater[data-node="ending"] .scene-image{filter:blur(13px) brightness(.43);transform:scale(1.12)}
.theater[data-node="ending"] .scene-top,.theater[data-node="ending"] .scene-bottom,.theater[data-node="ending"] .panel-heading,.theater[data-node="ending"] .progress,.theater[data-node="ending"] .panel-foot{display:none}
.keepsake-display{position:absolute;left:53px;right:53px;top:96px;pointer-events:auto}
.keepsake-print{display:block;position:relative;width:100%;padding:0;background:#f7faf5;box-shadow:0 22px 50px #0006;transform:rotate(-1.5deg);border-radius:1px;transition:transform .2s}
.keepsake-print:hover{transform:rotate(0deg) translateY(-2px)}
.keepsake-print canvas{display:block;width:100%;height:auto;aspect-ratio:3/4}
.keepsake-edit-cue{position:absolute;bottom:-26px;left:0;right:0;text-align:center;color:#c6d7c7;font-size:9px;letter-spacing:.04em}
.theater[data-node="ending"] .interaction{max-height:24%;padding:15px 26px 16px;overflow:auto;background:linear-gradient(transparent,#08181bd9 25%,#08181bf5)}
.keepsake-caption>small{font-size:9px;color:#acd9c0;letter-spacing:.1em}
.keepsake-caption h2{font-size:15px;font-weight:500;line-height:1.5;margin:5px 0 12px;color:#e8f3e9}
.theater[data-node="ending"] .end-links{margin:0;gap:9px}
.theater[data-node="ending"] .end-links button{min-height:42px;padding:10px 12px;font-size:11px}
.ending-extras{display:flex;justify-content:space-between;gap:8px;margin-top:8px;align-items:flex-start}
.ending-extras .text-link,.finish-memo summary{font-size:9px;padding:6px 0;white-space:nowrap;color:#a8c4b2;cursor:pointer}
.finish-memo{font-size:10px;line-height:1.8;color:#bdd3c4}
.finish-memo[open]{flex:1;min-width:0}
.finish-memo .end-record{font-size:10px;padding:11px;margin-top:6px;white-space:normal;border-radius:8px;background:#153126}
.finish-memo .end-record p{margin:0}
.finish-memo .personal-note{margin-top:8px!important;border-top:1px solid #b6d6bd33;padding-top:8px}
dialog.keepsake-dialog{background:#f2f6ee;color:#31533b;border:1px solid #cfdbca;border-radius:17px;padding:21px;width:390px;max-height:690px;overflow:auto;scrollbar-width:thin;color-scheme:light}
.keepsake-dialog .modal-heading{margin-bottom:15px;align-items:flex-start}
.keepsake-dialog .modal-heading small{color:#839a7d;font-size:9px;letter-spacing:.12em}
.keepsake-dialog .modal-heading h2{color:#2d5037;font-size:21px;font-weight:550;margin:8px 0 0}
.keepsake-dialog .icon-button{background:#e3ecde;color:#4d6a4b;width:30px;height:30px;font-size:20px}
.keepsake-photo-row{display:grid;grid-template-columns:116px minmax(0,1fr);gap:18px;align-items:center;margin:0 0 16px}
.keepsake-editor-canvas{display:block;width:116px;height:auto;aspect-ratio:3/4;box-shadow:0 7px 18px #50704d22;touch-action:none;cursor:grab}
.keepsake-editor-canvas:active{cursor:grabbing}
.keepsake-photo-actions>p{font-size:11px;line-height:1.8;margin:0 0 11px;color:#6c8568}
.keepsake-upload{display:block;width:100%;min-height:39px;padding:9px;background:#315d44;color:#f2f7ec;border-radius:20px;font-size:10px}
.keepsake-restore{display:block;background:none;padding:9px 0 0;color:#85997e;font-size:9px}
.keepsake-form{display:grid;gap:12px}
.keepsake-name-row{display:grid;grid-template-columns:1fr 1fr;gap:11px}
.keepsake-form label,.keepsake-zoom{display:grid;gap:6px;color:#6e856a;font-size:10px}
.keepsake-form input:not([type="range"]){width:100%;min-width:0;height:39px;border:1px solid #d8e1d2;background:#fbfdf8;color:#31523b;border-radius:7px;padding:8px 10px;font-size:12px}
.keepsake-form input::placeholder{color:#a3b09b}
.keepsake-zoom{margin-top:12px;grid-template-columns:auto minmax(0,1fr);gap:15px;align-items:center}
.keepsake-zoom input{width:100%;accent-color:#6e9e7c}
.keepsake-framing{display:flex;align-items:center;gap:8px;margin-top:12px;color:#6e856a;font-size:10px}
.keepsake-framing>span{margin-right:auto}
.keepsake-framing button{padding:6px 10px;border-radius:14px;border:1px solid #ceddca;background:transparent;color:#70896b;font-size:9px}
.keepsake-framing button[aria-pressed="true"]{background:#d9e9d4;color:#355c3e;border-color:#a9c5a5}
.keepsake-status{font-size:9px;line-height:1.8;color:#81967c;margin:11px 0 13px;min-height:16px}
.keepsake-dialog .primary{background:#315d44;color:#eff7e9;min-height:42px}
@media(prefers-reduced-motion:reduce){.keepsake-print{transition:none}}

/* Reflection is a main-route pause, then stays visible beside the keepsake. */
.theater[data-node="memory"] .interaction{max-height:78%;overflow:auto;background:linear-gradient(transparent,#08181bf0 10%);padding-top:26px}
.theater[data-node="memory"] .panel-foot{display:none}
.reflection-sheet{background:#f4f3e9;color:#31503d;border-radius:5px 18px 18px 5px;padding:20px;margin:12px 0 15px;box-shadow:0 12px 32px #0002;border-left:3px solid #b4cfb5}
.reflection-label{font-size:10px;letter-spacing:.1em;color:#738672}
.reflection-intro{font-size:13px;line-height:1.8;margin:12px 0 16px}
.reflection-prompts{display:grid;gap:8px;padding-bottom:16px;border-bottom:1px solid #cdd9c8;font-size:12px}
.reflection-prompts b{font-size:10px;color:#829d81;margin-right:10px;font-weight:400}
.reflection-input-label{display:block;font-size:11px;margin:15px 0 8px;color:#617c61}
.reflection-sheet .memory-input{background:repeating-linear-gradient(transparent,transparent 29px,#d8dfd3 30px);border:0;border-radius:0;min-height:150px;padding:0;color:#294937;line-height:30px;font-size:16px;resize:vertical}
.reflection-sheet .memory-input::placeholder{color:#93a28d}
.reflection-sheet .memory-input:focus{outline:2px solid #83b8a0;outline-offset:4px}
.reflection-meta{display:flex;gap:10px;justify-content:space-between;color:#81917a;margin-top:10px;font-size:10px}
.reflection-meta small{font-size:10px}.reflection-meta span{white-space:nowrap}
.reflection-save{width:100%}.reflection-skip{display:block;margin:8px auto 0;min-height:38px}
.theater[data-node="ending"] .keepsake-display{left:85px;right:85px;top:82px}
.theater[data-node="ending"] .interaction{max-height:43%;padding-top:24px;overflow:auto}
.reflection-saved{border-left:2px solid #a7dfc6;padding:2px 0 2px 13px;margin:0 0 14px}
.reflection-saved>small{font-size:10px;color:#a7cbb4;letter-spacing:.08em}
.reflection-saved h2{font-size:15px;margin:10px 0;color:#e4f0e7}
.reflection-saved .personal-note{font-size:13px;line-height:1.8;white-space:pre-wrap;overflow-wrap:anywhere;margin:9px 0;color:#e6f0e7;max-height:130px;overflow:auto}
.reflection-saved .text-link{padding:4px 0;font-size:11px;color:#b2e7d0}
.reflection-saved .primary{margin-top:6px;min-height:42px;width:100%}
