:root {
  --bg: #f6f7f9;
  --panel: #ffffff;
  --text: #17202a;
  --muted: #667085;
  --line: #dde3ea;
  --primary: #1769aa;
  --primary-dark: #0f4e80;
  --danger: #c0392b;
  --ok: #16855a;
  --warn: #a05b00;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  background: var(--bg);
  color: var(--text);
}
button, input, select, textarea {
  font: inherit;
}
button {
  border: 0;
  border-radius: 6px;
  background: var(--primary);
  color: #fff;
  padding: 9px 14px;
  cursor: pointer;
}
button:hover { background: var(--primary-dark); }
button.ghost {
  background: #eef3f8;
  color: var(--primary-dark);
}
button.danger { background: var(--danger); }
button.ok { background: var(--ok); }
button:disabled {
  opacity: .5;
  cursor: not-allowed;
}
input, select, textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  padding: 9px 10px;
}
textarea { min-height: 88px; resize: vertical; }
label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 14px;
}
.hidden { display: none !important; }
.login {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}
.login-panel {
  width: min(420px, 100%);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 28px;
}
.login-panel h1 { margin: 0 0 8px; }
.login-panel p { margin: 0 0 24px; color: var(--muted); }
.login-panel form, .form-grid { display: grid; gap: 14px; }
.captcha-row {
  display: grid;
  grid-template-columns: 1fr 112px;
  gap: 8px;
}
.captcha-row button {
  background: #111827;
  color: #fff;
  letter-spacing: 3px;
  font-weight: 800;
  padding: 9px 8px;
}
.entry-tabs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin: 0 0 18px;
}
.entry-tabs a {
  text-align: center;
  text-decoration: none;
  color: var(--primary-dark);
  background: #eef3f8;
  border-radius: 6px;
  padding: 8px 6px;
  font-size: 14px;
}
.entry-tabs a.active {
  background: var(--primary);
  color: #fff;
}
.app {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 230px 1fr;
}
.sidebar {
  background: #111827;
  color: #fff;
  padding: 18px;
  display: grid;
  align-content: start;
  gap: 18px;
}
.brand { display: grid; gap: 6px; }
.brand span { color: #b7c0cd; font-size: 13px; }
nav { display: grid; gap: 6px; }
nav button {
  width: 100%;
  background: transparent;
  text-align: left;
  color: #d9e2ef;
  padding: 10px 12px;
}
nav button.active, nav button:hover { background: #243044; }
.content { min-width: 0; }
.topbar {
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 22px;
  background: var(--panel);
  border-bottom: 1px solid var(--line);
}
.topbar h2 { margin: 0; font-size: 22px; }
#view { padding: 22px; }
.cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}
.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
}
.metric {
  display: grid;
  gap: 8px;
}
.metric span { color: var(--muted); font-size: 14px; }
.metric strong { font-size: 28px; }
.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 14px;
  align-items: center;
}
.table-wrap {
  overflow: auto;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
}
table {
  width: 100%;
  border-collapse: collapse;
  min-width: 860px;
}
th, td {
  border-bottom: 1px solid var(--line);
  padding: 11px 12px;
  text-align: left;
  vertical-align: top;
}
th { background: #f9fafb; color: #475467; font-size: 13px; }
td { font-size: 14px; }
.status {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 999px;
  background: #eef3f8;
  color: var(--primary-dark);
  white-space: nowrap;
}
.status.bad { background: #fdecea; color: var(--danger); }
.status.ok { background: #e7f6ef; color: var(--ok); }
.status.warn { background: #fff3dc; color: var(--warn); }
.actions { display: flex; flex-wrap: wrap; gap: 6px; }
.thumbs { display: flex; gap: 6px; flex-wrap: wrap; }
.thumbs a {
  color: var(--primary);
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}
.split {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 16px;
  align-items: start;
}
.modal-mask {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, .42);
  display: grid;
  place-items: center;
  padding: 20px;
  z-index: 20;
}
.modal {
  width: min(720px, 100%);
  max-height: 90vh;
  overflow: auto;
  background: var(--panel);
  border-radius: 8px;
  padding: 20px;
  position: relative;
}
.modal-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 34px;
  height: 34px;
  padding: 0;
  background: #eef3f8;
  color: var(--text);
}
.modal-body h3 { margin-top: 0; }
.toast {
  position: fixed;
  right: 18px;
  bottom: 18px;
  background: #111827;
  color: #fff;
  padding: 12px 14px;
  border-radius: 6px;
  z-index: 30;
}
.empty {
  color: var(--muted);
  padding: 28px;
  text-align: center;
}
.access-denied {
  min-height: 100vh;
  display: grid;
  place-content: center;
  gap: 12px;
  padding: 24px;
  text-align: center;
}
.access-denied h1,
.access-denied p { margin: 0; }
.access-denied p { color: var(--muted); }

@media (max-width: 900px) {
  .app { grid-template-columns: 1fr; }
  .sidebar {
    position: sticky;
    top: 0;
    z-index: 10;
    padding: 12px;
    gap: 10px;
  }
  nav {
    grid-auto-flow: column;
    overflow-x: auto;
    gap: 4px;
  }
  nav button { white-space: nowrap; text-align: center; }
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .split { grid-template-columns: 1fr; }
  #view { padding: 14px; }
}

@media (max-width: 520px) {
  .cards { grid-template-columns: 1fr; }
  .topbar { height: auto; padding: 14px; gap: 10px; }
  .topbar h2 { font-size: 19px; }
  .toolbar button, .toolbar select, .toolbar input { width: 100%; }
}

body.mobile-entry {
  background: #f3f5f7;
}

body.mobile-entry .app {
  display: block;
  min-height: 100vh;
  padding-bottom: 74px;
}

body.mobile-entry .sidebar {
  position: sticky;
  top: 0;
  z-index: 10;
  background: #ffffff;
  color: var(--text);
  border-bottom: 1px solid var(--line);
  padding: 12px 14px;
  display: block;
}

body.mobile-entry .brand {
  gap: 2px;
}

body.mobile-entry .brand strong {
  font-size: 18px;
}

body.mobile-entry .brand span {
  color: var(--muted);
}

body.mobile-entry #logoutBtn {
  position: absolute;
  right: 12px;
  top: 14px;
  padding: 7px 10px;
}

body.mobile-entry nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 15;
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  overflow-x: auto;
  gap: 0;
  background: #fff;
  border-top: 1px solid var(--line);
  box-shadow: 0 -6px 20px rgba(15, 23, 42, .08);
}

body.mobile-entry nav button {
  color: #344054;
  background: #fff;
  border-radius: 0;
  padding: 10px 8px 12px;
  text-align: center;
  white-space: nowrap;
  font-size: 13px;
}

body.mobile-entry nav button.active,
body.mobile-entry nav button:hover {
  background: #eaf3fb;
  color: var(--primary-dark);
}

body.mobile-entry .topbar {
  height: auto;
  padding: 14px;
  background: transparent;
  border-bottom: 0;
}

body.mobile-entry .topbar h2 {
  font-size: 22px;
}

body.mobile-entry #refreshBtn {
  width: auto;
}

body.mobile-entry #view {
  padding: 0 14px 18px;
}

body.mobile-entry .cards {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

body.mobile-entry .card {
  border-radius: 8px;
  padding: 14px;
}

body.mobile-entry .metric strong {
  font-size: 24px;
}

body.mobile-entry .toolbar {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

body.mobile-entry .toolbar button,
body.mobile-entry .toolbar a {
  width: 100%;
}

body.mobile-entry .toolbar a button {
  width: 100%;
}

body.mobile-entry .table-wrap {
  background: transparent;
  border: 0;
  overflow: visible;
}

body.mobile-entry table,
body.mobile-entry thead,
body.mobile-entry tbody,
body.mobile-entry tr,
body.mobile-entry th,
body.mobile-entry td {
  display: block;
  width: 100%;
  min-width: 0;
}

body.mobile-entry thead {
  display: none;
}

body.mobile-entry tr {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px;
  margin-bottom: 10px;
}

body.mobile-entry td {
  border: 0;
  padding: 6px 0;
}

body.mobile-entry td:empty {
  display: none;
}

body.mobile-entry .actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

body.mobile-entry .actions button {
  width: 100%;
}

body.mobile-entry .split {
  grid-template-columns: 1fr;
}

body.mobile-entry .modal {
  width: 100%;
  max-height: 92vh;
  align-self: end;
  border-radius: 12px 12px 0 0;
}

body.pc-entry .sidebar {
  position: sticky;
  top: 0;
  min-height: 100vh;
}

body.pc-entry {
  overflow: hidden;
}

body.pc-entry .app {
  height: 100vh;
  overflow: hidden;
}

body.pc-entry .sidebar {
  height: 100vh;
  overflow: hidden;
}

body.pc-entry .content {
  height: 100vh;
  min-height: 0;
  overflow: auto;
}

body.pc-entry .topbar {
  position: sticky;
  top: 0;
  z-index: 9;
}

body.store-entry .sidebar {
  padding: 0;
  border: 0;
  background: transparent;
}

body.store-entry .brand,
body.store-entry #logoutBtn {
  display: none;
}

body.store-entry .topbar {
  padding: 22px 18px 10px;
}

body.store-entry .topbar h2 {
  font-size: 26px;
  font-weight: 800;
  color: #101828;
}

body.store-entry #refreshBtn {
  border-radius: 999px;
  padding: 7px 12px;
}

body.store-entry #view {
  padding: 4px 16px 22px;
}

body.store-entry .store-metrics {
  gap: 12px;
}

body.store-entry .store-metrics .card {
  min-height: 118px;
  border: 1px solid #e6ebf1;
  box-shadow: 0 8px 22px rgba(15, 23, 42, .06);
}

body.store-entry .store-metrics .card:nth-child(1) {
  border-top: 4px solid #1769aa;
}

body.store-entry .store-metrics .card:nth-child(2) {
  border-top: 4px solid #c0392b;
}

body.store-entry .store-metrics .card:nth-child(3) {
  border-top: 4px solid #16855a;
}

body.store-entry .store-metrics .card:nth-child(4) {
  border-top: 4px solid #a05b00;
}

body.store-entry .metric span {
  color: #475467;
  font-weight: 650;
}

body.store-entry .metric strong {
  margin-top: 3px;
  font-size: 25px;
  line-height: 1.1;
}

body.store-entry .metric small {
  color: #98a2b3;
}

body.store-entry .metric-button {
  color: var(--text);
  background: #fff;
  text-align: left;
}

body.store-entry .metric-button:hover {
  background: #f8fbfe;
}

body.store-entry .metric-button::after {
  content: "查看";
  margin-top: 8px;
  color: var(--primary);
  font-size: 13px;
  font-weight: 700;
}

body.store-entry .store-action {
  margin-top: 18px;
}

body.store-entry .primary-cta {
  width: 100%;
  min-height: 54px;
  border-radius: 10px;
  background: #1769aa;
  font-size: 18px;
  font-weight: 750;
  box-shadow: 0 10px 24px rgba(23, 105, 170, .24);
}

body.store-entry .primary-cta:hover {
  background: #0f4e80;
}

body.store-entry nav {
  grid-template-columns: repeat(3, 1fr);
  grid-auto-flow: initial;
  grid-auto-columns: initial;
  overflow: hidden;
}

body.store-entry nav button {
  position: relative;
  padding: 13px 8px 14px;
  font-size: 14px;
  font-weight: 650;
}

body.store-entry nav button.active::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 6px;
  width: 22px;
  height: 3px;
  border-radius: 999px;
  background: var(--primary);
  transform: translateX(-50%);
}

.advance-ledger-head {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  margin-bottom: 14px;
}

.ledger-card {
  background: #fff;
  border: 1px solid #e6ebf1;
  border-radius: 8px;
  padding: 14px;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  box-shadow: 0 8px 22px rgba(15, 23, 42, .05);
}

.ledger-card.primary {
  background: linear-gradient(135deg, #1769aa, #0f4e80);
  color: #fff;
}

.ledger-card span {
  color: #667085;
  font-weight: 650;
}

.ledger-card.primary span {
  color: rgba(255,255,255,.78);
}

.ledger-card strong {
  font-size: 22px;
}

.advance-ledger-list {
  display: grid;
  gap: 12px;
}

.advance-card {
  background: #fff;
  border: 1px solid #e6ebf1;
  border-radius: 8px;
  padding: 14px;
  box-shadow: 0 8px 22px rgba(15, 23, 42, .05);
}

.advance-card-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.advance-card h3 {
  margin: 0 0 5px;
  font-size: 17px;
}

.advance-card p {
  margin: 0;
}

.advance-card-head p,
.usage-item span,
.usage-item small {
  color: #667085;
  font-size: 13px;
}

.advance-money {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin: 14px 0;
}

.advance-money p {
  background: #f8fafc;
  border-radius: 8px;
  padding: 10px;
  display: grid;
  gap: 4px;
}

.advance-money span {
  color: #667085;
  font-size: 12px;
}

.advance-money strong {
  font-size: 16px;
}

.ledger-proof {
  margin: 8px 0 12px;
}

.ledger-proof a {
  color: var(--primary);
  font-weight: 700;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}

.usage-list h4 {
  margin: 0 0 8px;
}

.usage-list {
  border-top: 1px solid #edf2f7;
  padding-top: 12px;
}

.usage-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 4px 10px;
  padding: 9px 0;
  border-bottom: 1px solid #f0f3f6;
}

.usage-item div {
  display: grid;
  gap: 2px;
}

.usage-item b {
  color: #16855a;
}

.usage-item small {
  grid-column: 1 / -1;
}

body.boss-entry .sidebar {
  padding: 0;
  border: 0;
  background: transparent;
}

body.boss-entry .brand,
body.boss-entry #logoutBtn {
  display: none;
}

body.boss-entry .topbar {
  padding: 22px 18px 10px;
}

body.boss-entry .topbar h2 {
  font-size: 26px;
  font-weight: 800;
  color: #101828;
}

body.boss-entry #view {
  padding: 4px 16px 22px;
}

body.boss-entry nav {
  grid-template-columns: repeat(2, 1fr);
  grid-auto-flow: initial;
  grid-auto-columns: initial;
  overflow: hidden;
}

body.boss-entry .boss-metrics {
  gap: 12px;
}

body.boss-entry .metric-button {
  color: var(--text);
  background: #fff;
  text-align: left;
  min-height: 118px;
  border: 1px solid #e6ebf1;
  box-shadow: 0 8px 22px rgba(15, 23, 42, .06);
}

body.boss-entry .metric-button:hover {
  background: #f8fbfe;
}

body.boss-entry .metric-button::after {
  content: "进入";
  margin-top: 8px;
  color: var(--primary);
  font-size: 13px;
  font-weight: 700;
}

body.boss-entry .boss-action {
  margin-top: 18px;
}

body.boss-entry .primary-cta {
  width: 100%;
  min-height: 54px;
  border-radius: 10px;
  background: #1769aa;
  font-size: 18px;
  font-weight: 750;
  box-shadow: 0 10px 24px rgba(23, 105, 170, .24);
}

body.pc-entry #view {
  background:
    linear-gradient(135deg, rgba(23,105,170,.08), transparent 32%),
    linear-gradient(225deg, rgba(22,133,90,.08), transparent 28%),
    var(--bg);
  min-height: calc(100vh - 64px);
}

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

.screen-head h3 {
  margin: 0 0 4px;
  font-size: 24px;
}

.screen-head p {
  margin: 0;
  color: var(--muted);
}

.segmented {
  display: inline-flex;
  padding: 4px;
  background: #eaf0f6;
  border-radius: 10px;
}

.segmented button {
  background: transparent;
  color: #344054;
  border-radius: 8px;
}

.segmented button.active {
  background: #fff;
  color: var(--primary-dark);
  box-shadow: 0 3px 10px rgba(15,23,42,.08);
}

.big-metrics {
  display: grid;
  grid-template-columns: 1.25fr 1fr 1fr 1fr;
  gap: 14px;
  margin-bottom: 16px;
}

.big-card {
  background: rgba(255,255,255,.92);
  border: 1px solid #e4eaf0;
  border-radius: 8px;
  padding: 18px;
  box-shadow: 0 12px 30px rgba(15,23,42,.07);
  display: grid;
  gap: 8px;
}

.big-card span {
  color: var(--muted);
  font-weight: 650;
}

.big-card strong {
  font-size: 28px;
  line-height: 1.1;
}

.big-card small {
  color: #98a2b3;
}

.big-card.primary {
  background: linear-gradient(135deg, #1769aa, #0f4e80);
  color: #fff;
}

.big-card.primary span,
.big-card.primary small {
  color: rgba(255,255,255,.78);
}

.big-card.warn {
  border-top: 4px solid #a05b00;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: 1.35fr .8fr .9fr;
  gap: 16px;
  align-items: stretch;
}

.viz-panel {
  background: rgba(255,255,255,.94);
  border: 1px solid #e4eaf0;
  border-radius: 8px;
  padding: 16px;
  box-shadow: 0 12px 30px rgba(15,23,42,.06);
  min-height: 260px;
}

.viz-panel.wide {
  grid-column: span 2;
}

.panel-title {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: baseline;
  margin-bottom: 14px;
}

.panel-title h3 {
  margin: 0;
}

.panel-title span {
  color: var(--muted);
  font-size: 13px;
}

.bar-list,
.supplier-list {
  display: grid;
  gap: 14px;
}

.bar-row,
.supplier-row {
  display: grid;
  gap: 7px;
}

.bar-label,
.supplier-row > div:first-child {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.bar-label span,
.supplier-row small {
  color: var(--muted);
}

.bar-track {
  width: 100%;
  height: 10px;
  border-radius: 999px;
  background: #edf2f7;
  overflow: hidden;
}

.bar-track i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #1769aa, #35a3d8);
}

.bar-parts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: #667085;
  font-size: 12px;
}

.donut {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  margin: 18px auto;
  display: grid;
  place-items: center;
  position: relative;
}

.donut::before {
  content: "";
  position: absolute;
  inset: 32px;
  background: #fff;
  border-radius: 50%;
}

.donut b,
.donut span {
  position: relative;
  z-index: 1;
}

.donut b {
  align-self: end;
}

.donut span {
  align-self: start;
  color: var(--muted);
  font-size: 12px;
}

.legend {
  display: grid;
  gap: 8px;
}

.legend p {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
}

.legend i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.legend .c0 { background: #1769aa; }
.legend .c1 { background: #16855a; }
.legend .c2 { background: #a05b00; }
.legend strong { margin-left: auto; }

.trend {
  width: 100%;
  height: 180px;
  background: linear-gradient(#eef3f8 1px, transparent 1px) 0 0/100% 25%;
}

.trend polyline {
  fill: none;
  stroke: #1769aa;
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.trend-foot {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: 12px;
}

.supplier-row {
  grid-template-columns: 1fr auto;
}

.supplier-row .bar-track {
  grid-column: 1 / -1;
}

.pay-status {
  display: grid;
  gap: 14px;
}

.pay-status p {
  margin: 0;
  padding: 14px;
  border-radius: 8px;
  background: #f8fafc;
  display: grid;
  gap: 4px;
}

.pay-status span,
.pay-status small {
  color: var(--muted);
}

.pay-status strong {
  font-size: 24px;
}

.finance-filters {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) minmax(150px, 1fr) 150px 150px auto;
  align-items: end;
}

.finance-filters a button {
  width: 100%;
}

.ops-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.ops-kpi {
  min-height: 116px;
  padding: 18px;
  background: #fff;
  border: 1px solid #dce3ea;
  border-top: 4px solid #237a57;
  display: grid;
  align-content: space-between;
}

.ops-kpi.critical {
  border-top-color: #b83232;
}

.ops-kpi span,
.ops-kpi small {
  color: #617184;
}

.ops-kpi strong {
  font-size: 32px;
  line-height: 1;
}

.ops-band {
  margin: 0 0 18px;
  padding: 20px 16px;
  background: #fff;
  border-top: 1px solid #dce3ea;
  border-bottom: 1px solid #dce3ea;
}

.compact-band {
  padding-bottom: 22px;
}

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

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

.section-heading h3 {
  font-size: 19px;
}

.section-heading p {
  margin-top: 4px;
  color: #6b7785;
  font-size: 13px;
}

.store-ops-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(260px, 1fr));
  gap: 12px;
}

.store-ops {
  border: 1px solid #dce3ea;
  border-radius: 6px;
  padding: 16px;
  background: #fbfcfd;
}

.store-ops.is-blocked {
  border-color: #e3a7a7;
  background: #fffafa;
}

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

.store-ops-head h3 {
  margin: 0;
  font-size: 18px;
}

.store-ops-lines {
  display: grid;
  gap: 0;
}

.store-ops-lines p {
  display: grid;
  grid-template-columns: 1fr auto 48px;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 8px 0;
  border-top: 1px solid #e8edf2;
}

.store-ops-lines span,
.store-ops-lines em {
  color: #6b7785;
  font-style: normal;
  font-size: 12px;
}

.store-ops-lines em {
  text-align: right;
}

.block-reason,
.warning-panel,
.success-panel {
  margin-top: 12px;
  padding: 10px 12px;
  border-left: 4px solid #b83232;
  background: #fff0f0;
  color: #8e2424;
}

.success-panel {
  border-left-color: #237a57;
  background: #edf9f3;
  color: #176342;
}

.admin-form-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(150px, 1fr));
  align-items: end;
  gap: 12px;
}

.admin-form-row label {
  display: grid;
  gap: 6px;
  color: #526172;
  font-size: 13px;
}

.admin-form-row input,
.admin-form-row select,
.admin-form-row textarea {
  width: 100%;
}

.admin-form-row select[multiple] {
  min-height: 94px;
}

.admin-form-row textarea {
  min-height: 72px;
}

.admin-form-row .wide-field {
  grid-column: span 2;
}

.inventory-preview-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0;
}

.inventory-preview-meta b {
  padding: 7px 10px;
  background: #edf2f6;
  border-radius: 4px;
  font-size: 13px;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 16px;
}

.muted {
  color: #6b7785;
}

@media (max-width: 1200px) {
  .big-metrics,
  .dashboard-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .viz-panel.wide {
    grid-column: span 2;
  }
  .ops-summary,
  .store-ops-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .admin-form-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
