/* v159: fixed image viewport and compact, intrinsically sized controls. */
svg.line-icon{display:inline-block;width:16px!important;height:16px!important;min-width:16px;max-width:16px;max-height:16px;flex:0 0 16px;margin:0;vertical-align:middle;color:#222;}
#postcard-dialog{position:fixed;width:min(760px,96vw);max-height:92dvh;padding:0;overflow:hidden;border-radius:18px;}
#postcard-dialog>#close-postcard{position:absolute;inset:8px 8px auto auto;float:none;margin:0;width:36px;height:36px;min-width:0;min-height:0;display:grid;place-items:center;padding:0;background:#fffdf6;border:1px solid #dddccf;color:#222;font:24px/1 sans-serif;z-index:15;}
#postcard-content{max-height:92dvh;overflow-y:auto;overflow-x:hidden;overscroll-behavior:contain;scrollbar-width:thin;}
.postcard-topline{display:flex;min-height:50px;padding:12px 54px 12px 18px;gap:12px;align-items:center;justify-content:space-between;}
.postcard-topline .eyebrow{font-size:11px;letter-spacing:.6px;}.postcard-topline #postcard-step{font-size:10px;}
#postcard-first-hint{font-size:11px;line-height:1.55;margin:0;padding:0 18px 10px;}
.postcard-visual{position:relative;height:clamp(150px,44dvh,420px);width:100%;overflow:hidden;background:#eeeade;}
#postcard-flipper{width:100%;height:100%;min-height:0;max-height:100%;aspect-ratio:auto!important;display:block;margin:0;padding:0;}
#postcard-flipper .postcard-turn,#postcard-flipper .postcard-face{width:100%;height:100%;}
#postcard-flipper img,#postcard-real-image{width:100%!important;height:100%!important;max-width:100%!important;max-height:100%!important;object-fit:contain!important;}
.postcard-image-label{font-size:10px;max-width:75%;padding:5px 8px;}
.photo-place{display:none;}.photo-credit-toggle{font-size:10px;min-height:30px;max-width:85%;padding:4px 8px;left:10px;bottom:8px;}
#postcard-dialog[data-view="letter"] .postcard-visual{display:none;}
.postcard-nav{padding:8px 16px 0;gap:8px;align-items:center;}
.postcard-nav button,.notebook-postcard-back,.postcard-share-button,.stamp-share{display:inline-flex;align-items:center;justify-content:center;gap:5px;width:auto;max-width:100%;min-width:0;min-height:36px;padding:5px 9px;border:1px solid #d8dccf;border-radius:8px;background:transparent;color:#222;font:12px/1.3 system-ui,sans-serif;}
.notebook-postcard-back{margin:8px 52px 0 16px;font-size:11px;}.postcard-nav button svg{width:14px!important;height:14px!important;min-width:14px;flex-basis:14px;}
#postcard-dialog .postcard-tools{display:flex;justify-content:flex-end;padding:4px 16px 0;}.postcard-share-button{float:none!important;margin:0!important;font-size:11px;}
#postcard-tap-hint,.photo-context{font-size:10px;line-height:1.55;padding:0 16px;margin:8px 0;}.photo-years{padding:0 16px;gap:6px;}.photo-years button{font-size:10px;min-height:30px;padding:4px 8px;}
.photo-credit{padding:10px 16px;font-size:10px;overflow-wrap:anywhere;}
.postcard-copy{padding:12px 18px 22px!important;clear:both;}.postcard-copy .postcard-letter-title{font:500 18px/1.4 Georgia,serif;margin:4px 0 12px;}.postcard-copy .wolf-letter{font-size:14px!important;line-height:1.8;margin:0 0 16px;white-space:pre-line;}.postcard-review{margin:0 0 12px;}.postcard-review button{font-size:10px;min-height:30px;padding:5px 8px;}
/* Replace native coloured/emoji disclosure marks with one black CSS chevron. */
summary{list-style:none;}summary::-webkit-details-marker{display:none;}summary::marker{content:'';}summary::before{content:'';display:inline-block;width:6px;height:6px;border-right:1.5px solid #222;border-bottom:1.5px solid #222;transform:rotate(-45deg);margin:0 9px 1px 2px;}details[open]>summary::before{transform:rotate(45deg);margin-bottom:3px;}
.chinese-discovery{padding:11px 12px;margin-top:14px;}.chinese-discovery>summary{color:#222;font-size:12px;}
.return-stamp{gap:8px;}.return-stamp img{width:44px;height:44px;}.return-stamp .stamp-share{margin-left:auto;}.stamp-share{width:36px;height:36px;padding:7px;}.city-source{color:#222;font-size:11px!important;gap:5px;}
.share-dialog{position:fixed;width:min(500px,94vw);padding:18px;max-height:92dvh;border-radius:16px;}.share-dialog>.close{position:absolute;right:8px;top:8px;width:34px;height:34px;margin:0;padding:0;color:#222;}.share-dialog h2{font-size:18px;margin:4px 35px 14px 0;}#share-preview{width:100%;aspect-ratio:4/3;height:auto;max-height:48dvh;object-fit:contain;margin:0 auto 8px;background:#f7f4eb;}.share-actions{gap:6px;padding:8px 0;}.share-actions button{font-size:11px;min-height:36px;padding:7px 8px;color:#222;}#share-status{font-size:11px;line-height:1.6;margin:6px 0;}.share-dialog>small{font-size:10px;line-height:1.6;}
@media(max-width:540px){.postcard-visual{height:clamp(145px,40dvh,320px);}.postcard-topline{padding-left:14px;}.postcard-nav{padding:7px 12px 0;}.postcard-copy{padding:10px 14px 20px!important;}.postcard-copy .postcard-letter-title{font-size:17px;}.postcard-nav button{font-size:11px;min-height:34px;padding:5px 8px;}.postcard-nav button span{font-size:10px;}.share-dialog{padding:15px;}.share-actions button{font-size:11px;}}

.postcard-loading>img{height:40dvh;max-height:320px;aspect-ratio:auto;object-fit:contain;background:#eeeade;}#postcard-dialog button,#postcard-share button,#travel-album button,#prepare-trip button,.host-games-back{color:#222;}
/* v160 fixed viewport; image and stamp constraints override every legacy rule. */
#postcard-dialog .postcard-topline{display:flex!important;flex-direction:row!important;gap:7px;padding:12px 48px 10px 14px;min-height:44px;}#postcard-dialog .postcard-topic{font-size:11px;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}#postcard-step{white-space:nowrap;margin-left:auto;}#postcard-first-hint,#postcard-tap-hint,#photo-years,#photo-context,.postcard-tools,.postcard-review{display:none!important;}
#postcard-dialog:not([data-view="letter"]) #postcard-content{height:min(76dvh,680px);display:flex;flex-direction:column;}#postcard-dialog:not([data-view="letter"]) .postcard-visual{flex:1;min-height:140px;height:auto!important;}#postcard-dialog:not([data-view="letter"]) .postcard-nav{display:none!important;}#postcard-dialog .photo-credit:not([hidden]){position:absolute;bottom:12px;left:12px;right:12px;z-index:12;background:#fffdf5;max-height:50dvh;overflow:auto;border:1px solid #d9d9cd;border-radius:10px;padding:12px;}
.visual-arrow,.image-share{position:absolute;z-index:5;display:grid!important;place-items:center;padding:8px!important;min-width:36px!important;min-height:36px!important;width:36px!important;height:36px!important;border:1px solid #ddd9ca;background:#fffdf3e8!important;border-radius:50%;color:#222!important;}.visual-arrow{top:45%;}.visual-prev{left:7px;}.visual-next{right:7px;}.image-share{bottom:8px;right:8px;}.image-share svg,.visual-arrow svg{width:15px!important;height:15px!important;}.photo-credit-toggle{z-index:6;max-width:calc(100% - 65px);}.postcard-image-label{display:none;}
#postcard-dialog[data-view="letter"] .postcard-topline{padding-bottom:4px;}#postcard-dialog[data-view="letter"] .postcard-nav{padding:4px 14px;}#postcard-dialog[data-view="letter"] .postcard-nav button{border:0;padding:4px;min-height:30px;}.letter-picture{position:relative;margin-bottom:14px;background:#eeeade;border-radius:9px;overflow:hidden;}.letter-picture>button:first-child{display:block;width:100%;padding:0;border:0;background:none;}.letter-picture img{display:block!important;width:100%!important;height:24dvh!important;max-height:240px!important;object-fit:contain!important;}.return-stamp{display:flex!important;flex-direction:row!important;align-items:center;gap:10px;width:100%;margin:18px 0;padding:10px;border:1px solid #dfdece;border-radius:10px;}.return-stamp>img{width:56px!important;height:56px!important;max-width:56px!important;object-fit:contain!important;flex:0 0 56px;cursor:zoom-in;}.return-stamp>span{font-size:12px;flex:1;}.return-stamp small{display:block;font-size:10px;margin-top:4px;}.return-stamp .stamp-share{margin:0!important;flex:0 0 36px;}#keepsake-detail>.keepsake-art{display:block;width:100%!important;height:30dvh!important;object-fit:contain!important;max-height:280px;}
#postcard-dialog .chinese-discovery>summary::before{content:''!important;width:6px;height:6px;border-right:1.5px solid #222;border-bottom:1.5px solid #222;display:inline-block;transform:rotate(-45deg);}#postcard-dialog details[open].chinese-discovery>summary::before{transform:rotate(45deg);}
#postcard-share{box-sizing:border-box!important;width:min(480px,94vw)!important;max-width:94vw!important;overflow-x:hidden!important;padding:16px!important;}#postcard-share #share-preview{box-sizing:border-box;display:block!important;width:100%!important;max-width:100%!important;height:48dvh!important;max-height:48dvh!important;aspect-ratio:auto!important;object-fit:contain!important;margin:0!important;}#postcard-share .share-actions{display:flex;gap:5px;}#postcard-share .share-actions button{min-width:0;flex:1;padding:7px 5px;font-size:11px;}#postcard-share>small{font-size:10px;}
.wolf-image-viewer{position:fixed;width:100vw;max-width:100vw;height:100dvh;max-height:100dvh;margin:0;padding:0;border:0;background:#181a17f5;overflow:hidden;}.viewer-close{position:absolute;right:12px;top:max(12px,env(safe-area-inset-top));z-index:3;width:40px;height:40px;border:0;border-radius:50%;font-size:25px;background:#fffaf0;color:#222;}.viewer-surface{width:100%;height:100%;display:flex;align-items:center;justify-content:center;overflow:hidden;touch-action:none;}.viewer-surface img{display:block!important;width:100%!important;height:100%!important;max-width:100%!important;max-height:100%!important;object-fit:contain!important;transform-origin:center;pointer-events:none;}
