/* Local batch settlement: all selectors are scoped to avoid moving legacy controls. */
#gaojiu-refined .sb-workspace{--sb-orange:#d87831;--sb-ink:#352b25;--sb-muted:#827468;--sb-line:#e9dfd4;--sb-soft:#fff8f1;min-width:0;color:var(--sb-ink);font-size:13px}
#gaojiu-refined .sb-workspace .gj-heading{margin-bottom:18px;gap:16px;align-items:center}
#gaojiu-refined .sb-workspace .gj-heading h2{font-size:27px;margin:4px 0 8px}
#gaojiu-refined .sb-workspace .gj-heading p{font-size:13px;line-height:1.7;max-width:780px}
#gaojiu-refined .sb-workspace .gj-actions{gap:8px;flex-wrap:wrap;justify-content:flex-end;flex-shrink:0}
#gaojiu-refined .sb-workspace .gj-panel.sb-panel{padding:16px;margin-bottom:14px;border:1px solid var(--sb-line);border-radius:12px;box-shadow:none;min-width:0}
#gaojiu-refined .sb-workspace :is(input:not([type=checkbox]):not([type=file]),select),.sb-dialog :is(input:not([type=checkbox]),select){box-sizing:border-box;height:36px;min-height:36px;font-size:13px;padding:6px 9px;width:100%;min-width:0;border:1px solid #ddcfc1;border-radius:7px;background:#fff;color:#352b25}
#gaojiu-refined .sb-workspace select,.sb-dialog select{padding-right:27px}
#gaojiu-refined .sb-workspace input[type=number],.sb-dialog input[type=number]{font-variant-numeric:tabular-nums;appearance:textfield;-moz-appearance:textfield}
#gaojiu-refined .sb-workspace input::-webkit-inner-spin-button,.sb-dialog input::-webkit-inner-spin-button{appearance:none}
#gaojiu-refined .sb-workspace input[type=checkbox],.sb-dialog input[type=checkbox]{width:16px;height:16px;min-height:16px;flex:0 0 16px;accent-color:#cf722e}
#gaojiu-refined .sb-workspace :is(input,select,textarea):focus-visible,.sb-dialog :is(input,select,textarea):focus-visible{outline:2px solid #e6ac77;outline-offset:1px;border-color:#cf722e}
#gaojiu-refined .sb-workspace .gj-button,.sb-dialog .gj-button{height:36px;min-height:36px;min-width:0;display:inline-flex;align-items:center;justify-content:center;gap:5px;padding:7px 12px;line-height:20px;font-size:13px;white-space:nowrap;border-radius:7px;flex-shrink:0}
#gaojiu-refined .sb-workspace .gj-button-primary,.sb-dialog .gj-button-primary{background:#cb7133;border:1px solid #cb7133;color:white}
#gaojiu-refined .sb-workspace .gj-button-soft,.sb-dialog .gj-button-soft{background:#fff8f1;border:1px solid #ead7c5;color:#785238}
#gaojiu-refined .sb-workspace .gj-button:disabled,.sb-dialog .gj-button:disabled{opacity:.5;cursor:wait}
.sb-stats{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-bottom:16px}.sb-stats>div{padding:16px 20px;background:linear-gradient(125deg,#fffaf5,#fff);border:1px solid #eadfd4;border-radius:10px;display:flex;flex-direction:column;gap:7px}.sb-stats span{color:#86715e;font-size:13px}.sb-stats strong{font-size:25px;color:#a25b2d;font-weight:650;font-variant-numeric:tabular-nums}
.sb-panel-head{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:12px;margin-bottom:12px}.sb-panel-head h3{margin:0!important;font-size:15px!important}.sb-panel-head h3 small{font-size:13px;color:#948374;font-weight:400;margin-left:8px}.sb-inline{display:flex;gap:7px;align-items:center;flex-wrap:wrap}.sb-muted,.sb-table-note{color:#88796d;font-size:13px;line-height:1.7;margin:7px 0}.sb-error{color:#af422a!important;line-height:1.7}.sb-meta-identity{display:grid;grid-template-columns:minmax(230px,1.3fr) minmax(160px,.8fr) minmax(170px,.8fr);gap:14px;align-items:end;margin-bottom:12px}.sb-meta-dates{display:grid;grid-template-columns:minmax(235px,1.25fr) minmax(235px,1.25fr) minmax(145px,.8fr) minmax(145px,.8fr);gap:14px}.sb-workspace label:not(.sb-upload),.sb-dialog label{display:flex;flex-direction:column;gap:6px;font-size:13px;color:#756555;margin:0}.sb-period-status{display:flex;align-items:center;justify-content:flex-end;gap:10px;min-height:36px}.sb-period-status small{color:#88796d;font-size:13px}.sb-badge{display:inline-flex;align-items:center;padding:3px 7px;border-radius:4px;line-height:1.35;font-size:12px;color:#98602c;background:#fcf0df;white-space:nowrap}.sb-badge.is-confirmed{color:#386b50;background:#ebf4ed}
.sb-tabs{display:flex;gap:5px;align-items:center;background:#f5eee6;border-radius:8px;padding:3px}.sb-tabs button{border:0!important;background:transparent!important;box-shadow:none!important;color:#8e7663!important;border-radius:5px;min-height:32px;padding:6px 15px!important;font-size:13px;cursor:pointer;white-space:nowrap}.sb-tabs button[aria-selected=true]{background:white!important;color:#ae612d!important;box-shadow:0 1px 4px #6a3b1514!important;font-weight:600}
.sb-table-wrap{max-width:100%;overflow:auto;overscroll-behavior-x:contain}.sb-table{border-collapse:separate!important;border-spacing:0;width:100%;font-size:13px;table-layout:auto}.sb-table th{background:#fbf7f1!important;color:#846c58!important;white-space:nowrap;font-weight:500;line-height:1.5}.sb-table :is(th,td){padding:10px 8px!important;border-bottom:1px solid #eee5dc!important;vertical-align:middle;text-align:left;line-height:1.5}.sb-table tbody tr:last-child td{border-bottom:0!important}.sb-table small{display:block;color:#978879;font-size:12px;line-height:1.65;margin-top:3px;overflow-wrap:anywhere}.sb-table strong{font-size:13px;font-weight:600}.sb-table td{font-variant-numeric:tabular-nums;color:#4e4035}.sb-grid{table-layout:fixed}.sb-grid th:first-child{width:28px}.sb-grid th:nth-child(2){width:140px}.sb-grid th:last-child{width:116px}.sb-grid .sb-room-cell .sb-badge{margin-top:6px}.sb-grid td input[type=number]{text-align:right;padding:6px!important}.sb-grid th:nth-child(n+3):not(:last-child),.sb-grid td:nth-child(n+3):not(:last-child){text-align:right}.sb-grid th{white-space:normal;word-break:keep-all}.sb-grid .sb-row-tools .gj-button{font-size:12px;height:30px;min-height:30px;padding:4px 7px;display:flex;width:100%;margin:3px 0}.sb-grid-quantity{min-width:890px}.sb-grid-brand{min-width:880px}.sb-grid-employee{min-width:780px}.sb-grid-employee th:nth-child(3){width:170px}.sb-grid-employee td:nth-child(3){text-align:left!important}.sb-grid .sb-mismatch{color:#bb4424!important;font-weight:700;background:#fff4ec}.sb-list-table{min-width:850px}.sb-list-table td:nth-child(2){font-size:12px}.sb-list-table .sb-inline{flex-wrap:nowrap}.sb-list-table td:last-child .gj-button{padding:6px 9px}.sb-check-summary{font-size:12px;line-height:1.8;color:#966b47;margin-top:6px}
.sb-upload{position:relative;overflow:hidden;cursor:pointer}.sb-upload input{position:absolute;inset:0;opacity:0;width:100%;height:100%;cursor:pointer}.sb-file-list{display:flex;flex-wrap:wrap;gap:8px}.sb-file-list>a,.sb-file-list>div{border:1px solid #ecdfd1;background:#fffaf4;padding:8px 10px;border-radius:7px;font-size:12px;color:#855a37;text-decoration:none;display:flex;align-items:center;gap:8px;flex-wrap:wrap;max-width:100%;overflow-wrap:anywhere}.sb-file-list small{color:#9c8a7b}.sb-file-list .gj-button{height:28px!important;min-height:28px!important;font-size:12px!important;padding:3px 7px!important}.sb-note{margin-top:12px!important}.sb-note textarea,.sb-dialog textarea{box-sizing:border-box;width:100%;padding:9px;font-size:13px;line-height:1.7;border:1px solid #ddcfc1;border-radius:7px;color:#352b25;background:#fff;resize:vertical;min-height:68px}.sb-payment-history{margin:12px 0}.sb-payment-history summary,.sb-dialog summary{cursor:pointer;padding:8px 0;color:#7e5d42;font-size:13px}.sb-footer{position:sticky;bottom:0;z-index:15;background:#fffaf3f5;border:1px solid #e9d5bf;box-shadow:0 -3px 18px #7a4b1610;backdrop-filter:blur(10px);padding:12px 16px;border-radius:10px;margin:16px 0 6px}.sb-footer-totals{display:flex;align-items:center;gap:20px;flex-wrap:wrap;padding-bottom:10px;margin-bottom:10px;border-bottom:1px solid #eadfcf;font-size:13px;color:#88715c}.sb-footer-totals strong{font-size:16px;color:#a25b2b;margin-left:7px;font-weight:600}.sb-footer-actions{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap}.sb-footer-actions>span{font-size:12px;color:#96806b}.sb-footer-actions .sb-inline{margin-left:auto}.sb-legacy-back{margin-bottom:12px}.sb-dialog{box-sizing:border-box;width:min(900px,calc(100vw - 48px));max-width:900px;max-height:88vh;overflow:auto;padding:24px!important;border:1px solid #e5d7c7;border-radius:14px;color:#352b25}.sb-dialog::backdrop{background:#29221b55}.sb-dialog form>label{margin:13px 0}.sb-dialog h2{font-size:20px;margin:0}.sb-dialog-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:20px;position:sticky;bottom:-24px;padding:12px 0;background:white}.sb-room-choices{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;max-height:50vh;overflow:auto}.sb-room-choices label,.sb-scene-choices label{display:flex!important;flex-direction:row!important;align-items:center;gap:10px;border:1px solid #e8dacb;border-radius:8px;padding:11px;cursor:pointer}.sb-room-choices small,.sb-scene-choices small{display:block;font-size:12px;line-height:1.6;color:#948170;margin-top:3px}.sb-scene-choices{display:grid;gap:8px;max-height:50vh;overflow:auto}.sb-scene-choices .is-disabled{opacity:.55;cursor:default}.sb-payment-meta{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}.sb-ocr-table{min-width:700px}.sb-ocr-table td:first-child{width:35px}.sb-ocr-table td:nth-child(3){width:240px}.sb-ocr-table td:nth-child(4),.sb-ocr-table td:nth-child(5){width:110px}.sb-ocr-text{white-space:pre-wrap;overflow-wrap:anywhere;max-height:200px;overflow:auto;background:#faf5ee;padding:12px;font-size:12px}
@media(max-width:1350px){#gaojiu-refined .sb-workspace .gj-heading{align-items:flex-start}#gaojiu-refined .sb-workspace .gj-heading h2{font-size:25px}.sb-meta-dates{gap:10px;grid-template-columns:minmax(225px,1.2fr) minmax(225px,1.2fr) minmax(135px,.75fr) minmax(135px,.75fr)}.sb-grid th:nth-child(2){width:126px}.sb-grid th:last-child{width:108px}.sb-grid :is(th,td){padding:9px 6px!important}.sb-grid-quantity{min-width:860px}.sb-grid-brand{min-width:850px}.sb-footer-totals{gap:14px}.sb-footer-actions{align-items:flex-end}}
@media(max-width:1050px){.sb-meta-dates{grid-template-columns:repeat(2,minmax(210px,1fr))}.sb-meta-identity{grid-template-columns:minmax(200px,1fr) minmax(150px,1fr)}.sb-period-status{grid-column:1/-1;justify-content:flex-start;min-height:auto}.sb-stats>div{padding:14px}.sb-stats strong{font-size:21px}.sb-panel-head>.sb-inline{margin-left:auto}.sb-footer-actions .sb-inline{width:100%;justify-content:flex-end}.sb-workspace .gj-heading{flex-wrap:wrap}}
@media(max-width:640px){.sb-stats{gap:7px}.sb-stats>div{padding:12px 8px}.sb-stats strong{font-size:18px}.sb-meta-identity,.sb-meta-dates{grid-template-columns:1fr}.sb-meta-dates label{min-width:0}.sb-dialog{padding:16px!important;width:calc(100vw - 24px)}.sb-room-choices,.sb-payment-meta{grid-template-columns:1fr}.sb-tabs button{padding:6px 10px!important}.sb-footer-totals{gap:8px 13px}.sb-footer-actions .sb-inline{flex-wrap:wrap}.sb-footer{padding:12px}.sb-dialog-actions{bottom:-16px}}
/* Keep entry actions in view; the form reserves their space. */
#gaojiu-refined .sb-workspace #sb-form{padding-bottom:138px}
#gaojiu-refined .sb-workspace .sb-footer{position:fixed;left:234px;right:36px;bottom:12px;margin:0;max-width:none;z-index:35}
#gaojiu-refined .sb-workspace .sb-attachment-panel{padding:10px 14px}
.sb-attachment-panel .sb-panel-head{margin-bottom:0;min-height:36px}.sb-attachment-intro{display:flex;align-items:center;gap:14px;flex-wrap:wrap}.sb-attachment-intro .sb-muted{margin:0}.sb-attachment-panel:has(.sb-file-list>.sb-muted) #sb-file-list{display:none}.sb-attachment-panel:not(:has(.sb-file-list>.sb-muted)) #sb-file-list{margin-top:8px}
.sb-room-line{display:flex;gap:6px;align-items:center;flex-wrap:wrap}.sb-grid .sb-room-cell .sb-badge{margin-top:0;font-size:12px;padding:2px 5px}.sb-grid .sb-room-cell small{margin-top:3px}.sb-grid .sb-row-tools>.sb-inline{flex-wrap:nowrap;gap:8px;justify-content:flex-start}.sb-grid .sb-row-link{font-size:13px;white-space:nowrap;display:inline-block;padding:4px 0;min-height:32px;border:0;background:transparent;color:#ac642e;flex:0 0 auto}.sb-grid th:last-child{width:122px}.sb-grid :is(th,td){padding-top:7px!important;padding-bottom:7px!important}.sb-grid th:nth-child(2){width:148px}
@media(max-width:1350px){.sb-grid th:nth-child(2){width:138px}.sb-grid th:last-child{width:116px}.sb-grid .sb-row-tools>.sb-inline{gap:6px}}
@media(max-width:1100px){#gaojiu-refined .sb-workspace .sb-footer{left:194px;right:22px}.sb-attachment-intro{gap:8px}}
@media(max-width:780px){#gaojiu-refined .sb-workspace .sb-footer{left:16px;right:16px;bottom:8px}#gaojiu-refined .sb-workspace #sb-form{padding-bottom:180px}}
/* The footer follows the measured content edges, including the compact sidebar. */
#gaojiu-refined .sb-workspace .gj-heading{margin-bottom:10px;align-items:center;gap:12px}
#gaojiu-refined .sb-workspace .gj-heading .gj-kicker{display:none}
#gaojiu-refined .sb-workspace .gj-heading h2{font-size:24px;line-height:30px;margin:0 0 3px}
#gaojiu-refined .sb-workspace .gj-heading p{line-height:20px;margin:0}
#gaojiu-refined .sb-workspace .gj-panel.sb-panel{padding:12px;margin-bottom:10px}
#gaojiu-refined .sb-workspace .sb-meta-identity>label{flex-direction:row;align-items:center;gap:8px;white-space:nowrap}
.sb-meta-identity{margin-bottom:8px;gap:12px}.sb-meta-identity>label>input,.sb-meta-identity>label>select{flex:1;min-width:0}.sb-meta-dates label{gap:4px!important}.sb-panel-head{margin-bottom:8px}
#gaojiu-refined .sb-workspace .sb-attachment-panel{padding:8px 12px}.sb-attachment-panel .sb-panel-head{margin:0}
.sb-grid .sb-room-cell>strong{display:block}.sb-room-meta{display:flex;align-items:center;gap:6px;margin-top:3px}.sb-grid .sb-room-meta small{margin:0;line-height:18px}.sb-grid .sb-room-meta .sb-badge{flex-shrink:0;line-height:16px;padding:0 4px;margin:0}.sb-grid th:nth-child(2){width:164px}.sb-grid th:last-child{width:116px}
#gaojiu-refined .sb-workspace .sb-footer{left:164px;right:20px;padding:8px 12px;bottom:10px}
.sb-footer-totals{padding-bottom:0;margin-bottom:6px;border:0;min-height:22px;gap:14px}.sb-footer-totals strong{font-size:16px}.sb-footer-actions{min-height:32px}
#gaojiu-refined .sb-workspace .sb-footer .gj-button{height:32px;min-height:32px;padding:5px 10px}
#gaojiu-refined .sb-workspace #sb-form{padding-bottom:105px}
@media(max-width:1050px){.sb-meta-identity{margin-bottom:8px}.sb-meta-identity>label{white-space:normal!important}.sb-footer-totals{gap:6px 12px}.sb-footer-actions .sb-inline{width:auto}.sb-footer-actions>span{max-width:100%}}
@media(max-width:780px){#gaojiu-refined .sb-workspace #sb-form{padding-bottom:160px}.sb-footer-actions .sb-inline{width:100%}.sb-meta-identity>label{flex-direction:column!important;align-items:stretch!important}}

/* Compact entry layout: override the shared desktop card spacing only here. */
#gaojiu-refined .sb-workspace .gj-panel.sb-panel {
  padding: 10px 12px !important;
  margin-bottom: 8px !important;
}
#gaojiu-refined .sb-workspace .sb-meta-identity {
  grid-template-columns: minmax(280px, 1.45fr) minmax(280px, 1.45fr) minmax(180px, 1fr) minmax(180px, 1fr);
  gap: 10px;
  margin-bottom: 8px;
}
#gaojiu-refined .sb-workspace .sb-meta-identity > label:first-child {
  grid-column: span 2;
}
#gaojiu-refined .sb-workspace .sb-meta-identity > label {
  display: grid;
  grid-template-columns: 52px minmax(0,1fr);
  gap: 8px;
}
#gaojiu-refined .sb-workspace .sb-meta-dates {
  grid-template-columns: minmax(280px, 1.45fr) minmax(280px, 1.45fr) minmax(180px, 1fr) minmax(180px, 1fr);
  gap: 10px;
}
#gaojiu-refined .sb-workspace .sb-meta-dates > label {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  align-items: center;
  gap: 8px !important;
  white-space: nowrap;
}
#gaojiu-refined .sb-workspace :is(input:not([type=checkbox]):not([type=file]),select) {
  height: 34px !important;
  min-height: 34px !important;
  font-size: 13px !important;
}
#gaojiu-refined .sb-workspace .gj-panel.sb-attachment-panel {
  padding: 5px 12px !important;
}
#gaojiu-refined .sb-workspace .sb-panel-head {
  min-height: 34px;
  gap: 8px;
  margin-bottom: 5px;
}
#gaojiu-refined .sb-workspace .sb-attachment-panel .sb-panel-head {
  margin-bottom: 0;
}
#gaojiu-refined .sb-workspace .gj-button {
  height: 34px !important;
  min-height: 34px !important;
  padding: 5px 10px !important;
  font-size: 13px !important;
}
#gaojiu-refined .sb-workspace .sb-tabs {
  padding: 2px;
}
#gaojiu-refined .sb-workspace .sb-tabs button {
  min-height: 30px;
  padding: 4px 12px !important;
}
#gaojiu-refined .sb-workspace .sb-table :is(th,td) {
  font-size: 13px !important;
  padding: 5px 6px !important;
  line-height: 20px !important;
  vertical-align: middle !important;
}
#gaojiu-refined .sb-workspace .sb-grid :is(th,td) {
  text-align: center !important;
}
#gaojiu-refined .sb-workspace .sb-grid th:nth-child(2) {
  width: 178px;
  text-align: left !important;
}
#gaojiu-refined .sb-workspace .sb-grid td:nth-child(2) {
  text-align: left !important;
}
#gaojiu-refined .sb-workspace .sb-room-meta {
  flex-wrap: wrap;
  gap: 3px 6px;
  margin-top: 0;
}
#gaojiu-refined .sb-workspace .sb-room-meta small {
  white-space: nowrap;
}
#gaojiu-refined .sb-workspace .sb-room-name {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 6px;
}
#gaojiu-refined .sb-workspace .sb-room-name .sb-badge {
  padding: 0 4px;
  line-height: 18px;
}
#gaojiu-refined .sb-workspace .sb-grid td input[type=number] {
  text-align: center;
  font-variant-numeric: tabular-nums;
}
#gaojiu-refined .sb-workspace .sb-row-tools > .sb-inline {
  justify-content: center;
}
#gaojiu-refined .sb-workspace .sb-table-note,
#gaojiu-refined .sb-workspace .sb-check-summary {
  font-size: 12px;
  line-height: 18px;
  margin: 4px 0 0;
}
#gaojiu-refined .sb-workspace .sb-check-summary {
  padding: 5px 8px;
  background: #fff8ee;
  border-radius: 6px;
}
#gaojiu-refined .sb-workspace .sb-check-summary[hidden] { display: none; }
#gaojiu-refined .sb-workspace .sb-check-summary summary { cursor: pointer; line-height: 20px; }
#gaojiu-refined .sb-workspace #sb-check-items { max-height: 144px; overflow: auto; }
#gaojiu-refined .sb-workspace #sb-check-items p { display: flex; flex-wrap: wrap; gap: 4px 12px; margin: 4px 0; }
#gaojiu-refined .sb-workspace .sb-check-summary:empty { display: none; }
#gaojiu-refined .sb-workspace .sb-table-feedback {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 4px 12px;
}
#gaojiu-refined .sb-workspace .sb-table-feedback > .sb-table-note { flex: 1; min-width: 360px; }
#gaojiu-refined .sb-workspace .sb-table-feedback:has(details[open]) { display: block; }
#gaojiu-refined .sb-workspace .sb-payments-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(180px, 1fr) minmax(200px, 1fr);
  gap: 0 18px;
}
#gaojiu-refined .sb-workspace .sb-payments-panel > .sb-panel-head {
  grid-column: 1;
  grid-row: 1;
  min-height: 28px;
  margin: 0;
}
#gaojiu-refined .sb-workspace .sb-payments-panel > .sb-muted {
  grid-column: 1 / -1;
  grid-row: 2;
}
#gaojiu-refined .sb-workspace .sb-payments-panel > .sb-muted {
  margin: 0;
  line-height: 18px;
  font-size: 12px;
}
#gaojiu-refined .sb-workspace :is(.sb-payment-history,.sb-extra-notes) {
  margin: 0;
  min-width: 0;
  grid-row: 1;
}
#gaojiu-refined .sb-workspace :is(.sb-payment-history,.sb-extra-notes) > summary {
  padding: 4px 0;
  font-size: 13px;
  line-height: 20px;
  color: #7e5d42;
  cursor: pointer;
}
#gaojiu-refined .sb-workspace .sb-payments-panel:has(details[open]) {
  display: block;
}
#gaojiu-refined .sb-workspace .sb-notes-grid {
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 12px;
  align-items: start;
}
#gaojiu-refined .sb-workspace .sb-note {
  margin-top: 4px !important;
}
#gaojiu-refined .sb-workspace .sb-footer {
  padding: 6px 10px;
  bottom: 8px;
}
#gaojiu-refined .sb-workspace .sb-footer-totals {
  margin-bottom: 4px;
}
@media(max-width:1200px) {
  #gaojiu-refined .sb-workspace .sb-meta-identity {
    grid-template-columns: repeat(2,minmax(0,1fr));
  }
  #gaojiu-refined .sb-workspace .sb-meta-identity > label:first-child {
    grid-column: auto;
  }
  #gaojiu-refined .sb-workspace .sb-meta-identity .sb-period-status {
    grid-column: 1/-1;
    min-height: 22px;
  }
  #gaojiu-refined .sb-workspace .sb-meta-dates {
    grid-template-columns: repeat(2,minmax(0,1fr));
    gap: 6px 12px;
  }
  #gaojiu-refined .sb-workspace .sb-meta-dates > label {
    grid-template-columns: 56px minmax(0,1fr);
  }
}
@media(max-width:780px) {
  #gaojiu-refined .sb-workspace .sb-meta-identity,
  #gaojiu-refined .sb-workspace .sb-meta-dates,
  #gaojiu-refined .sb-workspace .sb-notes-grid,
  #gaojiu-refined .sb-workspace .sb-payments-panel {
    grid-template-columns: minmax(0,1fr);
  }
  #gaojiu-refined .sb-workspace .sb-meta-identity > label {
    flex-direction: row !important;
    align-items: center !important;
  }
  #gaojiu-refined .sb-workspace .sb-payments-panel { display: block; }
}

/* Six equal fields and a fourth column for source files and review status. */
#gaojiu-refined .sb-workspace .sb-top-panel {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  align-items: stretch;
}
#gaojiu-refined .sb-workspace .sb-entry-fields {
  grid-column: span 3;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px 14px;
  min-width: 0;
}
#gaojiu-refined .sb-workspace .sb-entry-fields > label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  line-height: 18px;
  min-width: 0;
  margin: 0;
}
#gaojiu-refined .sb-workspace .sb-entry-fields :is(input,select) {
  width: 100%;
  margin: 0;
}
#gaojiu-refined .sb-workspace .sb-attachment-column {
  display: grid;
  grid-template-rows: 28px minmax(0, 1fr) 22px;
  gap: 4px;
  height: 122px;
  min-width: 0;
  border-left: 1px solid var(--sb-line);
  padding-left: 14px;
}
#gaojiu-refined .sb-workspace .sb-attachment-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
#gaojiu-refined .sb-workspace .sb-attachment-heading h3 {
  font-size: 13px !important;
  line-height: 18px;
  margin: 0;
  white-space: nowrap;
}
#gaojiu-refined .sb-workspace .sb-attachment-heading .sb-upload {
  height: 28px !important;
  min-height: 28px !important;
  padding: 2px 8px !important;
}
#gaojiu-refined .sb-workspace .sb-attachment-content {
  min-height: 0;
  overflow: auto;
  scrollbar-gutter: stable;
}
#gaojiu-refined .sb-workspace .sb-attachment-content > .sb-muted {
  font-size: 12px;
  line-height: 18px;
  margin: 0 0 4px;
}
#gaojiu-refined .sb-workspace .sb-attachment-content:has(.sb-file-list > :is(a,div)) > .sb-muted { display: none; }
#gaojiu-refined .sb-workspace .sb-attachment-column .sb-file-list {
  display: grid;
  gap: 5px;
}
#gaojiu-refined .sb-workspace .sb-attachment-column .sb-file-list > :is(a,div) {
  display: grid;
  grid-template-columns: minmax(0,1fr) auto;
  align-items: center;
  gap: 1px 6px;
  padding: 4px 6px;
}
#gaojiu-refined .sb-workspace .sb-attachment-column .sb-file-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
}
#gaojiu-refined .sb-workspace .sb-attachment-column .sb-file-list > div > small {
  grid-column: 1;
  font-size: 11px;
  line-height: 16px;
}
#gaojiu-refined .sb-workspace .sb-attachment-column .sb-file-list .gj-button {
  height: 28px !important;
  min-height: 28px !important;
  padding: 2px 6px !important;
  grid-column: 2;
}
#gaojiu-refined .sb-workspace .sb-attachment-column .sb-file-list > div > .gj-button:last-child { grid-row: 1 / 3; }
#gaojiu-refined .sb-workspace .sb-attachment-column .sb-file-list > div:has(.sb-error) > .gj-button:last-child { grid-row: auto; }
#gaojiu-refined .sb-workspace .sb-attachment-column .sb-period-status {
  min-height: 22px;
  justify-content: flex-end;
  gap: 8px;
  white-space: nowrap;
}
#gaojiu-refined .sb-workspace .sb-grid tbody tr:nth-child(even) td { background: #fdfaf6; }
#gaojiu-refined .sb-workspace .sb-grid tbody tr:focus-within td { background: #fff4e7; }
@media (max-width: 1190px) {
  #gaojiu-refined .sb-workspace .sb-top-panel { grid-template-columns: repeat(3,minmax(0,1fr)); }
  #gaojiu-refined .sb-workspace .sb-attachment-column {
    grid-column: 1 / -1;
    grid-template-columns: minmax(180px,1fr) minmax(0,2fr) auto;
    grid-template-rows: auto;
    height: auto;
    min-height: 34px;
    border-left: 0;
    border-top: 1px solid var(--sb-line);
    padding: 8px 0 0;
    align-items: center;
    gap: 14px;
  }
  #gaojiu-refined .sb-workspace .sb-attachment-content { max-height: 68px; }
}
@media (max-width: 850px) {
  #gaojiu-refined .sb-workspace .sb-entry-fields { grid-template-columns: repeat(2,minmax(0,1fr)); }
  #gaojiu-refined .sb-workspace .sb-attachment-column { grid-template-columns: minmax(0,1fr) auto; }
  #gaojiu-refined .sb-workspace .sb-attachment-content { grid-row: 2; grid-column: 1 / -1; }
  #gaojiu-refined .sb-workspace .sb-attachment-column .sb-period-status { grid-row: 1; grid-column: 2; }
}
@media (max-width: 540px) {
  #gaojiu-refined .sb-workspace .sb-entry-fields { grid-template-columns: minmax(0,1fr); }
  #gaojiu-refined .sb-workspace .sb-attachment-column { display: flex; flex-direction: column; align-items: stretch; }
}

/* Scene association shows the whole period and explicit eligibility reasons. */
.sb-scene-toolbar { display:flex; align-items:center; flex-wrap:wrap; gap:8px; margin:10px 0; }
.sb-scene-toolbar > span { margin-left:auto; color:#88796d; font-size:13px; }
.sb-scene-groups { max-height:50vh; overflow:auto; padding:2px; }
.sb-scene-group { min-width:0; border:0; padding:0; margin:0 0 14px; }
.sb-scene-group:last-child { margin-bottom:0; }
.sb-scene-group legend { font-size:14px; font-weight:600; padding:0 0 8px; }
.sb-scene-group legend small { font-size:12px; font-weight:400; color:#88796d; }
.sb-scene-group .sb-scene-choices { max-height:none; overflow:visible; grid-template-columns:repeat(2,minmax(0,1fr)); }
.sb-scene-group .sb-scene-choices label { padding:8px; }
.sb-scene-group .sb-scene-choices input { flex-shrink:0; }
.sb-scene-group .sb-scene-choices .is-disabled { opacity:.7; background:#f7f5f2; }
@media(max-width:640px){ .sb-scene-group .sb-scene-choices { grid-template-columns:1fr; } }
.sb-dialog .sb-confirm-missing { display:flex; flex-direction:row; gap:8px; align-items:center; margin:12px 0 0; padding:10px; border-radius:7px; background:#fff5e8; }
.sb-dialog .sb-confirm-missing[hidden] { display:none; }
.sb-dialog .sb-confirm-missing input { width:16px; height:16px; min-height:16px; flex:0 0 16px; }

/* Everyday settlement stays in one table; optional accounting details stay closed. */
#gaojiu-refined .sb-workspace .sb-grid-review { min-width: 990px; }
#gaojiu-refined .sb-workspace .sb-grid-review th { width: auto; white-space: nowrap; }
#gaojiu-refined .sb-workspace .sb-grid-review .sb-col-select { width: 28px; }
#gaojiu-refined .sb-workspace .sb-grid-review .sb-col-room { width: 178px; }
#gaojiu-refined .sb-workspace .sb-grid-review .sb-col-amount { width: 90px; }
#gaojiu-refined .sb-workspace .sb-grid-review .sb-col-employee { width: 132px; }
#gaojiu-refined .sb-workspace .sb-grid-review .sb-col-tools { width: 50px; }
#gaojiu-refined .sb-workspace .sb-grid-review td :is(input,select) { padding-left: 5px; }
#gaojiu-refined .sb-workspace .sb-grid-review .sb-room-meta small { white-space: normal; overflow-wrap: anywhere; }
.sb-link-state { display: flex; flex-wrap: wrap; align-items: center; gap: 0 5px; margin-top: 1px; }
#gaojiu-refined .sb-workspace .sb-link-status { font-size: 12px; line-height: 18px; min-height: 20px; padding: 0; color: #627965; }
#gaojiu-refined .sb-workspace .sb-link-status.sb-pending { color: #a16a35; }
#gaojiu-refined .sb-workspace .sb-link-state small { font-size: 12px; line-height: 17px; margin: 0; }
#gaojiu-refined .sb-workspace .sb-link-notice { color: #a16a35; overflow-wrap: anywhere; }
.sb-more-actions { position: relative; }
.sb-more-actions > summary { display: flex; align-items: center; min-height: 34px; padding: 0 10px; border: 1px solid #ead7c5; border-radius: 7px; color: #785238; cursor: pointer; list-style: none; white-space: nowrap; }
.sb-more-actions > summary::after { content: '▾'; margin-left: 7px; font-size: 11px; }
.sb-more-actions > div { position: absolute; right: 0; top: calc(100% + 5px); display: grid; gap: 5px; padding: 7px; border: 1px solid #ead7c5; border-radius: 8px; background: #fffaf5; z-index: 25; box-shadow: 0 5px 16px #46301a18; min-width: 142px; }
.sb-more-actions:not([open]) > div { display: none; }
.sb-payment-panels { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; align-items: stretch; }
.sb-payment-panels .sb-panel { min-width: 0; }
.sb-payment-stats { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 7px; margin: 7px 0; }
.sb-payment-stats > span { display: flex; flex-direction: column; gap: 3px; font-size: 12px; color: #88796d; }
.sb-payment-stats strong { font-size: 16px; color: #785238; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.sb-employee-balances { display: grid; gap: 3px; color: #786b5e; font-size: 12px; line-height: 18px; }
.sb-unallocated { background: #fff5e8; color: #996330; border-radius: 6px; padding: 5px 8px; font-size: 12px; line-height: 18px; margin: 7px 0; }
#gaojiu-refined .sb-workspace .sb-payment-history { margin: 5px 0 0; }
#gaojiu-refined .sb-workspace .sb-payment-history > summary { font-size: 12px; padding: 3px 0; }
.sb-payment-history .sb-table { min-width: 450px; }
.sb-payment-history .sb-inline { gap: 4px; margin-top: 4px; }
#gaojiu-refined .sb-workspace .sb-payment-history .gj-button { min-height: 28px !important; height: 28px !important; padding: 2px 5px !important; font-size: 12px !important; }
.sb-payment-guide { margin: 8px 0; font-size: 12px; }
.sb-payment-allocation-note { border-radius: 7px; padding: 10px 12px; color: #8d613b; background: #fff5e8; line-height: 1.7; font-size: 13px; }
.sb-payment-meta:has(> label:first-child:nth-last-child(2)) { grid-template-columns: repeat(2,minmax(0,1fr)); }
.sb-row-facts { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 8px 14px; background: #fcf8f2; padding: 10px; margin: 10px 0; border-radius: 7px; font-size: 13px; }
.sb-scene-choices [data-open-claim] { margin-top: 4px; font-size: 12px; color: #a16a35; }
@media(max-width: 1050px) {
  .sb-payment-panels { grid-template-columns: minmax(0,1fr); }
}
@media(max-width: 640px) {
  .sb-row-facts { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .sb-payment-meta:has(> label:first-child:nth-last-child(2)) { grid-template-columns: minmax(0,1fr); }
  .sb-payment-stats strong { font-size: 15px; }
}

/* Compact overview and date/time fields keep the focus on amounts and the period. */
#gaojiu-refined .sb-workspace .sb-stats-compact { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; margin-bottom: 10px; }
#gaojiu-refined .sb-workspace .sb-stats-compact > div { padding: 12px 16px; gap: 4px; }
#gaojiu-refined .sb-workspace .sb-stats-compact strong { font-size: 24px; line-height: 30px; }
.sb-stats-compact small { font-size: 12px; line-height: 18px; color: #93806f; }
.sb-mine-period { border-bottom: 1px solid var(--sb-line); }
.sb-mine-period:last-child { border-bottom: 0; }
.sb-mine-period > summary { display: grid; align-items: center; gap: 12px; position: relative; padding: 12px 22px 12px 0; cursor: pointer; list-style: none; color: #7a6553; }
.sb-mine-period > summary { grid-template-columns: minmax(280px,1.8fr) minmax(160px,1fr) minmax(160px,1fr); }
.sb-mine-period > summary::-webkit-details-marker { display: none; }
.sb-mine-period > summary::after { content: '▾'; position: absolute; right: 1px; top: 50%; transform: translateY(-50%); color: #ab754a; }
.sb-mine-period[open] > summary::after { transform: translateY(-50%) rotate(180deg); }
.sb-mine-period > summary strong { color: #574334; font-size: 14px; }
.sb-mine-period > summary b { color: #a25b2d; font-weight: 600; font-size: 15px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.sb-mine-period > summary small { display: block; font-size: 12px; line-height: 18px; color: #93806f; margin-top: 4px; }
.sb-mine-period .sb-table { min-width: 600px; }
#gaojiu-refined .sb-workspace .sb-payment-stats { grid-template-columns: repeat(2,minmax(0,1fr)); }
#gaojiu-refined .sb-workspace .sb-refund-hint { font-size: 12px; line-height: 18px; margin-top: 2px; white-space: nowrap; }
#gaojiu-refined .sb-workspace .sb-period-field { display: flex; flex-direction: column; gap: 4px; line-height: 18px; min-width: 0; color: #756555; }
.sb-period-parts { display: flex; align-items: center; gap: 6px; min-width: 0; }
#gaojiu-refined .sb-workspace .sb-period-parts > input { flex: 1 1 140px; width: 0; min-width: 0; padding-left: 7px; padding-right: 5px; }
.sb-timepicker { position: relative; flex: 0 0 94px; min-width: 0; }
.sb-timepicker > summary { box-sizing: border-box; height: 34px; display: flex; align-items: center; justify-content: center; gap: 5px; border: 1px solid #ddcfc1; border-radius: 7px; background: #fff; color: #352b25; font-size: 13px; font-variant-numeric: tabular-nums; list-style: none; cursor: pointer; }
.sb-timepicker > summary::-webkit-details-marker { display: none; }
.sb-timepicker > summary::after { content: '▾'; color: #93806f; font-size: 10px; }
.sb-timepicker > summary:focus-visible { outline: 2px solid #e6ac77; outline-offset: 1px; }
.sb-time-popover { position: absolute; top: 40px; right: 0; z-index: 50; box-sizing: border-box; width: 226px; padding: 9px; border: 1px solid #e5d4c3; border-radius: 8px; background: #fffdf9; box-shadow: 0 6px 20px #46301a20; }
.sb-time-columns { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 8px; }
#gaojiu-refined .sb-workspace .sb-time-column > label { gap: 3px; align-items: stretch; text-align: center; font-size: 12px; }
#gaojiu-refined .sb-workspace .sb-time-column input { text-align: center; padding: 5px !important; }
.sb-time-values { max-height: 138px; overflow-y: auto; margin-top: 5px; scrollbar-width: thin; overscroll-behavior: contain; }
.sb-time-values button { width: 100%; min-height: 27px; padding: 3px 0; border: 0; border-radius: 4px; background: transparent; color: #746352; font-size: 13px; cursor: pointer; font-variant-numeric: tabular-nums; }
.sb-time-values button[aria-selected=true] { background: #f9e7d5; color: #a75a24; font-weight: 600; }
.sb-time-values button:hover { background: #fff0df; }
.sb-time-values button:disabled { opacity: .45; cursor: default; }
.sb-time-popover > small { display: block; margin-top: 7px; text-align: center; color: #95816f; font-size: 11px; line-height: 16px; }
@media(max-width: 850px) {
 .sb-mine-period > summary { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 6px 12px; }
 .sb-mine-period > summary > span:first-child { grid-column: 1 / -1; }
}

/* A shared second line keeps all entry controls aligned with the refund hint. */
#gaojiu-refined .sb-workspace .sb-grid-review :is(th,td) { padding: 4px 6px !important; }
.sb-grid-review .sb-entry-cell { display: grid; grid-template-rows: 34px 14px; gap: 1px; min-width: 0; }
.sb-grid-review .sb-entry-control { display: flex; align-items: center; justify-content: center; min-width: 0; height: 34px; }
.sb-grid-review .sb-entry-control > :is(input,select) { width: 100%; }
#gaojiu-refined .sb-workspace .sb-entry-hint { display: block; height: 14px; line-height: 14px; margin: 0; font-size: 12px; white-space: nowrap; }
.sb-grid-review .sb-entry-hint.is-empty { visibility: hidden; }

/* Payment records reserve one right-aligned action column for every row. */
#gaojiu-refined .sb-workspace .sb-payment-panels { gap: 10px; margin-bottom: 8px; }
#gaojiu-refined .sb-workspace .sb-payment-panels > .sb-panel { padding: 8px 10px !important; margin-bottom: 0 !important; }
#gaojiu-refined .sb-workspace .sb-payment-panels .sb-panel-head { margin-bottom: 3px; }
#gaojiu-refined .sb-workspace .sb-payment-stats { gap: 8px; margin: 4px 0; }
.sb-payment-stats > span { flex-direction: row; align-items: baseline; flex-wrap: wrap; gap: 2px 7px; line-height: 22px; }
.sb-payment-stats strong { line-height: 22px; }
#gaojiu-refined .sb-workspace .sb-payment-history { margin: 2px 0 0; }
#gaojiu-refined .sb-workspace .sb-payment-history > summary { padding: 2px 0; line-height: 20px; }
.sb-payment-history > .sb-muted { margin: 3px 0; font-size: 12px; }
.sb-payment-record-table { table-layout: fixed; }
.sb-payment-history .sb-payment-record-table { min-width: 440px; }
.sb-payment-date-col { width: 104px; }
.sb-payment-amount-col { width: 84px; }
.sb-payment-actions-col { width: 126px; }
#gaojiu-refined .sb-workspace .sb-payment-record-table :is(th,td) { padding: 4px 5px !important; }
.sb-payment-note { overflow-wrap: anywhere; }
#gaojiu-refined .sb-workspace .sb-payment-actions-cell { text-align: right; }
.sb-payment-actions { display: flex; align-items: center; justify-content: flex-end; flex-wrap: nowrap; gap: 6px; }
#gaojiu-refined .sb-workspace .sb-payment-actions .gj-button { height: 28px !important; min-height: 28px !important; padding: 2px 6px !important; margin: 0 !important; font-size: 12px !important; line-height: 20px; background: #fffdf9; color: #7a6a5b; border-color: #e4dbd1; }
#gaojiu-refined .sb-workspace .sb-payment-actions [data-sb-action=delete-payment] { color: #a34c42; border-color: #e5ccc5; background: #fffaf7; }
#gaojiu-refined .sb-workspace .sb-payment-actions [data-sb-action=delete-payment]:hover { color: #913d34; background: #fff1eb; }
.sb-deleted-payments > summary { color: #938171; }

/* One footer row when it fits; action groups wrap together and remain visible. */
#gaojiu-refined .sb-workspace .sb-footer { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 5px 14px; padding: 7px 10px; }
#gaojiu-refined .sb-workspace .sb-footer-totals { flex: 1 1 500px; min-width: 0; min-height: 34px; margin: 0; padding: 0; border: 0; align-items: center; gap: 5px 14px; }
.sb-footer-totals > span { white-space: nowrap; }
#gaojiu-refined .sb-workspace .sb-footer-actions { flex: 0 1 auto; min-height: 34px; margin-left: auto; align-items: center; flex-wrap: nowrap; gap: 10px; }
#gaojiu-refined .sb-workspace .sb-footer-actions > span { white-space: nowrap; }
#gaojiu-refined .sb-workspace .sb-footer-actions .sb-inline { width: auto; margin-left: 0; flex-wrap: nowrap; }
@media(max-width: 640px) {
 #gaojiu-refined .sb-workspace .sb-footer-totals { flex-basis: 100%; min-height: 24px; }
 #gaojiu-refined .sb-workspace .sb-footer-actions { flex-wrap: wrap; justify-content: flex-end; gap: 4px 10px; }
 #gaojiu-refined .sb-workspace .sb-footer-actions .sb-inline { margin-left: auto; }
}

/* Long notes and employee names wrap within their cells without covering actions. */
#gaojiu-refined .sb-workspace .sb-payment-record-table td.sb-payment-note,
#gaojiu-refined .sb-workspace .sb-payment-record-table td:first-child { white-space: normal !important; overflow-wrap: anywhere; text-align: left !important; }
#gaojiu-refined .sb-workspace .sb-payment-record-table td:first-child small { white-space: normal !important; overflow-wrap: anywhere; }
#gaojiu-refined .sb-workspace .sb-payment-record-table td:nth-child(2) { white-space: nowrap !important; }

/* Paired identity fields keep eight metadata inputs within the existing two-row grid. */
#gaojiu-refined .sb-workspace .sb-meta-pair { display: grid; grid-template-columns: minmax(140px,1.6fr) minmax(98px,1fr); gap: 10px; min-width: 0; }
#gaojiu-refined .sb-workspace .sb-meta-pair > label { display: flex; flex-direction: column; min-width: 0; gap: 4px; margin: 0; line-height: 18px; }
#gaojiu-refined .sb-workspace .sb-meta-pair input[data-sb-meta=settlementNumber] { text-align: center; }
#gaojiu-refined .sb-workspace .sb-grid-review { min-width: 1030px; }
#gaojiu-refined .sb-workspace .sb-grid-review .sb-col-amount { width: 104px; }
#gaojiu-refined .sb-workspace .gj-button { border-radius: 8px; font-weight: 500; transition: background-color .15s,border-color .15s,box-shadow .15s; }
#gaojiu-refined .sb-workspace .gj-button-primary { background: #c96c2c; border-color: #c96c2c; box-shadow: 0 1px 2px #97501918; }
#gaojiu-refined .sb-workspace .gj-button-primary:hover { background: #b95e23; border-color: #b95e23; }
#gaojiu-refined .sb-workspace .gj-button-soft:hover { background: #fff0df; border-color: #dbba99; }
#gaojiu-refined .sb-workspace .gj-button:focus-visible { outline: 2px solid #dea374; outline-offset: 2px; }

/* Explicit columns keep sequence, units, and money aligned throughout the list. */
.sb-batch-list-table { table-layout: fixed; min-width: 1040px; }
.sb-batch-number-col { width: 88px; }
.sb-batch-period-col { width: 182px; }
.sb-batch-rooms-col { width: 62px; }
.sb-batch-units-col { width: 64px; }
.sb-batch-money-col { width: 110px; }
.sb-batch-status-col { width: 84px; }
.sb-batch-actions-col { width: 158px; }
#gaojiu-refined .sb-workspace .sb-batch-list-table :is(th,td):nth-child(1),
#gaojiu-refined .sb-workspace .sb-batch-list-table :is(th,td):nth-child(4),
#gaojiu-refined .sb-workspace .sb-batch-list-table :is(th,td):nth-child(8) { text-align: center; }
#gaojiu-refined .sb-workspace .sb-batch-list-table :is(th,td):nth-child(5),
#gaojiu-refined .sb-workspace .sb-batch-list-table :is(th,td):nth-child(6),
#gaojiu-refined .sb-workspace .sb-batch-list-table :is(th,td):nth-child(7),
#gaojiu-refined .sb-workspace .sb-batch-list-table :is(th,td):nth-child(9) { text-align: right; }
#gaojiu-refined .sb-workspace .sb-batch-list-table .sb-batch-name { white-space: normal !important; overflow-wrap: anywhere; }
.sb-batch-list-table .sb-batch-number { color: #a7602e; font-weight: 600; }
.sb-batch-list-table .sb-batch-subline { display: flex; align-items: baseline; flex-wrap: wrap; gap: 2px 8px; }
.sb-batch-subline > span + span { padding-left: 8px; border-left: 1px solid #ddcfc1; }
.sb-batch-list-table td:last-child .sb-inline { justify-content: flex-end; }

/* Notifications sit above the measured save bar instead of covering its buttons. */
body:has(.sb-workspace) #toast { box-sizing: border-box; bottom: var(--sb-toast-bottom,24px); left: var(--sb-toast-left,50%); width: max-content; max-width: min(var(--sb-toast-width,760px),calc(100vw - 24px)); z-index: 60; display: flex; align-items: flex-start; gap: 12px; padding: 12px 15px; border-radius: 9px; line-height: 21px; white-space: pre-wrap; overflow-wrap: anywhere; }
body:has(.sb-workspace) #toast .sb-toast-content { flex: 1 1 auto; min-width: 0; max-height: min(38vh,calc(100vh - var(--sb-toast-bottom,24px) - 36px)); overflow-y: auto; overscroll-behavior: contain; white-space: pre-wrap; overflow-wrap: anywhere; }
body:has(.sb-workspace) #toast .sb-toast-locate { flex: 0 0 auto; border: 1px solid #ffffff66; border-radius: 6px; padding: 3px 8px; margin: 0; color: inherit; background: #ffffff12; font: inherit; font-size: 12px; line-height: 18px; }
#sb-notice:empty { display: none; }
.sb-page-notice { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 10px 12px; margin-bottom: 10px; border: 1px solid #e8c6b5; border-left: 3px solid #b96842; border-radius: 8px; background: #fff6ef; color: #914728; }
.sb-page-notice > p { flex: 1 1 auto; min-width: 0; margin: 0; font-size: 13px; line-height: 22px; white-space: pre-wrap; overflow-wrap: anywhere; }
.sb-notice-actions { display: flex; gap: 6px; flex-wrap: nowrap; }
.sb-inline-notice { padding: 8px 10px; border-radius: 7px; background: #fff1e8; color: #93472c; font-size: 13px; line-height: 22px; white-space: pre-wrap; overflow-wrap: anywhere; }
@media(max-width: 780px) {
 .sb-page-notice { flex-direction: column; gap: 6px; }
 .sb-notice-actions { align-self: flex-end; }
}

/* Override shared table alignment for the bill identity column. */
#gaojiu-refined .sb-workspace .sb-batch-list-table :is(th,td):nth-child(2),
#gaojiu-refined .sb-workspace .sb-batch-list-table :is(th,td):nth-child(3) { text-align: left !important; }
#gaojiu-refined .sb-workspace .sb-batch-list-table .sb-batch-name > strong { display: block; text-align: left; }
#gaojiu-refined .sb-workspace .sb-batch-list-table .sb-batch-subline { justify-content: flex-start; text-align: left; }

/* Employee totals share real table columns; per-period detail opens inline. */
.sb-employee-table { table-layout: fixed; min-width: 640px; }
.sb-employee-account-col { width: 20%; }
.sb-employee-amount-col { width: 18%; }
.sb-employee-units-col { width: 12%; }
.sb-employee-table > thead > tr > th:nth-child(n+3),
.sb-employee-table > tbody > .sb-employee-row > .sb-employee-number { text-align: right !important; white-space: nowrap; font-variant-numeric: tabular-nums; }
.sb-employee-row > td { vertical-align: middle; }
.sb-employee-row:nth-child(4n+3) { background: #fcfaf7; }
.sb-employee-rooms span { display: block; line-height: 20px; overflow-wrap: anywhere; }
#gaojiu-refined .sb-workspace .sb-employee-expand { display: inline-flex; align-items: center; gap: 7px; max-width: 100%; text-align: left; font-size: 14px; font-weight: 600; overflow-wrap: anywhere; white-space: normal; }
.sb-employee-expand > span { flex: none; color: #b17a50; }
.sb-employee-expand:focus-visible { outline: 2px solid #d87c35; outline-offset: 3px; border-radius: 3px; }
.sb-employee-total { color: #b65f25; font-weight: 700; font-size: 15px; }
.sb-employee-detail[hidden] { display: none; }
.sb-employee-detail > td { padding: 0 12px 12px !important; background: #faf6f0; }
.sb-employee-detail .sb-table { table-layout: auto; min-width: 580px; }
.sb-employee-detail .sb-table td { white-space: normal; overflow-wrap: anywhere; }
.sb-employee-hint { margin: 8px 0 0; font-size: 12px; line-height: 18px; color: #8c7968; }
#gaojiu-refined .sb-workspace .sb-employee-table > thead > tr > th:nth-child(-n+2),
#gaojiu-refined .sb-workspace .sb-employee-table > tbody > .sb-employee-row > td:nth-child(-n+2) { text-align: left !important; }
#gaojiu-refined .sb-workspace .sb-employee-table > tbody > .sb-employee-row > .sb-employee-total { color: #b65f25 !important; font-weight: 700; }
