.accounting-check-modal{position:fixed;inset:0;z-index:1200;background:#102a44d9;overflow:auto;padding:12px}.accounting-check-modal[hidden],.accounting-check-card[hidden]{display:none}.accounting-check-panel{max-width:950px;margin:auto;background:#f3f7fd;border-radius:16px;padding:16px;min-height:90vh;color:#122b48}.accounting-check-panel>header,.accounting-check-card>header{display:flex;justify-content:space-between;gap:12px;align-items:center}.accounting-check-panel section{background:white;border:1px solid #d6e3f2;border-radius:14px;padding:16px;margin:12px 0}.accounting-check-stats{display:grid;grid-template-columns:repeat(auto-fit,minmax(130px,1fr));gap:8px}.accounting-check-stats button{background:#e8f1fd;border:0;border-radius:12px;padding:12px;color:#153a66;text-align:right}.accounting-check-stats b{display:block;font-size:1.5rem}.accounting-check-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:10px}.accounting-check-create label{display:block;margin:10px 0}.accounting-check-create input,.accounting-check-create select,.accounting-check-create textarea{display:block;width:100%;box-sizing:border-box;padding:10px;border:1px solid #c9d9eb;border-radius:9px}.accounting-check-create textarea{min-height:70px}.accounting-check-create>button,.accounting-check-actions button{background:#127b57;color:white;border:0;border-radius:9px;padding:10px 16px;cursor:pointer}.accounting-check-customer{display:block;width:100%;text-align:right;margin:4px 0;padding:9px;background:#eef5fd;border:1px solid #cbdcec;border-radius:8px}.accounting-check-card{border:1px solid #d8e5f3;border-radius:12px;padding:12px;margin:10px 0;background:#fff}.accounting-check-card>header span{background:#e7f1fc;padding:5px 9px;border-radius:20px}.accounting-check-photo img{max-width:180px;max-height:150px;object-fit:contain;border:1px solid #d7e2ef;border-radius:6px}.accounting-check-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:10px}.accounting-check-actions button:nth-child(2){background:#1e63b7}.accounting-check-card .negative{color:#b22222}

.check-photo-picker{padding:12px;border:1px solid #ccdaea;border-radius:12px;margin:12px 0}.check-photo-picker input[hidden],#checkPhotoPreview[hidden]{display:none!important}#checkPhotoPreview img{display:block;max-width:100%;max-height:360px;margin:12px auto;object-fit:contain}.check-photo-delete{background:#fff0f0!important;color:#b42318!important;border:1px solid #edb8b8!important}.check-camera-dialog{width:min(94vw,700px);background:#10233f;color:white;border:0;border-radius:16px;padding:14px;z-index:10000;text-align:center}.check-camera-dialog::backdrop{background:#000c}.check-camera-dialog video{width:100%;max-height:65vh;object-fit:contain}.check-camera-dialog button{min-height:44px;margin:6px;padding:10px 18px;font:inherit;border-radius:10px}
.accounting-check-number-search{background:#eef6ff;padding:16px;border:1px solid #c5d9ef;border-radius:12px}.accounting-check-number-search input{display:block;width:100%;padding:12px;margin:8px 0;border:1px solid #b9cee5;border-radius:8px;font:inherit}.accounting-check-number-search button{margin:6px 0 6px 8px}
.accounting-check-modal{padding:12px;overflow:hidden}.accounting-check-panel{max-width:1250px;height:calc(100dvh - 24px);min-height:0;display:flex;flex-direction:column;padding:0;overflow:hidden}.accounting-check-panel>header{padding:12px 20px;border-bottom:1px solid #d6e3f2;background:#153954;color:white;flex:none}.accounting-check-panel>header h2{margin:0;font-size:18px}.accounting-check-panel>header button{padding:8px 14px;border:1px solid #668394;background:transparent;color:white;border-radius:9px}#accountingCheckBody{overflow:auto;min-height:0;flex:1;padding:0 18px 18px;scrollbar-gutter:stable}.check-workspace-tools{position:sticky;top:0;z-index:5;background:#f3f7fd;padding:10px 0;border-bottom:1px solid #d4e0eb;display:grid;grid-template-columns:minmax(0,1.5fr) minmax(180px,1fr);gap:8px 14px}.accounting-check-panel .check-workspace-tools .accounting-check-number-search{margin:0;padding:0;border:0;background:transparent}.accounting-check-number-search h3,.accounting-check-number-search p{display:none}.accounting-check-number-search label{margin:0;font-size:11px}.accounting-check-number-search input{padding:9px;margin:3px 0;font-size:12px}.accounting-check-number-search button{font:inherit;font-size:10px;padding:5px 10px;border:1px solid #bdd0df;border-radius:7px;background:white}.check-seller-filter{margin:0;font-size:11px}.check-seller-filter select{display:block;width:100%;margin:3px 0;padding:10px;border:1px solid #91b6c9;border-radius:9px;background:#fff;font:inherit;font-size:13px;color:#173954}.check-workspace-tools .accounting-check-stats{grid-column:1/-1;display:flex;gap:6px;overflow:auto}.accounting-check-stats button{flex:1;white-space:nowrap;font:inherit;font-size:11px;padding:8px 12px;display:flex;align-items:center;justify-content:space-between;gap:12px;border:1px solid #d6e3ee}.accounting-check-stats b{font-size:17px}.accounting-check-stats button[aria-pressed=true]{background:#125d83;color:white;border-color:#125d83}#checkWorkspaceStatus{grid-column:1/-1;color:#087149;margin:0;font-size:12px}#checkWorkspaceStatus:empty{display:none}.accounting-check-panel .accounting-check-list{padding:0;border:0;background:transparent;margin:12px 0}.accounting-check-list>h3{font-size:12px;color:#687e91}.accounting-check-card{display:grid;grid-template-columns:minmax(0,1fr) 220px;column-gap:20px;padding:18px;margin:12px 0;overflow:hidden}.accounting-check-card>header,.check-facts{grid-column:1/-1}.accounting-check-card>header>b{font-size:16px}.accounting-check-card>header span{font-size:11px;white-space:nowrap}.accounting-check-card>p,.accounting-check-card>small{grid-column:1;margin:6px 0;font-size:12px;overflow-wrap:anywhere}.check-facts{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:7px;margin:14px 0;padding-bottom:12px;border-bottom:1px solid #e4edf4}.check-facts>div{background:#f1f6fb;padding:9px;border-radius:8px;min-width:0}.check-facts small{display:block;font-size:10px;color:#71879a}.check-facts b{font-size:12px;display:block;margin-top:5px;overflow-wrap:anywhere}.accounting-check-card>.accounting-check-photo{grid-column:2;grid-row:3/span 8;align-self:start}.check-photo-open{display:grid;gap:7px;border:1px solid #d3e4ed;background:#f6fafc;border-radius:10px;padding:8px;width:100%;color:#19688c;font:inherit;font-size:11px;cursor:zoom-in}.accounting-check-photo img{max-width:100%;width:100%;height:190px;max-height:none;object-fit:contain}.accounting-check-card>.accounting-check-actions{grid-column:1/-1;border-top:1px solid #e7eef4;padding-top:12px;justify-content:flex-start}.check-new-fold{background:white;border:1px solid #d5e2ed;border-radius:12px;margin:12px 0;padding:12px}.check-new-fold>summary{cursor:pointer;font-weight:700;color:#1b557c}.accounting-check-panel .check-new-fold .accounting-check-create{border:0;margin:0;padding:12px 0}.check-photo-viewer{width:min(96vw,1200px);max-width:96vw;max-height:94dvh;padding:0;background:#102a3f;color:white;border:0;border-radius:14px;z-index:20000}.check-photo-viewer::backdrop{background:#06121de8}.check-photo-viewer header{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:12px 16px}.check-photo-controls{display:flex;gap:8px;flex-wrap:wrap;padding:8px 16px;background:#1a394e}.check-photo-viewer button{font:inherit;font-size:12px;border:1px solid #60859e;background:#244c65;color:white;border-radius:8px;padding:8px 12px}.check-photo-stage{overflow:auto;max-height:70dvh;background:#e9eff3;text-align:center;padding:20px}.check-photo-stage img{width:100%;height:auto;max-width:none;object-fit:contain;transform-origin:center}.check-photo-viewer[open]{display:block}@media(max-width:700px){.accounting-check-modal{padding:0}.accounting-check-panel{height:100dvh;border-radius:0}.accounting-check-panel>header{padding:10px 12px}.accounting-check-panel>header h2{font-size:15px}#accountingCheckBody{padding:0 10px 10px}.check-workspace-tools{gap:6px;grid-template-columns:1fr}.check-workspace-tools .accounting-check-stats{grid-column:1;display:grid;grid-template-columns:repeat(2,1fr)}.accounting-check-stats button{padding:6px 8px;font-size:10px}.check-seller-filter select{padding:7px}.accounting-check-card{grid-template-columns:minmax(0,1fr);padding:12px}.accounting-check-card>header>b{font-size:14px}.check-facts{grid-template-columns:repeat(3,minmax(0,1fr));gap:5px}.check-facts>div{padding:7px}.check-facts b{font-size:11px}.accounting-check-card>.accounting-check-photo{grid-column:1;grid-row:auto}.accounting-check-photo img{height:160px}.check-photo-open{max-width:100%}.check-photo-viewer{width:98vw;max-width:98vw}.check-photo-viewer header b{font-size:12px}.check-photo-controls{gap:5px;padding:7px}.check-photo-viewer button{padding:7px;font-size:11px}}

.check-photo-stage img{width:auto;max-width:100%;max-height:65dvh}

.check-photo-stage{position:relative;height:70dvh;max-height:70dvh;overflow:hidden;touch-action:none;cursor:grab;padding:0}.check-photo-stage:active{cursor:grabbing}.check-photo-stage img{position:absolute;left:50%;top:50%;max-width:none;max-height:none;user-select:none;pointer-events:none;transform-origin:center}

.check-create-shortcuts{grid-column:1/-1;display:flex;gap:8px;flex-wrap:wrap}.check-create-shortcuts button{flex:1;padding:11px;border:1px solid #b9cfe5;border-radius:10px;background:#e9f4ff;color:#123d60;font:inherit;font-weight:bold}.check-create-shortcuts .check-bounced-new{background:#fff0f0;border-color:#e8a3a3;color:#ad2020}.accounting-check-card.bank-bounced{border:2px solid #dc5a5a;border-right:6px solid #c92525}.check-bounced-warning{padding:10px;color:#b11a1a;background:#fff0f0;font-weight:bold;border-radius:9px}.check-customer-call a{display:inline-block;background:#e7f5ec;padding:8px 13px;border-radius:8px;color:#087144;font-weight:bold}.check-new-fold>summary{padding:14px;font-weight:bold}.accounting-check-create{scroll-margin-top:15px}
@media(max-width:760px){.accounting-check-modal{overflow-y:auto!important;overflow-x:hidden!important;height:var(--savar-visible-height,100dvh)!important;bottom:auto!important;padding:0!important;box-sizing:border-box}.accounting-check-panel{height:auto!important;min-height:100%!important;max-height:none!important;display:block!important;overflow:visible!important}.accounting-check-panel>header{position:static!important;top:auto!important}#accountingCheckBody{overflow:visible!important;height:auto!important;max-height:none!important;display:block!important;padding-bottom:40px!important}.check-workspace-tools{position:static!important;top:auto!important}.check-create-shortcuts button{font-size:12px;min-height:44px}.accounting-check-create input,.accounting-check-create textarea,.accounting-check-create select{font-size:16px;scroll-margin:20px}.accounting-check-create>button{min-height:48px;margin:14px 0 30px;width:100%}}

/* Receipt-workspace fix: only the outer toolbar may stick; cards scroll as one unit. */
#accountingCheckModal .accounting-check-card{position:relative;display:block;isolation:isolate;contain:layout;overflow:hidden}
#accountingCheckModal .accounting-check-card>header{position:static!important;inset:auto!important;z-index:auto!important;transform:none!important;min-height:0;height:auto;width:auto;flex-wrap:wrap;background:transparent}
#accountingCheckModal .accounting-check-card .check-facts,#accountingCheckModal .accounting-check-card>.accounting-check-photo,#accountingCheckModal .accounting-check-card>.accounting-check-actions,#accountingCheckModal .check-customer-call{position:static!important;inset:auto!important;transform:none!important}
#accountingCheckModal .accounting-check-card>.accounting-check-photo{float:left;width:220px;max-width:35%;margin:10px 18px 15px 0}
#accountingCheckModal .accounting-check-card>.accounting-check-actions{clear:both;display:flex;min-height:44px}
#accountingCheckModal .accounting-check-card .check-facts{clear:both}
#accountingCheckModal .accounting-check-photo img{position:static!important;display:block;margin:auto}
#accountingCheckModal .accounting-check-card p,#accountingCheckModal .accounting-check-card small{overflow-wrap:anywhere}
@media(max-width:760px){#accountingCheckModal .accounting-check-card>.accounting-check-photo{float:none;width:100%;max-width:100%;margin:12px 0}#accountingCheckModal .accounting-check-card>header{gap:8px}}
#accountingCheckModal .accounting-check-card[hidden]{display:none!important}

.check-search-context{margin:12px 0;padding:14px;border:1px solid #9fc3d6;border-radius:10px;background:#fff;color:#193b53;line-height:1.9}.check-search-context h3{font-size:15px}.check-search-context p,.check-search-context b{overflow-wrap:anywhere}.check-search-context article{padding:10px;border-bottom:1px solid #dbe7ee}.check-search-context button{font:inherit;padding:10px 14px;margin:6px;border:1px solid #b4cedf;border-radius:8px;background:#eaf4fb;color:#125d83}
.check-submission-origin{grid-column:1/-1;background:#eaf5ff;border:1px solid #c8ddee;border-radius:10px;padding:10px;line-height:1.9}.check-submission-origin small{display:block}.check-submission-origin strong{display:block;color:#9b5a00}.check-search-context{background:white;border:1px solid #c8ddee;padding:12px;border-radius:10px;line-height:1.9;margin:10px 0;overflow-wrap:anywhere}
.check-workspace-folder>summary{display:flex;align-items:center;gap:10px;min-height:50px;list-style:none}.check-workspace-folder>summary:after{content:'＋';margin-right:auto;font-size:21px;color:#6b8ba5}.check-workspace-folder[open]>summary:after{content:'−'}.check-workspace-folder>summary>span{font-size:11px;font-weight:400;color:#64849b}.check-case-folder{margin:10px 0;border:1px solid #cbdde9;background:#fff;border-radius:12px;overflow:hidden;min-width:0}.check-case-folder[hidden]{display:none!important}.check-case-folder>summary{display:flex;align-items:center;justify-content:space-between;gap:12px;cursor:pointer;padding:14px;min-height:70px;list-style:none;color:#174360;background:#f7fafc}.check-case-folder>summary:after{content:'＋';color:#6790ad;font-size:21px;flex-shrink:0}.check-case-folder[open]>summary{background:#edf5fb;border-bottom:1px solid #d9e6ef}.check-case-folder[open]>summary:after{content:'−'}.check-folder-identity{min-width:0;flex:1;display:grid;gap:5px}.check-folder-identity b{font-size:14px}.check-folder-identity>span{font-size:13px;overflow-wrap:anywhere}.check-folder-identity small{font-size:11px;color:#7a8d9e}.check-folder-state{font-size:11px;padding:6px 9px;border-radius:8px;background:#e6eff5;color:#3f6a87;max-width:150px;overflow-wrap:anywhere}.check-case-folder>.accounting-check-card{margin:0!important;border:0!important;border-radius:0!important}.check-folder-filters{display:grid;grid-template-columns:1fr 1fr;gap:12px;padding:10px 2px}.check-folder-filters>.accounting-check-number-search{grid-column:1/-1;margin:0}.check-folder-filters>.accounting-check-stats{grid-column:1/-1;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px}.check-folder-filters .accounting-check-stats button{white-space:normal;min-height:48px;font:inherit;font-size:11px}.check-workspace-folder .accounting-check-list>h3{display:none}.check-workspace-tools:has(.check-create-shortcuts){grid-template-columns:1fr}.check-case-folder:has(>.bank-bounced)>summary{background:#fff1f1;color:#a72f2f}.check-case-folder summary:focus-visible,.check-workspace-folder summary:focus-visible{outline:3px solid #81b9d8;outline-offset:-3px}.accounting-check-modal .check-workspace-tools{scroll-margin-top:0}#checkWorkspaceStatus:not(:empty){padding:12px;border:1px solid #b8d9c7;border-radius:10px;background:#eef8f0;line-height:1.9;font-size:13px}@media(max-width:760px){.check-workspace-folder{padding:5px!important;margin:10px 0}.check-workspace-folder>summary{padding:12px 8px;font-size:13px;flex-wrap:wrap}.check-workspace-folder>summary:after{margin-right:auto}.check-case-folder>summary{padding:12px 10px;gap:8px;min-height:82px}.check-folder-identity b{font-size:13px}.check-folder-state{font-size:10px;max-width:104px;padding:5px 7px}.check-folder-filters{grid-template-columns:1fr;gap:10px}.check-folder-filters>.accounting-check-stats{grid-template-columns:1fr 1fr}.check-create-shortcuts{margin-top:4px}.check-create-shortcuts button{min-height:48px}.check-case-folder{scroll-margin:8px}}
.check-case-category{margin:12px 0;background:#f5f9fd;border:1px solid #c9dce9;border-radius:12px;min-width:0}.check-case-category>summary{padding:16px;min-height:54px;display:flex;gap:14px;align-items:center;list-style:none;cursor:pointer;color:#214d6e}.check-case-category>summary:after{content:'＋';margin-right:auto;font-size:22px}.check-case-category[open]>summary:after{content:'−'}.check-case-category>summary>span{font-size:12px;color:#68879e}.check-case-category[data-check-category=closed]>summary{color:#557e66;background:#eff7f1;border-radius:12px}.check-category-items{padding:0 10px 10px}.check-case-category[hidden]{display:none!important}.check-folder-meta{display:flex!important;gap:8px;flex-wrap:wrap;margin-top:4px}.check-folder-meta small{font-size:11px!important;padding:5px 8px;border:1px solid #dbe8f1;border-radius:6px;background:#eef5fb;color:#416584!important}.accounting-check-card .check-facts{grid-template-columns:repeat(4,minmax(0,1fr))}.accounting-check-photo img{height:300px!important;max-height:400px!important;object-fit:contain}.check-case-folder>summary{min-height:116px}.check-folder-identity>span{line-height:1.8}.check-folder-meta small{white-space:normal}.accounting-check-card>header>b{line-height:1.9}@media(max-width:760px){.check-folder-meta{gap:5px}.check-folder-meta small{font-size:10px!important;padding:5px}.check-folder-meta small:last-child{flex-basis:100%}.accounting-check-card .check-facts{grid-template-columns:repeat(2,minmax(0,1fr))}.check-case-folder>summary{align-items:flex-start}.check-folder-state{margin-top:5px;max-width:88px}.check-category-items{padding:0 5px 6px}.check-case-category>summary{padding:12px;font-size:14px}.accounting-check-photo img{height:340px!important}}

.check-entry-facts{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.check-entry-facts input{display:block;width:100%;box-sizing:border-box}.check-entry-hint{font-size:12px;color:#6e869a;line-height:1.9}@media(max-width:760px){.check-entry-facts{grid-template-columns:1fr}}
