/* ==========================================================================
   Inventory list screens: session list, session lines / discrepancies, campaign follow-up, participants filter.
   Builds on the list toolkit (app.css .lk-* / .dt-*) and inventory-campaign.css; tokens only.
   ========================================================================== */

/* ---------- Page tabs above a filter bar: underline tabs, never mistaken for the quick-view chips ---------- */
.inv-tabs {
  flex: 1 1 100%;
  min-width: 0;
  border-bottom: 1px solid var(--line);
}
.inv-tabs .chips {
  gap: 2px;
}
.inv-tabs .chip {
  border: 0;
  border-bottom: 2px solid transparent;
  border-radius: 0;
  background: none;
  margin-bottom: -1px;
  padding: 7px 12px 8px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--muted);
}
.inv-tabs .chip:hover {
  color: var(--ink);
}
.inv-tabs .chip.on {
  background: none;
  color: var(--ink);
  border-bottom-color: var(--brand);
}
.inv-tabs .chip .n {
  font-weight: 600;
  font-size: 11.5px;
  background: var(--surface-3);
  color: var(--text-2);
  border-radius: 99px;
  padding: 0 6px;
  opacity: 1;
}
.toolbar > .inv-tabs ~ .lk-bar {
  flex: 1 1 100%;
}

/* ---------- Book vs counted: difference badge ---------- */
.qd {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  padding: 1px 7px;
  border-radius: 6px;
  font-family: var(--f-mono);
  font-size: 12.5px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  line-height: 1.5;
  white-space: nowrap;
}
.qd.neg {
  background: var(--bad-soft);
  color: var(--bad);
}
.qd.pos {
  background: var(--info-soft);
  color: var(--info);
}
.qd.zero,
.qd.none {
  color: var(--muted);
  font-weight: 500;
}

/* ---------- Zone / team chips ---------- */
.inv-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  max-width: 100%;
  padding: 0 8px;
  border-radius: 6px;
  background: var(--surface-3);
  color: var(--text-2);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.7;
  white-space: nowrap;
}
.inv-chip.zone {
  font-family: var(--f-mono);
  letter-spacing: 0.01em;
}
.inv-chip.zone.none {
  font-family: var(--f-body);
  font-weight: 500;
  background: var(--warn-soft);
  color: var(--warn);
}
.inv-chip.team {
  background: var(--surface);
  border: 1px solid var(--line-2);
  line-height: 1.55;
}

/* ---------- Table cells ---------- */
.inv-pcell {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 150px;
}
.inv-pcell .bar {
  flex: 1;
  min-width: 70px;
}
.inv-issues,
.inv-res,
.inv-where {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 6px;
}
.dt .inv-issues,
.dt .inv-res {
  flex-wrap: nowrap;
}
.inv-note {
  display: block;
  max-width: 260px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--text-2);
}
.inv-note .st {
  vertical-align: 1px;
}
.inv-ev {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  margin-left: 6px;
  color: var(--muted);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}
.inv-ev .icon {
  width: 13px;
  height: 13px;
}
.inv-dmg {
  color: var(--warn);
  font-weight: 600;
}
.inv-need {
  display: inline-flex;
  color: var(--warn);
}
.inv-need .icon {
  width: 16px;
  height: 16px;
}
.inv-hint {
  margin: 0;
}
.dt .t td .sm-select {
  height: 30px !important;
}

/* ---------- Phone / tablet line card ---------- */
.inv-lcard .inv-qline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 2px 8px;
  margin-top: 4px;
  font-size: 13px;
  color: var(--text-2);
}
.inv-lcard .inv-qline b {
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.inv-lcard .code.inv-kind {
  font-family: var(--f-body);
  font-size: 12px;
}
.inv-lcard .lk-facts {
  align-items: center;
}
.inv-lcard .lk-facts .st {
  font-size: 11.5px;
}

/* ---------- Line sheet: book / counted / difference tiles ---------- */
.inv-qbig {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
  gap: 8px;
}
.inv-qbig > div {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 10px 12px;
  border-radius: var(--r);
  background: var(--surface-2);
  border: 1px solid var(--line);
}
.inv-qbig small {
  color: var(--muted);
  font-size: 12px;
}
.inv-qbig b {
  font-size: 20px;
  line-height: 1.1;
  color: var(--ink);
}
.inv-qbig .qd {
  font-size: 15px;
  padding: 2px 9px;
}

/* ---------- Participants filter ---------- */
.inv-ptools {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.inv-ptools > .search {
  flex: 1 1 240px;
}
.inv-ptools > select.input {
  flex: 1 1 200px;
  width: auto;
  min-width: 0;
  max-width: 100%;
}
@media (min-width: 640px) {
  .inv-ptools > select.input {
    flex: 0 1 260px;
  }
}
.inv-pill-btn {
  border: 0;
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}
.inv-pill-btn:hover {
  background: var(--line);
}
.inv-pill-btn.on {
  background: var(--ink);
  color: var(--surface);
}
.inv-pill-btn:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 1px;
}

/* ---------- Campaign cards ---------- */
.cc-ic {
  width: 13px;
  height: 13px;
  vertical-align: -2px;
}
.camp-card.cs-ACTIVE {
  box-shadow:
    inset 3px 0 0 var(--brand),
    var(--shadow);
}

/* ---------- Counting screen ---------- */
.cnt-need {
  font-size: 11.5px;
}
