/* Compact Dealer Inventory screen (Super Admin). Scoped to the inventory view only; other admin screens are unchanged. */
[data-view="inventory"] { --inv-ink: #0b2e75; --inv-muted: #5b6b85; --inv-line: #e3e9f3; --inv-soft: #f5f8fd; --inv-blue: #1769d2; --inv-red: #c0392b; }
[data-view="inventory"] .panel { padding: 18px 20px; border-radius: 14px; margin-bottom: 16px; }
[data-view="inventory"] .panel-heading { align-items: flex-start; gap: 16px; margin-bottom: 14px; }
[data-view="inventory"] .panel-heading h2 { margin: 0 0 4px; font-size: 19px; color: var(--inv-ink); }
[data-view="inventory"] .panel-heading p { max-width: 860px; margin: 0; font-size: 12.5px; line-height: 1.5; color: var(--inv-muted); }
[data-view="inventory"] .panel-heading .table-actions { flex: 0 0 auto; }

/* Buttons: undo the large global button size (modern.css) inside this view. */
[data-view="inventory"] .admin-button,
[data-view="inventory"] .quiet-button { min-height: 34px; padding: 0 14px; border-radius: 8px; font-size: 13px; white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; }
[data-view="inventory"] .quiet-button { background: #fff; border: 1px solid var(--inv-line); color: var(--inv-ink); }

/* Toolbar: search + filters on the left, Reset / Add item on the right. */
[data-view="inventory"] .inv-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 0 0 12px; }
[data-view="inventory"] .inv-toolbar input[type="search"],
[data-view="inventory"] .inv-toolbar select { height: 36px; min-height: 36px; padding: 0 12px; border: 1px solid var(--inv-line); border-radius: 8px; font-size: 13px; background: #fff; }
[data-view="inventory"] .inv-toolbar input[type="search"] { flex: 1 1 220px; max-width: 300px; }
[data-view="inventory"] .inv-toolbar select { flex: 0 1 170px; }
[data-view="inventory"] .inv-toolbar-end { display: flex; gap: 8px; margin-left: auto; }

/* Table */
[data-view="inventory"] .table-scroll { border: 1px solid var(--inv-line); border-radius: 10px; overflow-x: auto; }
[data-view="inventory"] table { width: 100%; border-collapse: collapse; font-size: 13px; }
[data-view="inventory"] th { padding: 9px 12px; background: var(--inv-soft); font-size: 11px; letter-spacing: .04em; color: #42557a; text-align: left; white-space: nowrap; }
[data-view="inventory"] td { padding: 9px 12px; border-top: 1px solid var(--inv-line); vertical-align: middle; }
[data-view="inventory"] .table-primary { font-size: 13.5px; }
[data-view="inventory"] .table-secondary { font-size: 12px; }

/* Product cell: thumbnail + name + "ID · size". */
[data-view="inventory"] .inv-product { display: flex; align-items: center; gap: 10px; min-width: 210px; }
[data-view="inventory"] .inv-thumb { flex: 0 0 40px; width: 40px; height: 40px; border: 1px solid var(--inv-line); border-radius: 8px; object-fit: contain; background: #fff; }
[data-view="inventory"] .inv-thumb--empty { display: inline-flex; align-items: center; justify-content: center; color: #9fb0c9; }
[data-view="inventory"] .inv-thumb--empty svg { width: 20px; height: 20px; }
[data-view="inventory"] .inv-product-name { display: block; font-weight: 700; color: var(--inv-ink); line-height: 1.3; }
[data-view="inventory"] .inv-product-meta { display: block; margin-top: 2px; font-size: 12px; color: var(--inv-muted); white-space: nowrap; }
[data-view="inventory"] .inv-stock { white-space: nowrap; }
[data-view="inventory"] .inv-stock strong { font-size: 14px; color: var(--inv-ink); }

/* Status pill with a dot. */
[data-view="inventory"] .inv-status { display: inline-flex; align-items: center; gap: 6px; padding: 3px 9px; border-radius: 999px; font-size: 12px; font-weight: 700; white-space: nowrap; }
[data-view="inventory"] .inv-status::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
[data-view="inventory"] .inv-status--ok { background: #e7f6ec; color: #1b7a3d; }
[data-view="inventory"] .inv-status--warn { background: #fff4dc; color: #9a6200; }
[data-view="inventory"] .inv-status--bad { background: #fdecea; color: #b3261e; }
[data-view="inventory"] .inv-status--muted { background: #eef1f6; color: #5b6b85; }

/* Actions: one compact row, never cut off. */
[data-view="inventory"] .inv-actions { display: flex; align-items: center; gap: 6px; white-space: nowrap; }
[data-view="inventory"] .inv-actions .table-action { min-height: 30px; padding: 0 10px; border-radius: 7px; font-size: 12px; }
[data-view="inventory"] .inv-icon-button { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; min-height: 30px; padding: 0; border: 1px solid var(--inv-line); border-radius: 7px; background: #fff; color: var(--inv-blue); cursor: pointer; }
[data-view="inventory"] .inv-actions .inv-icon-button { flex: 0 0 30px; width: 30px; padding: 0; }
[data-view="inventory"] .inv-icon-button svg { flex: 0 0 16px; width: 16px; height: 16px; }
[data-view="inventory"] .inv-icon-button:hover { background: #eef4ff; }
[data-view="inventory"] .inv-icon-button.delete { color: var(--inv-red); border-color: #f3c9c4; }
[data-view="inventory"] .inv-icon-button.delete:hover { background: #fdecea; }
[data-view="inventory"] .inv-icon-button:disabled { opacity: .5; cursor: default; }
[data-view="inventory"] .inv-visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Pagination / summary and forms. */
[data-view="inventory"] .order-pagination { margin-top: 10px; font-size: 12.5px; gap: 8px; }
[data-view="inventory"] .form-grid { gap: 10px 14px; }
[data-view="inventory"] .form-grid label { font-size: 12.5px; }
[data-view="inventory"] .form-grid input,
[data-view="inventory"] .form-grid select { min-height: 36px; font-size: 13px; }
[data-view="inventory"] .icon-button { width: 30px; height: 30px; }
[data-view="inventory"] .settings-note { font-size: 12.5px; }

/* Smaller laptop screens (1366 and below). */
@media (max-width: 1440px) {
  [data-view="inventory"] .panel { padding: 16px 16px; }
  [data-view="inventory"] td, [data-view="inventory"] th { padding-left: 10px; padding-right: 10px; }
  [data-view="inventory"] .inv-product { min-width: 190px; }
}
@media (max-width: 700px) {
  [data-view="inventory"] .inv-toolbar-end { margin-left: 0; }
  [data-view="inventory"] .inv-toolbar input[type="search"] { max-width: none; }
}
