/* Keep the complete name and its badge in one naturally wrapping title line.
   Products without batches reserve no extra row or badge space. */
.expiry-slot { display:inline; }
.expiry-slot:empty { display:none; }
.expiry-slot:not(:empty) { display:inline-block; margin-left:6px; vertical-align:middle; }
.expiry-pill { display:inline-flex; align-items:center; min-height:24px; padding:2px 8px; white-space:nowrap;
  border:1px solid #cbd5e1; border-radius:999px; background:#f1f5f9; color:#475569;
  font-family:inherit; font-size:11px; line-height:1.2; font-weight:700; cursor:pointer; }
.expiry-pill:disabled { opacity:.6; cursor:default; }
.expiry-near { background:#fffbeb; color:#92400e; border-color:#f1d181; }
.expiry-expired { background:#fef2f2; color:#b91c1c; border-color:#efb5b5; }
.expiry-unknown, .expiry-stale { border-style:dashed; }
#batchDlg { width:580px; max-width:calc(100vw - 24px); }
#batchDlg .dlg-body { width:auto; max-width:100%; }
.batch-product { font-size:16px; font-weight:700; overflow-wrap:anywhere; }
.batch-product small { display:block; font-size:13px; font-weight:400; color:var(--dim); }
.batch-meta { display:flex; flex-wrap:wrap; justify-content:space-between; gap:8px;
  margin:12px 0; font-size:12px; color:var(--dim); }
.batch-meta b { color:var(--green-d); }
.batch-table { width:100%; table-layout:fixed; border-collapse:collapse; font-size:13px; }
.batch-table th, .batch-table td { padding:10px 6px; text-align:left; border-bottom:1px solid var(--grid-line); overflow-wrap:anywhere; }
.batch-table th { color:var(--dim); font-size:12px; }
.batch-table th:first-child { width:50%; }
.batch-table th:last-child { width:18%; }
.batch-table td:last-child, .batch-table th:last-child { text-align:right; }
.batch-table small { display:block; margin-top:3px; color:var(--dim); font-size:11px; }
.batch-totals { display:flex; justify-content:space-between; gap:8px; flex-wrap:wrap; margin-top:12px; font-size:12px; color:var(--dim); }
.batch-totals b { color:var(--txt); }
.batch-warning, .batch-table .batch-warning { color:var(--red); }
.batch-near, .batch-table .batch-near { color:#92400e; }
.batch-note, .batch-allocation, .batch-warning, .batch-empty { font-size:12px; margin-top:10px; }
.batch-note, .batch-allocation { color:var(--dim); }
.batch-actions { display:flex; justify-content:flex-end; gap:8px; margin-top:16px; }
.batch-actions [hidden] { display:none; }
@media (pointer:coarse) {
  .expiry-pill { min-height:32px; }
  .batch-actions button { min-height:44px; }
}
