/* One-pixel size preview, scoped to worksheet content; keep page controls unchanged. */
.sales-statistics-page .sales-spreadsheet .ant-table-cell {
  font-size: 15px;
}
.sales-statistics-page .sales-spreadsheet .ant-table-thead > tr > th {
  line-height: 22px;
}
.sales-statistics-page .sales-spreadsheet .text-xs {
  font-size: calc(var(--sales-page-font-size, 13px) * 0.85 + 1px) !important;
}
.sales-statistics-page .sales-spreadsheet .text-sm {
  font-size: calc(var(--sales-page-font-size, 13px) + 1px) !important;
}
.sales-statistics-page .sales-spreadsheet .text-base {
  font-size: calc(var(--sales-page-font-size, 13px) * 1.08 + 1px) !important;
}

/* Compact, consistent header controls. Undo/redo have no resting container. */
.sales-statistics-page .sales-business-header { box-shadow: none; }
.sales-statistics-page .sales-header-tools { align-items: center; gap: 8px; }
.sales-statistics-page .sales-header-tools > :is(a, div) {
  border-radius: 6px;
  border-color: #dce5f2;
  box-shadow: none;
}
.sales-statistics-page .sales-header-tools > div:has(> .sheet-action-button) {
  border: 0;
  background: transparent;
  padding: 0;
  gap: 4px;
}
.sales-statistics-page .sales-header-tools .sheet-action-button {
  position: relative;
  border: 1px solid transparent;
  background: transparent;
  box-shadow: none;
  border-radius: 6px;
  color: #383b40;
  overflow: visible;
}
.sales-statistics-page .sales-header-tools .sheet-action-button:disabled {
  pointer-events: auto;
  opacity: 1;
  color: #bec3ca;
  cursor: default;
}
.sales-statistics-page .sales-header-tools .sheet-action-button:is(:hover, :focus-visible) {
  background: #f0f1f3;
  border-color: #e5e7eb;
}
.sales-statistics-page .sales-header-tools .sheet-action-button::after {
  content: attr(title);
  position: absolute;
  top: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%);
  border: 1px solid #dedfe3;
  border-radius: 7px;
  background: #fff;
  box-shadow: 0 3px 10px #18223718;
  padding: 7px 12px;
  color: #303238;
  font: 13px/20px "Microsoft YaHei", "PingFang SC", sans-serif;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  z-index: 100;
}
.sales-statistics-page .sales-header-tools .sheet-action-button:is(:hover, :focus-visible)::after {
  opacity: 1;
  visibility: visible;
}
@media (pointer: coarse) {
  .sales-statistics-page .sales-header-tools .sheet-action-button { width: 44px; height: 44px; }
}
