/* Receipt viewer is independent of business forms and their modal lifecycle. */
.wh-receipt-viewer{width:min(1280px,calc(100vw - 48px));height:min(1000px,calc(100dvh - 48px));max-width:none;max-height:none;margin:auto;padding:0;border:1px solid var(--jade-line);border-radius:22px;background:var(--jade-surface);color:var(--jade-ink);font-family:var(--jade-font);box-shadow:0 24px 80px #10291f40;overflow:hidden}
.wh-receipt-viewer[open]{display:flex;flex-direction:column}
.wh-receipt-viewer::backdrop{background:#10291fba}
.wh-receipt-head{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:17px 24px;border-bottom:1px solid var(--jade-line);flex:none}
.wh-receipt-head>div{min-width:0}.wh-receipt-head h2{font-size:21px;font-weight:600;margin:0}.wh-receipt-head p{font-size:14px;line-height:1.5;margin:4px 0 0;color:var(--jade-muted);overflow-wrap:anywhere}
.wh-receipt-viewer button,.wh-receipt-viewer a{font:inherit;font-size:14px;min-height:44px;padding:9px 14px;border:1px solid var(--jade-line);border-radius:11px;background:var(--jade-surface);color:var(--jade-brand);cursor:pointer;display:inline-flex;justify-content:center;align-items:center;text-decoration:none}
.wh-receipt-viewer button:hover,.wh-receipt-viewer a:hover{background:var(--jade-brand-soft)}.wh-receipt-viewer button:disabled{opacity:.45;cursor:default}.wh-receipt-viewer [data-wh-close]{min-height:48px;flex:none;background:var(--jade-brand);color:#fff;border:0}
.wh-receipt-tools{display:flex;align-items:center;justify-content:center;gap:10px;padding:10px 16px;flex:none;border-bottom:1px solid var(--jade-line);flex-wrap:wrap}.wh-receipt-tools [data-wh-scale]{min-width:54px;font:14px var(--jade-font-data);text-align:center}.wh-receipt-tools [data-wh-minus],.wh-receipt-tools [data-wh-plus]{min-width:44px;font-size:20px}
.wh-receipt-status{flex:1;min-height:0;display:flex;align-items:center;justify-content:center;flex-direction:column;gap:20px;padding:24px;text-align:center;font-size:16px;color:var(--jade-muted)}
.wh-receipt-body{flex:1;min-height:0;min-width:0;overflow:auto;background:var(--jade-canvas);overscroll-behavior:contain}
.wh-receipt-canvas{display:flex;min-height:100%;min-width:100%;width:max-content;padding:16px;box-sizing:border-box}.wh-receipt-stage{position:relative;margin:auto;flex:none}.wh-receipt-viewer img.wh-receipt-image{position:absolute;left:50%;top:50%;max-width:none;max-height:none;object-fit:contain;transform-origin:center;user-select:none}
.wh-receipt-pdf{display:block;width:100%;height:100%;border:0}.wh-receipt-pdf p{padding:24px;color:var(--jade-muted)}
.wh-receipt-foot{display:flex;align-items:center;justify-content:space-between;gap:16px;flex:none;padding:10px 24px;border-top:1px solid var(--jade-line);font-size:13px;line-height:1.6;color:var(--jade-muted)}.wh-receipt-foot a{flex:none}
.wh-receipt-viewer [hidden]{display:none!important}.wh-receipt-viewer :focus-visible{outline:2px solid var(--jade-focus);outline-offset:3px}
.rb-page button.rb-attachment-preview{display:block;width:100%;padding:0;border:0;text-align:center;cursor:zoom-in}
@media(max-width:760px){.wh-receipt-viewer{width:100%;height:100dvh;border:0;border-radius:0}.wh-receipt-head{padding:calc(12px + env(safe-area-inset-top,0px)) 16px 12px;gap:12px}.wh-receipt-head h2{font-size:20px}.wh-receipt-head p{font-size:13px}.wh-receipt-viewer button,.wh-receipt-viewer a{font-size:14px;padding-inline:12px}.wh-receipt-tools{padding:8px 16px;gap:8px}.wh-receipt-tools [data-wh-scale]{min-width:42px}.wh-receipt-foot{padding:10px 16px calc(10px + env(safe-area-inset-bottom,0px));gap:10px}.wh-receipt-foot span{min-width:0}.wh-receipt-foot a{font-size:13px;padding-inline:10px}}
