:root {
  --bg: #f6faf8;
  --surface: #ffffff;
  --surface-soft: #edf8f4;
  --text: #13201d;
  --muted: #64736e;
  --border: #dfe9e5;
  --primary: #009a87;
  --primary-dark: #007264;
  --warning: #e05f45;
  --warning-soft: #fff0eb;
  --shadow: 0 18px 42px rgba(20, 44, 38, 0.07);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 1180px;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Helvetica Neue", Arial, sans-serif;
  letter-spacing: 0;
}

button,
input {
  font: inherit;
}

button {
  border: 0;
  cursor: pointer;
}

.login-page {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 460px;
  background:
    linear-gradient(135deg, rgba(0, 154, 135, 0.12), transparent 36%),
    linear-gradient(225deg, rgba(224, 95, 69, 0.12), transparent 34%),
    var(--bg);
}

.login-brand {
  padding: 72px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.brand-mark {
  width: 42px;
  height: 42px;
  border: 7px solid var(--primary);
  border-radius: 50%;
  position: relative;
}

.brand-mark::after {
  content: "";
  position: absolute;
  left: -12px;
  top: 16px;
  width: 68px;
  height: 10px;
  border-radius: 999px;
  background: var(--warning);
  transform: rotate(-18deg);
}

.login-title {
  max-width: 680px;
}

.login-title h1 {
  margin: 0;
  font-size: 56px;
  line-height: 1.06;
  font-weight: 900;
}

.login-title p {
  margin: 22px 0 0;
  max-width: 600px;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.7;
}

.login-points {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  max-width: 760px;
}

.login-point {
  min-height: 118px;
  padding: 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.72);
}

.login-point strong {
  display: block;
  font-size: 18px;
}

.login-point span {
  display: block;
  margin-top: 10px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

.login-panel-wrap {
  padding: 32px;
  display: flex;
  align-items: center;
}

.login-panel {
  width: 100%;
  padding: 34px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.login-panel h2 {
  margin: 0;
  font-size: 28px;
}

.login-panel p {
  margin: 10px 0 28px;
  color: var(--muted);
  line-height: 1.6;
}

.field {
  display: grid;
  gap: 8px;
  margin-bottom: 18px;
}

.field label {
  color: #3b4a45;
  font-size: 14px;
  font-weight: 700;
}

.field input {
  height: 46px;
  padding: 0 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
  color: var(--text);
  outline: none;
}

.field input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0, 154, 135, 0.12);
}

.primary-btn,
.secondary-btn,
.ghost-btn {
  height: 42px;
  padding: 0 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 800;
}

.primary-btn {
  width: 100%;
  background: var(--primary);
  color: white;
}

.primary-action-btn {
  height: 42px;
  padding: 0 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius);
  background: var(--primary);
  color: white;
  font-size: 14px;
  font-weight: 850;
}

.secondary-btn {
  background: var(--surface-soft);
  color: var(--primary-dark);
}

.ghost-btn {
  background: white;
  color: var(--text);
  border: 1px solid var(--border);
}

.error {
  min-height: 22px;
  margin: 6px 0 14px;
  color: var(--warning);
  font-size: 14px;
}

.login-demo {
  margin-top: 18px;
  padding: 14px;
  border-radius: var(--radius);
  background: var(--surface-soft);
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

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

.sidebar {
  min-height: 100vh;
  padding: 24px 18px;
  background: var(--surface);
  border-right: 1px solid var(--border);
}

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

.sidebar-brand .brand-mark {
  flex: 0 0 auto;
  width: 30px;
  height: 30px;
  border-width: 5px;
}

.sidebar-brand .brand-mark::after {
  left: -8px;
  top: 11px;
  width: 48px;
  height: 7px;
}

.sidebar-brand strong {
  display: block;
  font-size: 18px;
}

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

.nav {
  display: grid;
  gap: 6px;
}

.mobile-page-select {
  display: none;
}

.nav-item {
  height: 42px;
  padding: 0 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  border-radius: var(--radius);
  border: 0;
  background: transparent;
  color: #4a5a55;
  font-size: 14px;
  font-weight: 750;
  text-align: left;
}

.nav-item.active {
  background: var(--surface-soft);
  color: var(--primary-dark);
}

.nav-dot {
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: currentColor;
}

.main {
  min-width: 0;
}

.topbar {
  height: 72px;
  padding: 0 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(246, 250, 248, 0.88);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(18px);
  position: sticky;
  top: 0;
  z-index: 3;
}

.topbar h1 {
  margin: 0;
  font-size: 24px;
}

.operator {
  display: flex;
  align-items: center;
  gap: 12px;
}

.operator-info {
  text-align: right;
}

.operator-info strong {
  display: block;
  font-size: 14px;
}

.operator-info span {
  color: var(--muted);
  font-size: 12px;
}

.avatar {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: var(--radius);
  background: var(--primary);
  color: white;
  font-weight: 900;
}

.content {
  padding: 28px;
}

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

.card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 10px 28px rgba(20, 44, 38, 0.045);
}

.stat-card {
  padding: 20px;
}

.stat-label {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.stat-value {
  margin-top: 14px;
  font-size: 32px;
  font-weight: 900;
}

.stat-trend {
  margin-top: 8px;
  color: var(--primary-dark);
  font-size: 13px;
  font-weight: 800;
}

.stat-card.warning .stat-trend {
  color: var(--warning);
}

.data-audit-page {
  display: grid;
  gap: 18px;
}

.data-audit-hero {
  background: linear-gradient(180deg, #ffffff 0%, #fbfffd 100%);
}

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

.audit-status-card {
  padding: 16px;
  box-shadow: none;
}

.audit-status-card.success {
  border-color: rgba(0, 154, 135, 0.22);
  background: #f7fffc;
}

.audit-status-card.warning {
  border-color: rgba(223, 137, 0, 0.24);
  background: #fffaf0;
}

.audit-status-card.critical {
  border-color: rgba(208, 68, 79, 0.24);
  background: #fff6f7;
}

.audit-status-label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.audit-status-value {
  margin-top: 9px;
  font-size: 28px;
  font-weight: 950;
}

.audit-status-card p {
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.audit-source-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.audit-source-strip span {
  min-height: 28px;
  padding: 6px 10px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: #fff;
  color: #38514a;
  font-size: 12px;
  font-weight: 850;
}

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

.audit-issue-board > div {
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fff;
}

.audit-issue-board strong {
  display: block;
  margin-bottom: 10px;
  font-size: 13px;
}

.audit-issue-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.audit-issue-tags span,
.audit-empty-tag {
  min-height: 28px;
  padding: 6px 9px;
  border-radius: 7px;
  background: var(--surface-soft);
  color: var(--primary-dark);
  font-size: 12px;
  font-weight: 850;
}

.audit-issue-tags.critical span {
  background: #fff1f3;
  color: var(--danger);
}

.audit-issue-tags.warning span {
  background: var(--warning-soft);
  color: var(--warning);
}

.audit-stock-stats {
  margin-top: 0;
}

.data-audit-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  align-items: start;
}

.data-audit-section.critical {
  border-color: rgba(208, 68, 79, 0.22);
}

.audit-section-count {
  min-width: 42px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--surface-soft);
  color: var(--primary-dark);
  font-size: 16px;
}

.data-audit-section h3 {
  margin: 16px 0 10px;
  font-size: 14px;
}

.data-audit-section h3:first-of-type {
  margin-top: 0;
}

.audit-row-list {
  display: grid;
  gap: 10px;
}

.audit-data-row,
.audit-simple-row {
  display: grid;
  gap: 12px;
  padding: 12px;
  border: 1px solid #edf3f0;
  border-radius: 10px;
  background: #fff;
}

.audit-data-row {
  grid-template-columns: minmax(0, 1.55fr) minmax(170px, 0.85fr);
  align-items: center;
}

.audit-product-cell {
  display: flex;
  gap: 10px;
  min-width: 0;
  align-items: center;
}

.audit-product-thumb {
  width: 50px;
  height: 50px;
  flex: 0 0 50px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: #fbfdfc;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.audit-product-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.audit-product-cell strong,
.audit-product-cell em,
.audit-product-cell small,
.audit-simple-row strong,
.audit-simple-row span,
.audit-simple-row em {
  display: block;
}

.audit-product-cell strong,
.audit-simple-row strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
}

.audit-product-cell em,
.audit-product-cell small,
.audit-simple-row em {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.45;
}

.audit-product-cell small,
.danger-text {
  color: var(--danger);
  font-weight: 850;
}

.audit-stock-cell {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.audit-stock-cell span {
  min-height: 24px;
  padding: 5px 7px;
  border-radius: 6px;
  background: #fbfdfc;
  color: #456158;
  font-size: 12px;
  font-weight: 850;
}

.audit-simple-row {
  grid-template-columns: minmax(140px, 0.8fr) minmax(0, 1.2fr) minmax(120px, 0.7fr);
  align-items: center;
}

.audit-simple-row span {
  color: var(--warning);
  font-size: 13px;
  font-weight: 850;
}

.traffic-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.summary-tile {
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
}

.summary-tile span,
.summary-tile em {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.summary-tile strong {
  display: block;
  margin: 8px 0 6px;
  font-size: 22px;
  font-weight: 900;
}

.summary-tile em {
  color: var(--primary-dark);
  font-weight: 800;
}

.chart {
  height: 220px;
  padding: 18px 18px 10px;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px;
  align-items: end;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background:
    linear-gradient(to top, rgba(223, 233, 229, 0.72) 1px, transparent 1px) 0 0 / 100% 50px,
    #fbfdfc;
}

.chart-col {
  min-width: 0;
  display: grid;
  gap: 8px;
  justify-items: center;
  align-items: end;
}

.bars {
  height: 160px;
  display: flex;
  align-items: end;
  gap: 6px;
}

.visitor-bar,
.order-bar {
  display: block;
  width: 18px;
  border-radius: 5px 5px 2px 2px;
}

.visitor-bar {
  background: rgba(0, 154, 135, 0.28);
  border: 1px solid rgba(0, 154, 135, 0.34);
}

.order-bar {
  background: var(--primary);
}

.chart-label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.chart-legend {
  display: flex;
  gap: 18px;
  margin: 12px 0 16px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.chart-legend span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.chart-legend i {
  width: 10px;
  height: 10px;
  border-radius: 3px;
}

.visitor-dot {
  background: rgba(0, 154, 135, 0.28);
}

.order-dot {
  background: var(--primary);
}

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

.stock-alert {
  padding: 12px;
  border-radius: var(--radius);
  background: var(--warning-soft);
  border: 1px solid #ffd6cc;
}

.stock-alert strong,
.stock-alert span,
.stock-alert em {
  display: block;
}

.stock-alert strong {
  font-size: 13px;
}

.stock-alert span {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
}

.stock-alert em {
  margin-top: 8px;
  color: var(--warning);
  font-size: 12px;
  font-style: normal;
  font-weight: 850;
}

.grid {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(340px, 0.65fr);
  gap: 16px;
  margin-top: 16px;
}

.below-grid {
  margin-top: 16px;
}

.dashboard-insights {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 16px;
  align-items: stretch;
}

.insight-panel {
  min-height: 280px;
}

.section-head.compact {
  margin-bottom: 14px;
}

.section-head.compact h2 {
  font-size: 17px;
}

.section-head.compact p {
  margin-top: 5px;
}

.sales-panel {
  grid-column: span 2;
}

.sales-trend-chart {
  height: 206px;
  padding: 14px 12px 12px;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 10px;
  align-items: end;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background:
    linear-gradient(to top, rgba(223, 233, 229, 0.72) 1px, transparent 1px) 0 0 / 100% 46px,
    #fbfdfc;
}

.sales-trend-col {
  min-width: 0;
  height: 176px;
  display: grid;
  grid-template-rows: 26px 1fr 18px 18px;
  gap: 5px;
  align-items: end;
  justify-items: center;
}

.sales-trend-col span {
  width: 24px;
  min-height: 10px;
  max-height: 100%;
  display: block;
  border-radius: 5px 5px 2px 2px;
  background: var(--primary);
}

.sales-trend-value,
.sales-trend-col em,
.sales-trend-col strong {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11px;
}

.sales-trend-value {
  color: var(--primary-dark);
  font-weight: 850;
}

.sales-trend-col em {
  color: var(--muted);
  font-style: normal;
}

.sales-trend-col strong {
  color: var(--text);
  font-weight: 850;
}

.insight-list {
  display: grid;
  gap: 11px;
}

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

.product-rank-row {
  grid-template-columns: 28px 44px minmax(0, 1fr);
}

.product-rank-row img,
.rank-image-empty {
  width: 44px;
  height: 44px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  object-fit: cover;
  background: #eef5f2;
}

.rank-image-empty {
  display: grid;
  place-items: center;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.rank-no {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #eef7f5;
  color: var(--primary-dark);
  font-size: 12px;
  font-weight: 900;
}

.insight-row strong,
.insight-row em,
.conversion-row strong,
.conversion-row em {
  display: block;
}

.insight-row strong,
.conversion-row strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
}

.insight-row em,
.conversion-row em {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.35;
}

.mini-progress,
.wide-progress {
  display: block;
  height: 7px;
  margin-top: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #edf3f0;
}

.mini-progress i,
.wide-progress i {
  height: 100%;
  display: block;
  border-radius: inherit;
  background: var(--primary);
}

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

.conversion-row .wide-progress {
  grid-column: 1 / -1;
  margin-top: 0;
}

.conversion-row > span {
  color: var(--primary-dark);
  font-size: 12px;
  font-weight: 900;
}

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

.efficiency-grid div {
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
}

.efficiency-grid span,
.efficiency-progress span,
.efficiency-progress em {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.efficiency-grid strong {
  display: block;
  margin-top: 6px;
  font-size: 20px;
}

.efficiency-progress {
  margin-top: 14px;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 12px;
}

.efficiency-progress strong {
  display: block;
  font-size: 18px;
}

.efficiency-progress em {
  color: var(--primary-dark);
  font-weight: 850;
}

.insight-empty {
  min-height: 150px;
  display: grid;
  place-items: center;
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
  background: #fbfdfc;
}

.product-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-top: 16px;
  align-items: start;
}

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

.toolbar-input,
.toolbar-select,
.product-form input,
.product-form select {
  height: 38px;
  padding: 0 11px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
  color: var(--text);
  outline: none;
  font-size: 13px;
}

.toolbar-input {
  width: 180px;
}

.toolbar-input:focus,
.toolbar-select:focus,
.product-form input:focus,
.product-form select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0, 154, 135, 0.12);
}

.product-table {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.product-row {
  display: grid;
  grid-template-columns: 34px minmax(220px, 1.5fr) minmax(150px, 0.86fr) minmax(112px, 0.6fr) minmax(150px, 0.82fr) minmax(210px, 1fr) minmax(170px, 0.78fr);
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid #edf3f0;
  background: #fff;
  font-size: 13px;
}

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

.product-row-head {
  background: #fbfdfc;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.check-cell {
  display: flex;
  align-items: center;
  justify-content: center;
}

.check-cell input {
  width: 16px;
  height: 16px;
  margin: 0;
  accent-color: var(--primary);
}

.product-row strong,
.product-row em {
  display: block;
}

.product-row strong {
  font-size: 13px;
}

.product-row em {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.4;
}

.price-stack strong {
  color: var(--text);
}

.cost-price-line {
  color: #9a6a2f !important;
  font-weight: 750;
}

.synthesis-status-line {
  color: #546b64 !important;
  font-weight: 750;
}

.ship-date-cell {
  display: grid;
  gap: 6px;
}

.ship-date-input {
  width: 100%;
  min-width: 0;
  height: 34px;
  padding: 0 8px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
  color: var(--text);
  font: inherit;
}

.presale-text {
  color: var(--warning) !important;
  font-weight: 850;
}

.form-hint {
  margin-top: -4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.product-summary {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.product-cover-thumb {
  width: 46px;
  height: 46px;
  flex: 0 0 46px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-soft);
  color: var(--primary-dark);
  font-size: 16px;
  font-weight: 900;
}

.product-cover-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mall-pool-section {
  margin-top: 16px;
}

.mall-category-section {
  margin-bottom: 16px;
}

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

.mall-category-heading h2,
.mall-category-heading p {
  margin: 0;
}

.mall-category-heading p {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 720;
}

.mall-category-groups {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.mall-category-group {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  min-width: 0;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fbfdfc;
}

.mall-category-group > strong {
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
}

.mall-category-group > div {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.mall-category-group span {
  padding: 5px 9px;
  border: 1px solid #cfe4dd;
  border-radius: 6px;
  background: #fff;
  color: var(--primary-dark);
  font-size: 12px;
  font-weight: 820;
}

.mall-pool-toolbar {
  align-items: flex-end;
}

.compact-filter {
  display: grid;
  gap: 4px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 820;
}

.compact-filter select {
  min-width: 112px;
  height: 36px;
  padding: 0 30px 0 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
  font: inherit;
  font-size: 12px;
  font-weight: 760;
  outline: none;
}

.compact-filter select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0, 154, 135, 0.1);
}

@media (max-width: 980px) {
  .mall-category-groups {
    grid-template-columns: 1fr;
  }

  .mall-pool-toolbar {
    width: 100%;
  }
}

.app-backbar {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 16px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: linear-gradient(180deg, #ffffff, #fbfdfc);
  box-shadow: 0 10px 24px rgba(20, 44, 38, 0.05);
}

.app-backbar .secondary-btn {
  flex: 0 0 auto;
}

.app-backbar strong,
.app-backbar span {
  display: block;
}

.app-backbar strong {
  color: var(--text);
  font-size: 15px;
  font-weight: 900;
}

.app-backbar span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.app-sync-card {
  margin-top: 16px;
}

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

.app-sync-grid div {
  min-width: 0;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fbfdfc;
}

.app-sync-grid strong,
.app-sync-grid span {
  display: block;
}

.app-sync-grid strong {
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
}

.app-sync-grid span {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 760;
  line-height: 1.45;
}

.mall-table {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.mall-row {
  display: grid;
  grid-template-columns: 34px minmax(210px, 1.3fr) minmax(150px, 0.8fr) minmax(220px, 1fr) 150px 82px;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid #edf3f0;
  background: #fff;
  font-size: 13px;
}

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

.mall-row-head {
  background: #fbfdfc;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.mall-row strong,
.mall-row em {
  display: block;
}

.mall-row em {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.4;
}

.ichiban-section {
  margin-top: 16px;
}

.ichiban-table {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.ichiban-row,
.ichiban-event-row,
.ichiban-prize-row,
.ichiban-special-row,
.ichiban-record-row,
.ichiban-settlement-row {
  display: grid;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid #edf3f0;
  background: #fff;
  font-size: 13px;
}

.ichiban-row {
  grid-template-columns: minmax(210px, 1.2fr) minmax(120px, 0.7fr) minmax(125px, 0.7fr) minmax(150px, 0.8fr) 82px 190px;
}

.ichiban-event-row {
  grid-template-columns: minmax(260px, 1.45fr) minmax(145px, 0.75fr) minmax(145px, 0.75fr) 86px 230px;
}

.ichiban-prize-row {
  grid-template-columns: minmax(250px, 1.35fr) minmax(140px, 0.75fr) minmax(112px, 0.58fr) 126px minmax(190px, 0.95fr) 86px;
}

.ichiban-special-row {
  grid-template-columns: minmax(260px, 1.4fr) minmax(210px, 1fr) minmax(88px, 0.45fr) minmax(185px, 0.9fr) 82px 86px;
}

.ichiban-record-row {
  grid-template-columns: minmax(140px, 0.85fr) minmax(260px, 1.4fr) 100px 120px 92px 120px;
}

.ichiban-settlement-row {
  grid-template-columns: minmax(150px, 0.8fr) minmax(130px, 0.75fr) minmax(230px, 1.2fr) minmax(220px, 1.1fr) 92px 120px;
}

.ichiban-row:last-child,
.ichiban-event-row:last-child,
.ichiban-prize-row:last-child,
.ichiban-special-row:last-child,
.ichiban-record-row:last-child,
.ichiban-settlement-row:last-child {
  border-bottom: 0;
}

.ichiban-row-head {
  background: #fbfdfc;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.ichiban-row strong,
.ichiban-row em,
.ichiban-event-row strong,
.ichiban-event-row em,
.ichiban-prize-row strong,
.ichiban-prize-row em,
.ichiban-special-row strong,
.ichiban-special-row em,
.ichiban-record-row strong,
.ichiban-record-row em,
.ichiban-settlement-row strong,
.ichiban-settlement-row em {
  display: block;
}

.ichiban-row em,
.ichiban-event-row em,
.ichiban-prize-row em,
.ichiban-special-row em,
.ichiban-record-row em,
.ichiban-settlement-row em {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.4;
}

.ichiban-actions {
  gap: 8px;
}

.ichiban-actions .secondary-btn,
.ichiban-actions .danger-btn {
  width: auto;
  height: 34px;
  min-height: 34px;
  padding: 0 12px;
}

.ichiban-sort-controls {
  display: grid;
  grid-template-columns: 30px minmax(48px, 1fr) 30px;
  gap: 6px;
  align-items: center;
  max-width: 126px;
}

.ichiban-prize-sort-input {
  width: 100%;
  height: 32px;
  box-sizing: border-box;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
  font-size: 13px;
  font-weight: 760;
  text-align: center;
}

.tiny-icon-btn {
  width: 30px;
  height: 30px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #f8fbf6;
  color: var(--accent);
  font-size: 14px;
  font-weight: 900;
  line-height: 1;
  cursor: pointer;
}

.tiny-icon-btn:disabled {
  cursor: not-allowed;
  opacity: 0.38;
}

.ichiban-event-summary,
.ichiban-detail-title {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.ichiban-cover-thumb,
.ichiban-cover-preview {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-soft);
  color: var(--primary-dark);
  font-weight: 900;
}

.ichiban-cover-thumb {
  width: 54px;
  height: 54px;
  font-size: 18px;
}

.ichiban-cover-preview {
  width: 86px;
  height: 86px;
  font-size: 24px;
}

.ichiban-cover-thumb img,
.ichiban-cover-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.readonly-product-line {
  display: grid;
  gap: 6px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fbfdfc;
}

.readonly-product-line span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.readonly-product-line strong,
.readonly-product-line em {
  display: block;
}

.readonly-product-line em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.probability-list {
  display: grid;
  gap: 10px;
}

.probability-row {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 100px 70px;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
  font-size: 13px;
}

.probability-row span,
.probability-row strong,
.probability-row em {
  display: block;
}

.probability-row strong {
  color: var(--primary-dark);
  font-size: 16px;
}

.probability-row em {
  color: var(--muted);
  font-style: normal;
}

.mall-switches {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.mini-check {
  min-height: 28px;
  padding: 0 9px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #fbfdfc;
  color: #3b4a45;
  font-size: 12px;
  font-weight: 850;
}

.mini-check input {
  width: 14px;
  height: 14px;
  margin: 0;
  accent-color: var(--primary);
}

.mall-config-inputs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.mall-config-box {
  display: grid;
  gap: 8px;
}

.mall-config-box .secondary-btn {
  width: 100%;
  height: 34px;
}

.mall-config-inputs label {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.mall-config-inputs input {
  width: 100%;
  height: 32px;
  padding: 0 8px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #fbfdfc;
  color: var(--text);
  outline: none;
}

.mall-config-inputs input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0, 154, 135, 0.12);
}

.mall-import-list {
  display: grid;
  gap: 10px;
}

.mall-import-row {
  display: grid;
  grid-template-columns: minmax(230px, 1fr) 110px minmax(180px, 0.8fr) 84px 72px;
  gap: 14px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
}

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

.mall-import-categories label {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.mall-import-categories select {
  width: 100%;
  height: 34px;
  margin-top: 4px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fff;
  color: var(--text);
}

.mall-import-row strong,
.mall-import-row em {
  display: block;
}

.mall-import-row em {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.empty-state {
  min-height: 154px;
  display: grid;
  place-items: center;
  gap: 8px;
  padding: 28px;
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
  text-align: center;
}

.empty-state strong,
.empty-state span {
  display: block;
}

.empty-state strong {
  font-size: 15px;
}

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

.compact-empty {
  min-height: auto;
  padding: 14px;
  place-items: start;
  text-align: left;
}

.primary-action-btn:disabled,
.secondary-btn:disabled,
.ghost-btn:disabled {
  cursor: not-allowed;
  opacity: 0.54;
}

.stock-warning-text {
  color: var(--warning);
}

.stock-stepper {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 32px;
}

.stock-input {
  width: 58px;
  height: 30px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #ffffff;
  color: var(--text);
  text-align: center;
  font-size: 15px;
  font-weight: 900;
  outline: none;
}

.stock-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0, 154, 135, 0.12);
}

.stock-step-btn {
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #fbfdfc;
  color: var(--primary-dark);
  font-size: 18px;
  font-weight: 900;
  line-height: 1;
}

.stock-step-btn:hover {
  border-color: rgba(0, 154, 135, 0.45);
  background: var(--surface-soft);
}

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

.compact-action {
  min-height: 30px;
  padding: 0 12px;
  font-size: 12px;
  line-height: 30px;
}

.switch-btn {
  height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0;
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.switch-track {
  width: 46px;
  height: 24px;
  padding: 3px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: #dce7e3;
  transition: background 0.18s ease;
}

.switch-track i {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 2px 6px rgba(20, 44, 38, 0.18);
  transform: translateX(0);
  transition: transform 0.18s ease;
}

.switch-btn.is-on {
  color: var(--primary-dark);
}

.switch-btn.is-on .switch-track {
  background: var(--primary);
}

.switch-btn.is-on .switch-track i {
  transform: translateX(22px);
}

.product-form {
  display: grid;
  gap: 12px;
}

.product-form label {
  display: grid;
  gap: 7px;
  color: #3b4a45;
  font-size: 12px;
  font-weight: 800;
}

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

.synthesis-toggle {
  position: relative;
}

.synthesis-toggle input[type='hidden'],
.synthesis-checkbox {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.synthesis-control {
  height: 40px;
  padding: 0 14px 0 6px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: #fbfdfc;
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.synthesis-control i {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #dce7e3;
  box-shadow: inset 0 0 0 1px rgba(21, 42, 37, 0.04);
}

.synthesis-checkbox:checked + .synthesis-control {
  border-color: rgba(0, 154, 135, 0.32);
  background: rgba(0, 154, 135, 0.08);
  color: var(--primary-dark);
}

.synthesis-checkbox:checked + .synthesis-control i {
  background: var(--primary);
}

.synthesis-off {
  display: inline;
}

.synthesis-on,
.synthesis-checkbox:checked + .synthesis-control .synthesis-off {
  display: none;
}

.synthesis-checkbox:checked + .synthesis-control .synthesis-on {
  display: inline;
}

.cover-upload {
  display: flex;
  align-items: center;
  gap: 14px;
}

.cover-preview {
  width: 96px;
  height: 96px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px dashed rgba(0, 154, 135, 0.38);
  border-radius: 8px;
  background: var(--surface-soft);
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.cover-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cover-picker {
  width: auto;
  min-width: 132px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
  color: var(--primary-dark);
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
}

.cover-picker input {
  display: none;
}

.form-check {
  display: inline-flex !important;
  grid-template-columns: none !important;
  align-items: center;
  gap: 8px !important;
}

.form-check input {
  width: 16px;
  height: 16px;
  margin: 0;
  accent-color: var(--primary);
}

.form-error {
  min-height: 18px;
  color: var(--warning);
  font-size: 12px;
}

.log-list {
  display: grid;
  gap: 10px;
}

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

.log-item {
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
}

.log-item strong,
.log-item span {
  display: block;
}

.log-item strong {
  font-size: 13px;
}

.log-item span {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 28px;
  background: rgba(19, 32, 29, 0.34);
}

.modal-panel {
  width: min(720px, 100%);
  max-height: calc(100vh - 56px);
  overflow: auto;
  padding: 22px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: 0 28px 80px rgba(20, 44, 38, 0.22);
}

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

.modal-head h2 {
  margin: 0;
  font-size: 20px;
}

.legacy-import-panel {
  width: min(980px, 100%);
}

.legacy-import-safety {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
  padding: 10px;
  border: 1px solid rgba(75, 151, 42, 0.18);
  border-radius: 10px;
  background: #f6fbef;
  color: #55711f;
  font-size: 12px;
  font-weight: 850;
}

.legacy-import-safety strong {
  color: #304712;
}

.legacy-import-safety span {
  padding: 3px 8px;
  border-radius: 999px;
  background: #fff;
}

.left-actions {
  justify-content: flex-start;
}

.legacy-import-summary {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
  margin-top: 18px;
}

.legacy-import-summary span {
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fbfdf7;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.legacy-import-summary b {
  display: block;
  margin-bottom: 4px;
  color: var(--primary-dark);
  font-size: 22px;
}

.legacy-import-status {
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 8px;
  background: #fff8df;
  color: #7a6416;
  font-size: 12px;
  font-weight: 850;
}

.legacy-preview-list {
  display: grid;
  gap: 8px;
  margin-top: 12px;
  max-height: 360px;
  overflow: auto;
}

.legacy-preview-row {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr) 72px;
  gap: 10px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fff;
}

.legacy-preview-row.is-duplicate {
  opacity: 0.64;
}

.legacy-preview-cover {
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px dashed rgba(75, 151, 42, 0.28);
  border-radius: 8px;
  background: #fbfdf7;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.legacy-preview-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.legacy-preview-row strong,
.legacy-preview-row em,
.legacy-preview-row small {
  display: block;
}

.legacy-preview-row strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.legacy-preview-row em {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.legacy-preview-row small {
  margin-top: 4px;
  color: var(--warning);
  font-size: 11px;
}

.legacy-preview-row > span {
  justify-self: end;
  padding: 4px 8px;
  border-radius: 999px;
  background: #f1f7e4;
  color: var(--primary-dark);
  font-size: 12px;
  font-weight: 850;
}

.legacy-import-result {
  display: grid;
  gap: 6px;
  margin-top: 14px;
  padding: 14px;
  border: 1px solid rgba(75, 151, 42, 0.2);
  border-radius: 10px;
  background: #f4fbeb;
}

.legacy-import-result strong {
  color: var(--primary-dark);
}

.legacy-import-result span,
.legacy-import-result em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.5;
}

.modal-head p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.icon-btn {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius);
  background: #fbfdfc;
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: 22px;
  line-height: 1;
}

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

.batch-ship-panel {
  width: min(760px, 100%);
}

.batch-ship-guide {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.batch-result {
  margin-top: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.batch-result-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  background: #fbfdfc;
  border-bottom: 1px solid var(--border);
}

.batch-result-summary span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.batch-result-list {
  max-height: 220px;
  overflow: auto;
}

.batch-result-list > div {
  padding: 10px 12px;
  border-bottom: 1px solid #edf3f0;
}

.batch-result-list > div:last-child {
  border-bottom: 0;
}

.batch-result-list strong,
.batch-result-list span {
  display: block;
}

.batch-result-list strong {
  font-size: 13px;
}

.batch-result-list span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.batch-result-list .is-success strong {
  color: var(--primary-dark);
}

.batch-result-list .is-failed strong {
  color: var(--danger);
}

.section {
  padding: 20px;
}

.section-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.section-head h2 {
  margin: 0;
  font-size: 18px;
}

.section-head p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 13px;
}

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

.app-entry {
  min-height: 138px;
  padding: 18px;
  display: block;
  text-align: left;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
  color: var(--text);
  position: relative;
}

.app-entry:hover {
  border-color: rgba(0, 154, 135, 0.45);
  background: var(--surface-soft);
}

.app-entry strong,
.app-entry span,
.app-entry em {
  display: block;
}

.app-entry strong {
  font-size: 16px;
}

.app-entry span {
  margin-top: 10px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.app-entry em {
  margin-top: 18px;
  color: var(--primary-dark);
  font-size: 13px;
  font-style: normal;
  font-weight: 900;
}

.app-entry.muted-entry {
  cursor: default;
  opacity: 0.72;
}

.app-entry.muted-entry:hover {
  border-color: var(--border);
  background: #fbfdfc;
}

.pair-page { min-width: 0; }
.pair-event-list,
.pair-prize-table { border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.pair-event-row,
.pair-prize-row { display: grid; align-items: center; gap: 14px; padding: 14px 16px; border-bottom: 1px solid var(--border); background: #fff; }
.pair-event-row { grid-template-columns: minmax(240px, 1.5fr) minmax(150px, .8fr) minmax(200px, 1fr) 120px 110px; }
.pair-prize-row { grid-template-columns: minmax(230px, 1.4fr) 120px 130px minmax(180px, 1fr) 120px 80px; }
.pair-event-row:last-child,
.pair-prize-row:last-child { border-bottom: 0; }
.pair-row-head { background: #f5f8f7; color: var(--muted); font-size: 12px; font-weight: 850; }
.pair-event-row strong,
.pair-event-row em,
.pair-prize-row strong,
.pair-prize-row em { display: block; }
.pair-event-row em,
.pair-prize-row em { margin-top: 5px; color: var(--muted); font-size: 12px; font-style: normal; }
.pair-overview-grid { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 16px; }
.pair-card-preview { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.pair-card-preview > div,
.pair-card-editor label > div { position: relative; aspect-ratio: 709 / 1063; display: grid; place-items: center; overflow: hidden; border: 1px dashed var(--border-strong); border-radius: 8px; background: #f8fbf9; }
.pair-card-preview img,
.pair-card-editor img { width: 100%; height: 100%; object-fit: contain; }
.pair-card-preview span { position: absolute; z-index: 1; top: 5px; left: 5px; width: 22px; height: 22px; display: grid; place-items: center; border-radius: 5px; background: #fff; color: var(--primary-dark); font-size: 11px; font-weight: 900; }
.pair-card-preview em,
.pair-card-editor em { color: var(--muted); font-size: 11px; font-style: normal; }
.pair-probability-preview { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.pair-probability-preview > div { position: relative; overflow: hidden; min-height: 44px; padding: 8px 10px; border: 1px solid var(--border); border-radius: 7px; background: #fbfdfc; }
.pair-probability-preview span,
.pair-probability-preview strong { position: relative; z-index: 1; display: block; }
.pair-probability-preview span { color: var(--muted); font-size: 11px; }
.pair-probability-preview strong { margin-top: 2px; font-size: 14px; }
.pair-probability-preview i { position: absolute; left: 0; bottom: 0; height: 3px; background: var(--primary); }
.pair-config-modal { max-height: min(900px, 92vh); overflow-y: auto; }
.pair-config-modal label small { display: block; margin-top: 5px; color: var(--muted); font-size: 11px; }
.pair-free-config { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.pair-config-block { margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--border); }
.subsection-title { margin-bottom: 12px; display: flex; align-items: baseline; justify-content: space-between; gap: 16px; }
.subsection-title strong { font-size: 15px; }
.subsection-title span { color: var(--muted); font-size: 12px; }
.pair-card-editor { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; margin-top: 12px; }
.pair-card-editor label { position: relative; min-width: 0; }
.pair-card-editor label > span { position: absolute; z-index: 1; top: 5px; left: 5px; width: 22px; height: 22px; display: grid; place-items: center; border-radius: 5px; background: #fff; font-size: 11px; font-weight: 900; }
.pair-card-editor input[type="file"] { width: 100%; margin-top: 6px; padding: 5px; font-size: 10px; }
.pair-probability-editor { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
.pair-probability-editor label { position: relative; display: grid; grid-template-columns: auto minmax(0,1fr) auto; align-items: center; gap: 6px; padding: 8px; border: 1px solid var(--border); border-radius: 7px; background: #fbfdfc; font-size: 12px; }
.pair-probability-editor input { width: 100%; height: 32px; padding: 5px 7px; }
.pair-probability-editor em { color: var(--muted); font-style: normal; }
.pair-level-editor { display: grid; gap: 10px; }
.pair-level-editor > div { display: grid; grid-template-columns: minmax(160px, 1fr) 90px minmax(160px, 1fr); gap: 10px; padding: 10px; border: 1px solid var(--border); border-radius: 8px; background: #fbfdfc; }
.pair-candidate-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; max-height: 65vh; overflow-y: auto; }
.pair-candidate-grid article { display: grid; grid-template-columns: 54px minmax(0, 1fr) auto; align-items: center; gap: 10px; padding: 10px; border: 1px solid var(--border); border-radius: 8px; }
.pair-candidate-grid strong,
.pair-candidate-grid span,
.pair-candidate-grid em { display: block; }
.pair-candidate-grid span,
.pair-candidate-grid em { margin-top: 4px; color: var(--muted); font-size: 11px; font-style: normal; }
.pair-prize-flags { display: flex; flex-wrap: wrap; gap: 5px; }
.pair-prize-flags span { padding: 3px 6px; border-radius: 5px; background: var(--surface-soft); color: var(--muted); font-size: 10px; font-weight: 800; }
.grand-prize-text { color: #d64b72 !important; font-weight: 850; }
.form-check-row { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 14px; }

@media (max-width: 1180px) {
  .pair-event-list,
  .pair-prize-table { overflow-x: auto; }
  .pair-event-row { min-width: 950px; }
  .pair-prize-row { min-width: 980px; }
  .pair-overview-grid { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  .pair-config-modal .form-grid-2,
  .pair-free-config,
  .pair-level-editor > div { grid-template-columns: 1fr; }
  .pair-card-editor { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .pair-probability-editor { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .pair-candidate-grid { grid-template-columns: 1fr; }
}

/* 对对碰配置工作台 */
.pair-modal-backdrop {
  padding: 18px;
}

.pair-config-modal {
  width: min(1120px, 100%);
  height: min(820px, calc(100vh - 36px));
  max-height: none;
  padding: 0;
  overflow: hidden;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  border-radius: 12px;
  background: #f4f7f6;
}

.pair-modal-header {
  min-height: 82px;
  padding: 18px 22px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid var(--border);
  background: #fff;
}

.pair-modal-header h2 {
  margin: 3px 0 0;
  font-size: 21px;
  letter-spacing: 0;
}

.pair-modal-header p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.pair-modal-kicker {
  color: var(--primary-dark);
  font-size: 11px;
  font-weight: 900;
}

.pair-modal-form {
  min-height: 0;
  display: grid;
  grid-template-columns: 218px minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr) 66px;
}

.pair-modal-aside {
  min-height: 0;
  padding: 20px 16px;
  border-right: 1px solid var(--border);
  background: #f8faf9;
}

.pair-config-progress {
  padding: 12px;
  border: 1px solid #dfeae6;
  border-radius: 8px;
  background: #fff;
}

.pair-config-progress strong,
.pair-config-progress span {
  display: block;
}

.pair-config-progress strong {
  font-size: 12px;
}

.pair-config-progress span {
  margin-top: 5px;
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pair-modal-aside nav {
  display: grid;
  gap: 4px;
  margin-top: 14px;
}

.pair-modal-aside nav a {
  min-height: 54px;
  padding: 9px 10px;
  display: grid;
  grid-template-columns: 25px minmax(0, 1fr);
  align-items: center;
  gap: 9px;
  border-radius: 7px;
  color: var(--text);
  text-decoration: none;
}

.pair-modal-aside nav a:hover {
  background: #edf6f2;
}

.pair-modal-aside nav b {
  width: 25px;
  height: 25px;
  display: grid;
  place-items: center;
  border: 1px solid #bcd7ce;
  border-radius: 50%;
  background: #fff;
  color: var(--primary-dark);
  font-size: 11px;
}

.pair-modal-aside nav span,
.pair-modal-aside nav em {
  display: block;
}

.pair-modal-aside nav span {
  font-size: 12px;
  font-weight: 850;
}

.pair-modal-aside nav em {
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
  font-style: normal;
  font-weight: 650;
}

.pair-aside-note {
  margin-top: 18px;
  padding: 11px;
  border-left: 3px solid #76b19d;
  background: #edf6f2;
}

.pair-aside-note strong,
.pair-aside-note span {
  display: block;
}

.pair-aside-note strong {
  font-size: 11px;
}

.pair-aside-note span {
  margin-top: 5px;
  color: #61746d;
  font-size: 10px;
  line-height: 1.55;
}

.pair-modal-content {
  min-height: 0;
  padding: 20px;
  overflow-y: auto;
  scroll-behavior: smooth;
}

.pair-form-section {
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: #fff;
}

.pair-form-section + .pair-form-section {
  margin-top: 14px;
}

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

.pair-section-heading > div:first-child {
  display: flex;
  align-items: center;
  gap: 9px;
}

.pair-section-heading > div:first-child > span {
  width: 28px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 5px;
  background: #e9f4f0;
  color: var(--primary-dark);
  font-size: 10px;
  font-weight: 950;
}

.pair-section-heading h3 {
  margin: 0;
  font-size: 15px;
}

.pair-section-heading p {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
}

.pair-form-grid {
  display: grid;
  gap: 13px;
}

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

.pair-field-wide {
  grid-column: span 2;
}

.pair-field {
  min-width: 0;
  display: grid;
  align-content: start;
  gap: 6px;
  color: #41514c;
  font-size: 11px;
  font-weight: 850;
}

.pair-field > span {
  min-height: 16px;
}

.pair-field > span i {
  margin-left: 4px;
  color: var(--danger);
  font-size: 9px;
  font-style: normal;
}

.pair-field input,
.pair-field select,
.pair-input-affix {
  width: 100%;
  height: 38px;
  box-sizing: border-box;
  border: 1px solid #d8e3df;
  border-radius: 7px;
  background: #fbfcfc;
  color: var(--text);
  font-size: 12px;
  outline: none;
}

.pair-field input,
.pair-field select {
  padding: 0 10px;
}

.pair-field input:focus,
.pair-field select:focus,
.pair-input-affix:focus-within {
  border-color: #68a994;
  box-shadow: 0 0 0 3px rgba(0, 154, 135, 0.09);
}

.pair-input-affix {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  overflow: hidden;
}

.pair-input-affix.suffix {
  grid-template-columns: minmax(0, 1fr) auto;
}

.pair-input-affix input {
  height: 36px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.pair-input-affix i {
  padding: 0 10px;
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  font-weight: 750;
}

.pair-limit-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 220px));
  gap: 13px;
}

.pair-bonus-panel {
  margin-top: 14px;
  padding: 14px;
  border: 1px solid #dce8e4;
  border-radius: 8px;
  background: #f8fbfa;
}

.pair-toggle-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.pair-toggle-line strong,
.pair-toggle-line em {
  display: block;
}

.pair-toggle-line strong {
  font-size: 12px;
}

.pair-toggle-line em {
  margin-top: 4px;
  color: var(--muted);
  font-size: 10px;
  font-style: normal;
}

.pair-toggle-line input {
  width: 38px;
  height: 21px;
  accent-color: var(--primary);
}

.pair-bonus-panel .pair-free-config {
  margin-top: 12px;
  grid-template-columns: repeat(3, minmax(0, 160px));
}

.pair-bonus-panel.is-disabled .pair-free-config {
  opacity: 0.42;
}

.pair-cover-uploader {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  padding: 12px;
  border: 1px solid #dce7e3;
  border-radius: 8px;
  background: #fafcfb;
}

.pair-cover-preview {
  width: 96px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px dashed #a8c7bc;
  border-radius: 7px;
  background: #eef6f3;
  color: var(--primary-dark);
  font-size: 12px;
  font-weight: 900;
}

.pair-cover-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.pair-cover-uploader strong {
  display: block;
  font-size: 12px;
}

.pair-cover-uploader p {
  margin: 5px 0 10px;
  color: var(--muted);
  font-size: 10px;
}

.pair-file-button {
  width: fit-content;
  height: 32px;
  padding: 0 12px;
  cursor: pointer;
}

.pair-file-button input,
.pair-card-upload > input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}

.pair-card-editor {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.pair-card-upload {
  min-height: 96px;
  padding: 7px;
  border: 1px solid #dce7e3;
  border-radius: 8px;
  background: #fafcfb;
  cursor: pointer;
}

.pair-card-upload:hover {
  border-color: #76ad9b;
  background: #f3f9f7;
}

.pair-card-upload > div {
  width: 100%;
  height: auto;
  aspect-ratio: 709 / 1063;
  border: 0;
  border-radius: 5px;
  background: #eef5f2;
}

.pair-card-number {
  top: 12px !important;
  left: 12px !important;
}

.pair-probability-heading {
  align-items: center;
}

.pair-probability-tools {
  display: flex;
  align-items: center;
  gap: 8px;
}

.pair-probability-tools .ghost-btn {
  height: 32px;
  padding: 0 10px;
  font-size: 11px;
}

#pairProbabilityTotal {
  min-width: 86px;
  height: 32px;
  padding: 0 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  font-size: 11px;
}

#pairProbabilityTotal.is-valid {
  background: #e9f6ee;
  color: #26724e;
}

#pairProbabilityTotal.is-invalid {
  background: #fff0f1;
  color: var(--danger);
}

.pair-probability-hint {
  margin-bottom: 12px;
  padding: 9px 11px;
  border-left: 3px solid #e1b24a;
  background: #fff9e9;
  color: #746333;
  font-size: 10px;
  line-height: 1.5;
}

.pair-probability-editor {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.pair-probability-editor label {
  display: grid;
  grid-template-columns: 1fr;
  gap: 6px;
  padding: 9px;
  border-radius: 7px;
  background: #fafcfb;
}

.pair-probability-editor label > span {
  color: #485a54;
  font-size: 10px;
  font-weight: 900;
}

.pair-probability-editor label > div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 4px;
}

.pair-probability-editor input {
  height: 34px;
  border: 1px solid #d8e3df;
  border-radius: 6px;
  background: #fff;
  font-size: 12px;
  text-align: right;
}

.pair-modal-footer {
  grid-column: 1 / -1;
  min-height: 66px;
  padding: 11px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-top: 1px solid var(--border);
  background: #fff;
}

.pair-modal-footer > span {
  color: var(--muted);
  font-size: 11px;
}

.pair-modal-footer > div {
  display: flex;
  gap: 9px;
}

.pair-modal-footer button {
  min-width: 92px;
}

@media (max-width: 900px) {
  .pair-config-modal {
    height: calc(100vh - 24px);
  }
  .pair-modal-form {
    grid-template-columns: 1fr;
  }
  .pair-modal-aside {
    display: none;
  }
  .pair-form-grid-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 480px) {
  .pair-modal-backdrop { padding: 0; }
  .pair-config-modal { height: 100vh; border-radius: 0; }
  .pair-modal-header { padding: 14px 16px; }
  .pair-modal-content { padding: 12px; }
  .pair-form-section { padding: 14px; }
  .pair-form-grid-2,
  .pair-limit-row,
  .pair-bonus-panel .pair-free-config { grid-template-columns: 1fr; }
  .pair-field-wide { grid-column: auto; }
  .pair-section-heading { align-items: flex-start; }
  .pair-section-heading > p { display: none; }
  .pair-card-editor { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .pair-card-upload > div { height: auto; }
  .pair-probability-editor { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .pair-modal-footer > span { display: none; }
  .pair-modal-footer { justify-content: flex-end; }
}

.marketing-section {
  margin-top: 16px;
}

.coupon-table {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.coupon-row {
  display: grid;
  grid-template-columns: minmax(210px, 1.4fr) minmax(105px, 0.7fr) minmax(150px, 0.9fr) minmax(130px, 0.8fr) 82px 124px;
  gap: 14px;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid #edf3f0;
  background: #fff;
  font-size: 13px;
}

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

.coupon-row-head {
  background: #fbfdfc;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.coupon-row strong,
.coupon-row em {
  display: block;
}

.coupon-row em {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.4;
}

.coupon-actions .switch-btn {
  width: 86px;
}

.coupon-modal-panel {
  width: min(760px, 100%);
}

.rule-section {
  margin-top: 16px;
}

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

.rule-template-card {
  min-height: 218px;
  padding: 16px;
  display: grid;
  gap: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fff;
}

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

.rule-card-head h3 {
  margin: 10px 0 0;
  font-size: 17px;
}

.rule-card-head p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.rule-highlight-list {
  display: grid;
  gap: 8px;
}

.rule-highlight-list span {
  min-height: 28px;
  padding: 7px 9px;
  border-radius: 7px;
  background: var(--surface-soft);
  color: #38514a;
  font-size: 12px;
  font-weight: 800;
}

.user-notice-card {
  border-color: rgba(0, 154, 135, 0.28);
  background: linear-gradient(180deg, #ffffff 0%, #fbfffd 100%);
}

.rule-display-pages {
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fbfdfc;
}

.rule-display-pages strong,
.rule-display-pages span {
  display: block;
}

.rule-display-pages strong {
  font-size: 12px;
}

.rule-display-pages span {
  margin-top: 6px;
  color: var(--primary-dark);
  font-size: 12px;
  font-weight: 850;
  line-height: 1.45;
}

.rule-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.rule-card-meta span {
  min-height: 26px;
  padding: 5px 8px;
  border-radius: 7px;
  background: #fbfdfc;
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.rule-binding-table,
.rule-version-table {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.rule-binding-row,
.rule-version-row {
  display: grid;
  gap: 14px;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid #edf3f0;
  background: #fff;
  font-size: 13px;
}

.rule-binding-row {
  grid-template-columns: minmax(180px, 1fr) minmax(190px, 1.1fr) minmax(130px, 0.72fr) 74px 110px 112px;
}

.rule-version-row {
  grid-template-columns: minmax(190px, 1fr) 128px minmax(260px, 1.25fr) 90px 110px;
}

.rule-binding-row:last-child,
.rule-version-row:last-child {
  border-bottom: 0;
}

.rule-row-head {
  background: #fbfdfc;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.rule-binding-row strong,
.rule-binding-row em,
.rule-version-row strong,
.rule-version-row em {
  display: block;
}

.rule-binding-row em,
.rule-version-row em {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.4;
}

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

.rule-modal-panel textarea {
  resize: vertical;
}

.rule-display-page-field {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fbfdfc;
}

.rule-display-page-field.is-muted {
  opacity: 0.72;
}

.rule-display-page-field strong {
  font-size: 13px;
}

.rule-display-page-field p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

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

.rule-page-checks .form-check {
  min-height: 34px;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
  font-size: 12px;
}

.table {
  width: 100%;
  border-collapse: collapse;
}

.table th,
.table td {
  padding: 13px 10px;
  border-bottom: 1px solid #edf3f0;
  text-align: left;
  font-size: 13px;
}

.table th {
  color: var(--muted);
  font-weight: 800;
}

.badge {
  min-height: 26px;
  padding: 0 9px;
  display: inline-flex;
  align-items: center;
  border-radius: 6px;
  background: var(--surface-soft);
  color: var(--primary-dark);
  font-size: 12px;
  font-weight: 850;
}

.badge.warning,
.badge.high {
  background: var(--warning-soft);
  color: var(--warning);
}

.badge.info {
  background: #edf4ff;
  color: #2f63b7;
}

.badge.success {
  background: #ecf8ef;
  color: #268a46;
}

.badge.muted {
  background: #f1f4f3;
  color: var(--muted);
}

.order-section {
  margin-top: 16px;
}

.order-keyword {
  width: 220px;
}

.order-table {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.order-row {
  display: grid;
  grid-template-columns: minmax(210px, 1.2fr) minmax(230px, 1.35fr) minmax(140px, 0.75fr) 90px 150px 148px;
  gap: 14px;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid #edf3f0;
  background: #fff;
  font-size: 13px;
}

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

.order-row-head {
  background: #fbfdfc;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.order-row strong,
.order-row em,
.order-items-brief span {
  display: block;
}

.order-row em,
.order-items-brief em {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.4;
}

.order-items-brief {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.order-brief-item {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  min-width: 0;
}

.mini-product-thumb {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface-soft);
  color: var(--primary-dark);
  font-size: 12px;
  font-weight: 900;
}

.mini-product-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.order-brief-item span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.order-actions {
  gap: 8px;
}

.order-actions .secondary-btn,
.order-actions .primary-action-btn {
  width: auto;
  height: 34px;
  padding: 0 12px;
}

.order-detail-panel {
  width: min(860px, 100%);
}

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

.detail-block,
.address-box,
.shipment-row {
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
}

.detail-block span,
.detail-block strong,
.detail-block em,
.address-box strong,
.address-box span,
.address-box em,
.shipment-row strong,
.shipment-row span,
.shipment-row em {
  display: block;
}

.detail-block span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.detail-block strong {
  margin-top: 7px;
  font-size: 16px;
}

.detail-block em,
.address-box span,
.address-box em,
.shipment-row em {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.45;
}

.address-box {
  margin-top: 12px;
}

.compact-address {
  margin-top: 0;
}

.order-item-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.order-item {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) 90px;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fff;
}

.order-item strong,
.order-item em {
  display: block;
}

.order-item em {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.order-item > span {
  text-align: right;
  font-weight: 900;
}

.shipment-list {
  margin-top: 14px;
}

.shipment-list h3 {
  margin: 0 0 10px;
  font-size: 15px;
}

.shipment-row + .shipment-row {
  margin-top: 8px;
}

.muted-line {
  padding: 12px;
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  color: var(--muted);
  font-size: 13px;
}

.aftersale-section {
  margin-top: 16px;
}

.aftersale-table {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.aftersale-row {
  display: grid;
  grid-template-columns: minmax(170px, 1fr) minmax(145px, 0.82fr) minmax(220px, 1.25fr) 95px 78px minmax(150px, 0.95fr) 86px;
  gap: 14px;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid #edf3f0;
  background: #fff;
  font-size: 13px;
}

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

.aftersale-row-head {
  background: #fbfdfc;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.aftersale-row strong,
.aftersale-row em,
.aftersale-log-brief span {
  display: block;
}

.aftersale-product-brief {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 8px;
}

.aftersale-product-brief img {
  width: 30px;
  height: 30px;
  border: 1px solid var(--border);
  border-radius: 5px;
  background: #f7faf8;
  object-fit: contain;
}

.aftersale-product-brief span {
  margin-left: 3px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.aftersale-row em,
.aftersale-log-brief span {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.42;
}

.aftersale-action-panel {
  width: min(980px, 100%);
}

.aftersale-item-panel {
  margin-bottom: 16px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
}

.aftersale-item-panel-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 10px;
}

.aftersale-item-panel-head strong { font-size: 14px; }
.aftersale-item-panel-head span { color: var(--muted); font-size: 12px; }

.aftersale-item-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.aftersale-item-row {
  min-width: 0;
  padding: 8px;
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) auto;
  gap: 9px;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: #fff;
}

.aftersale-item-row img {
  width: 48px;
  height: 48px;
  border-radius: 5px;
  background: #f7faf8;
  object-fit: contain;
}

.aftersale-item-row > div { min-width: 0; }
.aftersale-item-row strong,.aftersale-item-row span { display: block; }
.aftersale-item-row strong { overflow: hidden; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.aftersale-item-row span { margin-top: 4px; color: var(--muted); font-size: 11px; }
.aftersale-item-row > div:last-child { text-align: right; }

.aftersale-action-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 16px;
}

.aftersale-log-panel {
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
}

.aftersale-log-panel h3 {
  margin: 0 0 12px;
  font-size: 15px;
}

.aftersale-log-item {
  padding: 11px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
}

.aftersale-log-item + .aftersale-log-item {
  margin-top: 9px;
}

.aftersale-log-item strong,
.aftersale-log-item span,
.aftersale-log-item em {
  display: block;
}

.aftersale-log-item span,
.aftersale-log-item em {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.45;
}

.finance-overview-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
  gap: 16px;
  margin-top: 16px;
}

.finance-panel {
  min-height: 260px;
}

.finance-trend {
  min-height: 170px;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 10px;
  align-items: end;
}

.finance-trend-bar {
  min-width: 0;
  display: grid;
  gap: 7px;
  text-align: center;
}

.finance-trend-bar span,
.finance-trend-bar em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.finance-trend-bar div {
  height: 130px;
  display: flex;
  align-items: end;
  justify-content: center;
  padding: 7px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fbfdfc;
}

.finance-trend-bar i {
  width: 100%;
  min-height: 8px;
  border-radius: 6px;
  background: linear-gradient(180deg, #00a890, #007d6e);
}

.finance-trend-bar strong {
  overflow: hidden;
  color: var(--primary-dark);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

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

.finance-risk-grid div {
  min-height: 72px;
  padding: 12px;
  display: grid;
  align-content: center;
  gap: 8px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fbfdfc;
}

.finance-risk-grid span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.finance-risk-grid strong {
  font-size: 18px;
}

.finance-section {
  margin-top: 16px;
}

.finance-flow-table {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.finance-flow-row {
  display: grid;
  grid-template-columns: minmax(150px, 0.95fr) minmax(150px, 0.95fr) minmax(140px, 0.78fr) 112px minmax(180px, 1.15fr) 116px;
  gap: 14px;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid #edf3f0;
  background: #fff;
  font-size: 13px;
}

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

.finance-row-head {
  background: #fbfdfc;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.finance-flow-row strong,
.finance-flow-row em {
  display: block;
}

.finance-flow-row em {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.42;
}

.money-positive {
  color: #16824a;
}

.money-negative {
  color: var(--warning);
}

.withdrawal-section {
  margin-top: 16px;
}

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

.withdrawal-row {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fff;
  overflow: hidden;
}

.withdrawal-main {
  display: grid;
  grid-template-columns: minmax(150px, 1fr) 120px minmax(150px, 1fr) 138px minmax(190px, 1.2fr) 86px;
  gap: 14px;
  align-items: center;
  padding: 15px 16px;
}

.withdrawal-main strong,
.withdrawal-main span {
  display: block;
}

.withdrawal-main span {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.withdrawal-detail-grid {
  display: grid;
  grid-template-columns: minmax(260px, 0.85fr) minmax(320px, 1fr);
  gap: 16px;
}

.admin-section {
  margin-top: 16px;
}

.admin-table {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.admin-row {
  display: grid;
  grid-template-columns: minmax(150px, 0.95fr) minmax(140px, 0.8fr) minmax(260px, 1.35fr) 72px minmax(130px, 0.8fr) 250px;
  gap: 14px;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid #edf3f0;
  background: #fff;
  font-size: 13px;
}

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

.admin-row-head {
  background: #fbfdfc;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.admin-row strong,
.admin-row em {
  display: block;
}

.admin-row em {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.permission-tags,
.permission-check-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.permission-tags span {
  padding: 5px 8px;
  border-radius: 7px;
  background: #eef8f5;
  color: var(--primary-dark);
  font-size: 12px;
  font-weight: 800;
}

.permission-check-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 8px;
}

.check-card {
  min-height: 38px;
  padding: 9px 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fbfdfc;
  color: var(--text);
  font-size: 13px;
  font-weight: 750;
}

.check-card input {
  width: 16px;
  height: 16px;
  accent-color: var(--primary);
}

.field-title {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.admin-modal-panel {
  width: min(760px, calc(100vw - 32px));
}

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

.danger-btn {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid #ffd7cc;
  border-radius: 10px;
  background: #fff5f2;
  color: #b64d35;
  font-weight: 850;
  cursor: pointer;
}

.user-section {
  margin-top: 16px;
}

.user-table {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.user-row {
  display: grid;
  grid-template-columns: minmax(190px, 1.05fr) minmax(260px, 1.35fr) 120px 150px 110px;
  gap: 14px;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid #edf3f0;
  background: #fff;
  font-size: 13px;
}

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

.user-row-head {
  background: #fbfdfc;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.user-row strong,
.user-row em,
.uid-cell strong,
.uid-cell em {
  display: block;
}

.user-row em,
.uid-cell em {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.4;
}

.user-color-tag {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  margin-top: 7px;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 850;
  line-height: 1;
}

.tag-green {
  background: #e9f7ef;
  color: #26824a;
}

.tag-blue {
  background: #edf4ff;
  color: #2d63b8;
}

.tag-yellow {
  background: #fff7d6;
  color: #936500;
}

.tag-red {
  background: #fff0ed;
  color: #b6422e;
}

.tag-gray {
  background: #eef2f1;
  color: #5f716c;
}

.user-inline-note {
  max-width: 240px;
  color: var(--muted);
}

.uid-cell strong {
  overflow-wrap: anywhere;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 12px;
}

.user-actions .secondary-btn,
.user-actions .ghost-btn {
  width: auto;
  height: 34px;
  padding: 0 12px;
}

.user-detail-panel {
  width: min(980px, 100%);
}

.user-profile-strip {
  display: grid;
  grid-template-columns: 1.2fr repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.user-profile-strip > div,
.detail-panel {
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
}

.user-profile-strip span,
.user-profile-strip strong,
.user-profile-strip em {
  display: block;
}

.user-profile-strip span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.user-profile-strip strong {
  margin-top: 7px;
  overflow-wrap: anywhere;
  font-size: 16px;
}

.user-profile-strip em {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.45;
}

.user-profile-strip .user-color-tag {
  display: inline-flex;
  margin-top: 0;
}

.user-profile-strip .tag-green {
  color: #26824a;
}

.user-profile-strip .tag-blue {
  color: #2d63b8;
}

.user-profile-strip .tag-yellow {
  color: #936500;
}

.user-profile-strip .tag-red {
  color: #b6422e;
}

.user-profile-strip .tag-gray {
  color: #5f716c;
}

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

.user-action-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.user-action-strip .secondary-btn {
  width: auto;
  height: 34px;
  padding: 0 12px;
}

.mark-color-field {
  display: grid;
  gap: 9px;
}

.mark-color-field > span {
  color: var(--text);
  font-size: 13px;
  font-weight: 850;
}

.mark-color-options {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.mark-color-option {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  cursor: pointer;
}

.mark-color-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.mark-color-option span {
  width: 24px;
  height: 24px;
  margin: 0;
  padding: 0;
  border: 2px solid rgba(21, 38, 33, 0.08);
  border-radius: 50%;
  box-shadow: 0 6px 16px rgba(21, 38, 33, 0.08);
}

.mark-color-option input:checked + span {
  border-color: var(--text);
  box-shadow: 0 0 0 4px rgba(64, 123, 93, 0.16);
}

.user-note-box {
  margin-top: 12px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
}

.user-note-box strong,
.user-note-box span {
  display: block;
}

.user-note-box strong {
  font-size: 13px;
}

.user-note-box span {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

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

.detail-panel-head h3 {
  margin: 0;
  font-size: 15px;
}

.detail-panel-head span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.compact-list,
.ledger-list {
  display: grid;
  gap: 8px;
}

.compact-item,
.ledger-row {
  display: grid;
  gap: 10px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
}

.compact-item {
  grid-template-columns: 34px minmax(0, 1fr) 70px;
}

.ledger-row {
  grid-template-columns: minmax(0, 1fr) 110px;
}

.compact-item strong,
.compact-item em,
.ledger-row strong,
.ledger-row em {
  display: block;
}

.compact-item em,
.ledger-row em {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.4;
}

.compact-item > span,
.ledger-row > div:last-child {
  text-align: right;
  font-weight: 900;
}

.ledger-panel {
  margin-top: 12px;
}

.inner-modal-backdrop {
  z-index: 120;
  background: rgba(20, 44, 38, 0.34);
}

.user-action-panel {
  width: min(680px, 100%);
}

.picking-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-top: 16px;
  align-items: start;
}

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

.pick-summary-row {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) 72px;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
}

.pick-summary-row strong,
.pick-summary-row em {
  display: block;
}

.pick-summary-row em {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.4;
}

.pick-summary-count {
  text-align: right;
}

.pick-summary-count strong {
  font-size: 22px;
  font-weight: 900;
}

.pick-summary-count span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.muted-count strong {
  color: var(--primary-dark);
}

.picking-table {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.picking-row {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(240px, 1.35fr) 90px 90px 130px 150px;
  gap: 14px;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid #edf3f0;
  background: #fff;
  font-size: 13px;
}

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

.picking-row-head {
  background: #fbfdfc;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.picking-row strong,
.picking-row em {
  display: block;
}

.picking-row em {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.4;
}

.picking-detail-panel {
  width: min(960px, 100%);
}

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

.package-card {
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fff;
}

.package-head,
.package-meta,
.package-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.package-head {
  justify-content: space-between;
}

.package-head strong,
.package-head em,
.package-address strong,
.package-address span {
  display: block;
}

.package-head > div:first-child > strong {
  font-size: 16px;
}

.package-head em,
.package-address span {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.package-meta strong {
  min-width: 52px;
  text-align: right;
  font-size: 20px;
  font-weight: 900;
}

.package-address {
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: var(--radius);
  background: #fbfdfc;
  border: 1px solid #edf3f0;
}

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

.package-item {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) 64px;
  column-gap: 10px;
  row-gap: 4px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fbfdfc;
}

.package-item.has-exception {
  border-color: #ffd6cc;
  background: var(--warning-soft);
}

.package-item span,
.package-item em,
.package-item strong {
  display: block;
}

.package-item-thumb {
  width: 46px;
  height: 46px;
  grid-row: 1 / span 2;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-soft);
  color: var(--primary-dark);
  font-size: 16px;
  font-weight: 900;
}

.package-item-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.package-item span {
  grid-column: 2;
  font-weight: 900;
}

.package-item em {
  grid-column: 2;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.package-item strong {
  grid-column: 3;
  grid-row: 1 / span 2;
  align-self: center;
  text-align: right;
  font-size: 20px;
}

.package-actions {
  justify-content: flex-end;
  margin-top: 12px;
}

.package-actions .secondary-btn,
.package-actions .primary-action-btn,
.package-actions .ghost-btn {
  width: auto;
  height: 34px;
  padding: 0 12px;
}

.pick-item-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.pick-item {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) 80px;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fff;
}

.pick-item.has-exception {
  border-color: #ffd6cc;
  background: var(--warning-soft);
}

.pick-item strong,
.pick-item em {
  display: block;
}

.pick-item em {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.exception-text {
  color: var(--warning) !important;
  font-weight: 850;
}

.pick-item-quantity {
  text-align: right;
  font-size: 22px;
  font-weight: 900;
}

.pick-stepper {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.pick-stepper strong {
  min-width: 48px;
  text-align: center;
  font-size: 15px;
}

.pick-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

.pick-actions .secondary-btn,
.pick-actions .ghost-btn {
  width: auto;
  height: 34px;
  padding: 0 12px;
}

.box-section {
  margin-top: 16px;
}

.box-domain-tabs {
  display: flex;
  align-items: flex-end;
  gap: 6px;
  margin-bottom: 16px;
  padding: 0 4px;
  border-bottom: 1px solid var(--border);
}

.box-domain-tab {
  width: auto;
  min-width: 150px;
  padding: 10px 16px 9px;
  border: 1px solid var(--border);
  border-bottom: 0;
  border-radius: 6px 6px 0 0;
  background: #f5f8f6;
  color: var(--muted);
  text-align: left;
}

.box-domain-tab strong,
.box-domain-tab span {
  display: block;
}

.box-domain-tab strong {
  color: var(--text);
  font-size: 14px;
}

.box-domain-tab span {
  margin-top: 3px;
  font-size: 11px;
}

.box-domain-tab.active {
  margin-bottom: -1px;
  border-color: #94b4a2;
  border-bottom: 1px solid #fff;
  background: #fff;
  color: var(--primary-dark);
}

.box-domain-tab.active strong {
  color: var(--primary-dark);
}

.market-admin-row {
  grid-template-columns: minmax(260px, 1.45fr) minmax(150px, 0.8fr) minmax(120px, 0.7fr) minmax(150px, 0.85fr) 110px minmax(120px, 0.65fr);
}

.synthesis-admin-row {
  grid-template-columns: minmax(260px, 1.4fr) minmax(150px, 0.8fr) 90px 110px minmax(150px, 0.8fr) 100px;
}

.synthesis-sub-tabs {
  display: flex;
  gap: 4px;
  width: fit-content;
  margin: 0 0 16px;
  padding: 4px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #eef3f1;
}

.synthesis-sub-tab {
  width: auto;
  min-width: 92px;
  height: 34px;
  padding: 0 14px;
  border-radius: 4px;
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.synthesis-sub-tab.active {
  background: #fff;
  color: var(--primary-dark);
  box-shadow: 0 1px 3px rgba(20, 44, 38, 0.1);
}

.synthesis-mall-row {
  grid-template-columns: minmax(260px, 1.45fr) 150px 145px 82px 120px 82px;
}

.synthesis-record-row {
  grid-template-columns: minmax(260px, 1.4fr) minmax(160px, 0.8fr) 72px 110px 90px minmax(140px, 0.7fr);
}

.synthesis-stock-stepper {
  width: 132px;
}

.inline-number-field {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
}

.inline-number-field input,
.compact-number-input {
  width: 92px;
  height: 36px;
  padding: 0 10px;
  border: 1px solid var(--border);
  border-radius: 5px;
  background: #fff;
  color: var(--text);
  font-weight: 800;
}

.compact-number-input {
  width: 70px;
}

.synthesis-product-save-btn {
  width: auto;
  height: 34px;
  padding: 0 14px;
}

.synthesis-import-panel {
  width: min(620px, calc(100vw - 40px));
}

.synthesis-import-picker {
  display: grid;
  grid-template-columns: 148px minmax(0, 1fr);
  gap: 16px;
  align-items: end;
  min-width: 0;
  overflow: hidden;
}

.synthesis-import-picker > label {
  min-width: 0;
  overflow: hidden;
}

.synthesis-import-picker select {
  display: block;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  text-overflow: ellipsis;
}

.synthesis-import-preview {
  display: grid;
  gap: 8px;
}

.synthesis-import-preview-image {
  width: 148px;
  aspect-ratio: 1;
  overflow: hidden;
  display: grid;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #f4f7f5;
  color: var(--primary-dark);
  font-size: 36px;
  font-weight: 900;
}

.synthesis-import-preview-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.synthesis-import-preview strong,
.synthesis-import-preview em,
.synthesis-import-preview span {
  display: block;
}

.synthesis-import-preview strong {
  font-size: 13px;
}

.synthesis-import-preview em,
.synthesis-import-preview span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
}

@media (max-width: 680px) {
  .synthesis-import-picker {
    grid-template-columns: 104px minmax(0, 1fr);
  }

  .synthesis-import-preview-image {
    width: 104px;
  }
}

.market-mode-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.synthesis-value-cell {
  color: var(--primary-dark);
  font-size: 20px;
  font-weight: 900;
}

.synthesis-edit-product-btn {
  width: auto;
  height: 34px;
  padding: 0 12px;
}

@media (max-width: 1100px) {
  .box-domain-tabs {
    overflow-x: auto;
  }

  .market-admin-row,
  .synthesis-admin-row,
  .synthesis-mall-row,
  .synthesis-record-row {
    min-width: 980px;
  }
}

.box-table {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.box-row {
  display: grid;
  grid-template-columns: minmax(250px, 1.35fr) minmax(130px, 0.78fr) minmax(120px, 0.7fr) 72px 112px minmax(110px, 0.65fr) 82px;
  gap: 14px;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid #edf3f0;
  background: #fff;
  font-size: 13px;
}

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

.box-row-head {
  background: #fbfdfc;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.box-row strong,
.box-row em {
  display: block;
}

.box-row em {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.4;
}

.box-quantity {
  color: var(--primary-dark);
  font-size: 20px;
  font-weight: 900;
}

.safe-lock-text {
  margin-top: 6px;
  color: var(--warning);
  font-size: 11px;
  font-style: normal;
  font-weight: 850;
  line-height: 1.35;
}

.box-grant-panel {
  width: min(760px, 100%);
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.52;
}

.todo-list {
  display: grid;
  gap: 10px;
}

.todo {
  padding: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
}

.todo strong {
  display: block;
  font-size: 14px;
}

.todo span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.todo-value {
  min-width: 86px;
  text-align: right;
}

.todo-value strong {
  color: var(--warning);
  font-size: 30px;
  line-height: 1;
}

.todo-value span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

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

.ops-action {
  min-height: 92px;
  padding: 14px;
  display: block;
  text-align: left;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
  color: var(--text);
}

.ops-action:hover {
  border-color: rgba(0, 154, 135, 0.45);
  background: var(--surface-soft);
}

.ops-action strong,
.ops-action span {
  display: block;
}

.ops-action strong {
  font-size: 14px;
}

.ops-action span {
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.health-strip {
  display: grid;
  gap: 10px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid #edf3f0;
}

.health-strip div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.health-strip span {
  color: var(--muted);
  font-size: 12px;
}

.health-strip strong {
  font-size: 13px;
}

.audit-row {
  display: grid;
  grid-template-columns: 1.1fr 1fr 90px 120px;
  gap: 12px;
  padding: 13px 0;
  border-bottom: 1px solid #edf3f0;
  font-size: 13px;
}

.audit-row.head {
  color: var(--muted);
  font-weight: 850;
}

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

.audit-section {
  margin-top: 16px;
}

.audit-signal-list,
.audit-log-table,
.audit-version-table {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.audit-signal-row,
.audit-log-row,
.audit-version-row {
  display: grid;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid #edf3f0;
  background: #fff;
  font-size: 13px;
}

.audit-signal-row {
  grid-template-columns: minmax(280px, 1.35fr) minmax(100px, 0.45fr) minmax(260px, 1.15fr);
}

.audit-log-row {
  grid-template-columns: minmax(130px, 0.8fr) minmax(180px, 1fr) minmax(220px, 1.2fr) 80px 130px;
}

.audit-version-row {
  grid-template-columns: minmax(180px, 1fr) minmax(140px, 0.75fr) minmax(200px, 1.1fr) 110px 130px;
}

.audit-signal-row:last-child,
.audit-log-row:last-child,
.audit-version-row:last-child {
  border-bottom: 0;
}

.audit-row-head {
  background: #fbfdfc;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.audit-signal-row strong,
.audit-signal-row em,
.audit-log-row strong,
.audit-log-row em,
.audit-version-row strong,
.audit-version-row em {
  display: block;
}

.audit-signal-row em,
.audit-log-row em,
.audit-version-row em {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.4;
}

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

.compliance-control {
  display: grid;
  gap: 9px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fbfdfc;
}

.compliance-control strong,
.compliance-control em {
  display: block;
}

.compliance-control em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.45;
}

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

.decor-meta {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 13px;
}

.decor-page-selector {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: 14px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #ffffff;
  box-shadow: 0 8px 18px rgba(20, 44, 38, 0.04);
}

.decor-page-selector-label {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.decor-page-grid {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
  min-width: 0;
}

.decor-page-tile {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  padding: 0 13px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: #fbfdfc;
  color: var(--text);
  text-align: center;
  cursor: pointer;
  box-shadow: none;
  transition: border-color 0.16s ease, box-shadow 0.16s ease, background 0.16s ease, color 0.16s ease;
}

.decor-page-tile:hover {
  border-color: rgba(0, 154, 135, 0.36);
  background: #ffffff;
  color: var(--primary-dark);
}

.decor-page-tile.active {
  border-color: var(--primary);
  color: #ffffff;
  background: var(--primary);
  box-shadow: 0 8px 16px rgba(0, 154, 135, 0.18);
}

.decor-page-tile.disabled {
  cursor: not-allowed;
  opacity: 0.46;
  box-shadow: none;
}

.decor-page-tile.disabled:hover {
  border-color: var(--border);
  background: #fbfdfc;
  color: var(--text);
}

.decor-page-tile[hidden] {
  display: none;
}

.decor-page-tile strong {
  display: block;
  min-width: 0;
  color: inherit;
  font-size: 13px;
  font-weight: 900;
}

.decor-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 455px;
  gap: 18px;
  align-items: start;
}

.decor-editor-card,
.decor-preview-card {
  min-width: 0;
}

.section-head.compact {
  margin-bottom: 14px;
}

.decor-module-list {
  display: grid;
  gap: 14px;
}

.decor-page-style-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 210px;
  gap: 16px;
  align-items: center;
  margin-bottom: 14px;
  padding: 14px;
  border: 1px solid #d8e96c;
  border-radius: 14px;
  background:
    linear-gradient(90deg, rgba(143, 177, 45, 0.08) 1px, transparent 1px) 0 0 / 18px 18px,
    linear-gradient(0deg, rgba(143, 177, 45, 0.08) 1px, transparent 1px) 0 0 / 18px 18px,
    #fffdf0;
}

.decor-page-style-card strong,
.decor-page-style-card span {
  display: block;
}

.decor-page-style-card strong {
  color: #2f3d18;
  font-size: 14px;
  font-weight: 900;
}

.decor-page-style-card span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.decor-page-style-card label {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
}

.decor-page-style-card input[type="color"] {
  width: 54px;
  height: 40px;
  padding: 3px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
}

.decor-page-style-card input:not([type="color"]) {
  width: 100%;
  height: 40px;
  padding: 0 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  font-weight: 800;
}

.decor-page-switch.active {
  border-color: #8fb12d;
  background: #eef9d4;
  color: #2f5f18;
}

.decor-module {
  border: 2px solid var(--module-border, var(--border));
  border-radius: 16px;
  background: #fbfdfc;
  overflow: hidden;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
}

.decor-module[open] {
  background: #ffffff;
}

.decor-module.is-dragging {
  opacity: 0.62;
  outline: 2px dashed var(--primary);
}

.decor-module-head {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 13px 14px;
  background: linear-gradient(180deg, #fffdf3, #eef9d4);
  border-bottom: 1px solid rgba(148, 163, 184, 0.3);
  cursor: pointer;
  list-style: none;
}

.decor-module-head::-webkit-details-marker {
  display: none;
}

.decor-module-head::after {
  content: "展开";
  justify-self: end;
  padding: 5px 9px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: #fff;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.decor-module[open] .decor-module-head::after {
  content: "收起";
  color: var(--primary-dark);
}

.decor-module-head strong,
.decor-module-head span {
  display: block;
}

.decor-module-head span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.drag-handle {
  width: 28px;
  height: 38px;
  display: grid;
  place-items: center;
  color: #7c9b22;
  cursor: grab;
  font-weight: 900;
  letter-spacing: -2px;
}

.decor-module-actions {
  display: flex;
  gap: 8px;
  margin-right: 58px;
}

.decor-module-body {
  display: grid;
  gap: 16px;
  padding: 16px;
}

.decor-module label {
  min-width: 0;
  display: grid;
  gap: 7px;
  color: #33423e;
  font-size: 13px;
  font-weight: 800;
}

.decor-module input,
.decor-module textarea,
.decor-module select {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fbfdfc;
  color: var(--text);
}

.decor-module input:not([type="color"]):not([type="file"]),
.decor-module select {
  min-height: 38px;
  padding: 0 10px;
}

.decor-module textarea {
  min-height: 88px;
  padding: 10px;
  resize: vertical;
}

.decor-module input[type="color"] {
  width: 54px;
  height: 38px;
  padding: 3px;
}

.decor-module input[type="file"] {
  padding: 8px;
}

.decor-basic-grid,
.decor-text-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.decor-text-grid label:nth-child(3) {
  grid-column: span 3;
}

.decor-hero-only-grid {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #f8fafc;
}

.decor-hero-only-grid label span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.5;
}

.decor-image-row {
  display: grid;
  grid-template-columns: 116px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 12px;
  border: 1px dashed var(--border);
  border-radius: 14px;
  background: #fff;
}

.decor-image-preview,
.decor-button-icon,
.decor-product-thumb {
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #f8fafc;
  color: var(--muted);
  font-size: 12px;
}

.decor-image-preview {
  width: 116px;
  height: 86px;
}

.decor-hero-image-row {
  grid-template-columns: 160px minmax(0, 1fr);
}

.decor-hero-image-row .decor-image-preview {
  width: 160px;
  height: 96px;
}

.decor-notice-editor {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px dashed var(--border);
  border-radius: 14px;
  background: #fff;
}

.decor-notice-list {
  display: grid;
  gap: 10px;
}

.decor-notice-row {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) auto;
  gap: 10px;
  align-items: end;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #f8fafc;
}

.decor-notice-row .secondary-btn {
  height: 38px;
  white-space: nowrap;
}

.decor-image-preview img,
.decor-button-icon img,
.decor-product-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.decor-image-row span,
.decor-subhead span {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
}

.decor-button-editor {
  display: grid;
  gap: 10px;
}

.decor-subhead {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.decor-button-row {
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #fff;
}

.decor-button-summary {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  cursor: pointer;
  list-style: none;
}

.decor-button-summary::-webkit-details-marker {
  display: none;
}

.decor-button-summary strong,
.decor-button-summary span {
  display: block;
}

.decor-button-summary span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.decor-button-fields {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  align-items: end;
  margin-top: 12px;
}

.decor-module-nav-only .decor-hero-only-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.decor-module-nav-only .decor-button-fields {
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1.35fr) 92px 92px minmax(0, 1.1fr);
}

.decor-module-nav-only input[type="color"] {
  width: 100%;
  height: 38px;
  padding: 3px;
}

.decor-nav-button-editor {
  padding: 12px;
  border: 1px dashed var(--border);
  border-radius: 14px;
  background: #fff;
}

.decor-button-icon {
  width: 58px;
  height: 58px;
}

.decor-product-picker {
  display: grid;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #fff;
}

.decor-products {
  max-height: 220px;
  overflow: auto;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding-right: 4px;
}

.decor-product-option {
  display: grid;
  grid-template-columns: 18px 48px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  padding: 9px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fbfdfc;
}

.decor-product-option strong,
.decor-product-option em {
  display: block;
}

.decor-product-option em {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.decor-product-thumb {
  width: 48px;
  height: 48px;
}

.decor-preview-card {
  position: sticky;
  top: 18px;
  max-height: none;
  overflow: visible;
  display: block;
}

#decorLivePreview {
  min-height: 0;
  overflow: visible;
}

.decor-preview-phone {
  width: 100%;
  max-height: calc(100vh - 150px);
  overflow: auto;
  border: 1px solid var(--border);
  border-radius: 24px;
  background:
    radial-gradient(circle at 14px 14px, rgba(240, 92, 142, 0.18) 1px, transparent 2px) 0 0 / 22px 22px,
    linear-gradient(90deg, rgba(143, 177, 45, 0.08) 1px, transparent 1px) 0 0 / 18px 18px,
    linear-gradient(0deg, rgba(143, 177, 45, 0.08) 1px, transparent 1px) 0 0 / 18px 18px,
    #fff9cd;
  padding: 10px;
  box-shadow: inset 0 0 0 5px #fff;
}

.decor-preview-top {
  height: 36px;
  display: grid;
  place-items: center;
  color: #1f2937;
  font-weight: 800;
  font-size: 13px;
}

.decor-preview-body {
  display: grid;
  gap: 8px;
}

.decor-preview-module {
  min-height: 48px;
  padding: 10px;
  border: 2px solid #8fb12d;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.88);
}

.decor-preview-module strong,
.decor-preview-module span {
  display: block;
}

.decor-preview-module span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.decor-live-home {
  color: #354229;
  font-family: "Trebuchet MS", "PingFang SC", Arial, sans-serif;
}

.decor-live-hero,
.decor-live-window {
  overflow: hidden;
  border: 2px solid var(--preview-border, #8fb12d);
  border-radius: 10px;
  background: rgba(255, 255, 246, 0.92);
  box-shadow: 0 2px 0 rgba(143, 177, 45, 0.12);
}

.decor-live-hero {
  position: relative;
  min-height: 144px;
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) 92px;
  gap: 6px;
  padding: 13px 10px 22px;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.56) 1px, transparent 1px) 0 0 / 13px 13px,
    linear-gradient(0deg, rgba(255, 255, 255, 0.56) 1px, transparent 1px) 0 0 / 13px 13px,
    linear-gradient(135deg, #fff7d6, #f6ffd9 58%, #ffe8ef);
}

.decor-live-hero::before {
  content: "🎀 ☆ ♡";
  position: absolute;
  left: 8px;
  top: 5px;
  color: #e55d91;
  font-size: 12px;
  letter-spacing: 4px;
}

.decor-live-hero-copy {
  min-width: 0;
  align-self: center;
}

.decor-live-hero-copy span,
.decor-live-hero-copy strong,
.decor-live-hero-copy em,
.decor-live-hero-copy small {
  display: block;
}

.decor-live-hero-copy span {
  color: #78a018;
  font-size: 20px;
  font-weight: 900;
}

.decor-live-hero-copy strong {
  margin-top: 2px;
  color: #e75491;
  font-size: 28px;
  line-height: 1.05;
  font-weight: 950;
  text-shadow: 2px 2px 0 #7da52a;
}

.decor-live-hero-copy em {
  margin-top: 8px;
  color: #4f6818;
  font-size: 13px;
  font-style: normal;
  font-weight: 900;
}

.decor-live-hero-copy small {
  margin-top: 5px;
  color: #e75491;
  font-size: 12px;
  font-weight: 900;
}

.decor-live-hero-art {
  min-width: 0;
  min-height: 92px;
  display: grid;
  place-items: center;
  align-self: stretch;
  overflow: hidden;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.38);
}

.decor-live-hero-art img,
.decor-live-sticker img,
.decor-live-mood-art img,
.decor-live-nav-item img,
.decor-live-product-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.decor-live-hero-art span,
.decor-live-sticker > span:first-child,
.decor-live-mood-art > span:first-child,
.decor-live-nav-item div span,
.decor-live-product-img span {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  font-size: 28px;
}

.decor-live-hero-foot {
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 4px;
  border-top: 1px dashed rgba(143, 177, 45, 0.55);
  color: #7a9826;
  text-align: center;
  font-size: 11px;
  font-weight: 900;
}

.decor-live-titlebar {
  min-height: 30px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto 18px 18px 18px;
  align-items: center;
  gap: 4px;
  padding: 4px 6px;
  border-bottom: 1px solid var(--preview-border, #8fb12d);
  background: linear-gradient(180deg, #fbffb9, #bcea53);
}

.decor-live-titlebar strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 950;
}

.decor-live-titlebar span {
  color: #6f8e18;
  font-size: 11px;
  font-weight: 900;
}

.decor-live-titlebar em {
  width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  border: 1px solid #748f24;
  background: rgba(255, 255, 255, 0.72);
  color: #3f5315;
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
  line-height: 1;
}

.decor-live-notice {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 78px;
  gap: 6px;
  padding: 8px;
}

.decor-live-notice p,
.decor-live-messages p {
  display: flex;
  gap: 7px;
  align-items: center;
  margin: 0 0 5px;
  font-size: 11px;
  line-height: 1.35;
}

.decor-live-notice b,
.decor-live-messages b {
  min-width: 24px;
  height: 20px;
  display: inline-grid;
  place-items: center;
  border: 1px solid #f5a9c3;
  border-radius: 4px;
  background: #fff0f7;
  color: #e75491;
  font-size: 10px;
  font-weight: 950;
}

.decor-live-sticker {
  min-width: 0;
  display: grid;
  gap: 3px;
  align-content: center;
  justify-items: center;
  color: #7ca023;
  font-size: 10px;
  font-weight: 900;
  text-align: center;
}

.decor-live-sticker img,
.decor-live-sticker > span:first-child {
  width: 58px;
  height: 48px;
}

.decor-live-window > a {
  display: block;
  margin: -3px 8px 8px auto;
  color: #79a01e;
  text-align: right;
  font-size: 11px;
  font-weight: 900;
}

.decor-live-nav {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 7px;
  padding: 9px;
}

.decor-live-nav-item {
  min-width: 0;
  padding: 7px 4px;
  display: grid;
  justify-items: center;
  border: 1px solid rgba(143, 177, 45, 0.55);
  border-radius: 8px;
  background:
    linear-gradient(90deg, rgba(143, 177, 45, 0.08) 1px, transparent 1px) 0 0 / 10px 10px,
    linear-gradient(0deg, rgba(143, 177, 45, 0.08) 1px, transparent 1px) 0 0 / 10px 10px,
    #fffef0;
}

.decor-live-nav-item div {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  margin-bottom: 4px;
  overflow: hidden;
}

.decor-live-nav-item strong,
.decor-live-nav-item span {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.decor-live-nav-item strong {
  font-size: 12px;
  font-weight: 950;
}

.decor-live-nav-item span {
  color: #667055;
  font-size: 10px;
  font-weight: 800;
}

.decor-live-split {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.decor-live-half {
  min-height: 150px;
}

.decor-live-messages,
.decor-live-mood {
  padding: 8px;
}

.decor-live-messages p {
  align-items: flex-start;
  border-bottom: 1px dotted rgba(143, 177, 45, 0.35);
  padding-bottom: 5px;
}

.decor-live-messages span {
  min-width: 0;
  color: #4b5144;
}

.decor-live-mood strong {
  color: #ef5b98;
  font-size: 18px;
}

.decor-live-mood p {
  margin: 5px 0 8px;
  font-size: 11px;
  font-weight: 900;
}

.decor-live-mood code {
  display: inline-block;
  padding: 2px 5px;
  background: #202020;
  color: white;
  font-family: "Courier New", monospace;
  font-size: 15px;
  font-weight: 900;
  letter-spacing: 1px;
}

.decor-live-mood-art {
  min-height: 48px;
  margin-top: 8px;
  display: grid;
  grid-template-columns: 45px minmax(0, 1fr);
  gap: 6px;
  align-items: center;
  color: #7da022;
  font-size: 11px;
  font-weight: 900;
}

.decor-live-products {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 8px;
}

.decor-live-product {
  position: relative;
  min-width: 0;
  padding: 5px;
  border: 1px solid #f1a7bf;
  border-radius: 8px;
  background: #fffdf9;
}

.decor-live-product i {
  position: absolute;
  left: 5px;
  top: 5px;
  padding: 1px 5px;
  border-radius: 5px;
  background: #ef5b98;
  color: white;
  font-size: 9px;
  font-style: normal;
  font-weight: 900;
}

.decor-live-product-img {
  height: 68px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 6px;
  background:
    radial-gradient(circle at 22px 16px, rgba(255, 255, 255, 0.9) 0 4px, transparent 5px),
    linear-gradient(135deg, #fff1df, #f5ffe0 55%, #ffe6f0);
}

.decor-live-product strong,
.decor-live-product span {
  display: block;
}

.decor-live-product strong {
  margin-top: 5px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 10px;
}

.decor-live-product span {
  margin-top: 3px;
  color: #ef5b98;
  font-size: 12px;
  font-weight: 950;
}

.decor-live-plain {
  margin: 0;
  padding: 10px;
  color: #516238;
  font-size: 12px;
  line-height: 1.5;
}

.mp-preview-phone {
  border: 1px solid #d8e76f;
  border-radius: 28px;
  background:
    radial-gradient(circle at 13px 13px, rgba(229, 84, 145, 0.13) 1px, transparent 2px) 0 0 / 20px 20px,
    linear-gradient(90deg, rgba(143, 177, 45, 0.11) 1px, transparent 1px) 0 0 / 17px 17px,
    linear-gradient(0deg, rgba(143, 177, 45, 0.11) 1px, transparent 1px) 0 0 / 17px 17px,
    #fff8c9;
  box-shadow: inset 0 0 0 6px rgba(255, 255, 255, 0.86), 0 12px 30px rgba(143, 177, 45, 0.18);
}

.mp-preview-top {
  height: 42px;
  color: #111827;
  font-size: 14px;
  font-weight: 950;
}

.mp-preview-home {
  gap: 6px;
  color: #433b25;
  font-family: "Trebuchet MS", "PingFang SC", Arial, sans-serif;
}

.mp-preview-hero,
.mp-preview-window {
  border: 2px solid var(--preview-border, #8fb12d);
  background: rgba(255, 255, 244, 0.94);
  overflow: hidden;
}

.mp-preview-hero {
  position: relative;
  min-height: 164px;
  padding: 14px 10px;
  background:
    radial-gradient(circle at 10% 17%, #fff 0 5px, transparent 6px),
    radial-gradient(circle at 78% 24%, rgba(255, 255, 255, 0.9) 0 4px, transparent 5px),
    linear-gradient(90deg, rgba(150, 186, 45, 0.22) 1px, transparent 1px) 0 0 / 15px 15px,
    linear-gradient(0deg, rgba(150, 186, 45, 0.22) 1px, transparent 1px) 0 0 / 15px 15px,
    linear-gradient(135deg, #fff9bd, #fffef0 46%, #eaffce);
}

.mp-preview-hero::before {
  content: "";
  position: absolute;
  left: 13px;
  right: 13px;
  bottom: 29px;
  border-top: 1px dashed #e6cd42;
}

.mp-preview-sticker {
  position: absolute;
  z-index: 5;
  width: 28px;
  height: 28px;
  object-fit: contain;
}

.mp-preview-sticker.heart {
  left: 14px;
  top: 18px;
}

.mp-preview-sticker.star {
  left: 52px;
  top: 24px;
}

.mp-preview-sticker.bow {
  left: 8px;
  top: 4px;
}

.mp-preview-sticker.lemon {
  left: 12px;
  bottom: 34px;
  width: 42px;
  height: 42px;
}

.mp-preview-hero-copy {
  position: relative;
  z-index: 4;
  width: 65%;
  padding: 42px 0 0 18px;
}

.mp-preview-kicker {
  color: #e96a93;
  font-size: 22px;
  font-weight: 950;
  line-height: 1;
  text-shadow: 1px 1px 0 #fff;
}

.mp-preview-name {
  margin-top: 4px;
  color: #e96a93;
  font-size: 30px;
  font-weight: 950;
  line-height: 1.04;
  text-shadow: 2px 2px 0 #fff, 4px 4px 0 #8caf28;
}

.mp-preview-desc {
  margin-top: 5px;
  color: #517019;
  font-size: 13px;
  font-weight: 950;
}

.mp-preview-note {
  margin-top: 3px;
  color: #6f961e;
  font-size: 12px;
  font-weight: 950;
}

.mp-preview-hero-art {
  position: absolute;
  right: -4px;
  bottom: 0;
  z-index: 2;
  width: 42%;
  height: 100%;
  display: grid;
  place-items: center;
}

.mp-preview-hero-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center bottom;
}

.mp-preview-hero-art span {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  font-size: 54px;
}

.mp-preview-hero-foot {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 6px;
  z-index: 6;
  color: #86aa24;
  text-align: center;
  font-size: 10px;
  font-weight: 950;
}

.mp-preview-window {
  border-radius: 8px;
  box-shadow: 0 2px 0 rgba(143, 177, 45, 0.12);
}

.mp-preview-titlebar {
  min-height: 30px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto 19px 19px 19px;
  align-items: center;
  gap: 4px;
  padding: 4px 7px;
  border-bottom: 1px solid var(--preview-border, #8fb12d);
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.25) 1px, transparent 1px) 0 0 / 12px 12px,
    linear-gradient(180deg, #fff170, #f4d94e);
}

.mp-preview-titlebar.green {
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.24) 1px, transparent 1px) 0 0 / 12px 12px,
    linear-gradient(180deg, #dfff7a, #afe03a);
}

.mp-preview-titlebar strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #365715;
  font-size: 14px;
  font-weight: 950;
}

.mp-preview-titlebar span {
  color: #71921e;
  font-size: 11px;
  font-weight: 950;
}

.mp-preview-titlebar em {
  width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  border: 1px solid #547119;
  background: rgba(255, 255, 244, 0.85);
  color: #344b10;
  font-size: 11px;
  font-style: normal;
  font-weight: 950;
  line-height: 1;
}

.mp-preview-notice {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 88px;
  min-height: 98px;
  gap: 8px;
  padding: 10px;
  background: #fffef5;
}

.mp-preview-notice-list p,
.mp-preview-messages p {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 0;
  color: #554b2a;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.35;
}

.mp-preview-notice-list p + p {
  margin-top: 6px;
}

.mp-preview-notice-list b,
.mp-preview-messages b {
  flex: 0 0 24px;
  width: 24px;
  height: 21px;
  display: grid;
  place-items: center;
  border: 1px solid #ffabc8;
  border-radius: 4px;
  background: #fff7fb;
  color: #e85d91;
  font-size: 10px;
  font-weight: 950;
}

.mp-preview-notice-side {
  display: grid;
  justify-items: center;
  align-content: center;
  color: #6f961e;
  text-align: center;
  font-size: 10px;
  font-weight: 950;
}

.mp-preview-notice-side div {
  padding: 4px 6px;
  border: 1px dashed #8faf2f;
  border-radius: 8px;
  background: #fffef7;
  color: #e85d91;
}

.mp-preview-notice-side img,
.mp-preview-notice-side > span {
  width: 56px;
  height: 46px;
  object-fit: contain;
}

.mp-preview-notice-side a,
.mp-preview-window > a {
  color: #6f961e;
  text-align: right;
  font-size: 11px;
  font-weight: 950;
  text-decoration: none;
}

.mp-preview-nav {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 7px;
  padding: 9px;
  background: #fffef5;
}

.mp-preview-nav-item {
  min-width: 0;
  min-height: 68px;
  display: grid;
  justify-items: center;
  align-content: center;
  padding: 6px 3px;
  border: 1px solid #aecb43;
  border-radius: 7px;
  background: #fffff0;
  box-shadow: none;
}

.mp-preview-nav-item div {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  margin-bottom: 4px;
  border: 1px dotted #7ba51f;
  border-radius: 7px;
  background: #fffef2;
  overflow: hidden;
}

.mp-preview-nav-item img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.mp-preview-nav-item div span {
  font-size: 17px;
}

.mp-preview-nav-item strong {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mp-preview-nav-item strong {
  color: #332b1d;
  font-size: 12px;
  font-weight: 950;
}

.mp-preview-notice-scroll {
  display: block;
  min-height: 102px;
  max-height: 102px;
  padding: 6px 8px;
  overflow: hidden;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

.mp-preview-notice-track {
  display: flex;
  flex-direction: column;
}

.mp-preview-notice-track.is-scrolling {
  animation: mpNoticeTicker var(--notice-duration, 8s) linear infinite;
}

.mp-preview-notice-page {
  flex: none;
  display: flex;
  flex-direction: column;
  justify-content: center;
  height: 90px;
}

.mp-preview-notice-scroll p {
  flex: none;
  display: flex;
  align-items: center;
  height: 30px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #57472b;
}

.mp-preview-notice-scroll p + p {
  margin-top: 0;
}

.mp-preview-notice-scroll b {
  flex: none;
  width: 25px;
  height: 21px;
  margin-right: 8px;
  border: 1px solid #f3a5c2;
  border-radius: 5px;
  background: #fff4fa;
  color: #e95a95;
  font-size: 10px;
  line-height: 19px;
  text-align: center;
}

.mp-preview-notice-scroll span {
  flex: 1;
  min-width: 0;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
}

.mp-preview-notice-scroll em {
  flex: none;
  max-width: 64px;
  margin-left: 7px;
  overflow: hidden;
  color: #7aa51f;
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@keyframes mpNoticeTicker {
  0%, 18% {
    transform: translateY(0);
  }
  100% {
    transform: translateY(calc(var(--notice-page-count, 1) * -90px));
  }
}

.mp-preview-nav-item > span {
  color: #5b5130;
  font-size: 10px;
  font-weight: 850;
}

.mp-preview-split {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.mp-preview-half {
  min-height: 176px;
}

.mp-preview-messages {
  padding: 8px 8px 2px;
}

.mp-preview-messages p {
  align-items: center;
  min-height: 31px;
  padding: 4px 0;
  border-bottom: 1px dotted rgba(143, 177, 45, 0.34);
}

.mp-preview-messages span {
  flex: 1;
  min-width: 0;
  overflow: hidden;
}

.mp-preview-messages span strong {
  display: block;
  color: #4b4025;
  font-size: 11px;
}

.mp-preview-messages em {
  flex: 0 0 40px;
  color: #7b7350;
  font-size: 9px;
  font-style: normal;
  text-align: right;
}

.mp-preview-mood {
  position: relative;
  min-height: 143px;
  padding: 10px;
  overflow: hidden;
  background: #fffef5;
}

.mp-preview-mood > strong {
  color: #8ab72c;
  font-size: 21px;
}

.mp-preview-mood p {
  margin: 4px 0 7px;
  color: #433b25;
  font-size: 11px;
  font-weight: 900;
}

.mp-preview-mood code {
  display: inline-block;
  padding: 2px 5px;
  background: #33351e;
  color: white;
  font-family: "Courier New", monospace;
  font-size: 15px;
  font-weight: 950;
  letter-spacing: 1px;
}

.mp-preview-mood-art {
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 8px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  min-height: 54px;
  border-top: 1px dashed #d7e778;
}

.mp-preview-mood-art img,
.mp-preview-mood-art > span:first-child {
  width: 58px;
  height: 42px;
  object-fit: contain;
}

.mp-preview-mood-art span:last-child {
  margin-left: 7px;
  padding: 5px 7px;
  border: 1px dashed #9fbd36;
  border-radius: 9px;
  background: #fffef7;
  color: #7aa51f;
  font-size: 10px;
  font-weight: 950;
  transform: rotate(5deg);
}

.mp-preview-products {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 7px;
  padding: 8px;
  background: #fffef5;
}

.mp-preview-product {
  position: relative;
  min-width: 0;
  padding: 5px;
  border: 1px solid #aac84a;
  border-radius: 7px;
  background: #fffef3;
  box-shadow: inset 0 0 0 2px rgba(248, 255, 203, 0.7);
}

.mp-preview-product i {
  position: absolute;
  left: 4px;
  top: 4px;
  padding: 1px 5px;
  border-radius: 5px;
  background: #8ab72c;
  color: #fff;
  font-size: 8px;
  font-style: normal;
  font-weight: 950;
}

.mp-preview-product-img {
  height: 58px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid #c9dc63;
  border-radius: 6px;
  background:
    radial-gradient(circle at 22px 16px, rgba(255, 255, 255, 0.92) 0 4px, transparent 5px),
    linear-gradient(135deg, #fffbd2, #f4ffd7 58%, #fff0c7);
}

.mp-preview-product-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.mp-preview-product-img span {
  font-size: 26px;
}

.mp-preview-product strong,
.mp-preview-product span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mp-preview-product strong {
  margin-top: 5px;
  color: #433b25;
  font-size: 10px;
  font-weight: 900;
}

.mp-preview-product span {
  margin-top: 2px;
  color: #e85d91;
  font-size: 12px;
  font-weight: 950;
}

.mp-preview-plain {
  margin: 0;
  padding: 10px;
  color: #516238;
  font-size: 12px;
  line-height: 1.5;
}

.mp-preview-fruit {
  padding: 6px 8px;
  border-top: 1px solid #d8e96c;
  border-bottom: 1px solid #d8e96c;
  background:
    linear-gradient(90deg, rgba(147, 185, 59, 0.22) 1px, transparent 1px) 0 0 / 12px 12px,
    #f2ffba;
  color: #e85d91;
  text-align: center;
  font-size: 13px;
}

/* The live preview uses the same 375px logical canvas as the WeChat miniapp. */
#decorLivePreview {
  min-height: 0;
  overflow: visible;
}

.decor-preview-fit {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  min-height: min(812px, calc(100vh - 122px));
  overflow: visible;
}

.mp-preview-phone {
  width: 375px;
  height: min(812px, calc(100vh - 122px));
  min-height: 640px;
  max-width: 100%;
  margin: 0 auto;
  padding: 0;
  flex: 0 0 375px;
  display: grid;
  grid-template-rows: 86px minmax(0, 1fr) 70px;
  overflow: hidden;
  transform: none !important;
  transform-origin: top center;
  border-color: #dce96d;
  border-radius: 22px;
  background: var(--page-bg, #fff8c9);
  box-shadow: 0 18px 38px rgba(143, 177, 45, 0.18);
}

.mp-preview-phone::-webkit-scrollbar {
  width: 0;
  height: 0;
}

.mp-preview-top {
  position: relative;
  height: 86px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 0 14px 14px;
  background: var(--page-bg, #fff8c9);
  color: #111827;
  font-size: 15px;
  font-weight: 950;
}

.mp-preview-top::before {
  content: "15:22";
  position: absolute;
  left: 38px;
  top: 25px;
  color: #111827;
  font-size: 14px;
  font-weight: 900;
}

.mp-preview-top::after {
  content: "▮▮▮  WiFi  36";
  position: absolute;
  right: 40px;
  top: 26px;
  color: #111827;
  font-size: 11px;
  font-weight: 900;
}

.mp-preview-top i {
  position: absolute;
  right: 13px;
  bottom: 9px;
  width: 76px;
  height: 32px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(20, 20, 20, 0.08);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.78);
  color: #111827;
  font-size: 17px;
  font-style: normal;
  letter-spacing: 2px;
}

.mp-preview-home {
  min-height: 0;
  align-content: start;
  grid-auto-rows: max-content;
  overflow-x: hidden;
  overflow-y: auto;
  gap: 5px;
  padding: 4px 5px 11px;
  background-color: var(--page-bg, #fff8c9);
  background-image: url("/assets/peipei-retro/bg-tile.svg");
  background-size: 36px 36px;
}

.mp-preview-home::-webkit-scrollbar {
  width: 0;
  height: 0;
}

.mp-preview-tabbar {
  position: relative;
  z-index: 3;
  height: 70px;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  align-items: center;
  padding: 5px 8px 7px;
  border-top: 1px solid rgba(143, 177, 45, 0.28);
  border-radius: 20px 20px 0 0;
  background:
    linear-gradient(180deg, rgba(255, 253, 244, 0.96), rgba(255, 251, 230, 0.98)),
    url("/assets/peipei-retro/bg-tile.svg");
  box-shadow: 0 -5px 18px rgba(143, 177, 45, 0.14);
}

.mp-preview-tab {
  min-width: 0;
  display: grid;
  justify-items: center;
  gap: 2px;
  color: #7a7352;
  font-size: 10px;
  font-weight: 800;
  line-height: 1.1;
}

.mp-preview-tab img {
  width: 25px;
  height: 25px;
  display: block;
  object-fit: contain;
}

.mp-preview-tab.active {
  color: #7aa51f;
  font-weight: 950;
}

.mp-mall-preview {
  background-color: var(--page-bg, #fff8c9);
}

.mp-mall-hero {
  position: relative;
  min-height: 118px;
  padding: 12px;
  overflow: hidden;
  border: 2px solid var(--preview-border, #8fb12d);
  border-radius: 4px;
  background-color: #fffbd4;
  background-image: url("/assets/peipei-retro/window-bg.svg");
  background-size: 60px 60px;
}

.mp-mall-hero > div:first-child {
  position: relative;
  z-index: 2;
  max-width: 218px;
}

.mp-mall-hero strong,
.mp-mall-hero span,
.mp-mall-hero em,
.mp-mall-hero b {
  display: block;
}

.mp-mall-hero strong {
  color: #7aa51f;
  font-size: 27px;
  font-weight: 950;
  line-height: 1.05;
  text-shadow: 2px 2px 0 #ffffff, 3px 3px 0 #f0d34a;
}

.mp-mall-hero span {
  margin-top: 5px;
  color: #433b25;
  font-size: 13px;
  font-weight: 900;
}

.mp-mall-hero em {
  margin-top: 5px;
  color: #e85d91;
  font-size: 12px;
  font-style: normal;
  font-weight: 950;
}

.mp-mall-hero b {
  width: max-content;
  max-width: 180px;
  margin-top: 6px;
  padding: 3px 9px;
  border: 1px dashed #9fbd36;
  border-radius: 999px;
  background: rgba(255, 255, 244, 0.85);
  color: #6f961e;
  font-size: 10px;
}

.mp-mall-hero-art {
  position: absolute;
  right: -2px;
  bottom: -2px;
  z-index: 1;
  width: 140px;
  height: 118px;
  display: grid;
  place-items: center;
}

.mp-mall-hero-art img,
.mp-mall-hero-art span {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.mp-mall-search {
  margin: 8px;
  min-height: 38px;
  display: flex;
  align-items: center;
  padding: 0 13px;
  border: 1px solid #a9c749;
  border-radius: 999px;
  background: #fffef2;
  color: #8a7e57;
  font-size: 12px;
  font-weight: 850;
}

.mp-mall-shell {
  min-height: 0;
  display: grid;
  grid-template-columns: 66px minmax(0, 1fr);
  gap: 6px;
}

.mp-mall-categories {
  display: grid;
  align-content: start;
  gap: 5px;
}

.mp-mall-categories span {
  min-height: 34px;
  display: grid;
  place-items: center;
  padding: 0 4px;
  overflow: hidden;
  border: 1px solid var(--preview-border, #8fb12d);
  border-radius: 7px;
  background: #fffef4;
  color: #5f652a;
  text-align: center;
  font-size: 10px;
  font-weight: 900;
  line-height: 1.12;
}

.mp-mall-categories span.active {
  background-image: url("/assets/peipei-retro/button-pink.svg");
  background-size: 100% 100%;
  color: #ffffff;
  border-color: #e776a4;
}

.mp-mall-goods {
  min-width: 0;
}

.mp-mall-products {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  padding: 7px;
  background: #fffef5;
}

.mp-mall-product {
  position: relative;
  min-width: 0;
  min-height: 128px;
  padding: 5px;
  border: 1px solid #a7be35;
  border-radius: 7px;
  background-image: url("/assets/peipei-retro/card-paper.svg");
  background-size: 100% 100%;
}

.mp-mall-product div {
  height: 62px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid #d5e879;
  border-radius: 5px;
  background: #fffbd8;
}

.mp-mall-product div img,
.mp-mall-product div span {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.mp-mall-product strong,
.mp-mall-product span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mp-mall-product strong {
  margin-top: 5px;
  color: #433b25;
  font-size: 10px;
  font-weight: 950;
}

.mp-mall-product span {
  margin-top: 4px;
  color: #e85d91;
  font-size: 12px;
  font-weight: 950;
}

.mp-mall-product button {
  position: absolute;
  right: 5px;
  bottom: 5px;
  width: 28px;
  height: 20px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 6px;
  background-image: url("/assets/peipei-retro/button-pink.svg");
  background-size: 100% 100%;
  color: #fff;
  font-size: 11px;
}

.mp-mall-cart {
  position: sticky;
  left: 6px;
  right: 6px;
  bottom: 5px;
  z-index: 5;
  min-height: 48px;
  display: grid;
  grid-template-columns: 36px auto 1fr 88px;
  align-items: center;
  gap: 6px;
  margin: 4px 4px 0;
  padding: 6px 8px;
  border: 2px solid var(--preview-border, #8fb12d);
  border-radius: 999px;
  background-color: rgba(255, 254, 244, 0.96);
  background-image: url("/assets/peipei-retro/window-bg.svg");
  background-size: 60px 60px;
}

.mp-mall-cart div {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
}

.mp-mall-cart div img,
.mp-mall-cart div span {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.mp-mall-cart strong {
  color: #e85d91;
  font-size: 17px;
  font-weight: 950;
}

.mp-mall-cart span {
  color: #7a7352;
  font-size: 10px;
  font-weight: 800;
}

.mp-mall-cart button {
  min-height: 34px;
  border: 0;
  border-radius: 999px;
  background-image: url("/assets/peipei-retro/button-green.svg");
  background-size: 100% 100%;
  color: #ffffff;
  font-size: 13px;
  font-weight: 950;
}

.mp-detail-cover,
.mp-detail-info,
.mp-detail-notice,
.mp-ichiban-hero,
.mp-ichiban-ribbon,
.mp-ichiban-events,
.mp-ichiban-detail-hero,
.mp-prize-list,
.mp-special-rules,
.mp-box-login,
.mp-box-summary,
.mp-mine-profile,
.mp-mine-orders,
.mp-mine-menu,
.mp-rules-head,
.mp-rule-card {
  min-width: 0;
  background-image: url("/assets/peipei-retro/window-bg.svg");
  background-size: 60px 60px;
}

.mp-detail-image {
  height: 188px;
  margin: 8px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid #cbdc68;
  border-radius: 8px;
  background-image: url("/assets/peipei-retro/card-paper.svg");
  background-size: 100% 100%;
}

.mp-detail-image img,
.mp-detail-image span {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.mp-detail-info,
.mp-detail-notice {
  color: #443b23;
}

.mp-detail-info > strong,
.mp-detail-info > span,
.mp-detail-info > p,
.mp-detail-notice > p {
  display: block;
  margin: 8px 10px;
}

.mp-detail-info > strong {
  font-size: 15px;
  font-weight: 950;
}

.mp-detail-info > span {
  color: #e85d91;
  font-size: 20px;
  font-weight: 950;
}

.mp-detail-info > p,
.mp-detail-notice > p {
  color: #6a623e;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.5;
}

.mp-detail-quantity {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 8px 10px;
  padding-top: 8px;
  border-top: 1px dashed #cbdc68;
}

.mp-detail-quantity > span {
  display: inline-flex;
  overflow: hidden;
  border: 1px solid #c4d85c;
  border-radius: 999px;
  background: #fffef4;
}

.mp-detail-quantity i,
.mp-detail-quantity em {
  display: grid;
  width: 28px;
  height: 24px;
  place-items: center;
  color: #6f961e;
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
}

.mp-detail-quantity em {
  color: #443b23;
  border-right: 1px dashed #cbdc68;
  border-left: 1px dashed #cbdc68;
}

.mp-detail-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 4px 0 2px;
  padding: 8px;
  border: 2px solid var(--preview-border, #8fb12d);
  border-radius: 12px;
  background: rgba(255, 254, 244, 0.96);
}

.mp-detail-actions button,
.mp-box-login button {
  min-height: 34px;
  border: 0;
  border-radius: 999px;
  background-image: url("/assets/peipei-retro/button-green.svg");
  background-size: 100% 100%;
  color: #fff;
  font-size: 12px;
  font-weight: 950;
}

.mp-detail-actions button:first-child {
  background-image: url("/assets/peipei-retro/card-paper.svg");
  border: 1px solid #a7be35;
  color: #66851b;
}

.mp-ichiban-hero > div:not(.mp-preview-titlebar),
.mp-ichiban-detail-hero > div:not(.mp-preview-titlebar),
.mp-box-summary > div:not(.mp-preview-titlebar),
.mp-mine-profile > div:not(.mp-preview-titlebar),
.mp-rules-head > div:not(.mp-preview-titlebar) {
  position: relative;
  padding: 10px;
}

.mp-ichiban-hero > div:not(.mp-preview-titlebar) {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
}

.mp-ichiban-hero > div:not(.mp-preview-titlebar) > div,
.mp-ichiban-detail-hero > div:not(.mp-preview-titlebar),
.mp-rules-head > div:not(.mp-preview-titlebar) > div {
  display: grid;
  place-items: center;
  overflow: hidden;
}

.mp-ichiban-hero img,
.mp-ichiban-hero > div:not(.mp-preview-titlebar) > div span,
.mp-ichiban-detail-hero img,
.mp-ichiban-detail-hero > div:not(.mp-preview-titlebar) span,
.mp-rules-head img,
.mp-rules-head > div:not(.mp-preview-titlebar) > div span {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.mp-ichiban-hero strong,
.mp-ichiban-detail-hero strong,
.mp-rules-head strong {
  display: block;
  color: #7aa51f;
  font-size: 17px;
  font-weight: 950;
}

.mp-ichiban-hero p,
.mp-ichiban-detail-hero p,
.mp-special-rules p,
.mp-rule-card p,
.mp-rules-head p {
  margin: 6px 0 0;
  color: #5d5732;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.45;
}

.mp-ichiban-hero span {
  color: #e85d91;
  font-size: 11px;
  font-weight: 950;
}

.mp-ichiban-events article,
.mp-box-items article {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  margin: 8px;
  padding: 8px;
  border: 1px solid #cbdc68;
  border-radius: 9px;
  background-image: url("/assets/peipei-retro/card-paper.svg");
  background-size: 100% 100%;
}

.mp-ichiban-events article div,
.mp-box-items article div {
  width: 50px;
  height: 50px;
  display: grid;
  place-items: center;
  border: 1px dashed #b9cf55;
  border-radius: 8px;
  background: #fffbd4;
}

.mp-ichiban-events article strong,
.mp-box-items article strong {
  display: block;
  overflow: hidden;
  color: #433b25;
  font-size: 12px;
  font-weight: 950;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mp-ichiban-events article span,
.mp-box-items article span {
  display: block;
  margin-top: 4px;
  color: #7a7352;
  font-size: 10px;
  font-weight: 800;
}

.mp-ichiban-hero > div:not(.mp-preview-titlebar) {
  min-height: 148px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 122px;
  gap: 7px;
  align-items: stretch;
  overflow: hidden;
  background-image: url("/assets/peipei-retro/window-bg.svg");
  background-size: 60px 60px;
}

.mp-ichiban-hero > div:not(.mp-preview-titlebar)::after {
  content: "";
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 20px;
  border-bottom: 1px dashed rgba(143, 177, 45, 0.55);
}

.mp-ichiban-hero > div:not(.mp-preview-titlebar) > div {
  position: relative;
  z-index: 2;
  display: block;
  overflow: visible;
  padding: 22px 0 18px 8px;
}

.mp-ichiban-hero > div:not(.mp-preview-titlebar) > figure {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: end center;
  min-width: 0;
  margin: 0;
  overflow: hidden;
}

.mp-ichiban-hero > div:not(.mp-preview-titlebar) > figure img,
.mp-ichiban-hero > div:not(.mp-preview-titlebar) > figure span {
  width: 126px;
  height: 126px;
  object-fit: contain;
}

.mp-ichiban-sticker {
  position: absolute;
  z-index: 4;
  object-fit: contain;
}

.mp-ichiban-sticker.heart {
  left: 13px;
  top: 14px;
  width: 28px;
  height: 28px;
}

.mp-ichiban-sticker.star {
  left: 57px;
  top: 20px;
  width: 24px;
  height: 24px;
}

.mp-ichiban-sticker.bow {
  right: 115px;
  top: 8px;
  width: 34px;
  height: 28px;
}

.mp-ichiban-hero b {
  display: block;
  color: #6f961e;
  font-size: 16px;
  font-weight: 950;
  line-height: 1;
  text-shadow: 1px 1px 0 #ffffff;
}

.mp-ichiban-hero strong {
  margin-top: 6px;
  color: #e85d91;
  font-size: 28px;
  line-height: 1.04;
  text-shadow: 1px 1px 0 #ffffff, 3px 3px 0 #84ad25;
}

.mp-ichiban-hero p {
  display: inline-block;
  max-width: 160px;
  margin-top: 8px;
  padding: 4px 8px;
  border: 1px dashed #9fbd36;
  border-radius: 999px;
  background: rgba(255, 255, 244, 0.9);
  color: #526819;
  font-size: 10px;
  font-weight: 900;
  line-height: 1.25;
}

.mp-ichiban-hero small {
  position: absolute;
  z-index: 3;
  left: 14px;
  right: 14px;
  bottom: 6px;
  color: #6f961e;
  text-align: center;
  font-size: 11px;
  font-weight: 950;
  text-shadow: 1px 1px 0 #ffffff;
}

.mp-ichiban-ribbon {
  position: relative;
  min-height: 48px;
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto 24px;
  gap: 6px;
  align-items: center;
  padding: 6px 8px;
  overflow: hidden;
  border: 2px solid var(--preview-border, #8fb12d);
  border-radius: 10px;
  background-image: url("/assets/peipei-retro/card-paper.svg");
  background-size: 100% 100%;
  box-shadow: 2px 2px 0 rgba(143, 177, 45, 0.15);
}

.mp-ichiban-ribbon::before {
  content: "";
  position: absolute;
  left: 8px;
  right: 8px;
  top: 5px;
  border-top: 1px dashed rgba(143, 177, 45, 0.42);
}

.mp-ichiban-ribbon > img,
.mp-ichiban-ribbon > span {
  position: relative;
  z-index: 1;
  width: 28px;
  height: 28px;
  object-fit: contain;
}

.mp-ichiban-ribbon > div {
  position: relative;
  z-index: 1;
  min-width: 0;
}

.mp-ichiban-ribbon strong,
.mp-ichiban-ribbon span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mp-ichiban-ribbon strong {
  color: #6f961e;
  font-size: 11px;
  font-weight: 950;
}

.mp-ichiban-ribbon span {
  margin-top: 2px;
  color: #6f6040;
  font-size: 9px;
  font-weight: 850;
}

.mp-ichiban-ribbon p {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 3px;
  max-width: 96px;
  margin: 0;
}

.mp-ichiban-ribbon em {
  padding: 2px 5px;
  border: 1px solid #d5c74e;
  border-radius: 999px;
  background: #fffef4;
  color: #e85d91;
  font-size: 8px;
  font-style: normal;
  font-weight: 900;
  line-height: 1;
  white-space: nowrap;
}

.mp-ichiban-ribbon > img:last-child {
  width: 22px;
  height: 22px;
}

.mp-ichiban-events article {
  grid-template-columns: 62px minmax(0, 1fr);
  gap: 7px;
  min-height: 90px;
  margin: 7px;
  padding: 7px;
  border-radius: 8px;
  box-shadow: 2px 2px 0 rgba(143, 177, 45, 0.11);
}

.mp-ichiban-events article.pink {
  border-color: #ef9fbd;
}

.mp-ichiban-events article.cherry {
  border-color: #d6b858;
}

.mp-ichiban-events article div {
  width: 58px;
  height: 58px;
}

.mp-ichiban-events article div img,
.mp-ichiban-events article div span {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.mp-ichiban-events main {
  min-width: 0;
}

.mp-ichiban-events header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 5px;
  align-items: start;
}

.mp-ichiban-events article header strong {
  font-size: 12px;
}

.mp-ichiban-events header b {
  padding: 3px 5px;
  border-radius: 999px;
  background: #fff3cf;
  color: #e85d91;
  font-size: 9px;
  font-weight: 950;
  line-height: 1;
  white-space: nowrap;
}

.mp-ichiban-events article main > span {
  height: 28px;
  overflow: hidden;
  margin-top: 4px;
  line-height: 1.35;
}

.mp-ichiban-events article i {
  display: block;
  height: 8px;
  margin-top: 5px;
  overflow: hidden;
  border: 1px solid #b7cc55;
  border-radius: 999px;
  background: #fff9ce;
}

.mp-ichiban-events article i em {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #bfe84f, #f4df54, #ff91b8);
}

.mp-ichiban-events footer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 48px;
  gap: 5px;
  align-items: end;
  margin-top: 5px;
}

.mp-ichiban-events footer p {
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
  margin: 0;
}

.mp-ichiban-events footer small {
  padding: 2px 5px;
  border: 1px solid #d6ca57;
  border-radius: 999px;
  background: #ffffdf;
  color: #6f961e;
  font-size: 8px;
  font-weight: 900;
  line-height: 1;
}

.mp-ichiban-events footer button {
  min-height: 22px;
  border: 0;
  border-radius: 999px;
  background-image: url("/assets/peipei-retro/button-green.svg");
  background-size: 100% 100%;
  color: #fff;
  font-size: 9px;
  font-weight: 950;
}

.mp-prize-list p {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  margin: 8px;
  padding-bottom: 8px;
  border-bottom: 1px dashed #cbdc68;
}

.mp-prize-list p:last-child {
  border-bottom: 0;
}

.mp-prize-list b,
.mp-rule-card b {
  color: #e85d91;
  font-weight: 950;
}

.mp-prize-list span,
.mp-prize-list em {
  color: #443b23;
  font-size: 11px;
  font-style: normal;
  font-weight: 850;
}

.mp-box-login strong,
.mp-box-login p {
  display: block;
  margin: 8px 10px;
  color: #443b23;
  font-size: 12px;
  font-weight: 900;
}

.mp-box-login p {
  color: #7a7352;
  font-size: 10px;
}

.mp-box-login > div:last-child {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 80px;
  gap: 7px;
  padding: 0 10px;
}

.mp-box-login span {
  display: flex;
  align-items: center;
  min-width: 0;
  padding: 0 9px;
  border: 1px solid #cbdc68;
  border-radius: 999px;
  background: #fffef4;
  color: #8a7e57;
  font-size: 10px;
  font-weight: 850;
}

.mp-box-user-chip {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  margin: 8px;
  padding: 7px;
  border: 1px dashed #cbdc68;
  border-radius: 8px;
  background: rgba(255, 255, 246, .76);
}

.mp-box-user-chip img,
.mp-box-user-chip > span {
  width: 38px;
  height: 38px;
  object-fit: contain;
}

.mp-box-user-chip p {
  margin: 0;
}

.mp-box-user-chip strong,
.mp-box-user-chip span {
  display: block;
  color: #443b23;
  font-size: 13px;
  font-weight: 950;
}

.mp-box-user-chip span {
  margin-top: 4px;
  color: #7a7352;
  font-size: 10px;
}

.mp-box-stats,
.mp-box-filters,
.mp-mine-assets,
.mp-mine-orders > div {
  display: grid;
  gap: 6px;
}

.mp-box-stats,
.mp-box-filters,
.mp-mine-assets {
  grid-template-columns: repeat(4, 1fr);
  padding: 8px;
}

.mp-box-stats b,
.mp-box-filters span,
.mp-mine-assets span {
  display: grid;
  place-items: center;
  min-height: 34px;
  border: 1px solid #cbdc68;
  border-radius: 8px;
  background: #fffef4;
  color: #7aa51f;
  font-size: 12px;
  font-weight: 950;
}

.mp-box-stats b {
  min-height: 38px;
  font-size: 10px;
  line-height: 1.15;
  text-align: center;
}

.mp-box-filters {
  grid-template-columns: repeat(5, max-content);
  overflow: hidden;
  padding: 6px 0;
}

.mp-box-filters span {
  min-width: 56px;
  min-height: 30px;
  font-size: 10px;
}

.mp-box-filters span.active {
  background-image: url("/assets/peipei-retro/button-green.svg");
  background-size: 100% 100%;
  color: #fff;
}

.mp-box-notice {
  margin: 0 0 8px;
  padding: 7px 8px;
  border: 1px dashed #cbdc68;
  border-radius: 8px;
  background: rgba(255, 255, 244, .82);
  color: #61751f;
  font-size: 10px;
  font-weight: 850;
}

.mp-box-items {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 8px;
}

.mp-box-items article {
  position: relative;
  min-height: 154px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 4px;
  margin: 0;
  padding: 7px;
  border: 1px solid #cbdc68;
  border-radius: 9px;
  background-image: url("/assets/peipei-retro/card-paper.svg");
  background-size: 100% 100%;
}

.mp-box-items article div {
  min-height: 70px;
  display: grid;
  place-items: center;
  border: 1px dashed #cbdc68;
  border-radius: 8px;
  background: #fffbd0;
  font-size: 38px;
}

.mp-box-items article strong {
  overflow: hidden;
  color: #443b23;
  font-size: 11px;
  font-weight: 950;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mp-box-items article span {
  justify-self: start;
  padding: 3px 7px;
  border: 1px solid #a7be35;
  border-radius: 999px;
  color: #66851b;
  font-size: 9px;
  font-weight: 900;
}

.mp-box-items article.safe {
  background-color: #f5ffd8;
}

.mp-box-items article em {
  position: absolute;
  right: 8px;
  top: 76px;
  padding: 2px 6px;
  border: 1px solid #e85d91;
  border-radius: 999px;
  background: #fff7c9;
  color: #e85d91;
  font-size: 10px;
  font-style: normal;
  font-weight: 950;
}

.mp-box-items article i {
  position: absolute;
  left: 8px;
  top: 76px;
  padding: 2px 6px;
  border: 1px solid #8dac2b;
  border-radius: 999px;
  background: #fffef4;
  color: #61751f;
  font-size: 9px;
  font-style: normal;
  font-weight: 950;
}

.mp-box-actions {
  grid-template-columns: minmax(0, 1fr) 86px 96px;
  align-items: center;
}

.mp-box-actions span {
  color: #443b23;
  font-size: 11px;
  font-weight: 950;
}

.mp-mine-profile > div:not(.mp-preview-titlebar) {
  display: grid;
  grid-template-columns: 62px minmax(0, 1fr) 54px;
  gap: 8px;
  align-items: center;
}

.mp-mine-profile b {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border: 2px solid #fff;
  border-radius: 12px;
  background: #fffef4;
  color: #7aa51f;
  font-size: 22px;
  font-weight: 950;
}

.mp-mine-profile strong,
.mp-mine-profile span,
.mp-mine-profile em {
  grid-column: 2;
  display: block;
}

.mp-mine-profile strong {
  color: #7aa51f;
  font-size: 17px;
  font-weight: 950;
}

.mp-mine-profile span,
.mp-mine-profile em {
  color: #443b23;
  font-size: 10px;
  font-style: normal;
  font-weight: 850;
}

.mp-mine-profile em {
  width: max-content;
  margin-top: 3px;
  padding: 2px 8px;
  border: 1px solid #cbdc68;
  border-radius: 999px;
  background: #fffef4;
  color: #7aa51f;
}

.mp-mine-profile img,
.mp-mine-profile > div:not(.mp-preview-titlebar) > span:last-child {
  grid-column: 3;
  grid-row: 1 / 4;
  width: 50px;
  height: 50px;
  object-fit: contain;
}

.mp-mine-assets {
  grid-template-columns: repeat(4, 1fr);
  padding: 0;
}

.mp-mine-assets span {
  min-height: 54px;
  font-size: 10px;
}

.mp-mine-assets b {
  display: block;
  color: #e85d91;
  font-size: 15px;
}

.mp-mine-orders > div {
  grid-template-columns: repeat(4, 1fr);
  padding: 8px;
}

.mp-mine-orders span {
  display: grid;
  justify-items: center;
  gap: 4px;
  min-height: 48px;
  border: 1px dashed #cbdc68;
  border-radius: 8px;
  background: #fffef4;
  font-size: 16px;
}

.mp-mine-orders b {
  color: #443b23;
  font-size: 10px;
}

.mp-mine-menu p {
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  margin: 0 10px;
  padding: 8px 0;
  border-bottom: 1px dashed #cbdc68;
}

.mp-mine-menu p:last-child {
  border-bottom: 0;
}

.mp-mine-menu span,
.mp-mine-menu em {
  color: #443b23;
  font-size: 12px;
  font-style: normal;
  font-weight: 950;
}

.mp-rules-head > div:not(.mp-preview-titlebar) {
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
}

.mp-rules-head > div:not(.mp-preview-titlebar) > div {
  width: 62px;
  height: 62px;
}

.mp-rule-card p {
  margin: 8px 10px;
}

.mp-rule-card p:last-child {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.mp-rule-card p:last-child b {
  padding: 4px 8px;
  border: 1px solid #cbdc68;
  border-radius: 999px;
  background: #fffef4;
}

.mp-preview-hero {
  min-height: 159px;
  margin-bottom: 7px;
  padding: 11px 9px 13px;
  border-width: 2px;
  border-radius: 2px;
  background-color: #fffbd4;
  background-image: url("/assets/peipei-retro/window-bg.svg");
  background-size: 60px 60px;
  box-shadow: inset 0 0 0 2px rgba(255, 250, 196, 0.7);
}

.mp-preview-hero::before {
  left: 11px;
  right: 11px;
  bottom: 24px;
  border-top: 2px dashed #f2d64a;
  border-bottom: 2px dotted #9fbd39;
  height: 9px;
}

.mp-preview-hero-copy {
  width: 210px;
  min-height: 107px;
  padding: 11px 12px;
  border: 2px dashed #e8d85b;
  border-radius: 20px 9px 20px 9px;
  background: rgba(255, 255, 246, 0.92);
}

.mp-preview-kicker {
  color: #648719;
  font-size: 21px;
}

.mp-preview-name {
  margin-top: 3px;
  color: #ea5b98;
  font-size: 29px;
  text-shadow: 2px 2px 0 #ffffff, 3px 3px 0 #85ad22;
}

.mp-preview-desc {
  margin-top: 4px;
  color: #648719;
  font-size: 13px;
}

.mp-preview-note {
  margin-top: 3px;
  color: #e84f8a;
  font-size: 12px;
}

.mp-preview-hero-art {
  right: -13px;
  width: 165px;
  height: 159px;
}

.mp-preview-hero-foot {
  bottom: 6px;
  font-size: 10px;
}

.mp-preview-sticker {
  width: 29px;
  height: 29px;
}

.mp-preview-sticker.heart {
  left: 12px;
  top: 12px;
}

.mp-preview-sticker.star {
  left: 66px;
  top: 15px;
  width: 27px;
  height: 27px;
}

.mp-preview-sticker.bow {
  left: auto;
  right: 153px;
  top: 8px;
  width: 33px;
  height: 27px;
}

.mp-preview-sticker.lemon {
  left: 9px;
  bottom: 17px;
  width: 40px;
  height: 40px;
}

.mp-preview-window {
  border-width: 2px;
  border-radius: 7px;
}

.mp-preview-titlebar {
  min-height: 24px;
  grid-template-columns: minmax(0, 1fr) auto 15px 15px 15px;
  gap: 3px;
  padding: 0 6px;
}

.mp-preview-titlebar strong {
  font-size: 12px;
}

.mp-preview-titlebar span {
  font-size: 10px;
}

.mp-preview-titlebar em {
  width: 15px;
  height: 15px;
  font-size: 10px;
}

.mp-preview-notice {
  grid-template-columns: minmax(0, 1fr) 88px;
  min-height: 89px;
  padding: 8px 7px 6px;
}

.mp-preview-notice-list p {
  gap: 6px;
  font-size: 12px;
}

.mp-preview-notice-list p + p {
  margin-top: 2px;
}

.mp-preview-notice-list b {
  flex-basis: 17px;
  width: 17px;
  height: 15px;
  font-size: 8px;
}

.mp-preview-notice-side img,
.mp-preview-notice-side > span {
  width: 52px;
  height: 46px;
}

.mp-preview-notice-side div {
  padding: 3px 5px;
  font-size: 9px;
}

.mp-preview-notice-side a {
  font-size: 11px;
}

.mp-preview-nav {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 6px;
  padding: 7px 6px 8px;
}

.mp-preview-nav-item {
  min-height: 66px;
  padding: 5px 2px;
  border-radius: 5px;
}

.mp-preview-nav-item div {
  width: 28px;
  height: 28px;
  margin-bottom: 4px;
  border: 0;
  background: transparent;
}

.mp-preview-nav-item strong {
  font-size: 11px;
}

.mp-preview-split {
  gap: 5px;
}

.mp-preview-half {
  min-height: 151px;
}

.mp-preview-messages {
  padding: 5px 6px 0;
}

.mp-preview-messages p {
  min-height: 26px;
  padding: 3px 0;
  gap: 5px;
}

.mp-preview-messages b {
  flex-basis: 21px;
  width: 21px;
  height: 21px;
  font-size: 9px;
}

.mp-preview-messages span {
  font-size: 10px;
}

.mp-preview-messages span strong {
  font-size: 10px;
}

.mp-preview-messages em {
  flex-basis: 35px;
  font-size: 9px;
}

.mp-preview-window > a {
  margin: 0 8px 5px auto;
  font-size: 11px;
}

.mp-preview-mood {
  min-height: 127px;
  padding: 8px;
}

.mp-preview-mood > strong {
  font-size: 20px;
}

.mp-preview-mood p {
  margin: 4px 0 6px;
  font-size: 10px;
}

.mp-preview-mood code {
  font-size: 12px;
  letter-spacing: 2px;
}

.mp-preview-mood-art {
  left: 9px;
  right: 9px;
  bottom: 9px;
  min-height: 39px;
}

.mp-preview-mood-art img,
.mp-preview-mood-art > span:first-child {
  width: 39px;
  height: 39px;
}

.mp-preview-mood-art span:last-child {
  padding: 5px 6px;
  font-size: 9px;
}

.mp-preview-products {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 7px;
  padding: 7px;
}

.mp-preview-product {
  min-height: 115px;
  padding: 4px;
  border-radius: 5px;
}

.mp-preview-product-img {
  height: 61px;
}

.mp-preview-product strong {
  height: 24px;
  white-space: normal;
  font-size: 10px;
  line-height: 1.2;
}

.mp-preview-product span {
  font-size: 11px;
}

.decor-preview-card #decorLivePreview {
  overflow: visible;
}

.decor-preview-card .decor-preview-fit {
  overflow: visible;
}

.decor-preview-card .mp-preview-phone {
  max-height: none;
  overflow: hidden;
}

/* Usability pass: admin works in the narrow in-app browser too. */
body {
  min-width: 0;
}

.login-page {
  grid-template-columns: minmax(0, 1fr) minmax(360px, 460px);
}

@media (max-width: 760px) {
  html,
  body {
    min-width: 0;
    overflow-x: hidden;
  }

  #app,
  .shell,
  .main,
  .content,
  .card,
  .section,
  .decor-page,
  .decor-layout,
  .decor-module,
  .decor-module-body {
    max-width: 100%;
    overflow-x: hidden;
  }

  .decor-page-selector {
    align-items: flex-start;
    padding: 10px;
  }

  .decor-page-grid {
    flex: 1;
    overflow-x: auto;
    flex-wrap: nowrap;
    padding-bottom: 2px;
  }

  .decor-page-tile {
    flex: 0 0 auto;
  }

  .login-page {
    display: block;
    min-height: 100vh;
    padding: 22px;
  }

  .login-brand {
    padding: 8px 0 18px;
    gap: 22px;
  }

  .login-title h1 {
    font-size: 34px;
    line-height: 1.12;
  }

  .login-title p {
    margin-top: 14px;
    font-size: 14px;
  }

  .login-points {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .login-point {
    min-height: 0;
    padding: 14px;
  }

  .login-panel-wrap {
    padding: 0;
  }

  .login-panel {
    padding: 22px;
  }

  .shell {
    display: block;
  }

  .sidebar {
    min-height: 0;
    padding: 14px 14px 10px;
    border-right: 0;
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 20;
  }

  .sidebar-brand {
    padding: 0 4px 10px;
  }

  .sidebar-brand span {
    display: none;
  }

  .mobile-page-select {
    width: 100%;
    height: 42px;
    display: block;
    padding: 0 14px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: #fbfdfc;
    color: var(--text);
    font-weight: 850;
    outline: none;
  }

  .nav {
    display: none;
  }

  .nav.mobile-open {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-top: 10px;
    padding-bottom: 0;
  }

  .nav-item {
    height: 36px;
    padding: 0 12px;
    white-space: nowrap;
    justify-content: center;
  }

  .topbar {
    height: auto;
    min-height: 64px;
    padding: 12px 14px;
    align-items: flex-start;
    gap: 10px;
    position: static;
  }

  .topbar h1 {
    font-size: 20px;
  }

  .operator-info,
  .avatar {
    display: none;
  }

  .content {
    padding: 14px;
  }

  .section-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .toolbar {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    justify-content: stretch;
    overflow-x: visible;
    padding-bottom: 0;
    gap: 8px;
  }

  .toolbar .badge {
    grid-column: 1 / -1;
    justify-content: center;
  }

  .toolbar button,
  .toolbar .secondary-btn,
  .toolbar .primary-action-btn {
    width: 100%;
    height: 38px;
    padding: 0 8px;
    min-width: 0;
    white-space: nowrap;
  }

  .decor-meta {
    display: grid;
    gap: 6px;
  }

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

  .decor-preview-card {
    position: static;
    order: -1;
    padding: 12px;
    max-height: none;
    overflow: visible;
    display: block;
  }

  .decor-preview-card .section-head.compact {
    margin-bottom: 8px;
  }

  .decor-preview-card .section-head.compact h2 {
    font-size: 16px;
  }

  .decor-preview-card .section-head.compact p {
    display: none;
  }

  .decor-preview-phone {
    max-height: 320px;
    padding: 7px;
    border-radius: 18px;
    overflow: auto;
  }

  .decor-preview-top {
    height: 24px;
    font-size: 11px;
  }

  .decor-preview-body {
    gap: 5px;
  }

  .decor-live-hero,
  .decor-live-window {
    border-width: 1px;
    border-radius: 8px;
  }

  .decor-live-hero {
    min-height: 96px;
    grid-template-columns: minmax(0, 1fr) 58px;
    gap: 4px;
    padding: 10px 7px 15px;
  }

  .decor-live-hero::before {
    left: 6px;
    top: 3px;
    font-size: 10px;
    letter-spacing: 2px;
  }

  .decor-live-hero-copy span {
    font-size: 15px;
  }

  .decor-live-hero-copy strong {
    margin-top: 1px;
    font-size: 22px;
    text-shadow: 1px 1px 0 #7da52a;
  }

  .decor-live-hero-copy em {
    margin-top: 5px;
    font-size: 11px;
  }

  .decor-live-hero-copy small {
    margin-top: 3px;
    font-size: 10px;
  }

  .decor-live-hero-art {
    min-height: 60px;
  }

  .decor-live-hero-art span,
  .decor-live-sticker > span:first-child,
  .decor-live-mood-art > span:first-child,
  .decor-live-nav-item div span,
  .decor-live-product-img span {
    font-size: 20px;
  }

  .decor-live-hero-foot {
    left: 7px;
    right: 7px;
    bottom: 2px;
    font-size: 9px;
  }

  .decor-live-titlebar {
    min-height: 23px;
    grid-template-columns: minmax(0, 1fr) auto 15px 15px 15px;
    gap: 3px;
    padding: 3px 5px;
  }

  .decor-live-titlebar strong {
    font-size: 11px;
  }

  .decor-live-titlebar span {
    font-size: 9px;
  }

  .decor-live-titlebar em {
    width: 15px;
    height: 15px;
    font-size: 10px;
  }

  .decor-live-notice {
    grid-template-columns: minmax(0, 1fr) 52px;
    gap: 4px;
    padding: 6px;
  }

  .decor-live-notice p,
  .decor-live-messages p {
    gap: 5px;
    margin-bottom: 4px;
    font-size: 10px;
  }

  .decor-live-notice b,
  .decor-live-messages b {
    min-width: 20px;
    height: 18px;
    font-size: 9px;
  }

  .decor-live-sticker {
    font-size: 9px;
  }

  .decor-live-sticker img,
  .decor-live-sticker > span:first-child {
    width: 42px;
    height: 36px;
  }

  .decor-live-window > a {
    margin: -2px 6px 6px auto;
    font-size: 10px;
  }

  .decor-live-nav {
    gap: 5px;
    padding: 6px;
  }

  .decor-live-nav-item {
    padding: 5px 3px;
    border-radius: 6px;
  }

  .decor-live-nav-item div {
    width: 26px;
    height: 26px;
    margin-bottom: 3px;
  }

  .decor-live-nav-item strong {
    font-size: 10px;
  }

  .decor-live-nav-item span {
    font-size: 9px;
  }

  .decor-live-split {
    gap: 5px;
  }

  .decor-live-half {
    min-height: 116px;
  }

  .decor-live-messages,
  .decor-live-mood {
    padding: 6px;
  }

  .decor-live-mood strong {
    font-size: 15px;
  }

  .decor-live-mood p {
    margin: 4px 0 6px;
    font-size: 10px;
  }

  .decor-live-mood code {
    font-size: 12px;
    letter-spacing: 0;
  }

  .decor-live-mood-art {
    min-height: 38px;
    margin-top: 6px;
    grid-template-columns: 34px minmax(0, 1fr);
    font-size: 9px;
  }

  .decor-live-products {
    gap: 5px;
    padding: 6px;
  }

  .decor-live-product {
    padding: 4px;
    border-radius: 6px;
  }

  .decor-live-product i {
    left: 4px;
    top: 4px;
    font-size: 8px;
  }

  .decor-live-product-img {
    height: 48px;
  }

  .decor-live-product strong {
    margin-top: 4px;
    font-size: 9px;
  }

  .decor-live-product span {
    margin-top: 2px;
    font-size: 10px;
  }

  .decor-module-head {
    grid-template-columns: 24px minmax(0, 1fr);
    padding: 11px 12px;
    gap: 9px;
  }

  .decor-module-head::after {
    grid-column: 2;
    justify-self: start;
    margin-top: 6px;
  }

  .decor-module-actions {
    grid-column: 1 / -1;
    margin-right: 0;
  }

  .decor-module-actions .secondary-btn {
    height: 34px;
    min-width: 72px;
  }

  .decor-module-body {
    gap: 12px;
    padding: 12px;
  }

  .decor-basic-grid,
  .decor-text-grid,
  .decor-products {
    grid-template-columns: 1fr;
  }

  .decor-text-grid label:nth-child(3) {
    grid-column: auto;
  }

  .decor-image-row {
    grid-template-columns: 86px minmax(0, 1fr);
  }

  .decor-image-preview {
    width: 86px;
    height: 72px;
  }

  .decor-button-row {
    padding: 9px;
  }

  .decor-button-summary {
    grid-template-columns: 48px minmax(0, 1fr);
    gap: 9px;
  }

  .decor-button-fields {
    grid-template-columns: 1fr;
  }

  .decor-button-icon {
    width: 48px;
    height: 48px;
  }
}

.loading {
  min-height: 100vh;
  display: grid;
  place-items: center;
  color: var(--muted);
}

@media (max-width: 1260px) {
  body {
    min-width: 0;
  }

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

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

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

  .sales-panel {
    grid-column: span 2;
  }

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

  .product-row {
    grid-template-columns: 34px minmax(180px, 1.25fr) minmax(120px, 0.8fr) 80px minmax(130px, 0.8fr) minmax(160px, 1fr) 120px;
  }

  .ichiban-row {
    grid-template-columns: minmax(190px, 1.1fr) 104px 104px 130px 72px 176px;
  }

  .ichiban-event-row {
    grid-template-columns: minmax(220px, 1.25fr) 122px 122px 72px 206px;
  }

  .ichiban-prize-row {
    grid-template-columns: minmax(220px, 1.2fr) 120px 104px 112px minmax(150px, 0.85fr) 78px;
  }

  .ichiban-special-row {
    grid-template-columns: minmax(230px, 1.3fr) minmax(180px, 0.95fr) 78px minmax(155px, 0.85fr) 72px 78px;
  }

  .ichiban-record-row {
    grid-template-columns: 120px minmax(220px, 1.25fr) 86px 96px 78px 104px;
  }

  .ichiban-settlement-row {
    grid-template-columns: 130px 116px minmax(200px, 1.1fr) minmax(180px, 1fr) 78px 104px;
  }

  .app-backbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .app-sync-grid {
    grid-template-columns: 1fr;
  }

  .audit-signal-row {
    grid-template-columns: minmax(240px, 1.25fr) 90px minmax(220px, 1fr);
  }

  .audit-log-row {
    grid-template-columns: 110px minmax(150px, 0.95fr) minmax(180px, 1fr) 70px 112px;
  }

  .audit-version-row {
    grid-template-columns: minmax(160px, 0.95fr) 120px minmax(170px, 1fr) 90px 112px;
  }

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

  .coupon-row {
    grid-template-columns: minmax(190px, 1.25fr) 100px minmax(140px, 0.9fr) 120px 76px 112px;
  }

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

  .rule-binding-row {
    grid-template-columns: minmax(170px, 1fr) minmax(170px, 1fr) 112px 70px 100px 104px;
  }

  .rule-version-row {
    grid-template-columns: minmax(170px, 1fr) 112px minmax(190px, 1.1fr) 82px 100px;
  }

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

  .aftersale-row {
    grid-template-columns: minmax(165px, 1fr) minmax(130px, 0.8fr) minmax(190px, 1.1fr) 84px 72px minmax(135px, 0.9fr) 80px;
  }

  .aftersale-action-layout {
    grid-template-columns: 1fr;
  }

  .aftersale-item-list {
    grid-template-columns: 1fr;
  }

  .finance-overview-grid {
    grid-template-columns: 1fr;
  }

  .finance-flow-row {
    grid-template-columns: minmax(140px, 0.9fr) minmax(140px, 0.9fr) minmax(130px, 0.75fr) 104px minmax(160px, 1fr) 104px;
  }

  .withdrawal-main {
    grid-template-columns: minmax(150px, 1fr) 116px minmax(150px, 1fr) 128px minmax(170px, 1fr) 80px;
  }

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

  .admin-row {
    grid-template-columns: minmax(145px, 0.85fr) minmax(130px, 0.75fr) minmax(210px, 1.05fr) 70px minmax(120px, 0.75fr) 220px;
  }

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

  .user-row {
    grid-template-columns: minmax(170px, 1fr) minmax(230px, 1.35fr) 110px 140px 96px;
  }

  .user-profile-strip,
  .user-detail-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .picking-layout {
    grid-template-columns: 1fr;
  }

  .pick-summary-list {
    grid-template-columns: 1fr;
  }

  .package-items {
    grid-template-columns: 1fr;
  }

  .picking-row {
    grid-template-columns: minmax(180px, 1fr) minmax(220px, 1.2fr) 90px 90px 130px 140px;
  }

  .box-row {
    grid-template-columns: minmax(220px, 1.25fr) minmax(120px, 0.72fr) minmax(120px, 0.72fr) 70px 100px 110px 78px;
  }

  .decor-layout {
    grid-template-columns: 1fr;
  }

  .decor-preview-card {
    position: static;
  }

  .decor-basic-grid,
  .decor-text-grid,
  .decor-products {
    grid-template-columns: 1fr;
  }

  .decor-button-row {
    grid-template-columns: 58px repeat(2, minmax(0, 1fr));
  }
}

/* Decoration workspace: compact navigation, focused editing and persistent actions. */
.decor-page {
  padding-top: 18px;
}

.decor-workspace-bar {
  position: sticky;
  top: 82px;
  z-index: 11;
  margin-bottom: 16px;
  padding: 14px 16px 10px;
  box-shadow: 0 10px 24px rgba(20, 44, 38, 0.08);
}

.decor-workspace-main,
.decor-workspace-title > div,
.decor-publish-actions,
.decor-editor-head,
.decor-editor-actions,
.decor-product-tools {
  display: flex;
  align-items: center;
}

.decor-workspace-main {
  justify-content: space-between;
  gap: 18px;
}

.decor-workspace-title {
  min-width: 0;
}

.decor-workspace-title > div {
  gap: 9px;
}

.decor-workspace-title h2,
.decor-editor-head h2 {
  margin: 0;
  font-size: 18px;
}

.decor-workspace-title > div > span {
  padding: 3px 7px;
  border-radius: 5px;
  background: var(--surface-soft);
  color: var(--primary-dark);
  font-size: 11px;
  font-weight: 850;
}

.decor-workspace-title p,
.decor-editor-head p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.decor-publish-actions {
  flex: none;
  gap: 8px;
}

.decor-publish-actions button {
  height: 38px;
}

.decor-workspace-bar .decor-page-selector {
  margin-top: 11px;
  padding: 7px 9px;
  border-radius: 8px;
  box-shadow: none;
}

.decor-page-select {
  display: none;
  width: 100%;
  height: 36px;
  padding: 0 10px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: #fff;
  color: var(--text);
  font-weight: 800;
}

.decor-workspace-bar .decor-page-tile {
  min-height: 29px;
  padding: 0 11px;
  border-radius: 6px;
}

.decor-workspace-bar .decor-page-tile.active {
  box-shadow: none;
}

.decor-workspace-bar .decor-meta {
  margin-top: 8px;
  display: flex;
  gap: 14px;
  color: var(--muted);
  font-size: 11px;
}

.decor-layout {
  grid-template-columns: minmax(0, 1fr) minmax(370px, 410px);
  gap: 16px;
}

.decor-editor-head {
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 12px;
}

.decor-editor-actions {
  flex: none;
  gap: 7px;
}

.decor-editor-actions input {
  width: 170px;
  height: 36px;
  padding: 0 10px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: #fff;
}

.decor-editor-actions button {
  height: 36px;
  padding: 0 10px;
}

.decor-module-outline {
  margin-bottom: 12px;
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 2px 0 6px;
  scrollbar-width: thin;
}

.decor-module-outline button {
  flex: none;
  height: 31px;
  padding: 0 9px 0 5px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border: 1px solid var(--border);
  border-radius: 6px 6px 2px 2px;
  background: #fff;
  color: var(--text);
  font-size: 12px;
  font-weight: 800;
}

.decor-module-outline button:hover {
  border-color: var(--primary);
  color: var(--primary-dark);
}

.decor-module-outline button span {
  width: 21px;
  height: 21px;
  display: grid;
  place-items: center;
  border-radius: 4px;
  background: var(--surface-soft);
  color: var(--primary-dark);
  font-size: 10px;
}

.decor-page-style-card,
.decor-module,
.decor-image-row,
.decor-product-picker,
.decor-button-row,
.decor-notice-editor {
  border-radius: 9px;
}

.decor-module-list {
  gap: 10px;
}

.decor-module {
  box-shadow: 0 5px 14px rgba(15, 23, 42, 0.045);
  scroll-margin-top: 210px;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.decor-module.is-focused {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(0, 154, 135, 0.12);
}

.decor-module-head {
  grid-template-columns: 28px minmax(0, 1fr) auto 52px;
  gap: 9px;
  padding: 10px 12px;
  background: #f6faef;
}

.decor-module-head::after {
  justify-self: stretch;
  padding: 4px 5px;
  border-radius: 5px;
  text-align: center;
}

.decor-module-actions {
  margin-right: 0;
  gap: 5px;
}

.decor-module-actions .decor-move-btn {
  width: 30px;
  height: 30px;
  padding: 0;
  border-radius: 6px;
  font-size: 16px;
}

.decor-module-body {
  gap: 12px;
  padding: 13px;
}

.decor-basic-grid,
.decor-text-grid {
  gap: 9px;
}

.decor-basic-grid {
  grid-template-columns: repeat(auto-fit, minmax(125px, 1fr));
}

.decor-product-tools {
  justify-content: space-between;
  gap: 10px;
}

.decor-product-search {
  flex: 1;
  height: 36px;
  padding: 0 10px;
  border: 1px solid var(--border);
  border-radius: 7px;
}

.decor-product-selected-count {
  flex: none;
  color: var(--primary-dark);
  font-size: 12px;
  font-weight: 850;
}

.decor-products {
  max-height: 310px;
}

.decor-product-option[hidden],
.decor-module[hidden],
.decor-module-outline button[hidden] {
  display: none;
}

.decor-preview-card {
  top: 90px;
  padding: 15px;
}

.decor-preview-live-badge {
  align-self: flex-start;
  padding: 4px 8px;
  border: 1px solid #b8d6ce;
  border-radius: 5px;
  background: #eef8f5;
  color: var(--primary-dark);
  font-size: 11px;
  font-weight: 850;
}

.decor-preview-card .mp-preview-phone,
.decor-preview-card .decor-preview-phone {
  max-width: 390px;
  margin: 0 auto;
}

@media (max-width: 1180px) {
  .decor-workspace-main,
  .decor-editor-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .decor-publish-actions,
  .decor-editor-actions {
    width: 100%;
  }

  .decor-editor-actions input {
    flex: 1;
    width: auto;
  }

  .decor-layout {
    grid-template-columns: 1fr;
  }

  .decor-preview-card {
    position: static;
    order: -1;
  }
}

@media (max-width: 760px) {
  .decor-workspace-bar {
    position: static;
  }

  .decor-page-selector-label,
  .decor-page-grid {
    display: none;
  }

  .decor-page-select {
    display: block;
  }

  .decor-publish-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .decor-publish-actions .badge {
    grid-column: 1 / -1;
    justify-content: center;
  }

  .decor-editor-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .decor-editor-actions input {
    grid-column: 1 / -1;
  }

  .decor-module-head {
    grid-template-columns: 22px minmax(0, 1fr) 44px;
  }

  .decor-module-actions {
    display: none;
  }

  .decor-hero-only-grid,
  .decor-module-nav-only .decor-hero-only-grid,
  .decor-button-fields,
  .decor-module-nav-only .decor-button-fields,
  .decor-notice-row,
  .decor-image-row,
  .decor-hero-image-row {
    grid-template-columns: 1fr;
  }
}

@media print {
  .sidebar,
  .topbar,
  .toolbar,
  .package-actions,
  .modal-backdrop {
    display: none !important;
  }

  body {
    min-width: 0;
    background: white;
  }

  .shell {
    display: block;
  }

  .content {
    padding: 0;
  }

  .card {
    box-shadow: none;
    break-inside: avoid;
  }
}
