:root {
  color-scheme: light;
  --bg: #f4f6f8;
  --surface: #ffffff;
  --surface-soft: #f8fafb;
  --surface-strong: #eef2f5;
  --text: #17212b;
  --text-soft: #536170;
  --muted: #8793a1;
  --line: #e4e9ed;
  --line-strong: #d7dee4;
  --blue: #245fda;
  --blue-soft: #eaf0ff;
  --green: #168967;
  --green-soft: #e7f6f1;
  --orange: #c66b16;
  --orange-soft: #fff2e5;
  --red: #cf3f3f;
  --red-soft: #ffeded;
  --purple: #7456b8;
  --purple-soft: #f1ecfb;
  --shadow: 0 1px 2px rgba(20, 31, 43, 0.04), 0 8px 24px rgba(20, 31, 43, 0.04);
  --shadow-float: 0 18px 45px rgba(20, 31, 43, 0.13);
  --radius: 8px;
  --sidebar-width: 224px;
  --font: "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", "Source Han Sans SC", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background: var(--bg);
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background: var(--bg);
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

html.cloud-gate-open,
html.cloud-gate-open body {
  overflow: hidden;
}

.cloud-gate {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: grid;
  place-items: center;
  padding: 24px;
}

.cloud-gate-backdrop {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(135deg, rgba(18, 31, 45, 0.96), rgba(26, 53, 77, 0.94)),
    radial-gradient(circle at 15% 10%, rgba(85, 146, 255, 0.24), transparent 34%);
}

.cloud-gate-card {
  position: relative;
  width: min(100%, 440px);
  max-height: calc(100vh - 48px);
  overflow: auto;
  padding: 30px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 28px 80px rgba(3, 13, 24, 0.35);
}

.cloud-gate-loading {
  display: grid;
  justify-items: center;
  text-align: center;
}

.cloud-gate-loading h1 {
  margin: 16px 0 6px;
  font-size: 20px;
}

.cloud-gate-loading p {
  margin: 0;
  color: var(--text-soft);
}

.cloud-gate-mark {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #e9f0ff;
}

.cloud-gate-mark span {
  width: 22px;
  height: 22px;
  border: 3px solid #d9e4fa;
  border-top-color: var(--blue);
  border-radius: 50%;
  animation: spin 800ms linear infinite;
}

.cloud-gate-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
}

.cloud-gate-logo {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #fff;
  background: #1f63dc;
  font-size: 19px;
  font-weight: 750;
}

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

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

.cloud-gate-brand span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
}

.cloud-gate-copy h1 {
  margin: 0;
  font-size: 25px;
  line-height: 1.2;
}

.cloud-gate-copy p {
  margin: 8px 0 0;
  color: var(--text-soft);
}

.cloud-gate-form {
  display: grid;
  gap: 14px;
  margin-top: 24px;
}

.cloud-gate-form label {
  display: grid;
  gap: 6px;
  color: var(--text-soft);
  font-size: 12px;
  font-weight: 650;
}

.cloud-gate-form input {
  width: 100%;
  min-height: 42px;
  padding: 0 12px;
  border: 1px solid var(--line-strong);
  border-radius: 7px;
  color: var(--text);
  background: #fff;
  outline: none;
}

.cloud-gate-form input:focus {
  border-color: #8aaef3;
  box-shadow: 0 0 0 3px rgba(36, 95, 218, 0.1);
}

.cloud-gate-error {
  min-height: 20px;
  color: var(--red);
  font-size: 12px;
}

.cloud-gate-submit {
  width: 100%;
  min-height: 44px;
  justify-content: center;
}

.cloud-gate-foot {
  margin-top: 18px;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}

.cloud-migration-actions {
  display: grid;
  gap: 10px;
  margin-top: 24px;
}

.cloud-migration-actions .button {
  width: 100%;
  justify-content: center;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  color: inherit;
}

button,
[role="button"] {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
  text-decoration: none;
}

svg {
  display: block;
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
}

.sidebar {
  position: sticky;
  top: 0;
  z-index: 20;
  height: 100vh;
  display: flex;
  flex-direction: column;
  padding: 18px 14px 14px;
  background: #fbfcfd;
  border-right: 1px solid var(--line);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 40px;
  padding: 0 8px;
  margin-bottom: 22px;
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 8px;
  color: #fff;
  background: #1f63dc;
  box-shadow: 0 6px 14px rgba(36, 95, 218, 0.2);
}

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

.brand-name {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0;
  white-space: nowrap;
}

.brand-sub {
  margin-top: 1px;
  color: var(--muted);
  font-size: 11px;
  white-space: nowrap;
}

.nav-label {
  padding: 0 10px;
  margin: 10px 0 7px;
  color: #9aa5b0;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.nav-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nav-item {
  position: relative;
  width: 100%;
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 0 11px;
  border: 0;
  border-radius: 7px;
  color: #596674;
  background: transparent;
  cursor: pointer;
  text-align: left;
  transition: color 140ms ease, background 140ms ease;
}

.nav-item:hover {
  color: var(--text);
  background: #f1f4f7;
}

.nav-item.active {
  color: var(--blue);
  background: var(--blue-soft);
  font-weight: 650;
}

.nav-item.active::before {
  content: "";
  position: absolute;
  left: -14px;
  top: 10px;
  width: 3px;
  height: 22px;
  border-radius: 0 3px 3px 0;
  background: var(--blue);
}

.nav-item svg {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
}

.nav-text {
  flex: 1;
  min-width: 0;
  white-space: nowrap;
}

.nav-badge {
  min-width: 20px;
  height: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 5px;
  border-radius: 10px;
  color: #9c4a00;
  background: var(--orange-soft);
  font-size: 11px;
  font-weight: 700;
}

.sidebar-foot {
  margin-top: auto;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.sync-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 12px;
  font-weight: 650;
}

.sync-dot {
  width: 7px;
  height: 7px;
  display: inline-block;
  margin-right: 6px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 3px var(--green-soft);
}

.sync-time {
  margin-top: 6px;
  color: var(--muted);
  font-size: 11px;
}

.sync-head.saving .sync-dot {
  background: var(--orange);
  box-shadow: 0 0 0 3px var(--orange-soft);
}

.sync-head.error .sync-dot {
  background: var(--red);
  box-shadow: 0 0 0 3px var(--red-soft);
}

.sync-button {
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 6px;
  color: var(--text-soft);
  background: transparent;
  cursor: pointer;
}

.sync-button:hover {
  color: var(--blue);
  background: var(--blue-soft);
}

.top-user {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 5px 4px 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.top-user-avatar {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 7px;
  color: #fff;
  background: #245fda;
  font-size: 12px;
  font-weight: 750;
}

.top-user-copy {
  min-width: 0;
  line-height: 1.2;
}

.top-user-copy strong,
.top-user-copy span {
  display: block;
  max-width: 112px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.top-user-copy strong {
  font-size: 12px;
}

.top-user-copy span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 10px;
}

.top-user-logout {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 6px;
  color: var(--text-soft);
  background: transparent;
  cursor: pointer;
}

.top-user-logout:hover {
  color: var(--red);
  background: var(--red-soft);
}

.sync-button.spin svg {
  animation: spin 720ms linear infinite;
}

.main-shell {
  min-width: 0;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 16;
  min-height: 66px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 26px;
  background: rgba(244, 246, 248, 0.92);
  border-bottom: 1px solid rgba(228, 233, 237, 0.9);
  backdrop-filter: blur(12px);
}

.store-picker {
  height: 38px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--surface);
  box-shadow: 0 1px 1px rgba(20, 31, 43, 0.03);
  cursor: pointer;
  font: inherit;
}

.store-picker-wrap {
  position: relative;
}

.store-menu {
  position: absolute;
  top: calc(100% + 7px);
  left: 0;
  z-index: 45;
  width: 286px;
  padding: 7px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  box-shadow: var(--shadow-float);
}

.store-menu-label {
  padding: 6px 9px 7px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
}

.store-menu-item {
  width: 100%;
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) 16px;
  align-items: center;
  gap: 8px;
  padding: 8px 9px;
  border: 0;
  border-radius: 7px;
  color: var(--text);
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.store-menu-item:hover {
  background: #f4f7fb;
}

.store-menu-item.active {
  color: var(--blue);
  background: var(--blue-soft);
}

.store-menu-item > svg {
  width: 15px;
  height: 15px;
}

.store-menu-icon {
  width: 27px;
  height: 27px;
  display: grid;
  place-items: center;
  border-radius: 7px;
  color: #a94800;
  background: #fff0e3;
  font-size: 11px;
  font-weight: 800;
}

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

.store-menu-item strong {
  font-size: 12px;
}

.store-menu-item small {
  margin-top: 1px;
  color: var(--muted);
  font-size: 9px;
}

.store-settings-table {
  min-width: 1260px;
}

.store-setting-name {
  min-width: 180px;
  display: flex;
  align-items: center;
  gap: 9px;
}

.store-setting-name strong,
.store-setting-name small {
  display: block;
}

.store-setting-name strong {
  color: var(--text);
  font-size: 12px;
}

.store-setting-name small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 9px;
}

.api-key {
  padding: 3px 6px;
  border-radius: 5px;
  color: #52606e;
  background: #eef2f5;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 10px;
}

.store-row-actions {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.danger-text {
  color: var(--red);
  border-color: #f2cece;
}

.api-settings-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.api-settings-grid > div {
  min-width: 0;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fcfdfe;
}

.api-settings-grid span,
.api-settings-grid strong {
  display: block;
}

.api-settings-grid span {
  color: var(--muted);
  font-size: 10px;
}

.api-settings-grid strong {
  margin-top: 5px;
  overflow: hidden;
  color: var(--text);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.import-template-grid,
.import-template-switch {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.import-template-card {
  min-width: 0;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 10px;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fcfdfe;
}

.import-template-card strong,
.import-template-card span,
.import-template-card small {
  display: block;
}

.import-template-card strong {
  color: var(--text);
  font-size: 12px;
}

.import-template-card span {
  margin-top: 4px;
  color: var(--text-soft);
  font-size: 10px;
}

.import-template-card small {
  margin-top: 5px;
  color: var(--muted);
  font-size: 9px;
}

.import-template-actions {
  grid-column: 1 / -1;
  display: flex;
  gap: 7px;
}

.import-template-actions .small-button {
  flex: 1;
}

.import-template-switch {
  margin-bottom: 14px;
}

.import-template-option {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) 16px;
  align-items: center;
  gap: 9px;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  background: #fff;
  text-align: left;
  cursor: pointer;
}

.import-template-option.active {
  border-color: #9bb7ed;
  background: #f8faff;
  box-shadow: 0 0 0 3px rgba(36, 95, 218, 0.08);
}

.import-template-option strong,
.import-template-option small {
  display: block;
}

.import-template-option strong {
  font-size: 12px;
}

.import-template-option small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 9px;
}

.import-template-option > svg {
  width: 15px;
  height: 15px;
  color: var(--green);
}

.monitor-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
  padding: 11px 14px;
  border-bottom: 1px solid var(--line);
  background: #fbfcfd;
}

.monitor-active-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 5px;
}

.monitor-active-filters > span:first-child {
  color: var(--muted);
  font-size: 10px;
}

.monitor-filter-chip {
  min-height: 25px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 0 5px 0 8px;
  border-radius: 13px;
  color: var(--blue);
  background: var(--blue-soft);
  font-size: 9px;
}

.monitor-filter-chip button {
  width: 17px;
  height: 17px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 50%;
  color: var(--blue);
  background: transparent;
  cursor: pointer;
}

.monitor-filter-chip button:hover {
  color: var(--red);
  background: #fff;
}

.monitor-filter-chip svg {
  width: 9px;
  height: 9px;
}

.monitor-matrix-scroll {
  max-height: 72vh;
}

.monitor-matrix-table {
  min-width: 2700px;
}

.monitor-matrix-table th,
.monitor-matrix-table td {
  height: 38px;
  padding-right: 8px;
  padding-left: 8px;
}

.monitor-matrix-table thead th {
  position: sticky;
  top: 0;
  z-index: 6;
  background: #fbfcfd;
}

.monitor-fixed-head {
  position: sticky !important;
  left: 0;
  width: 393px;
  min-width: 393px;
  max-width: 393px;
  text-align: left !important;
}

.monitor-product-date-header td {
  position: sticky;
  top: 38px;
  z-index: 5;
  color: var(--text-soft);
  background: #eef3f8;
}

.monitor-date-product-cell {
  position: sticky !important;
  left: 0;
  z-index: 7 !important;
  width: 393px;
  min-width: 393px;
  max-width: 393px;
  box-shadow: 1px 0 0 var(--line);
}

.monitor-date-product-cell strong,
.monitor-date-product-cell span {
  display: block;
}

.monitor-date-product-cell strong {
  color: var(--text);
  font-size: 10px;
}

.monitor-date-product-cell span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 8px;
}

.monitor-image-col {
  position: sticky;
  left: 0;
  z-index: 2;
  width: 78px;
  min-width: 78px;
  max-width: 78px;
  background: #fff;
  box-shadow: 1px 0 0 var(--line);
}

.monitor-id-col {
  position: sticky;
  left: 78px;
  z-index: 2;
  width: 205px;
  min-width: 205px;
  max-width: 205px;
  background: #fff;
  box-shadow: 1px 0 0 var(--line);
}

.monitor-metric-col {
  position: sticky;
  left: 283px;
  z-index: 2;
  width: 110px;
  min-width: 110px;
  max-width: 110px;
  color: var(--text) !important;
  background: #fff;
  font-weight: 700 !important;
  box-shadow: 1px 0 0 var(--line);
}

.monitor-matrix-table th.monitor-image-col,
.monitor-matrix-table th.monitor-id-col,
.monitor-matrix-table th.monitor-metric-col {
  z-index: 5;
  background: #fbfcfd;
}

.monitor-day-col {
  min-width: 76px;
  text-align: right;
}

.monitor-day-col span,
.monitor-day-col small {
  display: block;
}

.monitor-day-col small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 8px;
  font-weight: 500;
}

.monitor-product-block {
  border-bottom: 2px solid #dce4ee;
}

.monitor-product-block:last-child {
  border-bottom: 0;
}

.monitor-product-start > td {
  border-top: 2px solid #dce4ee !important;
}

.product-main-image.monitor-product-image {
  width: 58px;
  height: 58px;
  margin: 0 auto;
}

.monitor-id-col strong,
.monitor-id-col span,
.monitor-id-col small {
  display: block;
}

.monitor-id-col strong {
  color: var(--text);
  font-size: 10px;
}

.monitor-id-col span {
  display: -webkit-box;
  margin-top: 4px;
  overflow: hidden;
  color: var(--text-soft);
  font-size: 9px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.monitor-id-col small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 8px;
}

.monitor-listing-date {
  margin-top: 5px;
  color: var(--orange);
  font-size: 8px;
  font-weight: 700;
}

.monitor-owner-chain {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 3px;
  margin-top: 6px;
}

.monitor-owner-chain b {
  padding: 2px 5px;
  border-radius: 5px;
  color: var(--text-soft);
  background: #eef2f5;
  font-size: 8px;
}

.monitor-owner-chain i {
  color: var(--blue);
  font-size: 8px;
  font-style: normal;
}

.monitor-rate-button {
  min-height: 22px;
  display: inline-flex;
  align-items: center;
  margin-top: 6px;
  padding: 0 7px;
  border: 1px solid #c8d7f6;
  border-radius: 6px;
  color: var(--blue);
  background: var(--blue-soft);
  font-size: 8px;
  cursor: pointer;
}

.monitor-rate-global {
  color: var(--blue);
  border-color: #c8d7f6;
}

.monitor-rate-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 12px;
}

.monitor-choice-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.monitor-product-choice-list {
  max-height: 480px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  overflow-y: auto;
}

.monitor-product-choice {
  min-width: 0;
  display: grid;
  grid-template-columns: 18px 42px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  padding: 9px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fcfdfe;
  cursor: pointer;
}

.monitor-product-choice:has(input:checked) {
  border-color: #9bb7ed;
  background: #f8faff;
}

.monitor-product-choice strong,
.monitor-product-choice small {
  display: block;
}

.monitor-product-choice strong {
  overflow: hidden;
  color: var(--text);
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.monitor-product-choice small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 8px;
}

.product-main-image.monitor-choice-image {
  width: 40px;
  height: 40px;
}

.store-avatar {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  color: #a94800;
  background: #fff0e3;
  font-size: 11px;
  font-weight: 800;
}

.store-name {
  max-width: 180px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 650;
}

.store-picker > svg {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  color: var(--muted);
}

.topbar-spacer {
  flex: 1;
}

.top-date {
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--text-soft);
  font-size: 12px;
  white-space: nowrap;
}

.top-date svg {
  width: 15px;
  height: 15px;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.icon-button,
.button,
.segment-button,
.small-button {
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--surface);
  cursor: pointer;
  transition: border-color 140ms ease, background 140ms ease, color 140ms ease, box-shadow 140ms ease;
}

.icon-button {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  padding: 0;
  color: var(--text-soft);
}

.icon-button:hover,
.button:hover,
.small-button:hover,
.segment-button:hover {
  border-color: var(--line-strong);
  background: #fbfcfd;
}

.icon-button:focus-visible,
.button:focus-visible,
.small-button:focus-visible,
.segment-button:focus-visible,
.nav-item:focus-visible,
.table-row-button:focus-visible {
  outline: 2px solid rgba(36, 95, 218, 0.32);
  outline-offset: 1px;
}

.button {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 13px;
  color: var(--text);
  font-weight: 620;
  white-space: nowrap;
}

.button.primary {
  color: #fff;
  border-color: var(--blue);
  background: var(--blue);
  box-shadow: 0 6px 14px rgba(36, 95, 218, 0.17);
}

.button.primary:hover {
  border-color: #194fbf;
  background: #194fbf;
}

.button.ghost {
  border-color: transparent;
  background: transparent;
}

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

.button svg,
.icon-button svg,
.small-button svg {
  width: 17px;
  height: 17px;
}

.page {
  max-width: 1580px;
  margin: 0 auto;
  padding: 26px;
}

.page-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 20px;
}

.eyebrow {
  margin: 0 0 5px;
  color: var(--muted);
  font-size: 12px;
}

.page-title {
  margin: 0;
  font-size: 25px;
  line-height: 1.25;
  letter-spacing: -0.015em;
}

.page-subtitle {
  margin: 7px 0 0;
  color: var(--text-soft);
  font-size: 13px;
}

.page-head-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-top: 3px;
}

.range-control {
  display: inline-flex;
  align-items: center;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.range-control-shell {
  position: relative;
}

.range-control .segment-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.range-control .segment-button svg {
  width: 14px;
  height: 14px;
}

.date-range-popover {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 40;
  width: 370px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  box-shadow: var(--shadow-float);
}

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

.date-range-head strong {
  font-size: 13px;
}

.date-range-head span {
  color: var(--muted);
  font-size: 10px;
}

.date-range-fields {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 14px minmax(0, 1fr);
  align-items: end;
  gap: 7px;
}

.date-range-fields > i {
  padding-bottom: 11px;
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  text-align: center;
}

.date-range-fields label {
  display: grid;
  gap: 5px;
}

.date-range-fields label > span {
  color: var(--text-soft);
  font-size: 10px;
  font-weight: 650;
}

.date-range-fields input {
  width: 100%;
  height: 36px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-radius: 7px;
  outline: 0;
  color: var(--text);
  background: #fff;
}

.date-range-fields input:focus {
  border-color: #9bb7ed;
  box-shadow: 0 0 0 3px rgba(36, 95, 218, 0.08);
}

.date-range-actions {
  display: flex;
  justify-content: flex-end;
  gap: 7px;
  margin-top: 13px;
}

.primary-small {
  color: #fff;
  border-color: var(--blue);
  background: var(--blue);
}

.segment-button {
  min-height: 31px;
  padding: 0 11px;
  border-color: transparent;
  color: var(--text-soft);
  background: transparent;
  font-size: 12px;
}

.segment-button.active {
  color: var(--blue);
  background: var(--blue-soft);
  font-weight: 700;
}

.notice-strip {
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  padding: 9px 12px;
  border: 1px solid #f1ddc2;
  border-radius: 8px;
  color: #754312;
  background: #fff9f0;
  font-size: 12px;
}

.notice-strip svg {
  width: 17px;
  height: 17px;
  flex: 0 0 auto;
  color: var(--orange);
}

.notice-strip strong {
  color: #5d3310;
}

.notice-close {
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  margin-left: auto;
  padding: 0;
  border: 0;
  border-radius: 5px;
  color: #98633a;
  background: transparent;
  cursor: pointer;
}

.notice-close:hover {
  background: #f9ecd9;
}

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

.kpi-card {
  position: relative;
  min-width: 0;
  min-height: 148px;
  padding: 16px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.kpi-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.kpi-label {
  color: var(--text-soft);
  font-size: 13px;
  font-weight: 600;
}

.metric-icon {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 7px;
}

.metric-icon svg {
  width: 16px;
  height: 16px;
}

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

.metric-icon.green {
  color: var(--green);
  background: var(--green-soft);
}

.metric-icon.orange {
  color: var(--orange);
  background: var(--orange-soft);
}

.metric-icon.purple {
  color: var(--purple);
  background: var(--purple-soft);
}

.metric-icon.red {
  color: var(--red);
  background: var(--red-soft);
}

.metric-value {
  margin-top: 8px;
  font-size: 28px;
  line-height: 1.15;
  font-weight: 740;
  letter-spacing: -0.025em;
  font-variant-numeric: tabular-nums;
}

.metric-foot {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  font-size: 12px;
}

.metric-compare {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-weight: 700;
}

.metric-compare.up {
  color: var(--green);
}

.metric-compare.down {
  color: var(--red);
}

.metric-compare svg {
  width: 13px;
  height: 13px;
}

.metric-note {
  color: var(--muted);
}

.metric-progress {
  height: 4px;
  margin-top: 14px;
  overflow: hidden;
  border-radius: 4px;
  background: #edf0f3;
}

.metric-progress > span {
  height: 100%;
  display: block;
  border-radius: inherit;
  background: var(--blue);
}

.sparkline {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 112px;
  height: 48px;
  opacity: 0.72;
  pointer-events: none;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 14px;
}

.panel {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.panel.span-4 {
  grid-column: span 4;
}

.panel.span-5 {
  grid-column: span 5;
}

.panel.span-6 {
  grid-column: span 6;
}

.panel.span-7 {
  grid-column: span 7;
}

.panel.span-8 {
  grid-column: span 8;
}

.panel.span-12 {
  grid-column: span 12;
}

.panel-head {
  min-height: 58px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 16px 11px;
  border-bottom: 1px solid var(--line);
}

.panel-head.no-border {
  border-bottom: 0;
}

.panel-title-wrap {
  min-width: 0;
}

.panel-title {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
}

.panel-subtitle {
  margin-top: 2px;
  color: var(--muted);
  font-size: 11px;
}

.panel-actions {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-left: auto;
}

.panel-body {
  padding: 16px;
}

.panel-body.flush {
  padding: 0;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border: 0;
  padding: 0;
  color: var(--blue);
  background: transparent;
  font-size: 12px;
  font-weight: 650;
  cursor: pointer;
}

.text-link:hover {
  color: #194fbf;
}

.text-link svg {
  width: 14px;
  height: 14px;
}

.chart-wrap {
  width: 100%;
  overflow: hidden;
}

.chart-svg {
  width: 100%;
  height: auto;
  overflow: visible;
}

.chart-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 8px;
  color: var(--text-soft);
  font-size: 11px;
}

.legend-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 2px;
  flex: 0 0 auto;
}

.target-progress-row {
  display: grid;
  grid-template-columns: 130px minmax(0, 1fr) 72px;
  align-items: center;
  gap: 12px;
  margin-top: 16px;
}

.target-progress-label {
  color: var(--text-soft);
  font-size: 12px;
}

.target-progress {
  height: 8px;
  overflow: hidden;
  border-radius: 5px;
  background: #edf0f3;
}

.target-progress > span {
  height: 100%;
  display: block;
  border-radius: inherit;
  background: var(--green);
}

.target-value {
  text-align: right;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 12px;
  font-weight: 700;
}

.target-progress-link {
  display: flex;
  justify-content: flex-end;
  margin-top: 8px;
}

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

.summary-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}

.summary-label {
  color: var(--text-soft);
  font-size: 12px;
}

.summary-value {
  font-size: 13px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.summary-bar {
  height: 5px;
  grid-column: 1 / -1;
  overflow: hidden;
  border-radius: 3px;
  background: #eff2f4;
}

.summary-bar > span {
  height: 100%;
  display: block;
  border-radius: inherit;
}

.alert-list {
  display: grid;
  gap: 0;
}

.alert-item {
  display: grid;
  grid-template-columns: 8px minmax(0, 1fr) auto;
  align-items: start;
  gap: 10px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
}

.alert-item:first-child {
  padding-top: 0;
}

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

.alert-priority {
  width: 7px;
  height: 7px;
  margin-top: 6px;
  border-radius: 50%;
}

.alert-priority.high {
  background: var(--red);
  box-shadow: 0 0 0 3px var(--red-soft);
}

.alert-priority.medium {
  background: var(--orange);
  box-shadow: 0 0 0 3px var(--orange-soft);
}

.alert-priority.low {
  background: var(--blue);
  box-shadow: 0 0 0 3px var(--blue-soft);
}

.alert-title {
  font-size: 13px;
  font-weight: 680;
}

.alert-desc {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
}

.alert-time {
  color: var(--muted);
  font-size: 11px;
  white-space: nowrap;
}

.table-scroll {
  width: 100%;
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  white-space: nowrap;
}

.data-table th {
  height: 38px;
  padding: 0 13px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  background: #fbfcfd;
  font-size: 11px;
  font-weight: 700;
  text-align: left;
}

.data-table th.right,
.data-table td.right {
  text-align: right;
}

.data-table th.center,
.data-table td.center {
  text-align: center;
}

.data-table td {
  height: 54px;
  padding: 0 13px;
  border-bottom: 1px solid var(--line);
  color: var(--text-soft);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}

.data-table tr:last-child td {
  border-bottom: 0;
}

.data-table tbody tr:hover td {
  background: #fafcff;
}

.table-strong {
  color: var(--text);
  font-weight: 680;
}

.table-rank {
  width: 25px;
  height: 25px;
  display: inline-grid;
  place-items: center;
  border-radius: 6px;
  color: var(--text-soft);
  background: #f1f3f5;
  font-size: 11px;
  font-weight: 750;
}

.table-rank.top {
  color: #9d4c05;
  background: var(--orange-soft);
}

.table-product {
  min-width: 218px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.product-thumb {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 7px;
  font-size: 13px;
  font-weight: 750;
}

.product-meta {
  min-width: 0;
}

.product-name {
  max-width: 250px;
  overflow: hidden;
  color: var(--text);
  font-size: 12px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.product-sku {
  margin-top: 2px;
  color: var(--muted);
  font-size: 10px;
}

.status-pill {
  min-height: 22px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 0 8px;
  border-radius: 11px;
  font-size: 11px;
  font-weight: 650;
}

.status-pill::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: currentColor;
}

.status-pill.good {
  color: var(--green);
  background: var(--green-soft);
}

.status-pill.watch {
  color: var(--orange);
  background: var(--orange-soft);
}

.status-pill.risk {
  color: var(--red);
  background: var(--red-soft);
}

.status-pill.neutral {
  color: #687583;
  background: #eff2f4;
}

.delta {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-weight: 700;
}

.delta.up {
  color: var(--green);
}

.delta.down {
  color: var(--red);
}

.delta svg {
  width: 12px;
  height: 12px;
}

.funnel {
  display: grid;
  gap: 9px;
}

.funnel-row {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr) 92px;
  align-items: center;
  gap: 10px;
}

.funnel-label {
  color: var(--text-soft);
  font-size: 12px;
}

.funnel-track {
  height: 24px;
  display: flex;
  align-items: center;
  overflow: hidden;
  border-radius: 5px;
  background: #f0f3f5;
}

.funnel-fill {
  height: 100%;
  min-width: 3px;
  border-radius: 5px;
  background: var(--blue);
}

.funnel-value {
  text-align: right;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 11px;
  font-weight: 700;
}

.channel-grid,
.platform-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.platform-card {
  min-width: 0;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fcfdfe;
}

.platform-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.platform-name {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  font-size: 13px;
  font-weight: 700;
}

.platform-mark {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 800;
}

.platform-spend {
  margin-top: 11px;
  font-size: 20px;
  font-weight: 740;
  font-variant-numeric: tabular-nums;
}

.platform-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 7px;
  color: var(--muted);
  font-size: 11px;
}

.toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
}

.search-box {
  min-width: 220px;
  height: 38px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--surface);
}

.search-box:focus-within {
  border-color: #9bb7ed;
  box-shadow: 0 0 0 3px rgba(36, 95, 218, 0.08);
}

.search-box svg {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  color: var(--muted);
}

.search-box input {
  width: 100%;
  border: 0;
  outline: 0;
  color: var(--text);
  background: transparent;
}

.search-box input::placeholder {
  color: #a2adb8;
}

.select-control {
  height: 38px;
  min-width: 128px;
  padding: 0 30px 0 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  color: var(--text-soft);
  background: var(--surface);
  cursor: pointer;
}

.toolbar-spacer {
  flex: 1;
}

.filter-chips {
  display: flex;
  align-items: center;
  gap: 6px;
}

.filter-chip {
  min-height: 32px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 16px;
  color: var(--text-soft);
  background: var(--surface);
  font-size: 11px;
  cursor: pointer;
}

.filter-chip.active {
  color: var(--blue);
  border-color: #c8d7f6;
  background: var(--blue-soft);
  font-weight: 700;
}

.table-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 14px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 11px;
}

.pagination {
  display: flex;
  align-items: center;
  gap: 4px;
}

.page-button {
  min-width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  padding: 0 7px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--text-soft);
  background: #fff;
  font-size: 11px;
  cursor: pointer;
}

.page-button.active {
  color: #fff;
  border-color: var(--blue);
  background: var(--blue);
}

.page-button:disabled {
  opacity: 0.45;
  cursor: default;
}

.drawer-backdrop {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: rgba(20, 31, 43, 0.28);
  animation: fade-in 140ms ease-out;
}

.drawer {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 61;
  width: min(430px, 100vw);
  height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  box-shadow: var(--shadow-float);
  animation: slide-in 180ms ease-out;
}

.drawer-head {
  min-height: 66px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 18px;
  border-bottom: 1px solid var(--line);
}

.drawer-title {
  font-size: 16px;
  font-weight: 720;
}

.drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 18px;
}

.drawer-close {
  margin-left: auto;
}

.drawer-product {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
}

.drawer-product .product-thumb {
  width: 48px;
  height: 48px;
  font-size: 17px;
}

.drawer-product-name {
  font-size: 14px;
  font-weight: 700;
}

.drawer-product-sku {
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.detail-item {
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.detail-label {
  color: var(--muted);
  font-size: 11px;
}

.detail-value {
  margin-top: 5px;
  font-size: 17px;
  font-weight: 720;
  font-variant-numeric: tabular-nums;
}

.mini-progress-list {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.mini-progress-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 12px;
}

.mini-progress {
  height: 6px;
  margin-top: 7px;
  overflow: hidden;
  border-radius: 4px;
  background: #edf0f3;
}

.mini-progress > span {
  height: 100%;
  display: block;
  border-radius: inherit;
}

.drawer-note {
  margin-top: 16px;
  padding: 12px;
  border-radius: 8px;
  color: #5f4a13;
  background: #fff8e6;
  font-size: 12px;
}

.drawer-actions {
  display: flex;
  gap: 8px;
  margin-top: 18px;
}

.drawer-actions .button {
  flex: 1;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(20, 31, 43, 0.34);
  animation: fade-in 140ms ease-out;
}

.modal {
  width: min(680px, 100%);
  max-height: min(780px, calc(100vh - 40px));
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 10px;
  background: #fff;
  box-shadow: var(--shadow-float);
  animation: modal-in 170ms ease-out;
}

.modal-head {
  min-height: 62px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 18px;
  border-bottom: 1px solid var(--line);
}

.modal-title {
  font-size: 16px;
  font-weight: 720;
}

.modal-close {
  margin-left: auto;
}

.modal-body {
  flex: 1;
  overflow-y: auto;
  padding: 18px;
}

.modal-foot {
  min-height: 64px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  padding: 0 18px;
  border-top: 1px solid var(--line);
  background: #fbfcfd;
}

.upload-zone {
  min-height: 176px;
  display: grid;
  place-items: center;
  padding: 22px;
  border: 1px dashed #b8c5d1;
  border-radius: 9px;
  background: #fafcfd;
  text-align: center;
  transition: border-color 150ms ease, background 150ms ease;
}

.template-format-label { display:flex; align-items:center; justify-content:center; flex-wrap:wrap; gap:8px; color:#64748b; font-size:12px; }
.template-format-label select { min-height:44px; max-width:100%; border:1px solid #dfe6f0; border-radius:9px; padding:8px 12px; color:#24384f; background:#fff; }

.upload-zone.dragover {
  border-color: var(--blue);
  background: var(--blue-soft);
}

.upload-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  margin: 0 auto 10px;
  border-radius: 50%;
  color: var(--blue);
  background: var(--blue-soft);
}

.upload-icon svg {
  width: 20px;
  height: 20px;
}

.upload-title {
  font-size: 14px;
  font-weight: 700;
}

.upload-sub {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
}

.upload-actions {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 14px;
}

.field-section {
  margin-top: 18px;
}

.field-section-title {
  margin-bottom: 9px;
  font-size: 13px;
  font-weight: 700;
}

.field-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.field-chip {
  min-width: 0;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fbfcfd;
}

.field-chip.required {
  border-color: #cbd9f5;
  background: #f8faff;
}

.field-chip-name {
  font-size: 12px;
  font-weight: 680;
}

.field-chip-note {
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
}

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

.source-card {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fcfdfe;
}

.source-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 8px;
}

.source-icon svg {
  width: 18px;
  height: 18px;
}

.source-name {
  margin-top: 10px;
  font-size: 13px;
  font-weight: 700;
}

.source-status {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 4px;
  color: var(--green);
  font-size: 11px;
  font-weight: 650;
}

.source-status::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: currentColor;
}

.source-meta {
  margin-top: 9px;
  color: var(--muted);
  font-size: 10px;
}

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

.quality-row {
  display: grid;
  grid-template-columns: 100px minmax(0, 1fr) 62px;
  align-items: center;
  gap: 10px;
}

.quality-label {
  color: var(--text-soft);
  font-size: 12px;
}

.quality-track {
  height: 6px;
  overflow: hidden;
  border-radius: 4px;
  background: #edf0f3;
}

.quality-track > span {
  height: 100%;
  display: block;
  border-radius: inherit;
  background: var(--green);
}

.quality-value {
  text-align: right;
  font-size: 11px;
  font-weight: 700;
}

.import-history {
  display: grid;
}

.history-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
}

.history-row:last-child {
  border-bottom: 0;
}

.history-name {
  font-size: 12px;
  font-weight: 650;
}

.history-meta {
  margin-top: 2px;
  color: var(--muted);
  font-size: 10px;
}

.history-count {
  color: var(--green);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.nav-groups {
  min-height: 0;
  flex: 1;
  overflow-y: auto;
  scrollbar-width: thin;
}

.nav-group + .nav-group {
  margin-top: 10px;
}

.icon-badge {
  position: absolute;
  top: 3px;
  right: 3px;
  min-width: 15px;
  height: 15px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 3px;
  border: 2px solid var(--bg);
  border-radius: 8px;
  color: #fff;
  background: var(--red);
  font-size: 9px;
  font-weight: 800;
}

.notification-button {
  position: relative;
}

.toolbar-note {
  color: var(--muted);
  font-size: 12px;
}

.table-link {
  max-width: 280px;
  overflow: hidden;
  padding: 0;
  border: 0;
  color: var(--blue);
  background: transparent;
  font-size: 12px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
  cursor: pointer;
}

.table-link:hover {
  color: #194fbf;
  text-decoration: underline;
}

.cell-sub {
  max-width: 260px;
  overflow: hidden;
  margin-top: 2px;
  color: var(--muted);
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cell-ellipsis {
  max-width: 300px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.text-danger {
  color: var(--red);
  font-weight: 700;
}

.task-list {
  display: grid;
}

.task-item {
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr);
  gap: 11px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}

.task-item:first-child {
  padding-top: 0;
}

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

.task-item.done {
  opacity: 0.62;
}

.task-check {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  margin-top: 1px;
  padding: 0;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  color: #fff;
  background: #fff;
  cursor: pointer;
}

.task-check.checked {
  border-color: var(--green);
  background: var(--green);
}

.task-check svg {
  width: 13px;
  height: 13px;
}

.task-title-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px;
}

.task-title {
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
}

.priority-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
}

.priority-dot.high {
  background: var(--red);
  box-shadow: 0 0 0 3px var(--red-soft);
}

.priority-dot.medium {
  background: var(--orange);
  box-shadow: 0 0 0 3px var(--orange-soft);
}

.priority-dot.low {
  background: var(--blue);
  box-shadow: 0 0 0 3px var(--blue-soft);
}

.task-desc {
  margin-top: 5px;
  color: var(--text-soft);
  font-size: 12px;
}

.task-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 8px;
  color: var(--muted);
  font-size: 11px;
}

.task-meta span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.task-meta svg {
  width: 13px;
  height: 13px;
}

.warehouse-list {
  display: grid;
  gap: 18px;
}

.warehouse-head,
.coverage-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 7px;
  color: var(--text-soft);
  font-size: 12px;
}

.warehouse-head strong,
.coverage-head strong {
  color: var(--text);
  font-size: 11px;
}

.warehouse-meta {
  margin-top: 6px;
  color: var(--muted);
  font-size: 10px;
}

.account-cell {
  display: flex;
  align-items: center;
  gap: 10px;
}

.account-avatar {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 800;
}

.account-avatar.large {
  width: 44px;
  height: 44px;
  color: #fff;
  font-size: 15px;
}

.account-hero,
.role-detail-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
}

.role-chip {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 700;
}

.role-list {
  display: grid;
}

.role-row {
  width: 100%;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) 54px 54px 18px;
  align-items: center;
  gap: 10px;
  padding: 13px 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  cursor: pointer;
  text-align: left;
}

.role-row:first-child {
  padding-top: 0;
}

.role-row:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.role-row:hover .role-name {
  color: var(--blue);
}

.role-row > svg {
  width: 16px;
  height: 16px;
  color: var(--muted);
}

.role-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 8px;
}

.role-icon.large {
  width: 44px;
  height: 44px;
}

.role-icon svg {
  width: 18px;
  height: 18px;
}

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

.role-name {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
}

.role-desc {
  display: -webkit-box;
  margin-top: 3px;
  overflow: hidden;
  color: var(--muted);
  font-size: 10px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.role-metrics {
  text-align: right;
}

.role-metrics strong,
.role-detail-stat strong {
  display: block;
  color: var(--text);
  font-size: 14px;
}

.role-metrics small,
.role-detail-stat small {
  color: var(--muted);
  font-size: 10px;
}

.role-detail-stat {
  margin-left: auto;
  text-align: right;
}

.system-tag {
  padding: 2px 5px;
  border-radius: 4px;
  color: var(--red);
  background: var(--red-soft);
  font-size: 9px;
  font-style: normal;
}

.permission-coverage {
  display: grid;
  gap: 14px;
}

.split-bar {
  height: 7px;
  display: flex;
  overflow: hidden;
  border-radius: 5px;
  background: #edf0f3;
}

.split-bar span,
.split-bar i {
  height: 100%;
  display: block;
}

.drawer-wide {
  width: min(640px, 100vw);
}

.detail-small {
  font-size: 14px;
}

.info-block {
  margin-top: 16px;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fcfdfe;
}

.info-block-head {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 9px;
  color: var(--text);
  font-size: 12px;
  font-weight: 700;
}

.info-block-head svg {
  width: 15px;
  height: 15px;
  color: var(--blue);
}

.info-line {
  color: var(--text-soft);
  font-size: 12px;
}

.info-line + .info-line {
  margin-top: 5px;
}

.info-line.muted {
  color: var(--muted);
}

.timeline {
  display: grid;
}

.timeline-item {
  position: relative;
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 9px;
  min-height: 48px;
}

.timeline-item:not(:last-child)::before {
  content: "";
  position: absolute;
  left: 8px;
  top: 18px;
  width: 1px;
  height: calc(100% - 2px);
  background: var(--line-strong);
}

.timeline-dot {
  position: relative;
  z-index: 1;
  width: 17px;
  height: 17px;
  display: grid;
  place-items: center;
  margin-top: 1px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  color: #fff;
  background: #fff;
}

.timeline-item.done .timeline-dot {
  border-color: var(--green);
  background: var(--green);
}

.timeline-dot svg {
  width: 10px;
  height: 10px;
}

.timeline-title {
  color: var(--text-soft);
  font-size: 12px;
  font-weight: 650;
}

.timeline-time {
  margin-top: 2px;
  color: var(--muted);
  font-size: 10px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.form-field {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-field.full {
  margin-top: 12px;
}

.form-field > span {
  color: var(--text-soft);
  font-size: 11px;
  font-weight: 650;
}

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  min-height: 38px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  outline: 0;
  color: var(--text);
  background: #fff;
  resize: vertical;
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  border-color: #9bb7ed;
  box-shadow: 0 0 0 3px rgba(36, 95, 218, 0.08);
}

.check-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.check-item,
.permission-check,
.switch-label {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  color: var(--text-soft);
  background: #fff;
  font-size: 11px;
  cursor: pointer;
}

.check-item input,
.permission-check input,
.switch-label input {
  accent-color: var(--blue);
}

.permission-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 18px 0 10px;
  color: var(--text-soft);
  font-size: 12px;
  font-weight: 650;
}

.permission-toolbar .small-button {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 30px;
  padding: 0 9px;
}

.permission-toolbar svg {
  width: 14px;
  height: 14px;
}

.permission-matrix {
  display: grid;
  gap: 9px;
}

.permission-module {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fcfdfe;
}

.permission-module-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 9px;
}

.permission-module-head strong {
  color: var(--text);
  font-size: 12px;
}

.permission-module-head span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 9px;
}

.switch-label {
  min-height: 28px;
  padding: 0 8px;
}

.permission-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.permission-check {
  min-height: 28px;
  padding: 0 8px;
}

.permission-check:has(input:checked),
.switch-label:has(input:checked) {
  border-color: #c8d7f6;
  color: var(--blue);
  background: var(--blue-soft);
}

.learning-track-panel {
  position: relative;
  overflow: hidden;
}

.learning-track-accent {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
}

.learning-track-title-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.learning-track-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 8px;
}

.learning-track-icon svg {
  width: 18px;
  height: 18px;
}

.learning-track-icon.large {
  width: 48px;
  height: 48px;
}

.learning-track-icon.large svg {
  width: 22px;
  height: 22px;
}

.learning-percent {
  font-size: 15px;
  font-weight: 780;
}

.learning-description {
  margin: 0 0 15px;
  color: var(--text-soft);
  font-size: 12px;
}

.learning-progress-block {
  margin-bottom: 14px;
}

.skill-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 14px;
}

.skill-chips span {
  padding: 4px 8px;
  border-radius: 10px;
  color: var(--text-soft);
  background: #f0f3f5;
  font-size: 10px;
  font-weight: 650;
}

.learning-outcome {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 11px 12px;
  border-radius: 8px;
  color: #5f4a13;
  background: #fff8e6;
  font-size: 11px;
}

.learning-outcome svg {
  width: 15px;
  height: 15px;
  flex: 0 0 auto;
  color: var(--orange);
}

.lesson-preview {
  display: grid;
  gap: 0;
  margin-top: 13px;
}

.lesson-preview-row {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  align-items: center;
  gap: 9px;
  padding: 9px 0;
  border-bottom: 1px solid var(--line);
}

.lesson-preview-row:last-child {
  border-bottom: 0;
}

.lesson-preview-row.done {
  opacity: 0.62;
}

.lesson-preview-row.current .lesson-preview-title {
  color: var(--blue);
}

.lesson-state {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--muted);
  background: #fff;
  font-size: 10px;
  font-weight: 750;
}

.lesson-preview-row.done .lesson-state {
  color: #fff;
  border-color: var(--green);
  background: var(--green);
}

.lesson-preview-row.current .lesson-state {
  color: var(--blue);
  border-color: #c8d7f6;
  background: var(--blue-soft);
}

.lesson-state svg {
  width: 12px;
  height: 12px;
}

.lesson-preview-title {
  color: var(--text-soft);
  font-size: 12px;
  font-weight: 650;
}

.lesson-preview-meta {
  margin-top: 2px;
  color: var(--muted);
  font-size: 10px;
}

.learning-actions {
  display: flex;
  gap: 8px;
  margin-top: 14px;
}

.learning-actions .button {
  flex: 1;
}

.weekly-plan {
  display: grid;
}

.weekly-plan-row {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 11px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
}

.weekly-plan-row:first-child {
  padding-top: 0;
}

.weekly-plan-row:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.weekly-plan-date {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  font-size: 11px;
  font-weight: 750;
}

.weekly-plan-copy {
  min-width: 0;
}

.weekly-plan-copy strong {
  display: block;
  color: var(--text);
  font-size: 12px;
}

.weekly-plan-copy span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
}

.learning-advice-list {
  display: grid;
  gap: 14px;
}

.learning-advice {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 9px;
}

.learning-advice > svg {
  width: 19px;
  height: 19px;
  margin-top: 1px;
  color: var(--blue);
}

.learning-advice strong {
  display: block;
  color: var(--text);
  font-size: 12px;
}

.learning-advice span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
}

.learning-hero {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) 74px;
  align-items: center;
  gap: 12px;
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
}

.learning-hero-copy p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 10px;
}

.learning-progress-circle {
  position: relative;
  width: 70px;
  height: 70px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: conic-gradient(var(--track) var(--progress), #e8ecef 0);
}

.learning-progress-circle::before {
  content: "";
  position: absolute;
  inset: 6px;
  border-radius: 50%;
  background: #fff;
}

.learning-progress-circle strong,
.learning-progress-circle span {
  position: relative;
  z-index: 1;
  display: block;
  text-align: center;
}

.learning-progress-circle strong {
  margin-top: 6px;
  color: var(--text);
  font-size: 14px;
}

.learning-progress-circle span {
  margin-top: -4px;
  color: var(--muted);
  font-size: 9px;
}

.lesson-drawer-list {
  display: grid;
}

.lesson-drawer-row {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  align-items: start;
  gap: 11px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}

.lesson-drawer-row.done {
  opacity: 0.64;
}

.lesson-drawer-row.current {
  margin: 0 -10px;
  padding-right: 10px;
  padding-left: 10px;
  border-radius: 7px;
  background: #f8faff;
}

.lesson-check {
  width: 25px;
  height: 25px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  color: var(--text-soft);
  background: #fff;
  font-size: 10px;
  font-weight: 750;
  cursor: pointer;
}

.lesson-check.checked {
  color: #fff;
  border-color: var(--green);
  background: var(--green);
}

.lesson-check svg {
  width: 13px;
  height: 13px;
}

.lesson-drawer-title {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  color: var(--text);
  font-size: 12px;
  font-weight: 700;
}

.current-tag {
  padding: 2px 6px;
  border-radius: 8px;
  color: var(--blue);
  background: var(--blue-soft);
  font-size: 9px;
  font-weight: 700;
}

.lesson-drawer-desc {
  margin-top: 4px;
  color: var(--text-soft);
  font-size: 11px;
}

.lesson-drawer-row .small-button:disabled {
  opacity: 0.5;
  cursor: default;
}

.goal-matrix {
  min-width: 1380px;
}

.goal-cell strong {
  display: block;
  color: var(--text);
  font-size: 11px;
}

.goal-cell small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 9px;
}

.goal-cell small.good-text {
  color: var(--green);
  font-weight: 700;
}

.goal-store-cell {
  display: flex;
  align-items: center;
  gap: 8px;
}

.goal-store-dot {
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  border-radius: 50%;
}

.store-goal-list {
  display: grid;
  gap: 15px;
}

.store-goal-row {
  display: grid;
  grid-template-columns: 10px minmax(0, 1fr) 150px 64px;
  align-items: center;
  gap: 12px;
}

.store-goal-main {
  min-width: 0;
}

.store-goal-value {
  text-align: right;
}

.store-goal-value strong {
  display: block;
  color: var(--text);
  font-size: 12px;
}

.store-goal-value span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 9px;
}

.modal-wide {
  width: min(820px, 100%);
}

.goal-form-top {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.goal-split-options {
  display: flex;
  gap: 7px;
  min-height: 38px;
  align-items: center;
}

.monthly-goal-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 9px;
}

.monthly-goal-field {
  padding: 9px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fcfdfe;
}

.monthly-goal-field span {
  display: block;
  margin-bottom: 5px;
  color: var(--text-soft);
  font-size: 10px;
  font-weight: 700;
}

.monthly-goal-field input {
  width: 100%;
  height: 34px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-radius: 6px;
  outline: 0;
  color: var(--text);
  background: #fff;
  font-size: 12px;
}

.monthly-goal-field input:focus {
  border-color: #9bb7ed;
  box-shadow: 0 0 0 3px rgba(36, 95, 218, 0.08);
}

.product-data-list {
  max-height: 760px;
  overflow-y: auto;
}

.product-data-unified {
  overflow: hidden;
}

.product-monitor-filterbar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 9px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  background: #fbfcfd;
}

.monitor-filter-title {
  height: 36px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0 4px;
  color: var(--text);
  font-size: 12px;
  font-weight: 750;
  white-space: nowrap;
}

.monitor-filter-title svg {
  width: 15px;
  height: 15px;
  color: var(--blue);
}

.product-monitor-filterbar > label:not(.monitor-check):not(.monitor-search) {
  display: grid;
  gap: 4px;
}

.product-monitor-filterbar > label > span {
  color: var(--muted);
  font-size: 9px;
  font-weight: 650;
}

.product-monitor-filterbar select {
  height: 34px;
  min-width: 112px;
  padding: 0 26px 0 8px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--text-soft);
  background: #fff;
  font-size: 11px;
}

.monitor-check {
  height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0 9px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--text-soft);
  background: #fff;
  font-size: 11px;
  cursor: pointer;
}

.monitor-check input {
  accent-color: var(--blue);
}

.monitor-search {
  width: min(310px, 28vw);
  margin-left: auto;
}

.product-quick-tabs,
.product-category-tabs {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 9px 14px;
  overflow-x: auto;
  border-bottom: 1px solid var(--line);
  background: #fff;
  scrollbar-width: thin;
}

.product-quick-tabs > span,
.product-category-tabs > span {
  flex: 0 0 auto;
  margin-right: 4px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
}

.product-category-tabs {
  background: #fafbfc;
}

.product-category-tabs .filter-chip,
.product-quick-tabs .filter-chip {
  min-width: max-content;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.product-quick-tabs .filter-chip svg {
  width: 13px;
  height: 13px;
}

.custom-filter-chip {
  color: var(--purple) !important;
  border-color: #d8cef0 !important;
}

.custom-filter-chip.active {
  color: #fff !important;
  border-color: var(--purple) !important;
  background: var(--purple) !important;
}

.custom-filter-add {
  color: var(--blue);
  border-style: dashed;
  border-color: #b9c9e8;
}

.custom-filter-edit {
  flex: 0 0 auto;
}

.custom-filter-restore,
.product-type-restore {
  flex: 0 0 auto;
  margin-left: 2px;
}

.removable-chip {
  position: relative;
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
}

.removable-chip > .filter-chip:first-child {
  border-radius: 16px;
  padding-right: 10px;
}

.chip-delete {
  position: absolute;
  top: -5px;
  right: -5px;
  z-index: 2;
  width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--muted);
  background: #f7f8fa;
  opacity: 0;
  visibility: hidden;
  transform: scale(0.72);
  pointer-events: none;
  cursor: pointer;
  transition: color 140ms ease, border-color 140ms ease, background 140ms ease, opacity 140ms ease, transform 140ms ease;
}

.removable-chip:hover .chip-delete,
.removable-chip:focus-within .chip-delete {
  opacity: 0.9;
  visibility: visible;
  transform: scale(1);
  pointer-events: auto;
}

.chip-delete:hover {
  color: var(--red);
  border-color: #f0c6c6;
  background: var(--red-soft);
  opacity: 1;
}

.chip-delete svg {
  width: 9px;
  height: 9px;
}

.product-type-manage {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--purple);
  border-color: #d8cef0;
}

.product-type-manage svg {
  width: 13px;
  height: 13px;
}

.product-sort-manage {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--blue);
  border-color: #c8d7f6;
}

.product-sort-manage svg {
  width: 13px;
  height: 13px;
}

.product-filter-reset {
  margin-left: auto;
  flex: 0 0 auto;
}

.product-monitor-scroll {
  max-height: 66vh;
}

.product-monitor-table {
  min-width: 1760px;
}

.product-monitor-table th,
.product-monitor-table td {
  padding-right: 10px;
  padding-left: 10px;
}

.product-monitor-table .product-sticky-col {
  position: sticky;
  left: 0;
  z-index: 2;
  min-width: 330px;
  max-width: 330px;
  background: #fff;
  box-shadow: 1px 0 0 var(--line);
}

.product-monitor-table th.product-sticky-col {
  z-index: 4;
  background: #fbfcfd;
}

.product-monitor-table tr.expanded .product-sticky-col,
.product-monitor-table tr.expanded > td {
  background: #f8faff;
}

.product-monitor-product {
  display: grid;
  grid-template-columns: 50px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
}

.product-main-image.row-image {
  width: 50px;
  height: 50px;
}

.product-monitor-title {
  display: -webkit-box;
  max-width: 250px;
  overflow: hidden;
  color: var(--text);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
  text-align: left;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.row-type-select {
  width: 100%;
  height: 24px;
  margin-top: 5px;
  padding: 0 5px;
  border: 1px solid var(--line);
  border-radius: 5px;
  color: var(--blue);
  background: #f8faff;
  font-size: 9px;
}

.row-assignment {
  min-width: 190px;
  display: grid;
  grid-template-columns: 78px 10px 78px 24px;
  align-items: center;
  gap: 4px;
}

.row-assignment select {
  width: 78px;
  height: 27px;
  padding: 0 4px;
  border: 1px solid var(--line);
  border-radius: 5px;
  color: var(--text-soft);
  background: #fff;
  font-size: 9px;
}

.row-assignment > span {
  color: var(--blue);
  font-size: 10px;
  text-align: center;
}

.row-save-button {
  width: 24px;
  height: 27px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 5px;
  color: var(--blue);
  background: #fff;
  cursor: pointer;
}

.row-save-button svg {
  width: 13px;
  height: 13px;
}

.product-tag-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  min-width: 104px;
  max-width: 120px;
}

.product-tag-stack span {
  padding: 2px 5px;
  border-radius: 8px;
  color: var(--blue);
  background: var(--blue-soft);
  font-size: 8px;
  font-weight: 700;
}

.product-tag-stack span.muted-tag {
  color: var(--muted);
  background: #f0f2f4;
}

.row-sparkline {
  width: 72px;
  height: 24px;
}

.seven-day-cell {
  min-width: 184px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.seven-day-cell > div {
  min-width: 92px;
}

.seven-day-cell strong,
.seven-day-cell small {
  display: block;
}

.seven-day-cell strong {
  color: var(--text);
  font-size: 11px;
}

.seven-day-cell small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 8px;
}

.group-seven-trend {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 7px;
}

.group-seven-trend .row-sparkline {
  width: 92px;
  height: 26px;
}

.group-seven-trend small {
  color: var(--muted);
  font-size: 8px;
  white-space: nowrap;
}

.product-day-row td {
  height: 36px;
}

.product-day-group-start > td {
  border-top: 2px solid #dfe6ef !important;
}

.product-day-group-start .product-sticky-col {
  border-top: 2px solid #dfe6ef;
}

.product-expanded-row > td {
  padding: 0 !important;
  border-bottom: 2px solid #dbe5f6 !important;
}

.product-expanded-row .metric-group-tabs {
  border-top: 1px solid var(--line);
}

.product-expanded-body {
  padding: 14px 16px;
}

.product-data-footer {
  min-height: 42px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 14px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  background: #fbfcfd;
  font-size: 10px;
}

.filter-condition-list {
  display: grid;
  gap: 8px;
}

.filter-condition-row {
  display: grid;
  grid-template-columns: minmax(130px, 0.9fr) minmax(120px, 0.8fr) minmax(180px, 1.4fr) 38px;
  align-items: center;
  gap: 8px;
}

.filter-condition-row select,
.filter-condition-row input {
  width: 100%;
  height: 38px;
  padding: 0 9px;
  border: 1px solid var(--line);
  border-radius: 7px;
  outline: 0;
  color: var(--text);
  background: #fff;
}

.filter-condition-row select:focus,
.filter-condition-row input:focus {
  border-color: #9bb7ed;
  box-shadow: 0 0 0 3px rgba(36, 95, 218, 0.08);
}

.filter-condition-row .icon-button {
  width: 36px;
  height: 36px;
}

.custom-condition-add {
  margin-top: 11px;
}

.custom-filter-modal .modal-body {
  min-height: 360px;
}

.inline-add-field {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  margin-top: 2px;
}

.inline-add-field input {
  width: 100%;
  height: 40px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  outline: 0;
  color: var(--text);
  background: #fff;
}

.inline-add-field input:focus {
  border-color: #9bb7ed;
  box-shadow: 0 0 0 3px rgba(36, 95, 218, 0.08);
}

.type-manage-list {
  display: grid;
}

.type-manage-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}

.type-manage-row:last-child {
  border-bottom: 0;
}

.type-manage-row strong,
.type-manage-row small {
  display: block;
}

.type-manage-row strong {
  color: var(--text);
  font-size: 12px;
}

.type-manage-row small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 9px;
}

.type-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.type-chip-list span {
  padding: 5px 8px;
  border-radius: 10px;
  color: var(--text-soft);
  background: #eef2f5;
  font-size: 10px;
}

.empty-inline {
  padding: 14px 0;
  color: var(--muted);
  font-size: 11px;
}

.sort-setting-list {
  display: grid;
  gap: 9px;
}

.sort-setting-row {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) 110px 38px;
  align-items: center;
  gap: 8px;
}

.sort-priority {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--blue);
  background: var(--blue-soft);
  font-size: 10px;
  font-weight: 750;
}

.sort-setting-row select {
  width: 100%;
  height: 38px;
  padding: 0 9px;
  border: 1px solid var(--line);
  border-radius: 7px;
  color: var(--text);
  background: #fff;
}

.sort-setting-row .icon-button {
  width: 36px;
  height: 36px;
}

.product-image-button {
  display: block;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  cursor: default;
}

.product-detail-backdrop {
  align-items: center;
}

.product-detail-modal {
  width: min(1480px, calc(100vw - 24px));
  height: min(900px, calc(100vh - 24px));
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 10px;
  background: #fff;
  box-shadow: var(--shadow-float);
  animation: modal-in 170ms ease-out;
}

.product-detail-topbar {
  min-height: 66px;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 0 18px;
  border-bottom: 1px solid var(--line);
  background: #fbfcfd;
}

.product-detail-title {
  color: var(--text);
  font-size: 15px;
  font-weight: 760;
}

.product-detail-subtitle {
  max-width: 700px;
  margin-top: 3px;
  overflow: hidden;
  color: var(--muted);
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.product-detail-top-actions {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-left: auto;
}

.product-detail-body {
  min-height: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.product-detail-main {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr) 190px;
  gap: 16px;
  padding: 16px;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.product-detail-media {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
}

.product-main-image.detail-hero-image {
  width: 100%;
  aspect-ratio: 1;
  height: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.product-main-image.detail-hero-image svg {
  width: 58%;
  height: 58%;
}

.product-detail-fields {
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-content: start;
  gap: 9px;
}

.product-detail-field {
  min-width: 0;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fcfdfe;
}

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

.product-detail-field span {
  color: var(--muted);
  font-size: 9px;
}

.product-detail-field strong {
  margin-top: 4px;
  overflow: hidden;
  color: var(--text);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.product-detail-side {
  display: grid;
  align-content: start;
  gap: 10px;
}

.product-detail-side .info-block {
  margin-top: 0;
}

.info-block.compact .text-link {
  width: 100%;
  justify-content: flex-start;
  margin-top: 7px;
  text-align: left;
}

.product-detail-tabs {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 9px 14px;
  border-bottom: 1px solid var(--line);
  background: #fbfcfd;
}

.product-detail-chart-toggle {
  height: 32px;
  margin-left: auto;
}

.detail-range-switch {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  margin-left: 3px;
  padding-left: 8px;
  border-left: 1px solid var(--line);
}

.detail-custom-range {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-left: 6px;
}

.detail-custom-range input {
  height: 32px;
  padding: 0 7px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--text-soft);
  background: #fff;
  font-size: 10px;
}

.detail-custom-range > span {
  color: var(--muted);
  font-size: 9px;
}

.product-detail-table-wrap {
  min-height: 0;
  flex: 1;
  overflow: hidden;
  background: #fff;
}

.product-detail-table-scroll {
  height: 100%;
}

.product-detail-table {
  min-width: 1420px;
}

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

.product-detail-table td {
  height: 40px;
}

.product-row-actions {
  display: grid;
  gap: 5px;
  min-width: 62px;
}

.product-row-actions .small-button {
  width: 100%;
  min-width: 62px;
}

.product-detail-total-row td {
  color: var(--text);
  background: #f3f6fa;
  font-weight: 760;
}

.product-detail-modal .button,
.product-detail-modal .icon-button {
  text-decoration: none;
}


.product-data-toolbar {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 13px 14px;
  border-bottom: 1px solid var(--line);
  background: #fbfcfd;
}

.product-data-toolbar .search-box {
  width: min(420px, 42vw);
}

.product-data-strip {
  display: flex;
  gap: 10px;
  padding: 14px;
  overflow-x: auto;
  border-bottom: 1px solid var(--line);
  background: #fff;
  scrollbar-width: thin;
}

.product-card {
  min-width: 270px;
  max-width: 270px;
  display: grid;
  grid-template-columns: 82px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  background: #fcfdfe;
  cursor: pointer;
  text-align: left;
  transition: border-color 140ms ease, box-shadow 140ms ease, transform 140ms ease;
}

.product-card:hover {
  border-color: #c7d4e2;
  transform: translateY(-1px);
}

.product-card.active {
  border-color: #9bb7ed;
  background: #f8faff;
  box-shadow: 0 0 0 3px rgba(36, 95, 218, 0.08);
}

.product-main-image {
  display: grid;
  place-items: center;
  overflow: hidden;
  flex: 0 0 auto;
  border-radius: 8px;
  color: var(--product-fg);
  background: var(--product-bg);
}

.product-main-image svg {
  width: 62%;
  height: 62%;
}

.product-main-image.card-image {
  width: 82px;
  height: 82px;
}

.product-main-image.detail-image {
  width: 58px;
  height: 58px;
}

.product-card-body {
  min-width: 0;
}

.product-card-body > strong,
.product-card-body > small {
  display: block;
}

.product-card-body > strong {
  display: -webkit-box;
  overflow: hidden;
  color: var(--text);
  font-size: 11px;
  font-weight: 700;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.product-card-body > small {
  margin-top: 3px;
  overflow: hidden;
  color: var(--muted);
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.owner-chain {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  margin-top: 7px;
}

.owner-chain b {
  padding: 2px 5px;
  border-radius: 5px;
  color: var(--text-soft);
  background: #eef1f3;
  font-size: 8px;
  font-weight: 650;
}

.owner-chain i {
  color: var(--blue);
  font-size: 10px;
  font-style: normal;
}

.product-card .source-tag {
  margin-top: 7px;
}

.product-data-detail {
  min-width: 0;
}

.product-data-detail .product-data-head {
  min-height: 76px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border-bottom: 1px solid var(--line);
}

.assignment-editor {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) 20px minmax(180px, 1fr) auto;
  align-items: end;
  gap: 10px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  background: #f8fafb;
}

.assignment-role {
  min-width: 0;
}

.assignment-role > span {
  display: block;
  margin-bottom: 5px;
  color: var(--text-soft);
  font-size: 10px;
  font-weight: 700;
}

.assignment-role select {
  width: 100%;
  height: 36px;
  padding: 0 9px;
  border: 1px solid var(--line);
  border-radius: 7px;
  color: var(--text);
  background: #fff;
}

.assignment-arrow {
  height: 36px;
  display: grid;
  place-items: center;
  color: var(--blue);
}

.assignment-arrow svg {
  width: 16px;
  height: 16px;
}

.product-data-item {
  width: 100%;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 11px 14px;
  border: 0;
  border-bottom: 1px solid var(--line);
  color: var(--text);
  background: #fff;
  text-align: left;
  cursor: pointer;
}

.product-data-item:hover {
  background: #fafcff;
}

.product-data-item.active {
  background: var(--blue-soft);
  box-shadow: inset 3px 0 var(--blue);
}

.product-data-copy {
  min-width: 0;
}

.product-data-copy strong,
.product-data-copy small {
  display: block;
}

.product-data-copy strong {
  overflow: hidden;
  color: var(--text);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.product-data-copy small {
  margin-top: 3px;
  overflow: hidden;
  color: var(--muted);
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.source-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 3px 7px;
  border-radius: 9px;
  color: #6b7580;
  background: #eff2f4;
  font-size: 9px;
  font-weight: 700;
  white-space: nowrap;
}

.source-tag.exact {
  color: var(--green);
  background: var(--green-soft);
}

.product-data-head {
  min-height: 70px;
}

.product-data-title {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 11px;
}

.product-data-title .panel-title {
  max-width: 520px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.metric-group-tabs {
  display: flex;
  gap: 5px;
  padding: 9px 14px;
  overflow-x: auto;
  border-bottom: 1px solid var(--line);
  background: #fbfcfd;
  scrollbar-width: thin;
}

.metric-group-tabs .segment-button {
  min-width: max-content;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.metric-group-tabs .segment-button span {
  min-width: 17px;
  height: 17px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  border-radius: 9px;
  color: var(--muted);
  background: #e9edf0;
  font-size: 9px;
}

.metric-group-tabs .segment-button.active span {
  color: var(--blue);
  background: #fff;
}

.metric-raw-note {
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 11px;
}

.metric-field-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 20px;
}

.metric-field {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(110px, auto);
  gap: 10px;
  padding: 9px 0;
  border-bottom: 1px solid var(--line);
}

.metric-field span {
  overflow: hidden;
  color: var(--text-soft);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.metric-field strong {
  overflow: hidden;
  color: var(--text);
  font-size: 11px;
  text-align: right;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.metric-wide-scroll {
  max-height: 560px;
}

.metric-wide-table th,
.metric-wide-table td {
  min-width: 120px;
  max-width: 220px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.metric-wide-table td {
  color: var(--text);
  font-weight: 650;
  text-align: right;
}

.empty-state {
  padding: 48px 20px;
  color: var(--muted);
  text-align: center;
}

.empty-state svg {
  width: 30px;
  height: 30px;
  margin: 0 auto 10px;
}

.toast-root {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 100;
  display: grid;
  gap: 8px;
  pointer-events: none;
}

.toast {
  min-width: 260px;
  max-width: min(380px, calc(100vw - 40px));
  display: flex;
  align-items: flex-start;
  gap: 9px;
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  background: #fff;
  box-shadow: var(--shadow-float);
  font-size: 12px;
  animation: toast-in 180ms ease-out;
  pointer-events: auto;
}

.toast svg {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  margin-top: 1px;
}

.toast.success svg {
  color: var(--green);
}

.toast.error svg {
  color: var(--red);
}

.toast.info svg {
  color: var(--blue);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes fade-in {
  from {
    opacity: 0;
  }
}

@keyframes slide-in {
  from {
    transform: translateX(22px);
    opacity: 0;
  }
}

@keyframes modal-in {
  from {
    transform: translateY(8px) scale(0.99);
    opacity: 0;
  }
}

@keyframes toast-in {
  from {
    transform: translateY(8px);
    opacity: 0;
  }
}

@media (max-width: 1180px) {
  .kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .panel.span-4,
  .panel.span-5,
  .panel.span-6,
  .panel.span-7,
  .panel.span-8 {
    grid-column: span 12;
  }

  .product-detail-main {
    grid-template-columns: 160px minmax(0, 1fr);
  }

  .product-detail-side {
    grid-column: 1 / -1;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .product-detail-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 820px) {
  .app-shell {
    display: block;
  }

  .sidebar {
    position: sticky;
    top: 0;
    z-index: 30;
    width: 100%;
    height: auto;
    display: block;
    padding: 9px 10px 10px;
    overflow: hidden;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .brand {
    min-height: 34px;
    margin-bottom: 7px;
    padding: 0 3px;
  }

  .brand-mark {
    width: 29px;
    height: 29px;
  }

  .brand-sub,
  .nav-label,
  .sidebar-foot {
    display: none;
  }

  .nav-groups {
    display: flex;
    gap: 5px;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
  }

  .nav-groups::-webkit-scrollbar {
    display: none;
  }

  .nav-group {
    display: flex;
    flex: 0 0 auto;
  }

  .nav-group + .nav-group {
    margin-top: 0;
  }

  .nav-list {
    flex-direction: row;
    gap: 5px;
  }

  .nav-item {
    width: auto;
    min-width: max-content;
    min-height: 36px;
    padding: 0 10px;
    border: 1px solid transparent;
    font-size: 12px;
  }

  .nav-item.active {
    border-color: #d2defa;
  }

  .nav-item.active::before {
    display: none;
  }

  .nav-item svg {
    width: 15px;
    height: 15px;
  }

  .nav-badge {
    height: 17px;
    min-width: 17px;
    font-size: 9px;
  }

  .topbar {
    min-height: 58px;
    padding: 9px 14px;
    overflow-x: auto;
  }

  .product-detail-modal {
    width: 100vw;
    height: 100vh;
    border-radius: 0;
  }

  .product-detail-topbar {
    align-items: flex-start;
    flex-direction: column;
    padding-top: 10px;
    padding-bottom: 10px;
  }

  .product-detail-top-actions {
    width: 100%;
    margin-left: 0;
    overflow-x: auto;
  }

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

  .product-detail-media {
    align-items: center;
  }

  .product-detail-media .product-main-image,
  .product-detail-media .button {
    width: min(240px, 100%);
  }

  .product-detail-fields,
  .product-detail-side {
    grid-template-columns: 1fr;
  }

  .product-detail-tabs {
    overflow-x: auto;
  }

  .store-picker-wrap {
    position: static;
  }

  .store-menu {
    position: fixed;
    top: 106px;
    right: 10px;
    left: 10px;
    width: auto;
  }

  .topbar-spacer,
  .top-date {
    display: none;
  }

  .top-actions {
    margin-left: auto;
  }

  .page {
    padding: 18px 14px 32px;
  }

  .page-head {
    display: block;
    margin-bottom: 16px;
  }

  .page-head-actions {
    margin-top: 13px;
    overflow-x: auto;
  }

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

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

  .panel.span-4,
  .panel.span-5,
  .panel.span-6,
  .panel.span-7,
  .panel.span-8,
  .panel.span-12 {
    grid-column: auto;
  }

  .channel-grid,
  .platform-grid,
  .source-grid {
    grid-template-columns: 1fr;
  }

  .field-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .role-row {
    grid-template-columns: 38px minmax(0, 1fr) 18px;
  }

  .role-metrics {
    display: none;
  }

  .store-goal-row {
    grid-template-columns: 10px minmax(0, 1fr) 64px;
  }

  .store-goal-value {
    grid-column: 2 / 4;
    text-align: left;
  }

  .monthly-goal-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .product-data-list {
    max-height: 360px;
  }

  .product-data-toolbar {
    flex-wrap: wrap;
  }

  .product-data-toolbar .search-box {
    width: 100%;
  }

  .product-data-toolbar .select-control {
    width: 100%;
  }

  .monitor-search {
    width: 100%;
    margin-left: 0;
  }

  .product-monitor-table .product-sticky-col {
    min-width: 265px;
    max-width: 265px;
  }

  .product-data-footer {
    align-items: flex-start;
    flex-direction: column;
    padding-top: 9px;
    padding-bottom: 9px;
  }

  .metric-field-list {
    grid-template-columns: 1fr;
  }

  .target-progress-row {
    grid-template-columns: 100px minmax(0, 1fr) 58px;
    gap: 8px;
  }

  .toolbar {
    align-items: stretch;
  }

  .search-box,
  .select-control {
    width: 100%;
    min-width: 0;
  }

  .toolbar-spacer {
    display: none;
  }

  .filter-chips {
    width: 100%;
    overflow-x: auto;
  }

  .table-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .toast-root {
    right: 12px;
    bottom: 12px;
  }
}

@media (max-width: 520px) {
  .store-picker {
    padding: 0 8px;
  }

  .store-name {
    max-width: 106px;
  }

  .top-actions .button .button-label {
    display: none;
  }

  .top-actions .button {
    width: 38px;
    padding: 0;
  }

  .top-user {
    padding: 3px;
    border-color: transparent;
    background: transparent;
  }

  .top-user-copy {
    display: none;
  }

  .page-title {
    font-size: 22px;
  }

  .page-head-actions {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }

  .range-control {
    grid-column: span 2;
    justify-content: space-between;
  }

  .page-head-actions .button {
    width: 100%;
  }

  .date-range-popover {
    position: fixed;
    top: 118px;
    right: 12px;
    left: 12px;
    width: auto;
  }

  .date-range-fields {
    grid-template-columns: 1fr;
  }

  .date-range-fields > i {
    display: none;
  }

  .metric-value {
    font-size: 25px;
  }

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

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

  .role-detail-head {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .role-detail-stat {
    width: 100%;
    margin-left: 56px;
    text-align: left;
  }

  .permission-module-head {
    align-items: flex-start;
  }

  .learning-hero {
    grid-template-columns: 48px minmax(0, 1fr);
  }

  .learning-progress-circle {
    grid-column: 1 / -1;
    justify-self: end;
  }

  .weekly-plan-row {
    grid-template-columns: 42px minmax(0, 1fr) auto;
  }

  .weekly-plan-row .status-pill {
    display: none;
  }

  .learning-actions {
    flex-direction: column;
  }

  .store-goal-row {
    grid-template-columns: 10px minmax(0, 1fr) auto;
  }

  .store-goal-value {
    grid-column: 2 / 4;
  }

  .product-data-title .panel-title {
    max-width: 190px;
  }

  .product-data-item {
    grid-template-columns: 34px minmax(0, 1fr);
  }

  .product-data-item .source-tag {
    grid-column: 2;
    justify-self: start;
  }

  .assignment-editor {
    grid-template-columns: 1fr;
  }

  .assignment-arrow {
    display: none;
  }

  .assignment-editor .button {
    width: 100%;
  }

  .product-data-detail .product-data-head {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .product-monitor-table .product-sticky-col {
    min-width: 230px;
    max-width: 230px;
  }

  .product-monitor-product {
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 8px;
  }

  .product-main-image.row-image {
    width: 42px;
    height: 42px;
  }

  .product-monitor-title {
    max-width: 160px;
  }

  .filter-condition-row {
    grid-template-columns: 1fr;
  }

  .filter-condition-row .icon-button {
    justify-self: end;
  }

  .inline-add-field {
    grid-template-columns: 1fr;
  }

  .inline-add-field .button {
    width: 100%;
  }

  .import-template-grid,
  .import-template-switch {
    grid-template-columns: 1fr;
  }

  .monitor-image-col {
    width: 60px;
    min-width: 60px;
    max-width: 60px;
  }

  .monitor-id-col {
    left: 60px;
    width: 138px;
    min-width: 138px;
    max-width: 138px;
  }

  .monitor-metric-col {
    left: 198px;
    width: 92px;
    min-width: 92px;
    max-width: 92px;
  }

  .monitor-date-product-cell {
    width: 290px;
    min-width: 290px;
    max-width: 290px;
  }

  .monitor-fixed-head {
    width: 290px;
    min-width: 290px;
    max-width: 290px;
  }

  .monitor-choice-grid,
  .monitor-product-choice-list {
    grid-template-columns: 1fr;
  }

  .funnel-row {
    grid-template-columns: 60px minmax(0, 1fr) 72px;
    gap: 7px;
  }

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

  .modal-backdrop {
    place-items: end center;
    padding: 0;
  }

  .modal {
    max-height: 92vh;
    border-radius: 12px 12px 0 0;
  }

  .modal-foot {
    flex-wrap: wrap;
    padding: 10px 14px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* 通用运营交互 */
.ops-toolbar{margin:0 0 18px;padding:14px 16px;background:#fff;border:1px solid #e6ebf2;border-radius:12px;box-shadow:0 2px 8px rgba(31,52,82,.04)}
.ops-row{display:flex;align-items:center;flex-wrap:wrap;gap:8px;margin:7px 0}.ops-row label{display:inline-flex;align-items:center;gap:5px;font-size:12px;color:#536275}.ops-row input,.ops-row select,.ops-columns input,.ops-panel input{border:1px solid #d6deea;border-radius:6px;background:#fff;color:#233044;padding:6px 8px;font:inherit;max-width:150px}.ops-muted{color:#8793a1;font-size:12px}.ops-panel{margin-top:18px}.ops-panel svg{width:100%;height:225px}.ops-empty{padding:28px;text-align:center;color:#8793a1;font-size:13px}.ops-risk{background:#fff8f6}.ops-risk td:nth-child(9){color:#cf3f3f;font-weight:600}.ops-columns{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:10px 0;padding:8px 10px;background:#f7f9fc;border-radius:8px;color:#536275;font-size:12px}.ops-columns summary{cursor:pointer;font-weight:600;margin-right:8px}.ops-columns label{display:inline-flex;align-items:center;gap:4px}.ops-resize{position:absolute;top:0;right:-4px;width:8px;height:100%;cursor:col-resize;touch-action:none}.ops-panel table th{position:relative;white-space:nowrap}.ops-panel table td input{min-width:150px;width:100%}
.inline-custom-range{display:flex;align-items:center;gap:8px;margin-top:8px;padding:8px 0}.inline-custom-range label{display:inline-flex;align-items:center;gap:5px;font-size:12px;color:#536275}.inline-custom-range input{border:1px solid #d6deea;border-radius:6px;padding:6px 8px;color:#233044;background:#fff}
.ticket-filter-bar{display:flex;gap:8px;flex-wrap:wrap;align-items:center;margin:14px 0;padding:12px 14px;background:#fff;border:1px solid #e6ebf2;border-radius:10px}.ticket-filter-bar input,.ticket-filter-bar select{border:1px solid #d6deea;border-radius:6px;padding:8px 10px;background:#fff;color:#233044}.ticket-filter-bar input{min-width:220px}.ticket-id,.ticket-type{font-size:11px;color:#8793a1;margin-left:6px}.ticket-type{padding:2px 6px;background:#f1f5f9;border-radius:4px}.ticket-overdue{border-left:3px solid #cf3f3f;background:#fff7f5}.ticket-overdue .task-meta{color:#cf3f3f}

/* 经营驾驶舱：导航、工作区和数据资产的统一视觉。 */
:root {
  --bg: #f3f5f9;
  --surface-soft: #f7f9fc;
  --surface-strong: #edf1f7;
  --text: #192b40;
  --text-soft: #607086;
  --muted: #8592a4;
  --line: #e3e9f1;
  --line-strong: #cdd7e4;
  --blue: #2563eb;
  --blue-soft: #edf3ff;
  --radius: 14px;
  --sidebar-width: 234px;
  --shadow: 0 2px 4px rgba(21, 42, 69, 0.02), 0 8px 26px rgba(21, 42, 69, 0.035);
}

.app-shell { align-items: start; }
.sidebar {
  padding: 25px 16px 16px;
  color: #d8e2ef;
  background: #102238;
  border-right-color: #102238;
}
.sidebar .brand { padding: 0 5px 24px; margin: 0 0 17px; border-bottom: 1px solid #ffffff12; }
.sidebar .brand-mark { width: 36px; height: 36px; border-radius: 11px; background: #326fee; box-shadow: 0 4px 12px #060e1c40; }
.sidebar .brand-name { color: #fff; font-size: 15px; letter-spacing: .02em; }
.sidebar .brand-sub { max-width: 155px; color: #8da3bd; font-size: 10px; overflow: hidden; text-overflow: ellipsis; }
.sidebar .nav-groups { min-height: 0; overflow-y: auto; scrollbar-width: thin; scrollbar-color: #415875 transparent; padding-right: 0; }
.sidebar .nav-group + .nav-group { margin-top: 17px; }
.sidebar .nav-label { margin: 0 0 8px; padding: 0 12px; color: #7f96b1; font-size: 10px; letter-spacing: .13em; }
.sidebar .nav-list { gap: 4px; }
.sidebar .nav-item { min-height: 44px; padding: 0 12px; border-radius: 9px; color: #b9c9dc; font-size: 13px; }
.sidebar .nav-item svg { width: 18px; height: 18px; color: #91aac6; }
.sidebar .nav-item:hover { color: #fff; background: #ffffff0a; }
.sidebar .nav-item.active { color: #fff; background: #2c62c7; box-shadow: 0 4px 14px #060f2233; }
.sidebar .nav-item.active svg { color: #fff; }
.sidebar .nav-item.active::before { left: -16px; top: 13px; height: 18px; background: #74a7ff; }
.sidebar .nav-badge { color: #ffdb9f; background: #ffffff16; }
.sidebar .sidebar-foot { margin-top: 24px; padding: 13px 10px; border-color: #ffffff12; border-radius: 10px; background: #0b1b2e; }
.sidebar .sync-head { color: #d9e5f3; font-size: 11px; }
.sidebar .sync-time { color: #7f97b3; font-size: 10px; }
.sidebar .sync-button { color: #9db7d7; }
.sidebar .sync-button:hover { background: #ffffff12; }
.main-shell { width: 100%; min-height: 100vh; }
.topbar { min-height: 76px; gap: 14px; padding: 12px 232px 12px 30px; background: #ffffffed; border-bottom-color: #e4eaf2; }
.topbar .store-picker { min-height: 42px; height: auto; border-color: #e1e7f0; border-radius: 10px; box-shadow: none; }
.store-avatar { border-radius: 8px; }
.top-date { color: #7b899b; font-size: 12px; white-space: nowrap; }
.top-actions { gap: 8px; }
.top-actions > .icon-button[data-action="open-import"] { display: none; }
.topbar .button.primary { box-shadow: none; }
.mobile-menu-toggle, .mobile-nav-backdrop { display: none; }
.page { max-width: 1640px; padding: 30px; }
.page-head { align-items: center; margin-bottom: 24px; }
.page-head > div:first-child { min-width: 0; }
.page-title { color: #14283f; font-size: 27px; font-weight: 750; letter-spacing: -.025em; }
.page-subtitle { max-width: 860px; margin-top: 9px; color: #6a7b8e; line-height: 1.75; }
.eyebrow { color: #73859a; font-size: 10px; font-weight: 700; letter-spacing: .12em; }
.page-head-actions { flex-wrap: wrap; justify-content: flex-end; }
.button, .icon-button, .segment-button, .small-button { border-radius: 9px; }
.button { min-height: 42px; padding: 0 15px; font-size: 12px; font-weight: 650; }
.icon-button { width: 42px; height: 42px; }
.button.primary { box-shadow: 0 4px 11px #2563eb16; }
.button:disabled, .icon-button:disabled { opacity: .48; cursor: not-allowed; box-shadow: none; }
.button:focus-visible, .icon-button:focus-visible, .segment-button:focus-visible, .nav-item:focus-visible,
.small-button:focus-visible, .mobile-menu-toggle:focus-visible, .setup-card a:focus-visible {
  outline: 3px solid #91b5ff; outline-offset: 3px;
}
.sidebar .nav-item:focus-visible { outline-color: #9bc0ff; outline-offset: -2px; }
.panel { border-radius: 14px; box-shadow: var(--shadow); }
.panel-head { min-height: 68px; padding: 18px 22px; gap: 12px; }
.panel-title { font-size: 15px; font-weight: 700; }
.panel-subtitle { margin-top: 5px; line-height: 1.6; }
.panel-body { padding: 22px; }
.panel-body > p { margin: 0 0 14px; line-height: 1.8; }
.panel-body > p:last-child { margin-bottom: 0; }
.dashboard-grid { gap: 20px; }
.kpi-grid { gap: 16px; margin-bottom: 20px; }
.kpi-card { min-height: 150px; padding: 21px; border-radius: 14px; }
.kpi-label { font-size: 12px; font-weight: 550; }
.metric-value { margin-top: 15px; font-size: 31px; font-weight: 750; }
.metric-foot { margin-top: 11px; }
.metric-note { color: #7a899a; font-size: 11px; }
.data-table th { padding: 13px 17px; color: #718196; background: #f7f9fc; font-size: 11px; font-weight: 650; }
.data-table td { padding: 15px 17px; border-bottom-color: #ecf0f5; font-size: 12px; }
.table-scroll { max-width: 100%; overscroll-behavior-x: contain; scrollbar-width: thin; scrollbar-color: #cad5e5 #f7f9fc; }
.data-table tbody tr:hover td { background: #f8faff; }
.drawer-note { padding: 12px 14px; border: 1px solid #e9edf4; border-radius: 9px; background: #f8fafc; color: #718095; font-size: 11px; line-height: 1.8; }
.notice-strip { border-radius: 11px; }
.range-control { min-height: 42px; border-radius: 10px; padding: 3px; }
.range-control .segment-button { min-height: 34px; padding: 0 12px; border-radius: 7px; }

.workspace-hero {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  margin-bottom: 20px;
  padding: 25px 28px;
  overflow: hidden;
  border: 1px solid #dce5f1;
  border-radius: 16px;
  background: linear-gradient(108deg, #fff 0%, #fff 55%, #f0f5ff 100%);
  box-shadow: 0 3px 14px #1f3e681f;
}
.workspace-hero::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 4px; background: #3272ec; }
.workspace-hero-copy { position: relative; min-width: 0; max-width: 780px; }
.workspace-hero-copy .eyebrow { margin-bottom: 7px; color: #426ba3; }
.workspace-hero h1, .workspace-hero .page-title { margin: 0; font-size: 29px; font-weight: 750; line-height: 1.35; letter-spacing: -.025em; }
.workspace-hero-copy > p:not(.eyebrow) { margin: 9px 0 0; color: #697b92; font-size: 12px; line-height: 1.75; }
.workspace-hero-actions { display: flex; align-items: center; flex-wrap: wrap; justify-content: flex-end; gap: 10px; flex: 0 0 auto; max-width: 310px; }
.workspace-hero-actions .button { min-height: 44px; }
.workspace-status-row { display: flex; align-items: center; flex-wrap: wrap; gap: 9px; margin-top: 18px; }
.workspace-hero + .workspace-status-row { margin: -2px 0 20px; }
.workspace-status-row > span:not(.status-pill) { font-size: 11px; color: #73859a; }
.status-pill.is-ready, .status-pill.is-pending, .status-pill.is-warning {
  display: inline-flex; align-items: center; gap: 6px; min-height: 25px; padding: 3px 9px;
  border: 1px solid transparent; border-radius: 6px; white-space: nowrap; font-size: 10px; font-weight: 600;
}
.status-pill.is-ready { color: #17785d; background: #edf7f3; border-color: #ddede5; }
.status-pill.is-pending { color: #718096; background: #f1f4f8; border-color: #e6ebf1; }
.status-pill.is-warning { color: #ab6f1c; background: #fff8eb; border-color: #f6e9cc; }
.ops-section-heading { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px 20px; margin: 26px 0 14px; }
.ops-section-heading h2, h2.ops-section-heading { margin: 0; color: #213950; font-size: 16px; font-weight: 700; }
.ops-section-heading p { margin: 4px 0 0; color: #8190a2; font-size: 11px; line-height: 1.7; }
.ops-section-heading > span { color: #7c8c9f; font-size: 11px; }
.setup-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-bottom: 20px; }
.setup-card { display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; align-items: start; gap: 14px; padding: 21px; border: 1px solid var(--line); border-radius: 13px; background: #fff; box-shadow: var(--shadow); }
.setup-step { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; color: #5479ac; background: #f0f4fa; font-size: 11px; font-weight: 750; font-variant-numeric: tabular-nums; }
.setup-step svg { width: 18px; height: 18px; }
.setup-copy { min-width: 0; }
.setup-copy h3 { margin: 1px 0 7px; color: #273c54; font-size: 13px; font-weight: 700; }
.setup-copy p { margin: 0; color: #7c8b9e; font-size: 11px; line-height: 1.8; overflow-wrap: anywhere; }
.setup-copy p + p { margin-top: 6px; }
.setup-card > .button, .setup-card > a { grid-column: 2 / -1; justify-self: start; margin-top: 1px; min-height: 34px; font-size: 11px; }
.setup-card > .status-pill { align-self: start; }
.readiness-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; align-items: start; gap: 20px; }
.readiness-main, .readiness-aside { min-width: 0; }
.readiness-aside .setup-card { grid-template-columns: minmax(0, 1fr); }
.readiness-aside { display: grid; gap: 18px; }
.readiness-aside .panel-body { padding: 20px; }
.readiness-aside h3 { margin: 0 0 12px; font-size: 13px; }
.readiness-aside p { color: #75869b; font-size: 12px; line-height: 1.85; }
.overview-summary-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: 20px; }
.overview-workspace-grid { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(280px, 1fr); align-items: start; gap: 20px; }

.bulk-dashboard-head { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-bottom: 18px; }
.bulk-dashboard-head h2, .bulk-dashboard-head h3 { margin: 0 0 5px; font-size: 17px; font-weight: 700; }
.bulk-dashboard-head p { margin: 0; color: #7a8b9f; font-size: 11px; line-height: 1.7; }
.bulk-kpi-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: 20px; }
.bulk-kpi-card { position: relative; min-width: 0; min-height: 144px; padding: 20px 22px; border: 1px solid var(--line); border-radius: 14px; background: #fff; box-shadow: var(--shadow); }
.bulk-kpi-card:first-child { border-top-color: #7ea8ef; }
.bulk-kpi-label { display: block; color: #718096; font-size: 12px; font-weight: 550; }
.bulk-kpi-value { display: block; max-width: 100%; margin: 13px 0 8px; color: #213a57; font-size: 28px; font-weight: 750; line-height: 1.2; letter-spacing: -.025em; font-variant-numeric: tabular-nums; white-space: nowrap; overflow-wrap: normal; overflow-x: auto; scrollbar-width: thin; }
.overview-workspace-grid .bulk-kpi-card { padding: 19px 20px; }
@media (min-width: 1181px) {
  .overview-workspace-grid .bulk-kpi-grid { grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); }
  .overview-workspace-grid .bulk-kpi-value { font-size: 26px; }
}
.bulk-kpi-note { display: block; color: #8a97a8; font-size: 10px; line-height: 1.7; }
.bulk-workspace-grid { display: grid; grid-template-columns: minmax(0, 1fr) 300px; align-items: start; gap: 20px; margin-bottom: 20px; }
.bulk-workspace-grid > * { min-width: 0; margin-bottom: 0 !important; }
.bulk-import-card .panel-body { padding: 22px; }
.bulk-capacity-card .panel-body { padding: 20px; }
.bulk-capacity-card .data-table th, .bulk-capacity-card .data-table td { padding: 10px 12px; font-size: 11px; }
.bulk-capacity-card .data-table { min-width: 0; }
.bulk-capacity-card p { color: #7a8a9d; font-size: 11px; line-height: 1.8; }
.bulk-details { margin: 14px 0 0; padding: 0; border: 1px solid #e7edf5; border-radius: 9px; background: #f8fafd; color: #718197; font-size: 11px; line-height: 1.85; }
.bulk-details > summary { padding: 12px 14px; color: #667c98; cursor: pointer; font-weight: 600; }
.bulk-details[open] > summary { border-bottom: 1px solid #e7edf5; }
.bulk-details > p, .bulk-details > div { margin: 0; padding: 13px 15px; }
.bulk-details > p + p { padding-top: 0; }
.bulk-empty-state { display: grid; justify-items: center; gap: 9px; min-height: 210px; padding: 34px 24px; border: 1px dashed #dce5f0; border-radius: 11px; background: #fbfcfe; color: #8190a3; text-align: center; }
.bulk-empty-state svg { width: 34px; height: 34px; color: #829fc6; }
.bulk-empty-state strong, .bulk-empty-state h3 { margin: 0; color: #465e78; font-size: 14px; font-weight: 650; }
.bulk-empty-state p { max-width: 450px; margin: 0; font-size: 12px; line-height: 1.8; }
.bulk-empty-state .button { margin-top: 7px; }
.bulk-query-toolbar { display: flex; align-items: end; flex-wrap: wrap; gap: 12px; margin-bottom: 15px; padding: 16px; border: 1px solid #e8edf4; border-radius: 11px; background: #f8fafd; }
.bulk-query-toolbar > label { min-width: 138px !important; }
.bulk-query-toolbar > .button { flex: 0 0 auto; }
#bulk-data-root label > span { color: #6f8095; font-size: 11px; font-weight: 550; }
#bulk-data-root input:not([type="checkbox"]):not([type="radio"]), #bulk-data-root select {
  width: 100%; max-width: 100%; min-width: 0; min-height: 42px; padding: 8px 11px;
  border: 1px solid #dbe3ee; border-radius: 8px; background: #fff; color: #3b536d; font: inherit; font-size: 12px;
}
#bulk-data-root input:focus-visible, #bulk-data-root select:focus-visible { outline: 3px solid #dbe8ff; outline-offset: 1px; border-color: #8fb1ec; }
#bulk-data-root input[type="file"] { padding: 6px; font-size: 11px; }
#bulk-data-root input[type="file"]::file-selector-button { min-height: 30px; margin-right: 8px; padding: 0 12px; border: 0; border-radius: 5px; color: #426599; background: #eef4fd; font: inherit; cursor: pointer; }
#bulk-data-root progress { height: 8px; appearance: none; accent-color: var(--blue); }
#bulk-data-root progress::-webkit-progress-bar { border-radius: 6px; background: #edf2fa; }
#bulk-data-root progress::-webkit-progress-value { border-radius: 6px; background: #3979ec; }
#bulk-data-root progress::-moz-progress-bar { border-radius: 6px; background: #3979ec; }
#bulk-data-root .panel-head { flex-wrap: wrap; }
#bulk-data-root .panel-head > .button { min-height: 34px; font-size: 11px; }
#bulk-data-root .data-table td { max-width: 240px; overflow-wrap: anywhere; }

@media (max-width: 1380px) {
  .topbar .top-actions > .icon-button { display: none; }
  .top-date { display: none; }
  .workspace-hero { align-items: flex-start; }
  .workspace-hero-actions { max-width: 220px; }
  .workspace-hero-actions .range-control { flex-wrap: wrap; }
  .readiness-layout, .bulk-workspace-grid { grid-template-columns: minmax(0, 1fr) 270px; }
}
@media (max-width: 1180px) {
  .page { padding: 24px; }
  .topbar { padding-left: 24px; }
  .workspace-hero { padding: 25px; flex-wrap: wrap; gap: 20px; }
  .workspace-hero-actions { max-width: none; justify-content: flex-start; }
  .workspace-hero h1, .workspace-hero .page-title { font-size: 26px; }
  .readiness-layout, .bulk-workspace-grid, .overview-workspace-grid { grid-template-columns: minmax(0, 1fr); }
  .readiness-aside { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .bulk-capacity-card .data-table th, .bulk-capacity-card .data-table td { padding: 12px 15px; }
  .kpi-grid, .bulk-kpi-grid, .overview-summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .setup-grid { grid-template-columns: minmax(0, 1fr); }
  .setup-card { padding: 19px; }
}
@media (max-width: 980px) and (min-width: 821px) {
  .topbar { padding-right: 208px; padding-left: 18px; gap: 8px; }
  .topbar .store-name { max-width: 120px; }
  .topbar .store-picker { padding: 0 9px; gap: 6px; }
  .topbar .store-avatar { display: none; }
  .topbar .button { padding: 0 11px; }
  .page { padding: 21px; }
  .page-head { align-items: flex-start; flex-direction: column; }
  .page-head-actions { justify-content: flex-start; padding-top: 0; }
  .readiness-aside { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 820px) {
  .app-shell { display: block; }
  .sidebar { position: fixed; inset: 0 auto 0 0; z-index: 42; display: flex; flex-direction: column; width: 244px; max-width: calc(100vw - 62px); height: 100dvh; padding: 25px 16px 16px; overflow: hidden; border: 0; visibility: hidden; pointer-events: none; transform: translateX(-100%); transition: transform 180ms ease; box-shadow: 12px 0 40px #081b3140; }
  .sidebar.mobile-open { visibility: visible; pointer-events: auto; transform: translateX(0); }
  .sidebar .brand { min-height: 40px; margin: 0 0 18px; padding: 0 5px 24px; }
  .sidebar .brand-mark { width: 36px; height: 36px; }
  .sidebar .brand-sub, .sidebar .nav-label, .sidebar .sidebar-foot { display: block; }
  .sidebar .nav-groups { display: block; overflow-x: hidden; overflow-y: auto; flex: 1 1 auto; }
  .sidebar .nav-group { display: block; }
  .sidebar .nav-group + .nav-group { margin-top: 17px; }
  .sidebar .nav-list { flex-direction: column; gap: 4px; }
  .sidebar .nav-item { width: 100%; min-width: 0; min-height: 44px; padding: 0 12px; border: 0; font-size: 13px; }
  .sidebar .nav-item.active::before { display: block; }
  .sidebar .nav-item svg { width: 18px; height: 18px; }
  .sidebar .nav-badge { min-width: 20px; height: 20px; font-size: 10px; }
  .sidebar .sidebar-foot { flex: 0 0 auto; margin-top: 20px; }
  .mobile-nav-backdrop { position: fixed; inset: 0; z-index: 41; display: block; width: 100%; height: 100%; padding: 0; border: 0; background: #10223870; backdrop-filter: blur(2px); cursor: pointer; }
  .mobile-menu-toggle { display: inline-grid; flex: 0 0 44px; width: 44px; height: 44px; place-items: center; padding: 0; border: 1px solid #dfe7f1; border-radius: 9px; color: #496481; background: #fff; cursor: pointer; }
  .mobile-menu-toggle svg { width: 20px; height: 20px; }
  .topbar { position: sticky; top: 0; z-index: 25; min-height: 76px; padding: 12px 204px 12px 18px; gap: 10px; overflow: visible; }
  .topbar .store-picker { min-height: 44px; }
  .topbar .store-name { max-width: 170px; }
  .topbar .top-actions, .topbar .top-date, .topbar .topbar-spacer { display: none; }
  .topbar .store-picker-wrap { min-width: 0; }
  .store-menu { top: 72px; right: 14px; left: 14px; width: auto; border-radius: 12px; }
  .store-menu-item { min-height: 48px; }
  .page { padding: 22px 18px 38px; }
  .page-head { display: flex; flex-direction: column; align-items: stretch; gap: 13px; }
  .page-head-actions { justify-content: flex-start; margin-top: 0; padding-top: 0; overflow-x: visible; }
  .page-title { font-size: 25px; }
  .page-subtitle { font-size: 12px; line-height: 1.8; }
  .workspace-hero { margin-bottom: 19px; padding: 23px; border-radius: 14px; }
  .workspace-hero-actions { gap: 8px; }
  .workspace-hero h1, .workspace-hero .page-title { font-size: 25px; }
  .setup-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .setup-card { grid-template-columns: 30px minmax(0, 1fr); gap: 11px; padding: 17px; }
  .setup-step { width: 30px; height: 30px; border-radius: 8px; }
  .setup-card > .status-pill { grid-column: 2; }
  .setup-card > .button, .setup-card > a { grid-column: 2; }
  .readiness-aside { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .panel-head { min-height: 64px; padding: 17px 20px; }
  .panel-body { padding: 20px; }
  .kpi-grid, .bulk-kpi-grid, .overview-summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .kpi-card, .bulk-kpi-card { min-height: 138px; padding: 19px; }
  .metric-value, .bulk-kpi-value { font-size: 28px; }
  .button, .icon-button { min-height: 44px; }
  .icon-button { width: 44px; height: 44px; }
  .range-control .segment-button { min-height: 38px; }
  .bulk-query-toolbar { padding: 14px; }
  .bulk-query-toolbar > label { min-width: 150px !important; }
  #bulk-data-root input:not([type="checkbox"]):not([type="radio"]), #bulk-data-root select { min-height: 44px; }
  #bulk-data-root .panel-head > .button { min-height: 40px; }
  #ta-auth-account-bar { top: 14px !important; right: 14px !important; min-height: 46px; padding: 3px 5px 3px 9px !important; border-radius: 10px !important; box-shadow: none !important; }
  #ta-auth-account-bar .ta-account-summary { max-width: 70px !important; }
  #ta-auth-account-bar .ta-account-role { display: none; }
  #ta-auth-account-bar .ta-button { min-height: 38px !important; }
  .date-range-popover { top: 80px; }
}
@media (max-width: 620px) {
  .setup-grid, .readiness-aside { grid-template-columns: minmax(0, 1fr); }
  .setup-card { grid-template-columns: 32px minmax(0, 1fr) auto; align-items: start; padding: 18px; }
  .setup-card > .status-pill { grid-column: auto; }
  .setup-card > .button, .setup-card > a { grid-column: 2 / -1; }
  .topbar { padding-right: 188px; padding-left: 14px; gap: 8px; }
  .topbar .store-avatar { display: none; }
  .topbar .store-picker { padding: 0 10px; gap: 6px; }
  .topbar .store-name { max-width: 126px; }
  .workspace-hero-actions .range-control { max-width: 100%; }
  .data-table { min-width: 600px; }
  .bulk-capacity-card .data-table { min-width: 0; }
}
@media (max-width: 520px) {
  .topbar { padding-right: 168px; padding-left: 12px; gap: 7px; }
  .topbar .store-name { max-width: 88px; font-size: 11px; }
  .topbar .store-picker { width: auto; max-width: 100%; padding: 0 8px; gap: 4px; }
  .topbar .store-picker > svg { width: 12px; height: 12px; }
  #ta-auth-account-bar { right: 10px !important; gap: 5px !important; max-width: 154px !important; }
  #ta-auth-account-bar .ta-account-summary { max-width: 47px !important; margin-right: 0; }
  #ta-auth-account-bar .ta-account-name { font-size: 11px; }
  #ta-auth-account-bar .ta-button { padding: 6px 7px !important; font-size: 11px; }
  .page { padding: 18px 12px 30px; }
  .page-title { font-size: 23px; }
  .page-head-actions { display: flex; gap: 8px; }
  .page-head-actions .button { width: auto; flex: 1 1 auto; }
  .page-head-actions .range-control { width: 100%; justify-content: space-between; }
  .range-control .segment-button { min-width: 0; padding: 0 9px; font-size: 11px; }
  .workspace-hero { padding: 21px 19px; gap: 18px; }
  .workspace-hero h1, .workspace-hero .page-title { font-size: 23px; }
  .workspace-hero-copy > p:not(.eyebrow) { font-size: 11px; }
  .workspace-hero-actions { width: 100%; }
  .workspace-hero-actions .button { flex: 1 1 auto; }
  .workspace-status-row { margin-top: 15px; gap: 7px; }
  .setup-card { grid-template-columns: 30px minmax(0, 1fr); padding: 17px; }
  .setup-card > .status-pill { grid-column: 2; }
  .setup-card > .button, .setup-card > a { grid-column: 2; }
  .setup-copy h3 { margin-bottom: 5px; }
  .kpi-grid, .bulk-kpi-grid, .overview-summary-grid { gap: 10px; }
  .kpi-card, .bulk-kpi-card { min-height: 132px; padding: 16px 14px; }
  .kpi-label, .bulk-kpi-label { font-size: 11px; }
  .metric-value, .bulk-kpi-value { font-size: 25px; }
  .bulk-kpi-note { font-size: 10px; }
  .panel-head { min-height: 60px; padding: 16px; }
  .panel-body, .bulk-import-card .panel-body, .bulk-capacity-card .panel-body { padding: 17px; }
  .panel-title { font-size: 14px; }
  .bulk-query-toolbar { gap: 11px; padding: 12px; }
  .bulk-query-toolbar > label { min-width: calc(50% - 8px) !important; }
  .bulk-query-toolbar > .button { width: 100%; }
  .bulk-empty-state { min-height: 190px; padding: 29px 18px; }
  .bulk-dashboard-head { align-items: flex-start; }
  .bulk-dashboard-head h2, .bulk-dashboard-head h3 { font-size: 16px; }
  .modal-backdrop { padding: 0; }
  .modal { border-radius: 16px 16px 0 0; }
  .drawer-note { padding: 11px 12px; }
}
@media (max-width: 380px) {
  .topbar { padding-right: 164px; padding-left: 10px; gap: 6px; }
  .topbar .store-name { max-width: 72px; }
  .topbar .store-picker { padding: 0 6px; }
  .kpi-grid, .bulk-kpi-grid, .overview-summary-grid { grid-template-columns: minmax(0, 1fr); }
  .kpi-card, .bulk-kpi-card { min-height: 119px; padding: 18px; }
  .bulk-kpi-value { margin-top: 10px; }
}

/* 实际导入组件及配置卡片的内容布局。 */
.configuration-panel .setup-card > .text-link,
.configuration-panel .setup-card > .cell-sub {
  grid-column: 2 / -1;
  justify-self: start;
  min-width: 0;
  margin-top: 2px;
}
.configuration-panel .setup-copy .status-pill { margin-top: 10px; }
.configuration-panel .setup-copy h3 small { margin-left: 5px; color: #92a0b1; font-size: 10px; font-weight: 450; }
.bulk-eyebrow { display: block; margin-bottom: 5px; color: #8797aa; font-size: 10px; font-weight: 650; letter-spacing: .06em; }
.bulk-range-note { max-width: 100%; overflow-wrap: anywhere; }
.bulk-notice { margin-bottom: 16px; padding: 12px 15px; border: 1px solid #dce8f5; border-radius: 9px; color: #5c7798; background: #f4f8fd; font-size: 12px; line-height: 1.8; white-space: pre-wrap; overflow-wrap: anywhere; }
.bulk-notice.is-error { color: #b44a4a; border-color: #f0dada; background: #fff5f5; }
.bulk-import-intro { color: #7a8b9e; font-size: 12px; }
.bulk-import-controls { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; gap: 17px 16px; margin: 18px 0; }
.bulk-import-controls > label { display: grid; min-width: 0 !important; gap: 8px !important; margin: 0; }
.bulk-import-controls > label:last-child { grid-column: 1 / -1; }
.bulk-import-controls > label > input,
.bulk-import-controls > label > select { min-width: 0; max-width: 100%; }
.bulk-capacity-count { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 7px; margin-bottom: 22px; }
.bulk-capacity-count > span:first-child { flex-basis: 100%; margin-bottom: 5px; color: #7d8da2; font-size: 11px; }
.bulk-capacity-count > strong { color: #29435f; font-size: 32px; font-weight: 750; line-height: 1.25; letter-spacing: -.025em; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.bulk-capacity-count > span:last-child { color: #91a0b2; font-size: 11px; }
.bulk-capacity-meta { display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 5px 12px; margin-bottom: 10px; color: #8291a4; font-size: 10px; }
.bulk-capacity-meta > strong { color: #526c8d; font-size: 11px; font-weight: 600; }
.bulk-capacity-track { width: 100%; height: 8px; margin-bottom: 12px; overflow: hidden; border-radius: 5px; background: #edf1f7; }
.bulk-capacity-fill { height: 100%; border-radius: inherit; background: #437fdf; }
.bulk-capacity-card p.bulk-capacity-status { margin: 12px 0 17px; color: #3c8b72; font-size: 11px; }
.bulk-capacity-card p.bulk-capacity-warning { margin: 12px 0 17px; padding: 10px 12px; border: 1px solid #f3e4c3; border-radius: 8px; color: #9f7029; background: #fff9ee; font-size: 11px; }
.bulk-dataset-counts { display: grid; gap: 0; margin: 15px 0; }
.bulk-dataset-counts > div { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid #edf1f6; }
.bulk-dataset-counts > div:last-child { border-bottom: 0; }
.bulk-dataset-counts span { min-width: 0; color: #8492a5; font-size: 11px; }
.bulk-dataset-counts strong { color: #61758e; font-size: 11px; font-weight: 600; text-align: right; font-variant-numeric: tabular-nums; }
.bulk-readiness-note { margin-top: 20px; padding-top: 17px; border-top: 1px solid #e9eef5; }
.bulk-readiness-note > strong { display: block; margin-bottom: 8px; color: #5b738e; font-size: 11px; font-weight: 650; line-height: 1.75; }
.bulk-readiness-note > p { margin: 0; color: #8997a9; font-size: 11px; line-height: 1.8; }
.bulk-readiness-note .bulk-details { margin-top: 12px; }
.bulk-task-empty { padding: 20px 12px; border: 1px dashed #e1e8f2; border-radius: 9px; color: #8a99ab; background: #fbfcfe; font-size: 12px; text-align: center; }
.bulk-query-status { margin: 0 0 17px; color: #8a98aa; font-size: 11px; line-height: 1.8; overflow-wrap: anywhere; }
.bulk-metric-details { margin-bottom: 18px; }
.bulk-metric-details > .table-scroll { padding: 0; }
.bulk-metric-details .drawer-note { margin: 12px; padding: 11px 13px; }
.bulk-page-nav { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-top: 18px; padding-top: 16px; border-top: 1px solid #e9eef5; }
.bulk-page-nav > span { margin-left: auto; color: #8b99ab; font-size: 11px; line-height: 1.7; }
.bulk-page-nav > span:first-child { margin-left: 0; margin-right: auto; }
.bulk-page-nav .button { min-height: 40px; }
@media (max-width: 820px) {
  .bulk-page-nav .button { min-height: 44px; }
  .configuration-panel .setup-card > .text-link { min-height: 40px; }
}
@media (max-width: 520px) {
  .bulk-import-controls { grid-template-columns: minmax(0, 1fr); gap: 15px; }
  .bulk-capacity-count { margin-bottom: 18px; }
  .bulk-capacity-meta { font-size: 11px; }
  .bulk-page-nav { gap: 9px; }
  .bulk-page-nav > span { width: 100%; margin: 0; }
  .bulk-page-nav > span:first-child { margin-right: 0; }
  .bulk-page-nav > .button { flex: 1 1 auto; }
}

/* Store-scoped Leke operation forms */
.care-select {display:grid;gap:8px;margin-bottom:18px;max-width:760px}
.care-select select,.care-fields select,.care-fields textarea,.care-confirm input {width:100%;padding:12px;border:1px solid var(--border,#dce4ef);border-radius:10px;background:#fff;color:#18314d;font:inherit;box-sizing:border-box}
.care-fields {display:grid;grid-template-columns:repeat(auto-fit,minmax(260px,1fr));gap:20px;margin:20px 0}
.care-fields label {display:grid;gap:6px;align-content:start;min-width:0}
.care-fields small,.care-fields details {color:#718096;font-size:12px}
.care-fields details p {overflow-wrap:anywhere;line-height:1.7}
.care-confirm {padding:20px;border:1px solid #e9b983;background:#fff9f0;border-radius:12px;margin:18px 0}
.care-confirm pre,.care-result pre {white-space:pre-wrap;overflow-wrap:anywhere;max-height:420px;overflow:auto;font-size:13px}
.care-result {margin-top:20px}
.care-result summary {cursor:pointer;color:#2864dd}
