.batch-dialog { width: min(920px, calc(100% - 26px)); }
.batch-dialog header { gap: 14px; }
.scan-count { margin-left: auto; display: grid; text-align: center; padding: 6px 12px; border-radius: 12px; background: var(--sage); color: var(--forest); }
.scan-count strong { font: 600 1.35rem Georgia, serif; }
.scan-count span { font-size: .65rem; }
.batch-scan-layout { display: grid; grid-template-columns: minmax(280px, 1.35fr) minmax(210px, .65fr); gap: 18px; }
.scan-recent { padding: 16px; border: 1px solid var(--line); border-radius: 14px; background: var(--paper); }
.scan-recent h3 { margin: 0 0 10px; font-size: .85rem; }
.scan-recent ol { list-style: none; padding: 0; margin: 0; display: grid; }
.scan-recent li { display: grid; grid-template-columns: auto 1fr; gap: 4px 9px; padding: 9px 0; border-top: 1px solid var(--line); font-size: .76rem; }
.scan-recent li:first-child { border-top: 0; }
.scan-recent small { grid-column: 2; color: var(--muted); }
.inline-barcode-form { display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 9px; margin-top: 14px; padding: 0; }
.batch-legend { display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0; }
.batch-legend span, .batch-status { display: inline-flex; padding: 5px 8px; border-radius: 999px; font-size: .68rem; }
.batch-legend .ready, .batch-status.ready, .batch-status.imported { background: #dcebdd; color: #245635; }
.batch-legend .review, .batch-status.review, .batch-status.error { background: #f8e7c6; color: #6c4b13; }
.batch-legend .owned, .batch-status.owned { background: #e3e7e4; color: #59615b; }
.batch-legend .missing, .batch-status.missing { background: #f4dfd8; color: var(--danger); }
.batch-review-list { display: grid; gap: 10px; max-height: 58vh; overflow: auto; }
.batch-review-item { display: grid; grid-template-columns: 64px 1fr auto; align-items: center; gap: 12px; padding: 11px; border: 1px solid var(--line); border-left: 4px solid #bfaa72; border-radius: 12px; }
.batch-review-item.ready, .batch-review-item.imported { border-left-color: #63926e; }
.batch-review-item.owned { border-left-color: #9da49e; }
.batch-review-item.missing, .batch-review-item.error { border-left-color: #b85c49; }
.batch-review-item img { width: 64px; height: 58px; object-fit: contain; background: white; border-radius: 7px; }
.batch-review-item > div { display: grid; }
.batch-review-item span { color: var(--muted); font-size: .72rem; margin-top: 3px; }

@media (max-width: 700px) {
  .batch-scan-layout { grid-template-columns: 1fr; }
  .scan-recent { max-height: 180px; overflow: auto; }
  .batch-review-item { grid-template-columns: 50px 1fr; }
  .batch-review-item img { width: 50px; height: 48px; }
  .batch-review-item .button { grid-column: 1 / -1; }
  .inline-barcode-form { grid-template-columns: 1fr; }
  .batch-dialog footer { flex-wrap: wrap; }
  .batch-dialog footer .button { flex: 1; }
}
