:root {
  color-scheme: light;
  --bg: #f5f7f8;
  --panel: #ffffff;
  --text: #1d252c;
  --muted: #65717b;
  --border: #d9e0e5;
  --accent: #1f7a6d;
  --accent-strong: #176257;
  --warn: #b66a00;
  --shadow: 0 10px 30px rgba(21, 36, 50, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Microsoft YaHei", "Segoe UI", Arial, sans-serif;
  line-height: 1.5;
}

.topbar {
  padding: 24px 32px;
  background: #ffffff;
  border-bottom: 1px solid var(--border);
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  font-size: 24px;
}

h2 {
  font-size: 18px;
}

.topbar p,
.muted {
  color: var(--muted);
}

.page {
  display: grid;
  gap: 20px;
  padding: 20px;
}

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

.filters {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 220px 180px;
  gap: 12px;
  padding: 14px;
}

label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

input,
select {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 9px 10px;
  color: var(--text);
  background: #ffffff;
  font: inherit;
}

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

.item-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 14px;
}

.item-card,
.record {
  display: grid;
  gap: 12px;
  padding: 14px;
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.item-photo {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 6px;
  background: #eef2f4;
  object-fit: cover;
}

.photo-placeholder {
  display: grid;
  place-items: center;
  color: var(--muted);
  font-weight: 700;
}

.item-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.item-title strong {
  font-size: 16px;
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  border-radius: 999px;
  padding: 2px 9px;
  background: #edf1f4;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.badge.low {
  background: #fff3df;
  color: var(--warn);
}

.meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}

.meta b {
  display: block;
  color: var(--text);
  font-size: 17px;
}

@media (max-width: 760px) {
  .topbar,
  .page {
    padding: 16px;
  }

  .filters,
  .meta {
    grid-template-columns: 1fr;
  }
}
