:root{--plum:#635078;--ink:#282431;--muted:#696371;--line:#ded9e4;--wash:#f2edf6;--danger:#9c3543;--green:#28634b;font-family:-apple-system,BlinkMacSystemFont,"Noto Sans JP","Yu Gothic",Meiryo,sans-serif;color:var(--ink);background:#f5f3f6;font-synthesis:none}*{box-sizing:border-box}body{margin:0}a{color:#5b4077}button,input,select{font:inherit}button,.button,summary{touch-action:manipulation}button,.button{min-height:48px;border:1px solid #c6bdce;border-radius:10px;padding:10px 14px;color:var(--plum);background:#fff;font-weight:650;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;text-decoration:none;text-align:center;line-height:1.4}button:disabled{opacity:.48;cursor:default}.primary{background:var(--plum);color:white;border-color:var(--plum)}button:hover:not(:disabled),.button:hover{filter:brightness(.96)}button:focus-visible,a:focus-visible,summary:focus-visible{outline:3px solid #a685c2;outline-offset:3px}input,select{width:100%;min-width:0;min-height:48px;border:1px solid #c8c0cf;border-radius:8px;padding:10px 12px;font-size:16px;background:#fff;color:var(--ink)}input:focus,select:focus{outline:2px solid #9775b3;outline-offset:1px}label{display:grid;gap:6px;font-weight:650;font-size:14px}input[type=checkbox]{width:22px;height:22px;min-height:22px;accent-color:var(--plum);flex-shrink:0}h1{font-size:22px;line-height:1.4;margin:0}h2{font-size:20px}p{line-height:1.6;margin:10px 0}.top{background:#fff;border-top:4px solid var(--plum);border-bottom:1px solid var(--line);min-height:74px;padding:10px max(16px,calc((100vw - 1180px)/2));display:flex;align-items:center;gap:22px}.top>a{display:flex}.top img{width:180px;height:42px;object-fit:contain}.top form{margin-left:auto}.app-title{font-size:14px;color:var(--muted)}.quiet{border-color:transparent;background:transparent;padding:8px;min-height:44px}.danger{color:var(--danger)}main{max-width:1180px;padding:18px 20px 30px;margin:auto}.casebar{display:flex;gap:12px;align-items:center;margin-bottom:14px}.casebar>form{flex:1}.casebar details{position:relative}.casebar details[open]>form{position:absolute;right:0;top:40px;width:280px;background:#fff;padding:18px;border:1px solid var(--line);box-shadow:0 8px 30px #28243122;z-index:6}.casebar summary{font-size:14px;cursor:pointer;min-height:48px;display:flex;align-items:center;padding:8px}.tabs{display:grid;grid-template-columns:repeat(3,1fr);border:1px solid var(--line);border-radius:12px;background:#eae5ee;padding:4px;gap:4px;margin-bottom:16px}.tabs a{min-height:48px;display:grid;place-items:center;text-decoration:none;font-size:14px;color:#625a6d;border-radius:8px}.tabs [aria-current]{background:#fff;color:#553c70;box-shadow:0 1px 4px #20102819;font-weight:750}.panel{background:#fff;border:1px solid var(--line);border-radius:16px;padding:22px}.capture{max-width:690px;margin:auto}.section-title{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-bottom:12px}.eyebrow{font-size:12px;letter-spacing:.05em;color:var(--muted)}.badge{background:var(--wash);color:#5e4774;font-size:12px;padding:6px 9px;border-radius:6px;white-space:nowrap}.done{color:var(--green);background:#e8f2ec}.muted{color:var(--muted)}.small,small{font-size:12px;font-weight:400}.full{width:100%}.capture-controls{display:flex;gap:8px;margin:12px 0}.capture-controls .primary{flex:1;min-height:54px;font-size:17px}.capture-meta{display:flex;align-items:center;gap:12px}.capture-meta>label:first-child{flex:1}.sound,.check{display:flex;align-items:center;gap:9px;min-height:48px}.sound{font-size:13px}.file-actions{display:flex;gap:8px;margin-top:12px}.file-actions button{flex:1;font-size:14px}.camera-frame{position:relative;background:#24202b;overflow:hidden;border-radius:12px;height:min(38vh,320px)}.camera-frame video{width:100%;height:100%;object-fit:contain}.guide{position:absolute;inset:8% 22%;border:1px dashed #ffffff99;border-radius:6px;pointer-events:none}.camera-hint{position:absolute;bottom:8px;left:0;right:0;color:#fff;text-align:center;font-size:12px}#flash{position:absolute;inset:0;background:#fff;opacity:0;pointer-events:none}#flash.active{animation:flash .3s ease}@keyframes flash{from{opacity:.8}to{opacity:0}}.upload-list{display:grid;gap:8px;margin:10px 0;max-height:300px;overflow:auto}.upload-item{display:grid;grid-template-columns:54px 1fr auto;align-items:center;gap:8px;padding:8px;border:1px solid var(--line);border-radius:10px}.upload-item img{width:54px;height:64px;object-fit:contain;background:var(--wash);border-radius:5px}.upload-item strong{display:block;font-size:13px}.upload-item .status{font-size:12px;line-height:1.5;overflow-wrap:anywhere}.upload-item[data-state=failed]{border-color:#c48185;background:#fff7f7}.upload-item[data-state=done] .status{color:var(--green)}.upload-item button{padding:6px 8px;font-size:12px;min-height:44px}.capture-bottom{display:grid;gap:8px;margin-top:14px}.capture-bottom .primary{min-height:54px;font-size:16px}.notice,.warning,.error{padding:10px 12px;border-radius:8px;background:#fff5de;color:#765319;overflow-wrap:anywhere}.error{background:#fff0f1;color:#8e2938}.notice{margin:12px 0;border:1px solid #e2c58a}.review-layout{display:grid;grid-template-columns:240px minmax(0,1fr);gap:16px;align-items:start}.entry-index h1{font-size:18px}.review-body{display:grid;grid-template-columns:42% minmax(0,1fr);gap:22px}.photo-side{min-width:0;position:sticky;top:12px;align-self:start}.photo-strip{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;max-height:65vh;overflow:auto}.photo-card{border:1px solid var(--line);border-radius:8px;text-align:center;overflow:hidden;background:var(--wash);font-size:12px}.zoom-photo{padding:4px;border:0;border-radius:0;width:100%;background:transparent}.zoom-photo img{width:100%;height:150px;object-fit:contain}.photo-card>span{display:block}.photo-card form{display:inline-block}.field{margin:12px 0 4px}.field small{color:var(--danger);margin-left:5px}.candidate-list{display:flex;flex-wrap:wrap;gap:5px}.candidate-list p{width:100%}.candidate{min-height:44px;text-align:left;font-size:13px;white-space:normal}.check{margin:14px 0;font-size:13px;font-weight:500}.confirm-bottom{position:sticky;bottom:0;background:#fff;padding:10px 0 max(10px,env(safe-area-inset-bottom));z-index:2}.confirm-bottom button{min-height:54px}.add-photo{margin:8px 0}.tools{border-top:1px solid var(--line);margin-top:16px;padding-top:16px}.tools summary,.export summary{min-height:44px;cursor:pointer;font-size:14px}.tools form{margin:8px 0}pre{white-space:pre-wrap;overflow-wrap:anywhere;font-size:13px;background:var(--wash);padding:12px}.export{margin-top:20px;padding:12px 18px}.empty{text-align:center;padding:40px 18px}.login{max-width:440px;margin:50px auto}.login label{margin:20px 0}footer{text-align:center;color:var(--muted);font-size:11px;padding:16px}.ocr-actions{display:flex;gap:6px;flex-wrap:wrap}.ocr-actions button{font-size:12px;min-height:44px}dialog{width:min(100vw,1000px);max-width:100vw;height:92dvh;max-height:96dvh;padding:12px;border:0;border-radius:12px;background:#f5f3f6}dialog::backdrop{background:#181221b8}.dialog-tools{display:flex;justify-content:flex-end;gap:8px;margin-bottom:8px}.zoom-scroll{overflow:auto;height:calc(100% - 60px);touch-action:pan-x pan-y pinch-zoom}.zoom-scroll img{width:100%;max-width:none;display:block}.sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}[hidden]{display:none!important}@media(max-width:760px){main{padding:12px 12px 20px}.top{padding:8px 12px;gap:8px;min-height:64px}.top img{width:150px;height:36px}.app-title{display:none}.panel{padding:16px;border-radius:12px}.casebar{margin-bottom:10px;gap:6px}.tabs{margin-bottom:12px}.review-layout{grid-template-columns:1fr;gap:12px}.entry-index{padding:12px 14px}.entry-index .section-title{margin-bottom:8px}.entry-index p{display:none}.review-body{grid-template-columns:1fr;gap:8px}.photo-side{position:static}.photo-strip{display:flex;gap:8px;overflow-x:auto;max-height:none;padding-bottom:4px}.photo-card{flex:0 0 95px}.zoom-photo img{height:92px}.photo-side>p{margin:4px 0}.field{margin-top:10px}.fields-side{min-width:0}.section-title h1{font-size:20px}.camera-frame{height:min(33vh,260px)}.eyebrow{font-size:11px}.capture .section-title{flex-wrap:wrap}.capture-bottom{padding-bottom:env(safe-area-inset-bottom)}.login{margin:25px auto}.check{align-items:flex-start;padding-top:10px}.photo-card .quiet{min-height:44px}.capture h1{font-size:23px}#ocr-status{margin:6px 0}.field-address input{font-size:16px}}@media(prefers-reduced-motion:reduce){*{animation:none!important;scroll-behavior:auto!important}}

/* v0.12: task-oriented mobile workspace */
:root{font-size:16px;--plum:#63467e;--wash:#f4eff8;--ink:#292231}body{background:#f8f6f9}label,.small,small,.badge,.eyebrow,.tabs a,.casebar summary,.app-title,.file-actions button,.upload-item strong,.upload-item .status,.upload-item button,.candidate,.check,.tools summary,.export summary,.ocr-actions button,pre{font-size:16px}.quiet,.candidate,.photo-card .quiet,.ocr-actions button,.tools summary,.export summary{min-height:48px}.panel{box-shadow:0 3px 18px #38214605}.capture h1{font-size:26px;letter-spacing:.02em}.section-title{flex-wrap:wrap}.eyebrow{letter-spacing:0}.badge{white-space:normal}h1{font-size:24px}.capture-options{margin:10px 0}.capture-options summary,.secondary-fields summary,.history summary{padding:12px 0;min-height:48px;cursor:pointer;color:var(--plum);font-weight:650}.capture-options[open]{border-bottom:1px solid var(--line);padding-bottom:12px}.capture-controls{position:sticky;bottom:102px;z-index:4;background:#fff;padding:8px 0}.capture-controls .primary{min-height:60px;font-size:20px;border-radius:16px}.capture-bottom{position:sticky;bottom:0;z-index:4;background:#fff;padding:10px 0 max(10px,env(safe-area-inset-bottom));grid-template-columns:1fr 1.3fr;gap:8px;border-top:1px solid var(--line)}.capture-bottom button{font-size:18px;min-height:60px}.camera-frame{height:min(39dvh,370px);border-radius:16px}.camera-hint{font-size:16px;background:#20172c99;padding:5px}.guide{border:2px solid #ffffffb3;inset:7% 15%}.upload-list{display:flex;overflow-x:auto;max-height:220px;scroll-snap-type:x proximity;gap:8px}.upload-item{flex:0 0 160px;display:flex;flex-direction:column;align-items:stretch;padding:8px;scroll-snap-align:start}.upload-item img{width:100%;height:80px;cursor:zoom-in}.upload-item strong{display:none}.upload-item .status{font-size:16px;line-height:1.35}.upload-item>div:last-child{display:flex;gap:4px;margin-top:auto}.upload-item button{min-height:48px;flex:1}.capture .muted{margin:6px 0}.review-layout{grid-template-columns:190px minmax(0,1fr)}.review-body{grid-template-columns:45% minmax(0,1fr);gap:20px}.photo-strip{display:flex;flex-direction:column;max-height:75dvh}.photo-card{flex-shrink:0}.zoom-photo img{height:270px}.photo-card span{font-size:16px}.field-name input,.field-amount input{font-size:22px;font-weight:650;min-height:56px}.field-name,.field-amount{font-size:18px}.secondary-fields{margin-top:12px;border-top:1px solid var(--line);border-bottom:1px solid var(--line)}.candidate{min-height:48px;display:block;width:100%;font-size:18px}.candidate small{display:block;color:var(--muted);font-size:16px}.confirm-bottom button{font-size:18px}.history{border-top:1px solid var(--line);margin-top:16px}.history article{font-size:16px;padding:10px 0;border-bottom:1px solid var(--line);overflow-wrap:anywhere}.history p{margin:4px 0}.notice{position:relative;z-index:7}.capture-toast{position:fixed;bottom:174px;left:50%;transform:translateX(-50%);max-width:calc(100vw - 24px);background:#285d49;color:#fff;padding:12px 20px;border-radius:12px;box-shadow:0 6px 30px #0003;z-index:20;font-size:18px;pointer-events:none}.top img{width:165px}footer{font-size:14px}.field-address input{min-height:52px}.field-postal_code input{min-height:52px;max-width:220px;letter-spacing:.025em}.entry-index h1{font-size:18px}.ocr-actions{margin:8px 0}.photo-side{top:12px}button,.button{overflow-wrap:anywhere}#notice:empty{display:none}
@media(max-width:760px){main{padding:10px 10px 24px}.panel{padding:14px}.top{min-height:60px}.tabs{margin-bottom:10px}.tabs a{font-size:16px}.casebar select{font-size:16px}.review-layout{grid-template-columns:1fr;gap:8px}.entry-index{padding:10px 12px;display:flex;gap:10px;align-items:center}.entry-index .section-title{margin:0;flex-shrink:0}.entry-index h1{display:none}.entry-index select{flex:1;width:0}.review-body{display:block}.photo-side{position:sticky;top:0;background:#fff;z-index:3;border-bottom:1px solid var(--line);margin:0 -4px;padding:4px}.photo-strip{flex-direction:row;max-height:174px;gap:6px;overflow-x:auto}.photo-card{flex:0 0 108px}.zoom-photo img{height:92px}.photo-card>span{font-size:16px;line-height:1.3}.photo-card .remove-photo{display:block}.photo-side>p{font-size:16px;margin:2px 0}.fields-side{padding-top:8px}.review .section-title{margin-bottom:6px}.capture .section-title{margin-bottom:8px}.capture .eyebrow{font-size:16px}.capture-meta{align-items:end}.sound{font-size:16px}.camera-frame{height:34dvh}.camera-hint{font-size:16px}.capture-controls{bottom:86px}.capture-bottom{margin-top:10px}.capture-bottom button{font-size:18px;padding:10px 8px}.upload-list{max-height:190px}.upload-item{flex-basis:145px}.upload-item img{height:65px}.check{font-size:16px;align-items:center}.confirm-bottom{position:sticky;bottom:0;padding-bottom:max(10px,env(safe-area-inset-bottom));z-index:4}.ocr-actions button{flex:1}.photo-card[data-selected]{outline:2px solid var(--plum)}.review{padding:12px}.capture h1{font-size:24px}.history article{font-size:16px}.dialog-tools button{padding:8px}.capture-options summary{font-size:16px}}

.zoom-canvas{position:relative;width:100%;min-width:100%}.zoom-canvas>img{width:100%}#vision-boxes{position:absolute;inset:0;width:100%;height:100%;pointer-events:none}.photo-card .remove-photo button{width:100%}.photo-strip{max-height:80dvh}@media(max-width:760px){.photo-strip{max-height:222px}.photo-card .zoom-photo img{height:78px}.photo-card .remove-photo button{padding:6px}}

/* Compact review: no duplicate controls for a unique suggestion. */
.source-note{margin:2px 0 6px;font-size:16px;color:var(--muted);line-height:1.4}.field>span{font-size:18px}.field small{display:inline;margin-left:10px}.confirm-bottom{border-top:1px solid var(--line);box-shadow:0 -8px 12px #fff}.confirm-bottom .check{margin:0 0 6px;min-height:48px}.secondary-fields>summary{font-size:18px}.photo-card>span{padding:2px 4px}.ocr-actions:has(button[hidden]){margin:0}#ocr-status{font-size:16px;line-height:1.4;padding:8px 10px}.sound{font-size:16px}
@media(max-width:760px){.photo-strip{max-height:132px}.photo-card{flex-basis:116px}.photo-card>span{font-size:16px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.photo-card .zoom-photo img{height:78px}.photo-side{padding:4px 0}.field{margin-top:8px}.confirm-bottom{margin-top:10px}.review-body .source-note{font-size:16px}.review .section-title{margin-bottom:4px}}

.primary-fields{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,1fr);gap:10px}.field-group{min-width:0}.source-note{overflow-wrap:anywhere}.confirm-bottom{position:static}.field-name input,.field-amount input{font-size:20px;padding:10px}.photo-side .zoom-photo{min-height:48px}
@media(max-width:760px){.top{min-height:56px;padding:6px 10px}.top img{height:30px}.entry-index{padding:6px 10px}.entry-index .badge{display:none}.review .section-title h1{font-size:20px}.photo-card .zoom-photo img{height:66px}.photo-strip{max-height:112px}.review .badge{font-size:16px}.fields-side{padding-top:4px}.confirm-bottom{padding-bottom:10px}.secondary-fields{margin-top:6px}.primary-fields .candidate-list{display:block}.primary-fields .candidate{font-size:16px;padding:8px}.primary-fields .source-note{font-size:16px}.review #ocr-status{margin:4px 0}.entry-index .section-title{display:none}}

.gpt-banner{display:flex;align-items:center;gap:12px;flex-wrap:wrap}.gpt-banner p{width:100%;margin:0}.gpt-banner .button{margin-left:auto}.ocr-actions{display:flex;flex-wrap:wrap;gap:8px}

/* v0.14: approved three-stage mobile workflow: current bag -> capture -> confirm */
:root{--plum:#624771;--plum-deep:#4d365f;--lav:#f1ecf4;--ink:#262331;--muted:#686272;--line:#e4dfe8;--green:#28614d;--cream:#faf6e8}
body{background:#f7f5f8;color:var(--ink)}
.v14-capture{max-width:850px;padding:0;overflow:visible;border-radius:16px}
.bag-hero{background:linear-gradient(115deg,#574063,#755b83);border-radius:15px 15px 0 0;color:white;padding:20px 20px 18px;position:relative}
.bag-eyebrow{display:block;font-size:16px;font-weight:750;color:#eee2f3;padding-right:90px}
.bag-state{position:absolute;right:18px;top:19px;padding:5px 10px;font-size:15px;font-weight:800;white-space:nowrap;border-radius:30px;background:#ffffff28;color:#fff;border:1px solid #ffffff50}
.bag-hero h1{font-size:32px;line-height:1.25;margin:9px 0 9px;color:#fff}
.bag-hero p{font-size:16px;line-height:1.65;color:#f7eefb;margin:0}
.bag-stages{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin-top:16px}
.bag-stages .stage{border-radius:9px;text-align:center;padding:10px 5px;font-size:14px;font-weight:750;color:#f3e9f6;background:#ffffff30;min-width:0}
.bag-stages .stage.current{background:white;color:#4d365f}.bag-stages .stage.complete{background:#e5daeb;color:#553c62}
.current-work{padding:20px 20px 0}
.v14-section{margin:8px 0 12px}.v14-section h2{font-size:21px;font-weight:800;line-height:1.4;margin:0}
.v14-capture .badge{font-size:15px;background:#f0eaf4;color:#584067;padding:8px 11px;border-radius:9px}
.v14-capture .upload-list{display:flex;gap:10px;overflow:auto;max-height:none;scroll-snap-type:x proximity;padding:2px 2px 12px;min-height:88px}
.v14-capture .upload-item{flex:0 0 148px;display:flex;flex-direction:column;align-items:stretch;gap:5px;padding:8px;border-radius:12px;background:#faf9fb;border:1px solid #ded7e3;scroll-snap-align:start}
.v14-capture .upload-item img{height:102px;width:100%;object-fit:contain;background:#eae7ed;border-radius:8px}
.v14-capture .upload-item .status{font-size:14px;line-height:1.4;min-height:36px;font-weight:700}
.v14-capture .upload-item .saved-photo-zoom{border:0;padding:0;min-height:auto;background:transparent}
.v14-capture .upload-item>span{font-size:14px;font-weight:700;color:#5a4b65}
.v14-capture .upload-item>div:last-child button{font-size:14px;min-height:44px}
.v14-capture .upload-item[data-state=failed]{border-color:#ba5a68;background:#fff1f2}
.v14-capture .status-line{background:#f1f6f2;color:#28614d;border-radius:10px;font-size:16px;font-weight:700;padding:12px 13px;line-height:1.5;margin:10px 0 16px;overflow-wrap:anywhere}
.v14-capture .launch-camera{min-height:68px;font-size:20px;line-height:1.4;border-radius:14px;font-weight:800;box-shadow:0 4px 10px #38214616}
.camera-glyph{font-size:26px;line-height:1;margin-right:7px}
.v14-capture .file-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:10px 0 6px}
.v14-capture .file-actions button{padding:10px 7px;min-height:55px;font-weight:750;font-size:15px;line-height:1.3}
.v14-capture .capture-options{margin:0 0 8px}.v14-capture .capture-options summary{font-size:15px;min-height:48px;padding:10px 0;color:#6a4c79}
.v14-capture .capture-options .capture-meta{padding:4px 2px 10px}.v14-capture .capture-options label{font-size:15px}
.v14-capture .capture-review{border-top:1px solid var(--line);margin-top:18px;padding-top:16px}
.v14-capture .capture-review h2{font-size:21px}
.v14-capture #capture-refresh{width:100%;margin:8px 0;min-height:48px;font-size:16px}
.v14-fields{display:grid;gap:17px;margin:15px 0 20px}.v14-fields .v14-field{min-width:0}
.v14-fields .v14-field label{display:flex;align-items:baseline;justify-content:space-between;gap:6px;font-size:18px;font-weight:800;margin-bottom:7px}
.v14-fields .v14-field label small{font-size:14px;color:#706779;font-weight:650}
.v14-fields input{min-height:58px;font-size:18px;line-height:1.3;font-weight:600;border-radius:11px;padding:12px 14px}
.v14-fields .field-name input,.v14-fields .field-amount input{font-size:22px;font-weight:800}
.v14-fields .candidate-list{display:flex;gap:6px;flex-wrap:wrap;margin-top:5px}.v14-fields .candidate-list .candidate{width:auto;max-width:100%;font-size:16px;min-height:44px}
.v14-fields .candidate-caption{font-size:14px;color:#896420;width:100%;margin:3px 0}
.v14-check{font-size:16px;line-height:1.5;min-height:64px;padding:12px 14px;border:1px solid var(--line);border-radius:12px;display:flex;gap:13px;align-items:center;margin:18px 0 0}
.v14-check input{width:24px;height:24px;min-height:24px;flex:0 0 auto}
.v14-capture .bag-bottom{position:sticky;bottom:0;z-index:10;background:#fff;box-shadow:0 -8px 30px #38214615;border-top:1px solid #e8e1eb;padding:12px 0 max(12px,env(safe-area-inset-bottom));display:grid;gap:8px}
.v14-capture .bag-bottom button{min-height:58px;font-weight:800;font-size:18px;border-radius:12px}
.v14-capture #defer-bag{background:#fff;border:1px solid #b7a6c1;color:#624771}
.v14-capture .bottom-hint{font-size:14px;text-align:center;color:#716778;margin:0;line-height:1.45}
.v14-capture .previous-bag{margin-bottom:12px;background:#edf6f0;color:#275b44;border-radius:10px;padding:13px;font-size:16px;line-height:1.5;font-weight:700}
.v14-capture .warning{font-size:16px;line-height:1.5;margin-bottom:10px}
/* Camera stays full-screen. It is never shrunk to fit the form. */
body.camera-open{overflow:hidden;overscroll-behavior:contain}
.camera-overlay{position:fixed;inset:0;z-index:5000;background:#16131b;color:white;display:flex;flex-direction:column;overflow:hidden;padding-top:env(safe-area-inset-top);padding-bottom:env(safe-area-inset-bottom)}
.camera-overlay[hidden]{display:none!important}
.camera-overlay-top{min-height:72px;display:flex;gap:10px;align-items:center;justify-content:space-between;padding:12px 16px;background:#25202d}
.camera-overlay-top>div{display:grid;gap:3px;min-width:0}.camera-overlay-top strong{font-size:20px;line-height:1.4}.camera-overlay-top span{font-size:15px;color:#e2d9e6}
.camera-overlay-top button{background:#ffffff18;color:white;border:1px solid #ffffff65;min-width:86px;font-size:16px;min-height:48px}
.camera-overlay .camera-frame{position:relative;flex:1;min-height:0;height:auto;max-height:none;margin:0;border-radius:0;background:#060609}
.camera-overlay .camera-frame video{width:100%;height:100%;object-fit:contain;display:block}
.camera-overlay .guide{inset:6% 11%;border:2px dashed #ffffffb4;border-radius:10px}
.camera-overlay .camera-hint{font-size:16px;bottom:12px;padding:10px;background:#16131b99;color:#fff}
.camera-overlay-bottom{background:#25202d;min-height:175px;display:flex;align-items:center;flex-direction:column;padding:10px 12px 16px;gap:8px;justify-content:center}
#camera-overlay-feedback{font-size:16px;line-height:1.4;text-align:center;color:#ebdfef;min-height:22px}
.camera-overlay #camera-shot{width:80px;height:80px;border-radius:50%;background:#fff;border:5px solid #aa96b7;display:flex;align-items:center;justify-content:center;padding:7px;min-height:80px;box-shadow:0 0 0 3px #ffffff30}
.camera-overlay #camera-shot span{border:3px solid #543b65;border-radius:50%;width:60px;height:60px;display:block}
.camera-overlay #camera-shot:disabled{opacity:.55}
.camera-overlay-caption{font-size:16px;font-weight:750;color:#e7dcee}
/* Review tab remains a recovery/editing place, with all six fields visible. */
.secondary-fields{display:block;border-top:1px solid var(--line);padding-top:8px;margin-top:10px}
.review .field{font-size:18px}.review .field>span{font-size:18px}.review .field input{min-height:55px;font-size:18px}
.review .check{font-size:16px}.review .confirm-bottom button{min-height:58px;font-size:18px}
.review #ocr-status{font-size:16px}.review .entry-index select{font-size:16px}
@media(min-width:760px){.v14-fields{grid-template-columns:1fr 1fr}.v14-fields .field-address{grid-column:span 2}.current-work{padding:20px 25px 0}.v14-capture .bag-bottom{grid-template-columns:1.2fr 1fr}.v14-capture .bottom-hint{grid-column:span 2}.bag-hero{padding:22px 26px}}
@media(max-width:760px){main{padding:10px 10px 26px}.v14-capture{padding:0;border-radius:14px}.bag-hero{padding:18px 16px 17px}.bag-hero h1{font-size:30px}.bag-stages{gap:5px}.bag-stages .stage{font-size:13px;padding:9px 3px}.current-work{padding:14px 14px 0}.v14-section h2{font-size:21px}.v14-fields{gap:15px}.v14-fields .v14-field label{font-size:18px}.v14-capture .upload-item{flex-basis:142px}.v14-capture .bag-bottom{margin:0 -14px;padding:11px 14px max(12px,env(safe-area-inset-bottom))}.camera-overlay .guide{inset:5% 10%}.camera-overlay-bottom{min-height:160px}.capture h1{font-size:30px}}
@media(max-width:370px){.v14-capture .file-actions button{font-size:14px}.bag-stages .stage{font-size:12px}.bag-hero h1{font-size:27px}.camera-overlay-top strong{font-size:18px}}

/* v0.14.3: case identity + bag number; simplified photo capture */
.v14-capture .bag-hero{padding:20px 22px 17px}
.v14-capture .bag-heading{display:flex;align-items:flex-start;gap:16px;justify-content:space-between;min-width:0}
.v14-capture .bag-heading-main{min-width:0;flex:1}
.v14-capture .bag-heading-main .bag-eyebrow{padding:0;font-size:15px;opacity:.93}
.v14-capture .bag-heading h1{font-size:clamp(23px,4vw,31px);overflow-wrap:anywhere;line-height:1.3;margin:5px 0 6px}
.v14-capture .bag-number-block{display:flex;flex-direction:column;align-items:flex-end;flex:0 0 auto;min-width:126px;max-width:42%;background:#ffffff1e;border:1px solid #ffffff40;border-radius:12px;padding:10px 12px}
.v14-capture .bag-number-title{font-size:13px;color:#f6ebfa;font-weight:700;white-space:nowrap}
.v14-capture .bag-number-block strong{font-size:25px;line-height:1.3;color:white;font-variant-numeric:tabular-nums}
.v14-capture .bag-hero-meta{display:flex;gap:10px;align-items:center;flex-wrap:wrap;margin:4px 0 11px}
.v14-capture .bag-hero-meta .bag-state{position:static;display:inline-flex;font-size:14px;padding:5px 10px}
.v14-capture .bag-case-count{font-size:14px;font-weight:750;color:#f2e8f6}
@media(max-width:560px){.v14-capture .bag-hero{padding:16px 16px 14px}.v14-capture .bag-heading{gap:8px}.v14-capture .bag-heading h1{font-size:23px}.v14-capture .bag-number-block{padding:8px;min-width:100px}.v14-capture .bag-number-title{font-size:11px}.v14-capture .bag-number-block strong{font-size:19px}.v14-capture .bag-case-count{font-size:13px}}

/* v0.15.0: case selection and new case action discoverability */
.case-select-label{display:block;font-size:14px;font-weight:700;margin:0 0 5px;color:#4e4257}
.casebar .create-case{align-self:end;min-width:170px}
.casebar .create-case>summary{display:block;padding:13px 16px;border:1px solid #684a7e;border-radius:10px;background:#fff;color:#5e4175;font-weight:700;text-align:center;cursor:pointer;list-style:none}
.casebar .create-case>summary::-webkit-details-marker{display:none}
.casebar .create-case[open]{position:relative;z-index:4}
.casebar .create-case form{background:white;border:1px solid #dbd0e2;padding:14px;border-radius:10px;box-shadow:0 8px 24px #0001}
@media (max-width:780px){.casebar .create-case{width:100%}.casebar .create-case>summary{min-height:48px}}

/* v0.15.2: Android case selector layout. Do not squeeze the picker beside a full-width action. */
.casebar{min-width:0}
.casebar>form{min-width:0}
.casebar #case-select{display:block;width:100%;min-width:0}
.casebar .create-case{flex:0 0 auto}
.casebar .case-select-label{line-height:1.45;white-space:normal;overflow-wrap:normal;word-break:normal}
@media(max-width:780px){
  .casebar{display:flex;flex-direction:column;align-items:stretch;gap:10px;margin-bottom:14px}
  .casebar>form,.casebar .create-case{flex:none;width:100%;min-width:0;margin:0}
  .casebar .case-select-label{display:block;width:100%;font-size:16px;line-height:1.5;margin:0 0 6px}
  .casebar #case-select{width:100%;min-width:0;min-height:54px;font-size:18px;padding:12px 16px}
  .casebar .create-case{align-self:stretch}
  .casebar .create-case>summary{width:100%;min-height:54px;font-size:17px;line-height:1.4;display:flex;align-items:center;justify-content:center;white-space:normal}
  .casebar .create-case[open]>form{position:static;width:100%;margin-top:8px;box-shadow:0 4px 14px #2824311a}
}
