:root {
  --bg: #f3f6fb;
  --panel: #ffffff;
  --text: #172033;
  --muted: #697386;
  --line: #e4e9f1;
  --nav: #0f172a;
  --nav-soft: #1e293b;
  --primary: #2563eb;
  --primary-soft: #e8f0ff;
  --green: #10b981;
  --green-soft: #e8f8f2;
  --amber: #f59e0b;
  --amber-soft: #fff7df;
  --red: #ef4444;
  --red-soft: #fff0f0;
  --slate-soft: #eef2f7;
  --rack-occupied: #10b981;
  --rack-critical: #f97316;
  --rack-empty: #94a3b8;
  --shadow: 0 10px 30px rgba(30, 41, 59, 0.07);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  min-width: 1100px;
  color: var(--text);
  background: var(--bg);
  font-family: Inter, "Segoe UI", Arial, sans-serif;
}

.auth-locked .app-shell {
  pointer-events: none;
  user-select: none;
}

.auth-overlay {
  position: fixed;
  z-index: 100;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at 20% 15%, rgba(59, 130, 246, 0.32), transparent 35%),
    linear-gradient(135deg, #081225, #14233d);
}

.auth-card {
  width: min(430px, calc(100vw - 40px));
  padding: 28px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 18px;
  color: #fff;
  background: rgba(15, 23, 42, 0.94);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.38);
}

.auth-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 26px;
  padding-bottom: 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.auth-brand strong,
.auth-brand span {
  display: block;
}

.auth-brand span {
  margin-top: 4px;
  color: #9eabc0;
  font-size: 10px;
}

.auth-card form {
  display: grid;
  gap: 14px;
}

.auth-heading h1 {
  font-size: 22px;
}

.auth-heading p {
  margin-bottom: 0;
  color: #aab5c7;
  font-size: 10px;
  line-height: 1.6;
}

.auth-card label > span {
  color: #cbd5e1;
}

.auth-card input {
  color: #fff;
  border-color: #334155;
  background: #172033;
}

.auth-links {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.auth-links button {
  padding: 3px 0;
  border: 0;
  color: #8eb6ff;
  background: transparent;
  font-size: 9px;
  font-weight: 700;
}

.auth-message {
  min-height: 18px;
  margin: 14px 0 0;
  color: #86efac;
  font-size: 9px;
  line-height: 1.5;
  text-align: center;
}

.auth-message.error {
  color: #fca5a5;
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.app-shell {
  display: grid;
  grid-template-columns: 248px 1fr;
  min-height: 100vh;
}

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 248px;
  display: flex;
  flex-direction: column;
  padding: 24px 18px;
  color: #fff;
  background: var(--nav);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 8px 28px;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  font-weight: 800;
  box-shadow: 0 8px 24px rgba(37, 99, 235, 0.35);
}

.brand strong,
.brand span {
  display: block;
}

.brand strong {
  font-size: 15px;
}

.brand span {
  margin-top: 4px;
  color: #9eabc0;
  font-size: 11px;
}

.nav-list {
  display: grid;
  gap: 7px;
}

.nav-item {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 12px 13px;
  border: 0;
  border-radius: 10px;
  color: #aab5c7;
  background: transparent;
  text-align: left;
  font-size: 13px;
  font-weight: 600;
}

.nav-item:hover,
.nav-item.active {
  color: #fff;
  background: var(--nav-soft);
}

.nav-item.active {
  box-shadow: inset 3px 0 0 #3b82f6;
}

.nav-icon {
  width: 22px;
  color: #8eb6ff;
  font-size: 20px;
  text-align: center;
}

.sidebar-actions {
  display: grid;
  gap: 10px;
  margin-top: 28px;
}

.button {
  border: 1px solid transparent;
  border-radius: 9px;
  padding: 10px 15px;
  font-size: 12px;
  font-weight: 700;
  transition: 0.2s ease;
}

.button:hover {
  transform: translateY(-1px);
}

.button-primary {
  color: #fff;
  background: var(--primary);
  box-shadow: 0 7px 16px rgba(37, 99, 235, 0.2);
}

.button-secondary {
  color: #dce7fa;
  border-color: #334155;
  background: #1e293b;
}

.button-ghost {
  color: var(--text);
  border-color: var(--line);
  background: #fff;
}

.button-danger {
  color: var(--red);
  border-color: #ffd2d2;
  background: var(--red-soft);
}

.full {
  width: 100%;
}

.sidebar-footer {
  display: grid;
  gap: 10px;
  margin-top: auto;
  padding: 18px 10px 4px;
  border-top: 1px solid #273449;
}

.legend-row {
  display: flex;
  align-items: center;
  gap: 9px;
  color: #aab5c7;
  font-size: 11px;
}

.legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.legend-dot.occupied {
  background: var(--rack-occupied);
}

.legend-dot.low {
  background: var(--rack-critical);
}

.legend-dot.empty {
  border: 1px solid var(--rack-empty);
  background: var(--rack-empty);
}

.main {
  grid-column: 2;
  padding: 0 28px 32px;
}

.topbar {
  height: 92px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.eyebrow {
  margin: 0 0 4px;
  color: var(--primary);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1.4px;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: 23px;
}

h2 {
  margin-bottom: 5px;
  font-size: 15px;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 9px;
}

.user-menu {
  min-width: 190px;
  display: grid;
  grid-template-columns: 30px 1fr auto;
  align-items: center;
  gap: 8px;
  height: 40px;
  padding: 4px 5px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
}

.user-avatar {
  width: 29px;
  height: 29px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #fff;
  background: var(--primary);
  font-size: 9px;
  font-weight: 900;
}

.user-menu strong,
.user-menu small {
  display: block;
}

.user-menu strong {
  font-size: 9px;
}

.user-menu small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 7px;
  text-transform: uppercase;
}

.user-menu button {
  padding: 6px;
  border: 0;
  border-radius: 6px;
  color: #b91c1c;
  background: var(--red-soft);
  font-size: 7px;
  font-weight: 800;
}

.search-box {
  width: 360px;
  height: 40px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  box-shadow: 0 2px 8px rgba(30, 41, 59, 0.03);
}

.search-box > span {
  color: #8290a5;
  font-size: 22px;
}

.search-box input {
  min-width: 0;
  flex: 1;
  border: 0;
  outline: 0;
  color: var(--text);
  font-size: 12px;
}

kbd {
  padding: 3px 6px;
  border: 1px solid var(--line);
  border-radius: 5px;
  color: #8893a5;
  background: #f8fafc;
  font-size: 9px;
}

.icon-button {
  width: 40px;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 9px;
  color: #617087;
  background: #fff;
  font-size: 19px;
}

.icon-button:hover {
  color: var(--primary);
  border-color: #bdcff9;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 18px;
}

.stat-card {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 17px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.stat-icon {
  width: 40px;
  height: 40px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border-radius: 10px;
  font-size: 20px;
  font-weight: 800;
}

.stat-icon.blue {
  color: var(--primary);
  background: var(--primary-soft);
}

.stat-icon.green {
  color: #059669;
  background: var(--green-soft);
}

.stat-icon.amber {
  color: #d97706;
  background: var(--amber-soft);
}

.stat-icon.slate {
  color: #64748b;
  background: var(--slate-soft);
}

.stat-card div {
  min-width: 0;
}

.stat-label {
  display: block;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.stat-card strong {
  display: block;
  margin: 2px 0;
  font-size: 20px;
}

.stat-card small {
  display: block;
  overflow: hidden;
  color: #98a1b1;
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stat-card-action {
  position: relative;
  padding-right: 42px;
  cursor: pointer;
  transition: 0.2s ease;
}

.stat-card-action:hover,
.stat-card-action:focus-visible {
  border-color: color-mix(in srgb, var(--rack-critical) 58%, white);
  background: color-mix(in srgb, var(--rack-critical) 8%, white);
  box-shadow: 0 12px 32px color-mix(in srgb, var(--rack-critical) 18%, transparent);
  transform: translateY(-2px);
  outline: none;
}

.stat-card-arrow {
  position: absolute;
  right: 16px;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 7px;
  color: color-mix(in srgb, var(--rack-critical) 75%, black);
  background: color-mix(in srgb, var(--rack-critical) 18%, white);
  font-size: 13px;
  font-weight: 900;
}

.view {
  display: none;
}

.view.active {
  display: block;
}

.address-mode .stats-grid {
  display: none;
}

.database-mode .stats-grid {
  display: none;
}

.non-warehouse-mode .stats-grid {
  display: none;
}

.home-search-result {
  margin-bottom: 18px;
}

.home-search-result[hidden] {
  display: none;
}

.home-search-card {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto minmax(260px, auto) auto;
  align-items: center;
  gap: 18px;
  padding: 16px 18px;
  border: 1px solid #a7c0fa;
  border-radius: 12px;
  background: linear-gradient(135deg, #ffffff, #eef5ff);
  box-shadow: var(--shadow);
}

.home-search-card.not-found {
  grid-template-columns: 1fr auto;
  border-color: #fdba74;
  background: linear-gradient(135deg, #fff, #fff7ed);
}

.home-result-kicker {
  display: block;
  margin-bottom: 4px;
  color: var(--primary);
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 1px;
}

.home-search-card.not-found .home-result-kicker {
  color: #c2410c;
}

.home-result-main strong,
.home-search-card.not-found strong {
  display: block;
  font-size: 16px;
}

.home-result-main p,
.home-search-card.not-found p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 10px;
}

.home-result-total {
  min-width: 130px;
  padding: 11px 14px;
  border-radius: 9px;
  color: #fff;
  background: linear-gradient(135deg, #1d4ed8, #3b82f6);
  text-align: center;
}

.home-result-total span,
.home-result-total small,
.home-result-total strong {
  display: block;
}

.home-result-total span {
  font-size: 7px;
  font-weight: 800;
  text-transform: uppercase;
}

.home-result-total strong {
  margin: 2px 0;
  font-size: 21px;
}

.home-result-total small {
  font-size: 8px;
}

.home-result-addresses {
  max-width: 420px;
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.home-result-addresses button,
.stock-address-list button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 8px;
  border: 1px solid #bfdbfe;
  border-radius: 7px;
  color: #1d4ed8;
  background: #eff6ff;
  font-size: 9px;
  font-weight: 800;
}

.home-result-addresses button b {
  color: var(--text);
}

.database-kpis {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 18px;
}

.admin-kpis {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-bottom: 18px;
}

.admin-kpis article {
  padding: 17px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--shadow);
}

.admin-kpis span,
.admin-kpis strong {
  display: block;
}

.admin-kpis span {
  color: var(--muted);
  font-size: 8px;
  font-weight: 800;
  text-transform: uppercase;
}

.admin-kpis strong {
  margin-top: 5px;
  color: var(--primary);
  font-size: 22px;
}

.admin-panel {
  overflow: hidden;
}

.admin-table-wrap {
  max-height: 720px;
}

.admin-table {
  font-size: 9px;
}

.admin-table th {
  position: sticky;
  z-index: 2;
  top: 0;
}

.admin-table td {
  vertical-align: top;
  white-space: normal;
}

.admin-table td:first-child {
  min-width: 150px;
}

.admin-table td:first-child strong,
.admin-table td:first-child small {
  display: block;
}

.admin-table td:first-child small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 8px;
}

.admin-table select,
.admin-table input[type="password"] {
  min-width: 125px;
  height: 34px;
  font-size: 8px;
}

.admin-permissions {
  min-width: 390px;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 5px;
}

.admin-permissions label {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 5px;
  border-radius: 6px;
  background: #f6f8fb;
}

.admin-permissions input {
  width: 13px;
  height: 13px;
}

.admin-permissions span {
  margin: 0;
  color: #526075;
  font-size: 7px;
  font-weight: 700;
  text-transform: none;
  letter-spacing: 0;
}

.admin-alert {
  display: inline-block;
  margin-top: 7px;
  padding: 4px 6px;
  border-radius: 999px;
  color: #b45309;
  background: var(--amber-soft);
  font-size: 7px;
  font-weight: 800;
}

.mini-button.danger {
  color: #b91c1c;
  border-color: #fecaca;
  background: var(--red-soft);
}

.mini-button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.database-kpi {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--shadow);
}

.database-kpi-icon {
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border-radius: 10px;
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.5px;
}

.database-kpi-icon.blue {
  color: var(--primary);
  background: var(--primary-soft);
}

.database-kpi-icon.green {
  color: #047857;
  background: var(--green-soft);
}

.database-kpi-icon.amber {
  color: #b45309;
  background: var(--amber-soft);
}

.database-kpi-icon.slate {
  color: #475569;
  background: var(--slate-soft);
}

.database-kpi div {
  min-width: 0;
}

.database-kpi span,
.database-kpi strong,
.database-kpi small {
  display: block;
}

.database-kpi div > span {
  color: var(--muted);
  font-size: 8px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.database-kpi strong {
  margin: 3px 0;
  font-size: 19px;
}

.database-kpi small {
  color: #9aa4b3;
  font-size: 8px;
}

.database-panel {
  overflow: hidden;
}

.database-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 17px 18px;
  border-bottom: 1px solid var(--line);
}

.database-header h2,
.database-header p {
  margin-bottom: 0;
}

.database-header h2 {
  font-size: 16px;
}

.database-header p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 9px;
}

.database-label {
  display: block;
  margin-bottom: 5px;
  color: var(--primary);
  font-size: 7px;
  font-weight: 900;
  letter-spacing: 1px;
}

.database-export-actions {
  display: flex;
  gap: 8px;
}

.database-toolbar {
  display: grid;
  grid-template-columns: minmax(230px, 1fr) 145px 145px 145px auto;
  align-items: center;
  gap: 8px;
  padding: 12px 18px;
  border-bottom: 1px solid var(--line);
  background: #fafbfd;
}

.database-search {
  height: 36px;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 0 10px;
  border: 1px solid #dce2eb;
  border-radius: 8px;
  background: #fff;
}

.database-search > span {
  color: #8290a5;
  font-size: 18px;
}

.database-search input {
  min-width: 0;
  height: auto;
  padding: 0;
  border: 0;
  box-shadow: none;
}

.database-toolbar select {
  height: 36px;
  font-size: 9px;
}

.database-result-count {
  color: var(--muted);
  font-size: 9px;
  font-weight: 800;
  text-align: right;
  white-space: nowrap;
}

.database-table-wrap {
  max-height: 590px;
  overflow: auto;
}

.database-table {
  font-size: 9px;
}

.database-table th {
  position: sticky;
  z-index: 1;
  top: 0;
}

.database-table th,
.database-table td {
  padding: 10px 11px;
}

.database-table td {
  max-width: 260px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.database-product-name {
  min-width: 210px;
  font-weight: 600;
  white-space: normal;
}

.database-sku {
  color: var(--primary);
}

.database-address-link {
  min-width: 34px;
  padding: 5px 7px;
  border: 0;
  border-radius: 6px;
  color: #1d4ed8;
  background: var(--primary-soft);
  font-size: 9px;
  font-weight: 900;
}

.database-status {
  display: inline-block;
  padding: 4px 7px;
  border-radius: 999px;
  font-size: 7px;
  font-weight: 900;
  white-space: nowrap;
}

.database-status.stocked {
  color: #047857;
  background: var(--green-soft);
}

.database-status.low {
  color: #b45309;
  background: color-mix(in srgb, var(--rack-critical) 18%, white);
}

.database-status.zero {
  color: #b91c1c;
  background: var(--red-soft);
}

.database-source-badge {
  display: inline-block;
  padding: 4px 7px;
  border-radius: 999px;
  color: #475569;
  background: var(--slate-soft);
  font-size: 7px;
  font-weight: 900;
  white-space: nowrap;
}

.database-source-badge.catalog {
  color: #6d28d9;
  background: #f1eafe;
}

.database-source-badge.stock {
  color: #047857;
  background: var(--green-soft);
}

.database-cameras-panel {
  margin-top: 18px;
  overflow: hidden;
}

.database-camera-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  padding: 14px;
}

.database-camera-card {
  min-width: 0;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  align-items: center;
  gap: 9px;
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 9px;
  color: var(--text);
  background: #fafbfd;
  text-align: left;
}

.database-camera-card:hover {
  border-color: #a7c0fa;
  background: var(--primary-soft);
}

.database-camera-icon {
  width: 38px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 7px;
  color: #fff;
  background: #172033;
  font-size: 7px;
  font-weight: 900;
}

.database-camera-card span:nth-child(2) {
  min-width: 0;
}

.database-camera-card strong,
.database-camera-card small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.database-camera-card strong {
  font-size: 9px;
}

.database-camera-card small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 7px;
}

.database-camera-card b {
  color: var(--primary);
  font-size: 7px;
  white-space: nowrap;
}

.database-camera-empty {
  grid-column: 1 / -1;
  padding: 25px;
  color: var(--muted);
  font-size: 9px;
  text-align: center;
}

.address-page-header {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 18px;
  padding: 15px 17px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--shadow);
}

.back-button {
  padding: 8px 11px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: #526075;
  background: #f8fafc;
  font-size: 10px;
  font-weight: 700;
}

.address-title-block {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
}

.address-page-code {
  width: 48px;
  height: 48px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(135deg, #1d4ed8, #3b82f6);
  font-size: 18px;
  font-weight: 800;
}

.address-title-block h2,
.address-title-block p {
  margin-bottom: 0;
}

.address-title-block h2 {
  font-size: 16px;
}

.address-title-block p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 9px;
}

.address-header-actions {
  display: flex;
  gap: 8px;
  margin-left: auto;
}

.address-page-grid {
  display: grid;
  grid-template-columns: minmax(650px, 1fr) 360px;
  gap: 18px;
  align-items: start;
}

.address-products-panel {
  overflow: hidden;
}

.address-table-wrap {
  min-height: 520px;
}

.address-products-table td {
  white-space: normal;
}

.address-products-table {
  font-size: 9px;
}

.address-products-table th,
.address-products-table td {
  padding: 11px 9px;
}

.address-sku,
.quantity-cell {
  color: var(--primary);
}

.product-name-cell {
  min-width: 150px;
  font-weight: 600;
}

.row-actions {
  display: grid;
  gap: 5px;
}

.mini-button {
  padding: 5px 7px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: #536177;
  background: #fff;
  font-size: 8px;
  font-weight: 700;
  white-space: nowrap;
}

.mini-button.primary {
  color: var(--primary);
  border-color: #c8d8fc;
  background: var(--primary-soft);
}

.address-empty-products {
  min-height: 360px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 8px;
  color: var(--muted);
  text-align: center;
}

.address-empty-products strong {
  color: var(--text);
  font-size: 13px;
}

.address-empty-products span {
  font-size: 10px;
}

.address-side-column {
  display: grid;
  gap: 18px;
}

.camera-panel {
  overflow: hidden;
}

.camera-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 14px 15px;
  border-bottom: 1px solid var(--line);
}

.camera-header h2 {
  margin-bottom: 0;
  font-size: 13px;
}

.camera-label {
  display: block;
  margin-bottom: 4px;
  color: var(--primary);
  font-size: 7px;
  font-weight: 800;
  letter-spacing: 1px;
}

.camera-status {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 7px;
  border-radius: 999px;
  color: #64748b;
  background: #eef2f7;
  font-size: 7px;
  font-weight: 800;
  white-space: nowrap;
}

.camera-status i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #94a3b8;
}

.camera-status.waiting {
  color: #b45309;
  background: var(--amber-soft);
}

.camera-status.waiting i {
  background: var(--amber);
}

.camera-status.connected {
  color: #047857;
  background: var(--green-soft);
}

.camera-status.connected i {
  background: var(--green);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.16);
}

.camera-status.error {
  color: #b91c1c;
  background: var(--red-soft);
}

.camera-status.error i {
  background: var(--red);
}

.camera-viewport {
  height: 230px;
  display: grid;
  place-items: center;
  overflow: hidden;
  color: #d8e0eb;
  background: radial-gradient(circle at 50% 35%, #26354a 0, #131e2e 55%, #0b1220 100%);
}

.camera-media {
  width: 100%;
  height: 100%;
  border: 0;
  object-fit: contain;
  background: #080d15;
}

.camera-empty {
  max-width: 245px;
  padding: 18px;
  text-align: center;
}

.camera-empty-icon {
  width: 54px;
  height: 36px;
  display: grid;
  place-items: center;
  margin: 0 auto 12px;
  border: 1px solid #43536a;
  border-radius: 8px;
  color: #8ba0bd;
  background: #1b293c;
  font-size: 9px;
  font-weight: 800;
}

.camera-empty strong,
.camera-empty p {
  display: block;
  margin-bottom: 0;
}

.camera-empty strong {
  color: #fff;
  font-size: 11px;
}

.camera-empty p {
  margin-top: 7px;
  color: #9aa9be;
  font-size: 8px;
  line-height: 1.6;
}

.camera-warning .camera-empty-icon {
  color: #fbbf24;
  border-color: #6f5b2a;
}

.camera-form {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.camera-form input,
.camera-form select {
  height: 35px;
  font-size: 9px;
}

.camera-form-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
}

.camera-form-actions .button {
  padding: 8px;
  font-size: 8px;
}

.camera-help {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 7px;
  line-height: 1.5;
}

.address-summary-panel {
  padding: 15px;
}

.address-summary-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.address-summary-head h2 {
  margin-bottom: 0;
}

.address-summary-head span {
  padding: 4px 7px;
  border-radius: 999px;
  color: #047857;
  background: var(--green-soft);
  font-size: 7px;
  font-weight: 800;
}

.address-summary-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.address-summary-metrics div {
  padding: 11px;
  border-radius: 8px;
  background: #f6f8fb;
}

.address-summary-metrics span,
.address-summary-metrics strong {
  display: block;
}

.address-summary-metrics span {
  color: var(--muted);
  font-size: 7px;
  text-transform: uppercase;
}

.address-summary-metrics strong {
  margin-top: 4px;
  font-size: 16px;
}

.address-recent {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.address-recent h3 {
  margin: 0 0 8px;
  font-size: 9px;
}

.address-recent div {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 0;
  border-bottom: 1px solid #edf0f4;
  font-size: 8px;
}

.address-recent p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 8px;
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(700px, 1fr) 300px;
  gap: 18px;
  align-items: start;
}

.panel {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.panel-header {
  min-height: 70px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 15px 18px;
  border-bottom: 1px solid var(--line);
}

.panel-header.compact {
  min-height: 64px;
}

.panel-header h2,
.panel-header p {
  margin-bottom: 0;
}

.panel-header p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 10px;
}

.filters {
  display: flex;
  gap: 3px;
  padding: 3px;
  border-radius: 8px;
  background: #f1f4f8;
}

.filter {
  border: 0;
  border-radius: 6px;
  padding: 6px 10px;
  color: var(--muted);
  background: transparent;
  font-size: 10px;
  font-weight: 700;
}

.filter.active {
  color: var(--primary);
  background: #fff;
  box-shadow: 0 2px 6px rgba(30, 41, 59, 0.08);
}

.warehouse-map {
  display: grid;
  grid-template-columns: 1fr 52px 1fr 52px 1fr 52px 1fr;
  gap: 8px;
  padding: 18px;
  background:
    linear-gradient(90deg, transparent 49.8%, rgba(37, 99, 235, 0.035) 50%, transparent 50.2%),
    #fff;
}

.rack-column {
  display: grid;
  gap: 5px;
}

.rack-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 3px;
  padding: 0 2px;
}

.rack-heading strong {
  color: var(--text);
  font-size: 12px;
}

.rack-heading span {
  color: var(--muted);
  font-size: 8px;
}

.aisle {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100%;
  border: 1px dashed #d9e1ec;
  border-radius: 7px;
  color: #9ba7b8;
  background: repeating-linear-gradient(135deg, #fafbfd, #fafbfd 6px, #f5f7fa 6px, #f5f7fa 12px);
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  writing-mode: vertical-rl;
}

.location-card {
  min-width: 0;
  height: 42px;
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) 32px;
  align-items: center;
  gap: 6px;
  padding: 4px 6px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--rack-empty);
  border-radius: 6px;
  color: var(--text);
  background: color-mix(in srgb, var(--rack-empty) 11%, white);
  text-align: left;
  transition: 0.18s ease;
}

.location-card:hover {
  border-color: #afc5f8;
  background: #f3f7ff;
  transform: translateX(1px);
}

.location-card.selected {
  border-color: var(--primary);
  background: var(--primary-soft);
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.12);
}

.location-card.is-occupied {
  border-color: color-mix(in srgb, var(--rack-occupied) 62%, white);
  border-left-color: var(--rack-occupied);
  background: color-mix(in srgb, var(--rack-occupied) 18%, white);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--rack-occupied) 18%, transparent);
}

.location-card.is-low {
  border-color: color-mix(in srgb, var(--rack-critical) 68%, white);
  border-left-color: var(--rack-critical);
  background: color-mix(in srgb, var(--rack-critical) 23%, white);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--rack-critical) 22%, transparent);
}

.location-card.filtered-out {
  opacity: 0.15;
  pointer-events: none;
}

.location-code {
  display: grid;
  place-items: center;
  height: 27px;
  border-radius: 5px;
  color: #516076;
  background: #edf1f6;
  font-size: 9px;
  font-weight: 800;
}

.location-card.is-occupied .location-code {
  color: color-mix(in srgb, var(--rack-occupied) 72%, black);
  background: color-mix(in srgb, var(--rack-occupied) 28%, white);
}

.location-card.is-low .location-code {
  color: color-mix(in srgb, var(--rack-critical) 72%, black);
  background: color-mix(in srgb, var(--rack-critical) 32%, white);
}

.location-card.is-empty {
  border-color: color-mix(in srgb, var(--rack-empty) 52%, white);
  border-left-color: var(--rack-empty);
}

.conditional-formatting-off .location-card {
  border-color: var(--line);
  border-left-color: #cad3df;
  background: #f9fafc;
  box-shadow: none;
}

.conditional-formatting-off .location-card .location-code {
  color: #516076;
  background: #edf1f6;
}

.location-content {
  min-width: 0;
}

.location-content strong,
.location-content span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.location-content strong {
  font-size: 9px;
}

.location-content span {
  margin-top: 2px;
  color: #9aa4b3;
  font-size: 8px;
}

.location-qty {
  color: #3e4b5e;
  font-size: 11px;
  font-weight: 800;
  text-align: right;
}

.detail-column {
  display: grid;
  gap: 18px;
}

.detail-panel {
  min-height: 286px;
}

.empty-detail {
  min-height: 286px;
  display: grid;
  place-items: center;
  padding: 32px;
  color: var(--muted);
  text-align: center;
}

.empty-detail-icon {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  margin: 0 auto 13px;
  border-radius: 16px;
  color: var(--primary);
  background: var(--primary-soft);
  font-size: 25px;
}

.empty-detail h3 {
  margin: 0 0 6px;
  color: var(--text);
  font-size: 14px;
}

.empty-detail p {
  max-width: 190px;
  margin-bottom: 0;
  font-size: 10px;
  line-height: 1.6;
}

.detail-head {
  padding: 17px;
  color: #fff;
  border-radius: 11px 11px 0 0;
  background: linear-gradient(135deg, #1e40af, #2563eb);
}

.detail-head.low {
  background: linear-gradient(135deg, #b45309, #f59e0b);
}

.detail-head.empty {
  color: var(--text);
  background: linear-gradient(135deg, #e7edf5, #f5f7fa);
}

.detail-address-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.detail-address {
  font-size: 23px;
  font-weight: 800;
}

.status-pill {
  padding: 5px 8px;
  border-radius: 999px;
  color: #065f46;
  background: rgba(255, 255, 255, 0.85);
  font-size: 8px;
  font-weight: 800;
  text-transform: uppercase;
}

.detail-head p {
  margin: 7px 0 0;
  opacity: 0.75;
  font-size: 9px;
}

.detail-body {
  padding: 16px;
}

.detail-stock-list {
  max-height: 190px;
  display: grid;
  gap: 5px;
  margin: -3px -3px 12px;
  padding: 3px;
  overflow: auto;
}

.detail-stock-item {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 9px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 7px;
  color: var(--text);
  background: #fafbfd;
  text-align: left;
}

.detail-stock-item:hover,
.detail-stock-item.selected {
  border-color: #9db9fb;
  background: var(--primary-soft);
}

.detail-stock-item span {
  min-width: 0;
}

.detail-stock-item strong,
.detail-stock-item small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.detail-stock-item strong {
  font-size: 9px;
}

.detail-stock-item small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 8px;
}

.detail-stock-item b {
  flex: 0 0 auto;
  color: var(--primary);
  font-size: 11px;
}

.selected-product {
  margin-bottom: 12px;
  padding: 10px;
  border-radius: 8px;
  background: #f6f8fb;
}

.selected-product span,
.selected-product strong,
.selected-product small {
  display: block;
}

.selected-product span {
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 8px;
  font-weight: 700;
  text-transform: uppercase;
}

.selected-product strong {
  overflow: hidden;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.selected-product small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 8px;
}

.detail-name {
  margin: 0 0 3px;
  font-size: 14px;
}

.detail-sku {
  color: var(--muted);
  font-size: 10px;
}

.detail-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 15px 0;
}

.detail-metric {
  padding: 10px;
  border-radius: 8px;
  background: #f6f8fb;
}

.detail-metric span,
.detail-metric strong {
  display: block;
}

.detail-metric span {
  margin-bottom: 3px;
  color: var(--muted);
  font-size: 8px;
  font-weight: 700;
  text-transform: uppercase;
}

.detail-metric strong {
  font-size: 16px;
}

.detail-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
}

.detail-actions .button {
  padding: 8px;
  font-size: 9px;
}

.detail-actions .wide {
  grid-column: 1 / -1;
}

.text-button {
  border: 0;
  color: var(--primary);
  background: transparent;
  font-size: 9px;
  font-weight: 700;
}

.recent-list {
  max-height: 330px;
  overflow: auto;
  padding: 4px 15px 12px;
}

.recent-item {
  display: grid;
  grid-template-columns: 27px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  padding: 10px 0;
  border-bottom: 1px solid #edf0f4;
}

.recent-item:last-child {
  border-bottom: 0;
}

.movement-icon {
  width: 27px;
  height: 27px;
  display: grid;
  place-items: center;
  border-radius: 7px;
  font-size: 13px;
  font-weight: 800;
}

.movement-icon.in,
.movement-icon.place {
  color: #059669;
  background: var(--green-soft);
}

.movement-icon.out,
.movement-icon.remove {
  color: var(--red);
  background: var(--red-soft);
}

.movement-icon.transfer {
  color: var(--primary);
  background: var(--primary-soft);
}

.recent-copy {
  min-width: 0;
}

.recent-copy strong,
.recent-copy span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.recent-copy strong {
  font-size: 9px;
}

.recent-copy span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 8px;
}

.recent-qty {
  font-size: 10px;
  font-weight: 800;
}

.recent-qty.positive {
  color: #059669;
}

.recent-qty.negative {
  color: var(--red);
}

.movements-panel {
  overflow: hidden;
}

.table-wrap {
  overflow: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11px;
}

th,
td {
  padding: 13px 17px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  white-space: nowrap;
}

th {
  color: var(--muted);
  background: #fafbfd;
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

td {
  color: #435066;
}

.table-address {
  color: var(--primary);
  font-weight: 800;
}

.movement-badge {
  display: inline-block;
  padding: 4px 7px;
  border-radius: 999px;
  font-size: 8px;
  font-weight: 800;
  text-transform: uppercase;
}

.movement-badge.in,
.movement-badge.place {
  color: #047857;
  background: var(--green-soft);
}

.movement-badge.out,
.movement-badge.remove {
  color: #b91c1c;
  background: var(--red-soft);
}

.movement-badge.transfer {
  color: #1d4ed8;
  background: var(--primary-soft);
}

.movement-filters {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) 170px 150px auto;
  align-items: center;
  gap: 8px;
  padding: 12px 18px;
  border-bottom: 1px solid var(--line);
  background: #fafbfd;
}

.movement-filters select {
  height: 36px;
  font-size: 9px;
}

.sku-detail-link {
  padding: 0;
  border: 0;
  color: var(--primary);
  background: transparent;
  font-size: inherit;
  font-weight: 800;
  text-decoration: underline;
  text-decoration-color: #bfdbfe;
  text-underline-offset: 3px;
}

.sku-detail-link:hover {
  color: #1d4ed8;
  text-decoration-color: #1d4ed8;
}

tr.is-critical td {
  background: color-mix(in srgb, var(--rack-critical) 10%, white);
}

tr.is-critical td:first-child {
  box-shadow: inset 4px 0 0 var(--rack-critical);
}

.conditional-formatting-off tr.is-critical td {
  background: transparent;
}

.conditional-formatting-off tr.is-critical td:first-child {
  box-shadow: none;
}

.empty-list {
  padding: 25px 10px;
  color: var(--muted);
  font-size: 10px;
  text-align: center;
}

.modal {
  width: min(560px, calc(100vw - 40px));
  padding: 0;
  border: 0;
  border-radius: 14px;
  color: var(--text);
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.28);
}

.modal.small {
  width: min(440px, calc(100vw - 40px));
}

.movement-detail-modal {
  width: min(880px, calc(100vw - 40px));
}

.modal-dialog-content {
  padding: 20px;
}

.stock-detail-subtitle {
  max-width: 680px;
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 10px;
}

.stock-detail-summary {
  display: grid;
  grid-template-columns: repeat(3, 1fr) 2fr;
  gap: 9px;
  margin-bottom: 14px;
}

.stock-detail-summary > div {
  min-width: 0;
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #f8fafc;
}

.stock-detail-summary span,
.stock-detail-summary strong,
.stock-detail-summary small {
  display: block;
}

.stock-detail-summary span {
  color: var(--muted);
  font-size: 7px;
  font-weight: 800;
  text-transform: uppercase;
}

.stock-detail-summary strong {
  margin: 3px 0;
  color: var(--primary);
  font-size: 18px;
}

.stock-detail-summary small {
  color: var(--muted);
  font-size: 8px;
}

.stock-address-list p {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 8px;
}

.stock-detail-filters {
  display: grid;
  grid-template-columns: 180px 150px 1fr;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}

.stock-detail-filters select {
  height: 36px;
  font-size: 9px;
}

.stock-detail-table-wrap {
  max-height: 390px;
  border: 1px solid var(--line);
  border-radius: 9px;
}

.settings-grid {
  display: grid;
  grid-template-columns: minmax(600px, 1fr) 350px;
  gap: 18px;
  align-items: start;
}

.settings-panel,
.settings-preview-panel {
  overflow: hidden;
}

.settings-body {
  display: grid;
  gap: 14px;
  padding: 18px;
}

.settings-section {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #fafbfd;
}

.settings-section-title {
  display: flex;
  align-items: center;
  gap: 11px;
  margin-bottom: 14px;
}

.settings-section-title h3,
.settings-section-title p {
  margin: 0;
}

.settings-section-title h3 {
  font-size: 12px;
}

.settings-section-title p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 9px;
}

.settings-icon {
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border-radius: 9px;
  color: var(--primary);
  background: var(--primary-soft);
  font-size: 10px;
  font-weight: 900;
}

.color-settings {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.block-count-settings {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.block-count-settings > label {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
}

.block-count-settings small {
  display: block;
  min-height: 22px;
  margin-top: 7px;
  color: var(--muted);
  font-size: 7px;
  line-height: 1.5;
}

.number-stepper {
  display: grid;
  grid-template-columns: 34px 1fr 34px;
  gap: 5px;
}

.number-stepper input {
  height: 36px;
  padding: 0 4px;
  text-align: center;
  font-weight: 800;
}

.number-stepper button {
  height: 36px;
  border: 1px solid #c8d8fc;
  border-radius: 8px;
  color: var(--primary);
  background: var(--primary-soft);
  font-size: 17px;
  font-weight: 800;
}

.number-stepper button:hover {
  color: #fff;
  background: var(--primary);
}

.color-settings label {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
}

.color-settings input[type="color"] {
  height: 42px;
  padding: 3px;
  cursor: pointer;
}

.toggle-setting {
  display: flex;
  align-items: center;
  gap: 9px;
  cursor: pointer;
}

.toggle-setting input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.toggle-control {
  width: 38px;
  height: 22px;
  position: relative;
  display: block;
  margin: 0;
  border-radius: 999px;
  background: #cbd5e1;
  transition: 0.2s ease;
}

.toggle-control::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.2);
  transition: 0.2s ease;
}

.toggle-setting input:checked + .toggle-control {
  background: var(--primary);
}

.toggle-setting input:checked + .toggle-control::after {
  transform: translateX(16px);
}

.toggle-setting b {
  font-size: 10px;
}

.settings-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding: 15px 18px;
  border-top: 1px solid var(--line);
  background: #fafbfd;
}

.settings-preview {
  display: grid;
  gap: 10px;
  padding: 18px;
}

.preview-address {
  display: grid;
  grid-template-columns: 42px 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 13px;
  border: 1px solid var(--line);
  border-left: 5px solid var(--rack-empty);
  border-radius: 9px;
  background: color-mix(in srgb, var(--rack-empty) 12%, white);
  font-size: 10px;
}

.preview-address span {
  display: grid;
  place-items: center;
  height: 32px;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.8);
  font-weight: 900;
}

.preview-address.is-occupied {
  border-color: color-mix(in srgb, var(--rack-occupied) 58%, white);
  border-left-color: var(--rack-occupied);
  background: color-mix(in srgb, var(--rack-occupied) 20%, white);
}

.preview-address.is-low {
  border-color: color-mix(in srgb, var(--rack-critical) 62%, white);
  border-left-color: var(--rack-critical);
  background: color-mix(in srgb, var(--rack-critical) 22%, white);
}

.conditional-formatting-off .preview-address {
  border-color: var(--line);
  border-left-color: #cad3df;
  background: #f9fafc;
}

.modal::backdrop {
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(2px);
}

.modal form {
  padding: 20px;
}

.modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 20px;
}

.modal-header h2 {
  margin-bottom: 0;
  font-size: 18px;
}

.modal-kicker {
  display: block;
  margin-bottom: 5px;
  color: var(--primary);
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 1px;
}

.modal-close {
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 7px;
  color: var(--muted);
  background: #f2f5f8;
  font-size: 18px;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.form-grid .wide {
  grid-column: 1 / -1;
}

label > span {
  display: block;
  margin-bottom: 6px;
  color: #526075;
  font-size: 9px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.field-helper {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 8px;
  line-height: 1.4;
}

.field-helper.found {
  color: #047857;
}

.field-helper.multiple {
  color: #b45309;
}

.field-helper.not-found {
  color: #b91c1c;
}

.product-match-field[hidden] {
  display: none;
}

input,
select {
  width: 100%;
  height: 40px;
  padding: 0 11px;
  border: 1px solid #dce2eb;
  border-radius: 8px;
  outline: none;
  color: var(--text);
  background: #fff;
  font-size: 11px;
}

input:focus,
select:focus {
  border-color: #8eb1ff;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 20px;
  padding-top: 15px;
  border-top: 1px solid var(--line);
}

.transfer-copy {
  margin-bottom: 16px;
  color: var(--muted);
  font-size: 11px;
}

.toast {
  position: fixed;
  z-index: 10;
  right: 24px;
  bottom: 24px;
  max-width: 340px;
  padding: 11px 15px;
  border-radius: 9px;
  color: #fff;
  background: #172033;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.25);
  font-size: 11px;
  font-weight: 700;
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: 0.25s ease;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

.toast.error {
  background: #b91c1c;
}

@media (max-width: 1250px) {
  .content-grid {
    grid-template-columns: 1fr;
  }

  .detail-column {
    grid-template-columns: 1fr 1fr;
  }

  .detail-panel,
  .empty-detail {
    min-height: 250px;
  }

  .database-camera-list {
    grid-template-columns: repeat(2, 1fr);
  }

  .settings-grid {
    grid-template-columns: 1fr;
  }

  .block-count-settings {
    grid-template-columns: repeat(2, 1fr);
  }
}
