html,
body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #dcebf3;
}

body {
  font-family: "SimSun", "Microsoft YaHei", Arial, sans-serif;
}

.pos-shell {
  min-height: 100vh;
  width: 100vw;
  max-width: 100vw;
  overflow: hidden;
}

.pos-login {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 20px;
}

.pos-workbench {
  width: 100vw;
  max-width: 100vw;
  height: 100vh;
  display: grid;
  grid-template-rows: 30px minmax(360px, 1fr) 226px 144px 28px;
  gap: 4px;
  padding: 0 2px 2px;
  background: #dcebf3;
  color: #1b2430;
  box-sizing: border-box;
  overflow: hidden;
}

.pos-workbench > * {
  min-width: 0;
}

.pos-workbench,
.pos-workbench *,
.pos-workbench *::before,
.pos-workbench *::after {
  box-sizing: border-box;
}

.pos-titlebar {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 8px;
  min-height: 30px;
  padding: 0 8px;
  color: #eaf7ff;
  background: linear-gradient(135deg, #123f78 0%, #1e5c9a 72%, #315d8e 100%);
  border: 1px solid #092e59;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.35);
  font-size: 15px;
  font-weight: 700;
}

.pos-titlebar strong {
  display: none;
}

.pos-titlebar a,
.pos-titlebar button,
.command-row button,
.settlement-actions button,
.member-actions button,
.section-head button,
.lookup-row button,
.dialog-head button {
  min-height: 24px;
  border: 1px solid #798a99;
  border-radius: 0;
  padding: 0 10px;
  color: #111;
  background: linear-gradient(#ffffff, #dbe6ee);
  text-decoration: none;
  font-size: 13px;
}

.pos-titlebar a {
  display: inline-flex;
  align-items: center;
}

.pos-main-table {
  min-height: 0;
  min-width: 0;
  overflow: hidden;
  border: 1px solid #9fb8c6;
  background: #fff;
}

.pos-main-table .table-wrap {
  height: 100%;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  border: 0;
  background: #fff;
}

.pos-table {
  min-width: 0;
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  table-layout: fixed;
}

.pos-table th,
.pos-table td {
  height: 31px;
  min-width: 0;
  padding: 0 2px;
  border-top: 0;
  border-left: 0;
  border-right: 1px solid #8c8c8c;
  border-bottom: 1px solid #a5a5a5;
  font-size: clamp(10px, 0.72vw, 15px);
  line-height: 1.15;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pos-table th {
  height: 38px;
  color: #101010;
  background: #fff;
  text-align: center;
  font-weight: 700;
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
  box-shadow: inset 0 -1px 0 #5f5f5f;
}

.pos-table td {
  background: #fff;
  font-size: clamp(9px, 0.64vw, 13px);
  text-align: center;
  white-space: nowrap;
}

.pos-table td input {
  width: 100%;
  min-width: 0;
  height: 29px;
  border: 0;
  padding: 0 3px;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: center;
  outline: none;
}

.pos-table td input:focus {
  background: #c9e1c7;
  box-shadow: inset 0 0 0 1px #6e9d72;
}

.pos-table td input.amount-input {
  background: #fffbd2;
  font-weight: 700;
}

.pos-table td input.amount-input:focus {
  background: #fff2a6;
}

.pos-table td input[data-field="line_amount"] {
  cursor: not-allowed;
}

.pos-table .pos-key-value {
  color: #f01818 !important;
  font-weight: 800 !important;
}

.pos-table td input[type="number"] {
  appearance: textfield;
  -moz-appearance: textfield;
}

.pos-table td .text-left {
  text-align: left;
}

.pos-table tbody tr:first-child td {
  background: #e8f1fb;
}

.pos-table tbody tr.selected td {
  background: #cfe2f4;
}

.pos-table th:nth-child(1) { width: 2.5%; }
.pos-table th:nth-child(2) { width: 8%; }
.pos-table th:nth-child(3) { width: 13%; }
.pos-table th:nth-child(4) { width: 4%; }
.pos-table th:nth-child(5) { width: 3%; }
.pos-table th:nth-child(6) { width: 4.5%; }
.pos-table th:nth-child(7) { width: 4.5%; }
.pos-table th:nth-child(8) { width: 3.5%; }
.pos-table th:nth-child(9) { width: 5.5%; }
.pos-table th:nth-child(10) { width: 3%; }
.pos-table th:nth-child(11) { width: 4.5%; }
.pos-table th:nth-child(12) { width: 5.5%; }
.pos-table th:nth-child(13) { width: 3.5%; }
.pos-table th:nth-child(14) { width: 3.5%; }
.pos-table th:nth-child(15) { width: 4%; }
.pos-table th:nth-child(16) { width: 4.5%; }
.pos-table th:nth-child(17) { width: 6%; }
.pos-table th:nth-child(18) { width: 4.5%; }
.pos-table th:nth-child(19) { width: 9%; }
.pos-table th:nth-child(20) { width: 4%; }

.pos-table .empty {
  color: transparent;
}

.pos-bottom {
  display: grid;
  grid-template-columns: minmax(0, .92fr) minmax(0, 1.14fr) minmax(0, .94fr);
  gap: 6px;
  min-height: 0;
  min-width: 0;
}

.command-panel,
.settlement-panel,
.member-panel,
.gold-material-pos-panel,
.pos-recent {
  min-height: 0;
  min-width: 0;
  overflow: hidden;
  border: 1px solid #9bb6c4;
  background: #eaf4f8;
}

.command-title,
.settlement-panel h2,
.member-panel h2 {
  position: relative;
  margin: 0;
  padding: 0 8px;
  height: 24px;
  color: #31435a;
  background: #eaf4f8;
  font-size: 18px;
  line-height: 24px;
  font-weight: 700;
}

.command-title::after,
.settlement-panel h2::after,
.member-panel h2::after {
  content: "";
  position: absolute;
  left: 8px;
  right: 8px;
  top: 12px;
  height: 1px;
  background: #9bb6c4;
  z-index: 0;
}

.command-title,
.settlement-panel h2,
.member-panel h2 {
  text-shadow: 0 1px 0 #fff;
}

.command-title {
  overflow: hidden;
}

.command-title::before,
.settlement-panel h2::before,
.member-panel h2::before {
  content: attr(class);
  display: none;
}

.command-row {
  display: grid;
  grid-template-columns: 1fr 60px;
  gap: 6px;
  padding: 4px 8px 6px;
  background: #eaf4f8;
}

.command-row input {
  height: 46px;
  border: 1px solid #8eabb8;
  background: #c4dfc4;
  color: #111;
  font-size: 22px;
  font-weight: 700;
}

.command-message {
  height: 108px;
  margin: 0 8px 6px;
  padding: 10px;
  border: 1px solid #c7ae59;
  background: #ffe9a2;
  color: #111;
  font-size: 22px;
  font-weight: 700;
  line-height: 1.18;
}

.recycle-box {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.settlement-grid {
  display: grid;
  grid-template-columns: 74px minmax(84px, 1fr) 74px minmax(84px, 1fr) 74px minmax(84px, 1fr);
  gap: 14px 10px;
  align-items: center;
  padding: 12px 10px 8px;
}

.settlement-grid span {
  color: #526076;
  font-size: 17px;
  text-align: right;
  white-space: nowrap;
}

.settlement-grid strong {
  display: block;
  min-width: 0;
  height: 34px;
  padding: 0 8px;
  border: 1px solid #eef4f8;
  background: #fff;
  color: #111;
  line-height: 34px;
  text-align: right;
  font-size: 18px;
  font-weight: 400;
}

.settlement-grid strong#totalAmount,
.settlement-grid strong:last-child {
  background: #fffdd2;
}

.settlement-actions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  padding: 0 10px 8px;
}

.settlement-actions #checkoutBtn {
  color: #111;
  border-color: #798a99;
  background: linear-gradient(#ffffff, #dbe6ee);
  font-weight: 700;
}

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

.member-grid label {
  display: grid;
  grid-template-columns: 50px minmax(0, 1fr);
  gap: 6px;
  align-items: center;
  color: #526076;
  font-size: 17px;
}

.member-grid label.wide {
  grid-column: span 2;
}

.member-grid input {
  min-width: 0;
  width: 100%;
  height: 34px;
  border: 1px solid #eef4f8;
  background: #fff;
  padding: 0 8px;
  color: #111;
  font-size: 16px;
}

.member-grid input[readonly] {
  color: #33445a;
}

.member-actions {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
  padding: 0 10px 8px;
}

.shortcut-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  min-width: 0;
  gap: 0;
  border-top: 1px solid #9bb6c4;
  border-left: 1px solid #9bb6c4;
  background: #d8e7ee;
}

.shortcut-grid button {
  height: 48px;
  border: 0;
  border-right: 1px solid #9bb6c4;
  border-bottom: 1px solid #9bb6c4;
  border-radius: 0;
  background: #edf7fb;
  color: #111;
  font-size: 16px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.shortcut-grid button:hover,
.shortcut-grid button:focus {
  background: #dbeefa;
  outline: 1px solid #5d8bb5;
  outline-offset: -2px;
}

.pos-statusbar {
  display: grid;
  grid-template-columns: auto auto 1fr auto;
  gap: 14px;
  align-items: center;
  height: 28px;
  padding: 0 6px;
  border: 1px solid #9bb6c4;
  background: linear-gradient(#eaf5fb, #c8dbe7);
  color: #305070;
  font-size: 16px;
}

.lookup-dialog {
  width: min(980px, calc(100vw - 30px));
  border: 1px solid #44657d;
  border-radius: 0;
  padding: 0;
}

.pos-confirm-dialog {
  border: 1px solid #315f86;
  border-radius: 2px;
  padding: 0;
  background: #eef5f9;
  box-shadow: 0 8px 24px rgba(20, 48, 78, .28);
}

.pos-confirm-dialog::backdrop {
  background: rgba(30, 42, 54, .06);
}

.clear-line-dialog {
  width: 430px;
}

.clear-all-dialog {
  width: 420px;
}

.pos-confirm-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 28px;
  margin: 0;
  padding: 2px 8px;
  color: #eaf7ff;
  background: linear-gradient(90deg, #134b82, #1c64a6 70%, #123f70);
  border-bottom: 1px solid #0e3765;
}

.pos-confirm-head strong {
  font-size: 14px;
  font-weight: 800;
}

.pos-confirm-head button {
  width: 24px;
  height: 24px;
  border: 0;
  background: transparent;
  color: #d8efff;
  font-size: 20px;
  font-weight: 800;
  line-height: 22px;
}

.clear-line-body {
  display: grid;
  place-items: center;
  min-height: 154px;
  background: linear-gradient(#fff, #eef5f9);
}

.clear-line-body label {
  display: grid;
  gap: 16px;
  color: #1b69be;
  font-size: 24px;
  font-weight: 800;
  text-align: left;
}

.clear-line-body input {
  width: 270px;
  height: 50px;
  border: 1px solid #b9c8d4;
  background: #fff;
  color: #12314b;
  font-size: 34px;
  font-weight: 800;
  padding: 0 8px;
}

.clear-all-body {
  display: grid;
  grid-template-columns: 78px auto;
  align-items: center;
  justify-content: center;
  gap: 22px;
  min-height: 150px;
  color: #1b69be;
  background: linear-gradient(#fff, #eef5f9);
}

.clear-all-body strong {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: 0;
}

.confirm-info-icon {
  width: 62px;
  height: 62px;
  border-radius: 50%;
  color: #fff;
  background: linear-gradient(#95d7df, #44aebd);
  box-shadow: inset 0 1px 2px rgba(255,255,255,.8), 0 1px 2px rgba(0,0,0,.2);
  font-family: Georgia, serif;
  font-size: 50px;
  font-style: italic;
  font-weight: 800;
  line-height: 62px;
  text-align: center;
}

.pos-confirm-actions {
  display: grid;
  align-items: center;
  justify-content: center;
  gap: 24px;
  min-height: 52px;
  border-top: 1px solid #b5c5cf;
  background: #e5eff5;
}

.pos-confirm-actions.two {
  grid-template-columns: repeat(2, 96px);
}

.pos-confirm-actions.three {
  grid-template-columns: repeat(3, 96px);
}

.pos-confirm-actions button {
  height: 36px;
  border: 1px solid #9aaebb;
  border-radius: 2px;
  background: linear-gradient(#f8fbfd, #cddbe4);
  color: #263545;
  font-size: 18px;
  font-weight: 800;
  box-shadow: inset 0 1px 0 #fff;
}

.pos-confirm-actions button:focus {
  outline: 2px solid #73a9cc;
  outline-offset: -3px;
}

.recycle-dialog {
  width: min(1180px, calc(100vw - 34px));
  max-height: calc(100vh - 44px);
  border: 1px solid #315f86;
  border-radius: 2px;
  padding: 0;
  background: #eaf4f8;
  box-shadow: 0 8px 28px rgba(0, 0, 0, .28);
}

.recycle-dialog::backdrop {
  background: rgba(20, 36, 48, .12);
}

.recycle-head {
  min-height: 28px;
  padding: 3px 8px;
  background: linear-gradient(90deg, #134b82, #1c64a6);
}

.recycle-dialog-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 390px;
  max-height: calc(100vh - 74px);
  overflow: auto;
  border: 1px solid #95b2c2;
  border-top: 0;
}

.recycle-left {
  min-width: 0;
  display: grid;
  align-content: start;
  gap: 8px;
  padding: 8px;
}

.recycle-dialog fieldset {
  margin: 0;
  padding: 8px;
  border: 1px solid #a7c0ce;
  background: #eaf4f8;
}

.recycle-dialog legend {
  padding: 0 4px;
  color: #30475d;
  font-size: 18px;
  font-weight: 800;
}

.recycle-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(250px, 1fr));
  gap: 7px 18px;
}

.recycle-form-grid label,
.recycle-right label {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  align-items: center;
  gap: 6px;
  min-width: 0;
  color: #4e6072;
  font-size: 16px;
}

.recycle-form-grid label.wide {
  grid-column: 1 / -1;
}

.recycle-form-grid label.with-actions {
  grid-template-columns: 62px minmax(0, 1fr) 58px 58px;
}

.recycle-dialog input,
.recycle-dialog select {
  width: 100%;
  min-width: 0;
  height: 29px;
  border: 1px solid #bccbd5;
  border-radius: 0;
  padding: 2px 6px;
  background: #fff;
  color: #111;
}

.recycle-dialog input[readonly] {
  background: #edf3f6;
  color: #7b8790;
}

.recycle-form-grid input[type="number"] {
  text-align: right;
}

.recycle-dialog button {
  min-height: 29px;
  border: 1px solid #9caeb8;
  border-radius: 2px;
  background: linear-gradient(#fff, #d4e2ea);
  color: #111;
  font-weight: 700;
}

.recycle-actions {
  display: grid;
  grid-template-columns: repeat(3, 96px);
  justify-content: center;
  gap: 92px;
  padding: 0 0 4px;
}

.recycle-right {
  min-width: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-content: start;
  gap: 7px;
  padding: 8px;
  border-left: 1px solid #95b2c2;
  background: #e8f3f8;
}

.recycle-camera {
  grid-column: 1 / -1;
  min-height: 205px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 14px;
  background: #c4dfc4;
  color: #1b2a1e;
  font-size: 28px;
}

.camera-mark {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border: 2px solid #5b7690;
  border-radius: 50%;
  background: #eef6fb;
  color: #1b4e78;
  font-size: 15px;
  font-weight: 900;
}

.recycle-preview {
  min-height: 74px;
  display: grid;
  place-items: center;
  border: 1px solid #c4d2da;
  background: linear-gradient(135deg, #fff, #d6edf9);
  color: #111;
  font-weight: 700;
}

.recycle-right > label,
.recycle-right > button {
  min-width: 0;
}

.recycle-right .check {
  grid-template-columns: 18px auto;
  font-size: 14px;
}

.recycle-right fieldset {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1fr 92px;
  gap: 6px;
}

.recycle-right fieldset label {
  grid-template-columns: 72px minmax(0, 1fr);
}

.recycle-right fieldset .wide {
  grid-column: 1 / -1;
}

.dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px;
  color: #fff;
  background: #1f5d91;
}

.lookup-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  padding: 10px;
  background: #eef2f5;
}

#lookupResult {
  max-height: 60vh;
  overflow: auto;
  padding: 0 10px 10px;
  background: #eef2f5;
}

.promoter-dialog {
  width: min(720px, calc(100vw - 30px));
}

.pos-payment-dialog {
  width: min(980px, calc(100vw - 80px));
  max-height: calc(100vh - 80px);
  border: 1px solid #315f86;
  border-radius: 2px;
  padding: 0;
  background: #e8f2f7;
  box-shadow: 0 10px 32px rgba(15, 45, 70, .28);
}

.pos-payment-dialog::backdrop {
  background: rgba(30, 42, 54, .10);
}

.pos-payment-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 30px;
  margin: 0;
  padding: 0 8px;
  color: #eaf7ff;
  background: linear-gradient(90deg, #134b82, #1c64a6 70%, #123f70);
  border-bottom: 1px solid #0e3765;
}

.pos-payment-head strong {
  font-size: 15px;
  font-weight: 800;
}

.pos-payment-head button {
  width: 26px;
  height: 24px;
  border: 0;
  background: transparent;
  color: #d8efff;
  font-size: 20px;
  font-weight: 800;
}

.pos-payment-body {
  padding: 34px 10px 8px;
  background: linear-gradient(135deg, #c4eee9 0, #eaf4f8 48%, #eaf4f8 100%);
}

.pos-payment-grid {
  width: min(760px, 100%);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 96px;
}

.pos-payment-grid label {
  display: grid;
  grid-template-columns: 124px 220px;
  align-items: center;
  color: #20394d;
  font-size: 36px;
  line-height: 1;
}

.pos-payment-grid input {
  width: 100%;
  height: 60px;
  border: 2px solid #b9c9d5;
  background: #c4dfc4;
  color: #f00000;
  text-align: center;
  font-size: 42px;
  font-weight: 900;
}

.pos-payment-grid input[readonly] {
  background: #fff;
  color: #111;
}

.pos-payment-grid .pay-due input,
.pos-payment-grid .pay-total input {
  font-size: 40px;
}

.pos-payment-actions {
  display: grid;
  grid-template-columns: repeat(4, 118px);
  justify-content: center;
  gap: 26px;
  margin: 32px auto 8px;
}

.pos-payment-actions button {
  min-height: 56px;
  border: 1px solid #9aaebb;
  border-radius: 2px;
  background: linear-gradient(#f8fbfd, #cddbe4);
  color: #263545;
  font-size: 30px;
  font-weight: 800;
  box-shadow: inset 0 1px 0 #fff;
}

.pos-payment-actions button:disabled {
  color: #8d9aa4;
  background: #e5edf2;
}

.pos-payment-options {
  display: grid;
  grid-template-columns: repeat(3, auto) 1fr;
  justify-content: end;
  align-items: center;
  gap: 8px 16px;
  width: min(940px, 100%);
  margin: 0 auto 6px;
  color: #3d5060;
  font-size: 15px;
}

.pos-payment-options select {
  height: 30px;
  border: 1px solid #a8bac6;
  background: #fff;
}

.pos-payment-coupon {
  width: min(940px, 100%);
  height: 170px;
  margin: 0 auto;
  overflow: hidden;
  border: 1px solid #aabac6;
  background: #fff;
}

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

.pos-payment-coupon th,
.pos-payment-coupon td {
  height: 28px;
  border: 1px solid #c8d1d8;
  padding: 0 6px;
  text-align: center;
  font-size: 15px;
}

.pos-payment-coupon th {
  background: #d8e8f2;
}

.payment-edit-dialog {
  width: min(1500px, calc(100vw - 36px));
  max-height: calc(100vh - 36px);
  padding: 0;
  border: 1px solid #315f86;
  background: #edf5f9;
  box-shadow: 0 12px 36px rgba(15, 45, 70, .32);
}

.payment-edit-body {
  max-height: calc(100vh - 90px);
  overflow: auto;
  padding: 10px;
  background: linear-gradient(135deg, #d2f1ed 0, #edf5f9 52%, #e4f1f8 100%);
}

.payment-edit-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  padding: 8px;
  border: 1px solid #a3bdcf;
  background: #f7fbfd;
  color: #1e435f;
  font-size: 16px;
  font-weight: 700;
}

.payment-edit-toolbar label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.payment-edit-toolbar input,
.payment-edit-toolbar button {
  min-height: 30px;
  border: 1px solid #9fb5c6;
  background: #fff;
  font: inherit;
}

.payment-edit-toolbar button,
.payment-edit-list button {
  padding: 2px 12px;
  cursor: pointer;
  background: linear-gradient(#fff, #d8e7f0);
}

.payment-edit-tip { color: #d52121; }

.payment-edit-list {
  max-height: 285px;
  overflow: auto;
  border: 1px solid #a3bdcf;
  border-top: 0;
  background: #fff;
}

.payment-edit-list table {
  width: 100%;
  border-collapse: collapse;
  min-width: 980px;
}

.payment-edit-list th,
.payment-edit-list td {
  height: 31px;
  padding: 2px 8px;
  border: 1px solid #c1d2de;
  text-align: center;
  font-size: 15px;
}

.payment-edit-list th { background: #d9eaf5; color: #173c5c; }
.payment-edit-list tr.selected td { background: #c8e2f3; }

.payment-edit-panel {
  margin-top: 10px;
  padding: 12px 12px 15px;
  border: 2px solid #2781bd;
  background: #eef8fb;
}

.payment-edit-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 18px 60px;
  margin: 0 auto 16px;
  color: #1c4261;
  font-size: 21px;
  font-weight: 800;
}

.payment-edit-grid { width: min(980px, 100%); gap: 16px 112px; }
.payment-edit-grid label { grid-template-columns: 150px 230px; }

.payment-edit-hint {
  min-height: 24px;
  margin: 13px 0 0;
  text-align: center;
  color: #14742c;
  font-size: 18px;
  font-weight: 800;
}

.payment-edit-hint.error { color: #c20f0f; }

.payment-edit-actions {
  display: flex;
  justify-content: center;
  gap: 26px;
  margin-top: 12px;
}

.payment-edit-actions button {
  min-width: 140px;
  min-height: 50px;
  border: 1px solid #9aaebb;
  background: linear-gradient(#fff, #cddbe4);
  color: #263545;
  font-size: 24px;
  font-weight: 800;
  cursor: pointer;
}

@media (max-width: 850px) {
  .payment-edit-grid { grid-template-columns: 1fr; gap: 12px; }
  .payment-edit-grid label { grid-template-columns: 130px 1fr; font-size: 26px; }
  .payment-edit-grid input { height: 48px; font-size: 30px; }
}

.promoter-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 10px;
  border-bottom: 1px solid #a8bdca;
  background: #eef2f5;
  color: #31435a;
  font-size: 14px;
}

.promoter-toolbar button,
#promoterResult button {
  min-height: 26px;
  border: 1px solid #798a99;
  border-radius: 0;
  padding: 0 10px;
  color: #111;
  background: linear-gradient(#ffffff, #dbe6ee);
}

#promoterResult {
  max-height: 55vh;
  overflow: auto;
  padding: 10px;
  background: #eef2f5;
}

#promoterResult table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
}

#promoterResult th,
#promoterResult td {
  height: 30px;
  border: 1px solid #9fb2be;
  padding: 0 8px;
  font-size: 14px;
  text-align: center;
}

#promoterResult th {
  background: #d8e8f2;
}

#promoterResult tr.selected td {
  background: #cfe2f4;
}

#promoterResult tbody tr:hover td {
  background: #e4f0f8;
}

.member-input-dialog {
  width: min(1040px, calc(100vw - 48px));
  border: 1px solid #315f86;
  border-radius: 2px;
  padding: 0;
  background: #f8fbfd;
  box-shadow: 0 10px 30px rgba(15, 45, 70, .24);
}

.member-input-dialog::backdrop {
  background: rgba(30, 42, 54, .08);
}

.member-input-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 28px;
  margin: 0;
  padding: 2px 8px;
  color: #fff;
  background: linear-gradient(90deg, #144e86, #1d64a3 72%, #123f70);
  border-bottom: 1px solid #0e3765;
}

.member-input-head strong {
  font-size: 15px;
  font-weight: 800;
}

.member-input-head button {
  width: 24px;
  height: 24px;
  border: 0;
  background: transparent;
  color: #d8efff;
  font-size: 20px;
  font-weight: 800;
  line-height: 22px;
}

.member-input-body {
  padding: 30px 0 0;
  background: linear-gradient(#fff, #eef5f9);
}

.member-input-top {
  display: grid;
  grid-template-columns: minmax(420px, 1fr) 360px;
  align-items: start;
  gap: 36px;
  width: min(760px, calc(100% - 58px));
  margin: 0 auto;
}

.member-input-search {
  display: grid;
  gap: 12px;
}

.member-input-search strong {
  color: #314761;
  font-size: 22px;
  letter-spacing: 0;
}

.member-input-search input {
  width: 100%;
  height: 48px;
  border: 1px solid #bdcbd6;
  background: #fff;
  color: #112235;
  font-size: 24px;
  padding: 2px 10px;
}

.member-input-actions {
  display: grid;
  grid-template-columns: repeat(3, 100px);
  gap: 24px;
}

.member-input-actions button {
  height: 38px;
  border: 1px solid #9aaebb;
  border-radius: 2px;
  background: linear-gradient(#f8fbfd, #cddbe4);
  color: #263545;
  font-size: 17px;
  font-weight: 800;
  box-shadow: inset 0 1px 0 #fff;
}

.member-input-qr {
  display: grid;
  grid-template-columns: 108px 1fr;
  gap: 16px;
  align-items: center;
  padding-top: 12px;
}

.member-input-qr-box {
  width: 96px;
  height: 96px;
  background:
    linear-gradient(90deg, #111 8px, transparent 8px) 0 0 / 16px 16px,
    linear-gradient(#111 8px, transparent 8px) 0 0 / 16px 16px,
    #fff;
  border: 5px solid #fff;
  outline: 1px solid #b7c4ce;
}

.member-input-qr span {
  color: #ff7a00;
  font-size: 18px;
  line-height: 1.25;
  font-weight: 800;
}

.member-input-tip {
  width: min(980px, calc(100% - 28px));
  margin: 10px auto 0;
  color: #ff2f47;
  font-size: 15px;
  font-weight: 700;
}

.member-input-table {
  width: min(980px, calc(100% - 28px));
  height: 244px;
  margin: 6px auto 0;
  overflow: auto;
  border: 1px solid #a9bac6;
  background: #fff;
}

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

.member-input-table th,
.member-input-table td {
  height: 26px;
  border: 1px solid #c5cdd4;
  padding: 0 6px;
  white-space: nowrap;
  text-align: center;
  font-size: 14px;
}

.member-input-table th {
  color: #23384c;
  background: #d8e8f2;
  font-weight: 800;
}

.member-input-table tbody tr:nth-child(even) td {
  background: #fff6d8;
}

.member-input-table tbody tr.selected td,
.member-input-table tbody tr:hover td {
  background: #cfe2f4;
}

.member-input-empty {
  padding: 28px;
  color: #6d7c88;
  text-align: center;
}

.member-dialog {
  width: min(1030px, calc(100vw - 34px));
  max-height: calc(100vh - 42px);
  border: 1px solid #315f86;
  border-radius: 2px;
  padding: 0;
  background: #eaf4f8;
  box-shadow: 0 8px 28px rgba(0, 0, 0, .28);
}

.member-dialog-head {
  min-height: 28px;
  padding: 3px 8px;
  background: linear-gradient(90deg, #134b82, #1c64a6);
}

.member-dialog-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: 10px;
  max-height: calc(100vh - 78px);
  overflow: auto;
  padding: 14px 22px 8px;
  background: linear-gradient(135deg, #bce9df 0, #eaf4f8 36%, #eaf4f8 100%);
}

.member-dialog-fields {
  display: grid;
  grid-template-columns: repeat(3, minmax(220px, 1fr));
  gap: 10px 28px;
  align-content: start;
}

.member-dialog-fields label {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr) 10px;
  align-items: center;
  gap: 6px;
  min-width: 0;
  color: #4e6072;
  font-size: 16px;
}

.member-dialog-fields label.wide {
  grid-column: span 2;
}

.member-dialog-fields label.member-buttons {
  grid-template-columns: 1fr 1fr;
}

.member-dialog-fields input,
.member-dialog-fields select {
  width: 100%;
  min-width: 0;
  height: 34px;
  border: 1px solid #b8c9d4;
  border-radius: 0;
  padding: 2px 8px;
  background: #fff;
  color: #111;
  font-size: 15px;
}

.member-dialog-fields input[readonly] {
  background: #edf3f6;
  color: #6f7b84;
}

.required {
  color: #d51920;
  font-weight: 900;
}

.member-dialog button,
.reprint-toolbar button,
#reprintResult button,
#suspendResult button {
  min-height: 30px;
  border: 1px solid #9caeb8;
  border-radius: 2px;
  background: linear-gradient(#fff, #d4e2ea);
  color: #111;
  font-weight: 700;
}

.member-photo-box {
  display: grid;
  align-content: start;
  gap: 12px;
  min-width: 0;
}

.member-photo-preview {
  height: 250px;
  display: grid;
  place-items: end center;
  padding: 10px;
  border: 2px solid #83909a;
  background: linear-gradient(135deg, #fff 0, #d6edf9 100%);
  color: #555;
  font-size: 18px;
}

.member-hobby-box {
  grid-column: 1 / 2;
  display: grid;
  grid-template-rows: auto 170px;
  max-width: 360px;
}

.mini-grid-title {
  display: grid;
  grid-template-columns: 28px 28px 1fr 28px 28px 1fr;
  align-items: center;
  gap: 4px;
  color: #4e6072;
}

.mini-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border: 1px solid #b8c9d4;
  background: #fff;
}

.mini-grid > div + div {
  border-left: 1px solid #b8c9d4;
}

.member-dialog-footer {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: auto auto 120px 120px 120px;
  justify-content: center;
  align-items: center;
  gap: 16px 28px;
  padding-top: 8px;
}

.member-dialog-footer label {
  color: #4e6072;
  font-size: 15px;
}

.reprint-dialog {
  width: min(860px, calc(100vw - 30px));
}

.member-query-dialog {
  width: min(1260px, calc(100vw - 30px));
  max-height: calc(100vh - 34px);
  background: #eaf4f8;
}

.member-query-toolbar,
.member-query-mini-toolbar {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) 96px 112px;
  gap: 8px;
  align-items: center;
  padding: 10px;
  border-bottom: 1px solid #a8bdca;
  background: linear-gradient(135deg, #bce9df 0, #eaf4f8 60%);
}

.member-query-toolbar label {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  color: #4e6072;
  font-size: 15px;
}

.member-query-toolbar input,
.member-query-mini-toolbar input {
  min-width: 0;
  height: 30px;
  border: 1px solid #b8c9d4;
  padding: 2px 8px;
}

.member-query-toolbar button,
.member-query-mini-toolbar button,
#memberQueryResult button,
#memberHistoryResult button,
#memberSupplementResult button {
  min-height: 30px;
  border: 1px solid #9caeb8;
  border-radius: 2px;
  background: linear-gradient(#fff, #d4e2ea);
  color: #111;
  font-weight: 700;
}

.member-query-body {
  display: grid;
  grid-template-columns: minmax(320px, .82fr) minmax(420px, 1fr) minmax(420px, 1fr);
  gap: 8px;
  padding: 8px;
  background: #eef2f5;
}

.member-query-body section {
  min-width: 0;
  display: grid;
  grid-template-rows: auto minmax(240px, 58vh);
  border: 1px solid #9fb2be;
  background: #fff;
}

.member-query-body h3 {
  margin: 0;
  height: 32px;
  line-height: 32px;
  color: #1263a0;
  background: #d8e8f2;
  text-align: center;
  font-size: 17px;
  letter-spacing: 0;
}

#memberQueryResult,
#memberHistoryResult,
#memberSupplementResult {
  min-height: 0;
  overflow: auto;
  padding: 8px;
}

.member-query-mini-toolbar {
  grid-template-columns: minmax(0, 1fr) 82px;
  padding: 8px;
  border-bottom: 1px solid #d0d9df;
  background: #eef2f5;
}

.member-query-body table {
  min-width: 620px;
  width: 100%;
  border-collapse: collapse;
}

.member-query-body th,
.member-query-body td {
  height: 28px;
  border: 1px solid #c5cdd4;
  padding: 0 6px;
  white-space: nowrap;
  text-align: center;
  font-size: 13px;
}

.member-query-body th {
  background: #d8e8f2;
}

.member-query-body tbody tr.selected td {
  background: #cfe2f4;
}

.member-query-body tbody tr:hover td {
  background: #e4f0f8;
}

.reprint-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 10px;
  border-bottom: 1px solid #a8bdca;
  background: #eef2f5;
  color: #31435a;
  font-size: 14px;
}

#reprintResult,
#suspendResult {
  max-height: 58vh;
  overflow: auto;
  padding: 10px;
  background: #eef2f5;
}

#reprintResult table,
#suspendResult table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
}

#reprintResult th,
#reprintResult td,
#suspendResult th,
#suspendResult td {
  height: 30px;
  border: 1px solid #9fb2be;
  padding: 0 8px;
  font-size: 14px;
  text-align: center;
}

#reprintResult th,
#suspendResult th {
  background: #d8e8f2;
}

#reprintResult tbody tr:hover td,
#suspendResult tbody tr:hover td {
  background: #e4f0f8;
}

.reprint-quality-dialog {
  width: min(1500px, calc(100vw - 12px));
  height: calc(100vh - 18px);
  max-width: none;
  max-height: none;
  padding: 0;
  border: 1px solid #194f81;
  border-radius: 2px;
  background: #e8f2f7;
}

.reprint-quality-dialog::backdrop,
.quality-preview-dialog::backdrop {
  background: rgba(0, 0, 0, 0.22);
}

.reprint-quality-head,
.quality-preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 28px;
  padding: 0 8px;
  margin: 0;
  border-bottom: 1px solid #2f5e85;
  background: linear-gradient(135deg, #0d3f78, #256b96 42%, #a6e3df);
  color: #fff;
  font-size: 15px;
}

.reprint-quality-head button,
.quality-preview-head button {
  width: 28px;
  height: 24px;
  border: 0;
  background: transparent;
  color: #e8fbff;
  font-size: 18px;
}

.reprint-quality-toolbar {
  display: grid;
  grid-template-columns: auto 14px auto 86px 100px 86px 86px 112px 86px 154px minmax(260px, 1fr);
  gap: 8px;
  align-items: center;
  padding: 8px;
  border-bottom: 1px solid #9fb9c8;
  background: linear-gradient(135deg, #c2ece6 0, #e7f7f8 65%, #eaf4f8 100%);
  color: #20394d;
  font-size: 14px;
}

.reprint-quality-toolbar label {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}

.reprint-quality-toolbar input,
.reprint-quality-toolbar select {
  height: 28px;
  border: 1px solid #9bb5c5;
  padding: 2px 6px;
  background: #fff;
  font-size: 14px;
}

.reprint-quality-toolbar button,
.quality-preview-toolbar button {
  min-height: 30px;
  border: 1px solid #8fa6b7;
  border-radius: 2px;
  background: linear-gradient(#fff, #d9e6ee);
  color: #10202e;
  font-weight: 700;
}

.reprint-keyword {
  grid-column: 1 / span 3;
}

.reprint-keyword input {
  width: 250px;
}

.reprint-tip {
  color: #d90000;
  white-space: nowrap;
}

.reprint-quality-body {
  display: grid;
  grid-template-rows: minmax(280px, 1fr) 36px minmax(210px, 38%);
  height: calc(100% - 110px);
  min-height: 0;
  background: #eef3f6;
}

.reprint-sales-table,
.reprint-items-table {
  min-height: 0;
  overflow: auto;
  border: 1px solid #a8b8c4;
  background: #fff;
}

.reprint-sales-grid,
.reprint-items-grid {
  min-width: 2100px;
  width: 100%;
  border-collapse: collapse;
}

.reprint-items-grid {
  min-width: 2300px;
}

.reprint-sales-grid th,
.reprint-sales-grid td,
.reprint-items-grid th,
.reprint-items-grid td {
  height: 28px;
  border: 1px solid #c4cfd7;
  padding: 0 7px;
  white-space: nowrap;
  text-align: center;
  font-size: 13px;
}

.reprint-sales-grid th,
.reprint-items-grid th {
  background: #d8e8f2;
  color: #111;
  font-weight: 700;
}

.reprint-sales-grid tbody tr.selected td,
.reprint-items-grid tbody tr.selected td {
  background: #b8d8e8;
}

.reprint-sales-grid tbody tr:hover td,
.reprint-items-grid tbody tr:hover td {
  background: #e6f2f7;
}

.reprint-items-grid tbody tr:nth-child(even) td {
  background: #fff8da;
}

.reprint-items-grid .recycle-row td {
  color: #b10000;
}

.reprint-detail-title {
  display: flex;
  align-items: center;
  justify-content: center;
  border-top: 1px solid #a8b8c4;
  border-bottom: 1px solid #a8b8c4;
  background: #eef7fb;
  color: #0071c8;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 8px;
}

.quality-preview-dialog {
  width: min(1420px, calc(100vw - 18px));
  height: calc(100vh - 18px);
  max-width: none;
  max-height: none;
  padding: 0;
  border: 1px solid #194f81;
  border-radius: 2px;
  background: #858585;
}

.quality-preview-toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 36px;
  padding: 4px 8px;
  border-bottom: 1px solid #87adbd;
  background: linear-gradient(#cdf3f4, #9dccd7);
}

.quality-preview-toolbar label {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
}

.quality-preview-toolbar input,
.quality-preview-toolbar select {
  height: 26px;
  border: 1px solid #8fa6b7;
  padding: 2px 5px;
  background: #fff;
}

.quality-preview-toolbar input {
  width: 76px;
}

.quality-print-hint {
  padding: 5px 12px;
  border-bottom: 1px solid #9abccc;
  background: #fff8df;
  color: #9a3b00;
  font-size: 12px;
  line-height: 1.45;
}

.quality-preview-stage {
  height: calc(100% - 64px);
  overflow: auto;
  padding: 24px 0 60px;
  background: #808080;
}

.quality-preview-page {
  margin: 0 auto;
  background: #fff;
  box-shadow: 0 0 0 3px #174b82;
  position: relative;
  overflow: hidden;
}

.quality-report {
  box-sizing: border-box;
  width: var(--receipt-paper-width, 210mm);
  height: var(--receipt-paper-height, 101.6mm);
  min-height: var(--receipt-paper-height, 101.6mm);
  padding: 0;
  color: #1d2b38;
  background: #fff;
  font-family: "Microsoft YaHei", Arial, sans-serif;
  font-size: 13px;
  position: relative;
  overflow: hidden;
}

.quality-report p {
  margin: 4px 0;
}

.quality-report-canvas {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: inherit;
  overflow: hidden;
}

.report-node {
  position: absolute;
  box-sizing: border-box;
  white-space: pre-line;
  line-height: 1.25;
  overflow: hidden;
  max-width: 100%;
}

.report-node[data-report-node="table"] {
  overflow: hidden;
  height: 30mm;
}

.report-node[data-report-node="table"] .report-table {
  width: 100%;
  table-layout: fixed;
  font-size: 7px;
  border-collapse: collapse;
}

.report-node[data-report-node="table"] .report-table th,
.report-node[data-report-node="table"] .report-table td {
  min-width: 0;
  padding: 0.45mm 0.35mm;
  font-size: 7px;
  line-height: 1.25;
  overflow-wrap: anywhere;
  word-break: break-word;
  white-space: normal;
}

/* The quality-report canvas is a fixed-size paper.  Force all nine item
   columns to share that paper width so none can be clipped on the right. */
#qualityPreviewPage .report-node[data-report-node="table"] .report-table,
#qualityPreviewPage .quality-report-items-table {
  width: 100% !important;
  min-width: 0 !important;
  max-width: 100% !important;
  table-layout: fixed !important;
}

#qualityPreviewPage .report-node[data-report-node="table"] .report-table col,
#qualityPreviewPage .quality-report-items-table col {
  width: 11.111% !important;
}

#qualityPreviewPage .report-node[data-report-node="table"] .report-table th,
#qualityPreviewPage .report-node[data-report-node="table"] .report-table td,
#qualityPreviewPage .quality-report-items-table th,
#qualityPreviewPage .quality-report-items-table td {
  display: table-cell !important;
  width: 11.111% !important;
  min-width: 0 !important;
  max-width: 11.111% !important;
  padding: 0.35mm 0.2mm !important;
  font-size: 6.4px !important;
  line-height: 1.2 !important;
  overflow-wrap: anywhere !important;
  word-break: break-all !important;
  white-space: normal !important;
}

.report-copy-node p {
  margin: 0;
  line-height: 1.15;
}

.report-title-node .report-value {
  display: block;
  width: 100%;
  text-align: inherit;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.quality-design-mode .report-node {
  outline: 1px dashed rgba(18, 99, 160, 0.4);
  cursor: move;
  user-select: none;
}

.quality-design-mode .report-node.selected {
  outline: 2px solid #e23a3a;
  background: rgba(255, 245, 245, 0.25);
}

.quality-design-mode .report-node::after {
  content: "";
  position: absolute;
  right: -4px;
  bottom: -4px;
  width: 8px;
  height: 8px;
  background: #e23a3a;
  border: 1px solid #fff;
  border-radius: 50%;
  opacity: 0;
}

.quality-design-mode .report-node.selected::after {
  opacity: 1;
}

.quality-report-head {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18mm;
  margin-bottom: 8mm;
}

.quality-report-head strong {
  display: block;
  margin-bottom: 4mm;
  text-align: center;
  font-size: 14px;
}

.quality-report-table {
  width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
}

.quality-report-items-table th,
.quality-report-items-table td {
  min-width: 0;
}

.quality-report-items-table th {
  white-space: nowrap;
}

.quality-report-table th,
.quality-report-table td {
  min-height: 7mm;
  border: 0;
  padding: 2mm 2mm;
  text-align: center;
  vertical-align: top;
  font-size: 13px;
}

.quality-report-table th {
  font-weight: 800;
}

.quality-report-footer {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1.2fr;
  gap: 12mm;
  margin-top: 20mm;
  align-items: end;
}

.quality-report-footer strong {
  display: block;
  text-align: center;
  font-size: 18px;
}

.sale-report .quality-report-head {
  gap: 12mm;
  margin-bottom: 6mm;
}

.sale-report .quality-report-head strong {
  font-size: 15px;
}

.sale-report .quality-report-table th,
.sale-report .quality-report-table td {
  font-size: 8.5px;
  padding: 0.8mm 1.2mm;
}

.sale-report .quality-report-footer {
  margin-top: 14mm;
}

.sale-report .quality-report-footer strong {
  font-size: 22px;
}

.sale-slip {
  box-sizing: border-box;
  width: 210mm;
  min-height: 101.6mm;
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: #fff;
  color: #111;
  font-family: "Microsoft YaHei", Arial, sans-serif;
}

.sale-slip-copy {
  box-sizing: border-box;
  min-height: 101.6mm;
  padding: 4mm 4.5mm 3mm;
  font-size: 10px;
  line-height: 1.35;
}

.sale-slip-copy + .sale-slip-copy {
  border-left: 1px dashed #555;
}

.sale-slip-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 3mm;
  padding-bottom: 1.5mm;
  border-bottom: 1px solid #333;
}

.sale-slip-head strong {
  font-size: 13px;
}

.sale-slip-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1mm 3mm;
  margin-bottom: 2mm;
}

.sale-slip-meta p {
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sale-slip-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

.sale-slip-table th,
.sale-slip-table td {
  border-bottom: 1px dotted #666;
  padding: 1.2mm 1mm;
  font-size: 9px;
  line-height: 1.2;
  vertical-align: top;
  word-break: break-all;
}

.sale-slip-table th:nth-child(1),
.sale-slip-table td:nth-child(1) { width: 29%; }
.sale-slip-table th:nth-child(2),
.sale-slip-table td:nth-child(2) { width: 39%; }
.sale-slip-table th:nth-child(3),
.sale-slip-table td:nth-child(3) { width: 11%; text-align: center; }
.sale-slip-table th:nth-child(4),
.sale-slip-table td:nth-child(4) { width: 21%; text-align: right; }

.sale-slip-summary {
  display: flex;
  justify-content: space-between;
  gap: 6px;
  margin-top: 2mm;
  font-size: 10px;
}

.sale-slip-footer {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-top: 4mm;
  padding-top: 1.5mm;
  border-top: 1px solid #333;
  font-size: 10px;
}

.sale-slip-divider {
  display: none;
}

.cancel-sale-dialog {
  width: min(1260px, calc(100vw - 30px));
  max-height: calc(100vh - 34px);
  border: 1px solid #315f86;
  border-radius: 2px;
  padding: 0;
  background: #eaf4f8;
}

.cancel-sale-toolbar {
  display: grid;
  grid-template-columns: 82px 96px 82px auto 72px minmax(260px, 1fr);
  gap: 8px;
  align-items: center;
  padding: 10px;
  border-bottom: 1px solid #9fb2be;
  background: linear-gradient(135deg, #bce9df 0, #eaf4f8 60%);
  color: #d51920;
  font-size: 14px;
}

.cancel-sale-toolbar label {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  align-items: center;
  gap: 6px;
  color: #4e6072;
}

.cancel-sale-toolbar input {
  height: 30px;
  border: 1px solid #b8c9d4;
  padding: 2px 8px;
}

.cancel-sale-toolbar button {
  min-height: 32px;
  border: 1px solid #9caeb8;
  border-radius: 2px;
  background: linear-gradient(#fff, #d4e2ea);
  color: #111;
  font-weight: 700;
}

.cancel-sale-body {
  display: grid;
  grid-template-rows: minmax(230px, 42vh) auto minmax(170px, 28vh);
  gap: 6px;
  padding: 8px;
  background: #eef2f5;
}

.cancel-sale-body h3 {
  margin: 0;
  color: #1263a0;
  text-align: center;
  font-size: 18px;
  letter-spacing: 0;
}

#cancelSaleResult,
#cancelSaleItemsResult {
  min-height: 0;
  overflow: auto;
  border: 1px solid #9fb2be;
  background: #fff;
}

#cancelSaleResult table,
#cancelSaleItemsResult table {
  min-width: 1120px;
  width: 100%;
  border-collapse: collapse;
}

#cancelSaleResult th,
#cancelSaleResult td,
#cancelSaleItemsResult th,
#cancelSaleItemsResult td {
  height: 28px;
  border: 1px solid #c5cdd4;
  padding: 0 6px;
  white-space: nowrap;
  text-align: center;
  font-size: 13px;
}

#cancelSaleResult th,
#cancelSaleItemsResult th {
  background: #d8e8f2;
}

#cancelSaleResult tbody tr:nth-child(even) td,
#cancelSaleItemsResult tbody tr:nth-child(even) td {
  background: #fff5d6;
}

#cancelSaleResult tbody tr.selected td {
  background: #cfe2f4;
}

.print-area {
  display: none;
}

@media (max-width: 1100px) {
  body {
    overflow: auto;
  }

  .pos-workbench {
    height: auto;
    min-height: 100vh;
    grid-template-rows: 30px 420px auto auto 28px;
  }

  .pos-bottom {
    grid-template-columns: 1fr;
  }

  .settlement-grid,
  .member-grid {
    grid-template-columns: 1fr 1fr;
  }

  .shortcut-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* 收银商品列表：按门店要求，整行信息更醒目、易核对。 */
.pos-table th,
.pos-table td,
.pos-table td input,
.pos-table td span {
  font-weight: 800;
}

.pos-table th {
  height: 42px;
  font-size: clamp(13px, .86vw, 18px);
}

.pos-table td {
  height: 39px;
  font-size: clamp(12px, .78vw, 16px);
}

.pos-table td input {
  height: 37px;
}

body.front-hide-weight .pos-table th:nth-child(4),
body.front-hide-weight .pos-table td:nth-child(4),
body.front-hide-labor-fee .pos-table th:nth-child(6),
body.front-hide-labor-fee .pos-table td:nth-child(6),
body.front-hide-sale-price .pos-table th:nth-child(11),
body.front-hide-sale-price .pos-table td:nth-child(11),
body.front-hide-labor-method .pos-table th:nth-child(16),
body.front-hide-labor-method .pos-table td:nth-child(16),
body.front-hide-extra-fee .pos-table th:nth-child(18),
body.front-hide-extra-fee .pos-table td:nth-child(18) {
  display: none;
}

.front-settings-dialog {
  width: min(1040px, 92vw);
  max-width: 92vw;
  min-height: 620px;
  padding: 0;
  overflow: hidden;
  border: 2px solid #21568f;
  background: #eef7fb;
  color: #152f4a;
  box-shadow: 0 18px 50px rgba(0, 0, 0, .35);
}

.front-settings-dialog::backdrop {
  background: rgba(0, 0, 0, .45);
}

.front-settings-head {
  height: 46px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 15px;
  color: #fff;
  background: linear-gradient(135deg, #123a6f, #2468a8 72%, #3e8ac0);
  font-size: 22px;
  font-weight: 800;
}

.front-settings-head strong::before {
  content: "●";
  color: #ffd62f;
  margin-right: 9px;
  font-size: 18px;
}

.front-settings-head button {
  border: 0;
  background: transparent;
  color: #fff;
  font-size: 28px;
  cursor: pointer;
}

.front-settings-body {
  min-height: 500px;
  padding: 12px 18px 18px;
  background: linear-gradient(#fff, #edf7fb);
}

.front-settings-tabs {
  display: flex;
  gap: 2px;
  border-bottom: 1px solid #97b3ca;
}

.front-settings-tabs button {
  padding: 8px 14px;
  border: 1px solid #9eb5c7;
  border-bottom: 0;
  border-radius: 5px 5px 0 0;
  background: #e6f0f6;
  color: #1b4367;
  font-size: 18px;
  font-weight: 800;
  cursor: pointer;
}

.front-settings-tabs button.active {
  background: #fff;
  color: #122f4b;
  transform: translateY(1px);
}

.front-settings-panel {
  min-height: 420px;
  padding: 20px 12px;
}

.front-settings-note-label {
  display: block;
  margin-bottom: 8px;
  font-size: 20px;
  font-weight: 800;
}

.front-settings-note-label em {
  margin-left: 12px;
  color: #e31919;
  font-size: 15px;
  font-style: normal;
}

.front-settings-dialog textarea,
.front-settings-dialog input,
.front-settings-dialog select {
  box-sizing: border-box;
  border: 1px solid #97aec2;
  border-radius: 2px;
  background: #fff;
  color: #142f4b;
  font: inherit;
}

.front-settings-dialog textarea {
  width: 100%;
  min-height: 230px;
  padding: 10px;
  resize: vertical;
  font-size: 18px;
  line-height: 1.55;
}

.front-settings-inline,
.front-settings-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px 30px;
  margin-top: 18px;
  max-width: 820px;
}

.front-settings-inline label,
.front-settings-form-grid label {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #173e60;
  font-size: 18px;
  font-weight: 800;
}

.front-settings-inline input,
.front-settings-form-grid input,
.front-settings-form-grid select {
  flex: 1;
  min-width: 0;
  height: 38px;
  padding: 0 9px;
  font-size: 17px;
}

.front-settings-inline .front-settings-check,
.front-settings-form-grid .front-settings-check {
  justify-content: flex-start;
}

.front-settings-check input,
.front-settings-check-grid input {
  flex: 0 0 auto;
  width: 19px;
  height: 19px;
}

.front-settings-check-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px 28px;
  padding-top: 18px;
}

.front-settings-check-grid label {
  display: flex;
  align-items: center;
  gap: 9px;
  color: #173e60;
  font-size: 18px;
  font-weight: 800;
}

.front-settings-footer {
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 40px;
  padding: 10px 24px;
  border-top: 1px solid #9bb6c9;
  background: #e6f1f7;
}

.front-settings-footer span {
  flex: 1;
  color: #17642b;
  font-size: 15px;
  font-weight: 700;
}

.front-settings-footer button {
  min-width: 140px;
  height: 42px;
  border: 1px solid #7195af;
  background: linear-gradient(#fff, #d4e6f0);
  color: #173e60;
  font-size: 21px;
  font-weight: 800;
  cursor: pointer;
}

.front-settings-footer #frontSettingsSaveBtn {
  background: linear-gradient(#e9fbff, #a8d5ea);
}

@media (max-width: 760px) {
  .front-settings-dialog { width: 96vw; min-height: 0; }
  .front-settings-body { min-height: 0; }
  .front-settings-tabs { overflow-x: auto; }
  .front-settings-tabs button { white-space: nowrap; font-size: 15px; }
  .front-settings-inline,
  .front-settings-form-grid,
  .front-settings-check-grid { grid-template-columns: 1fr; }
}

/* 质保单 v25：210mm × 101.6mm 针式打印增强可读性 */
.quality-report.sale-report,
.print-area .quality-report.sale-report {
  color: #000 !important;
  font-family: "Microsoft YaHei", "SimSun", Arial, sans-serif !important;
  font-weight: 700;
  text-rendering: geometricPrecision;
}

.quality-report.sale-report .report-node:not([data-report-node="table"]) {
  color: #000 !important;
  font-size: 10.5px !important;
  font-weight: 700 !important;
  line-height: 1.32 !important;
}

.quality-report.sale-report .report-title-node .report-value,
.quality-report.sale-report .report-amount-node strong {
  color: #000 !important;
  font-size: 18px !important;
  font-weight: 900 !important;
  line-height: 1.15 !important;
  letter-spacing: .08mm;
}

.quality-report.sale-report .report-copy-node p {
  color: #000 !important;
  font-size: 10.5px !important;
  font-weight: 700 !important;
  line-height: 1.32 !important;
}

.quality-report.sale-report .report-node[data-report-node="table"] .report-table,
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table {
  color: #000 !important;
  font-size: 10px !important;
  font-weight: 700 !important;
}

.quality-report.sale-report .report-node[data-report-node="table"] .report-table th,
.quality-report.sale-report .report-node[data-report-node="table"] .report-table td,
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table th,
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table td {
  color: #000 !important;
  font-size: 10px !important;
  font-weight: 700 !important;
  line-height: 1.28 !important;
  padding: .65mm .35mm !important;
}

.quality-report.sale-report .report-node[data-report-node="table"] .report-table th,
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table th {
  font-size: 10.5px !important;
  font-weight: 900 !important;
}

/* 兼容已保存的旧模板：即使旧模板仍有这两个节点，也不再显示。 */
#qualityPreviewPage [data-report-node="companyAddress"],
#qualityPreviewPage [data-report-node="companyPhone"],
.print-area [data-report-node="companyAddress"],
.print-area [data-report-node="companyPhone"] {
  display: none !important;
}

/* 金料由收银端部分出库，实时显示同一条码的剩余克重。 */
.gold-material-pos-panel {
  padding: 0 8px 8px;
  color: #233447;
  background: #eef7fb;
}

.gold-material-pos-head {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 28px;
  border-bottom: 1px solid #9bb6c4;
}

.gold-material-pos-head h2 {
  margin: 0;
  font-size: 17px;
  line-height: 28px;
  white-space: nowrap;
}

.gold-material-pos-head button {
  margin-left: auto;
}

.gold-material-pos-head span {
  min-width: 0;
  color: #526c82;
  font-size: 12px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.gold-material-pos-query,
.gold-material-pos-form {
  display: grid;
  gap: 6px;
  margin-top: 8px;
}

.gold-material-pos-query {
  grid-template-columns: minmax(0, 1fr) auto;
}

.gold-material-pos-form {
  grid-template-columns: minmax(0, .82fr) minmax(0, 1.18fr) auto;
  align-items: end;
}

.gold-material-pos-panel label {
  display: grid;
  gap: 3px;
  color: #40576d;
  font-size: 12px;
}

.gold-material-pos-panel input {
  width: 100%;
  min-width: 0;
  height: 28px;
  padding: 3px 6px;
  border: 1px solid #8eabb8;
  background: #fff;
  color: #111;
  font-size: 13px;
}

.gold-material-pos-panel button {
  min-height: 28px;
  border: 1px solid #798a99;
  border-radius: 0;
  padding: 0 9px;
  color: #111;
  background: linear-gradient(#ffffff, #dbe6ee);
  font-size: 13px;
  white-space: nowrap;
}

.gold-material-pos-panel button:disabled,
.gold-material-pos-panel input:disabled {
  cursor: not-allowed;
  opacity: .6;
}

.gold-material-pos-panel p {
  margin: 7px 0 0;
  color: #526c82;
  font-size: 12px;
  line-height: 1.35;
}

@media (max-width: 1100px) {
  .gold-material-pos-form { grid-template-columns: 1fr 1fr; }
  .gold-material-pos-form button { grid-column: 1 / -1; }
}

@media print {
  @page {
    size: 210mm 101.6mm;
    margin: 0;
  }

  html,
  body {
    margin: 0 !important;
    padding: 0 !important;
    width: var(--active-print-paper-width, 210mm) !important;
    min-width: var(--active-print-paper-width, 210mm) !important;
    max-width: var(--active-print-paper-width, 210mm) !important;
    height: var(--active-print-paper-height, 101.6mm) !important;
    min-height: var(--active-print-paper-height, 101.6mm) !important;
    max-height: var(--active-print-paper-height, 101.6mm) !important;
    overflow: hidden !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  body > *:not(.print-area) {
    display: none !important;
  }

  .print-area {
    position: absolute !important;
    inset: 0 !important;
    display: block !important;
    width: var(--active-print-paper-width, 210mm) !important;
    min-width: var(--active-print-paper-width, 210mm) !important;
    max-width: var(--active-print-paper-width, 210mm) !important;
    height: var(--active-print-paper-height, 101.6mm) !important;
    min-height: var(--active-print-paper-height, 101.6mm) !important;
    max-height: var(--active-print-paper-height, 101.6mm) !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
    font-family: "Microsoft YaHei", Arial, sans-serif !important;
    break-before: avoid !important;
    break-after: avoid !important;
    break-inside: avoid !important;
  }

  .print-area .quality-report {
    width: var(--active-print-paper-width, 210mm) !important;
    min-width: var(--active-print-paper-width, 210mm) !important;
    max-width: var(--active-print-paper-width, 210mm) !important;
    height: var(--active-print-paper-height, 101.6mm) !important;
    min-height: var(--active-print-paper-height, 101.6mm) !important;
    max-height: var(--active-print-paper-height, 101.6mm) !important;
    margin: 0 !important;
    box-shadow: none !important;
    page-break-after: avoid !important;
    break-before: avoid !important;
    break-after: avoid !important;
    break-inside: avoid !important;
  }

  .print-area .quality-report-canvas {
    overflow: hidden;
  }

  .print-area > * ~ * {
    display: none !important;
  }

  .sale-slip {
    width: var(--active-print-paper-width, 210mm) !important;
    height: var(--active-print-paper-height, 101.6mm) !important;
    box-shadow: none !important;
    page-break-after: avoid !important;
  }

  .sale-slip-copy {
    min-height: 101.6mm;
    box-shadow: none;
    page-break-after: avoid;
  }

  .sale-slip-divider {
    display: none !important;
  }
}

/* 20260728-quality-columns-v26: keep all warranty item fields on one 210 x 101.6mm page. */
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"],
.print-area .quality-report.sale-report .report-node[data-report-node="table"] {
  left: 6mm !important;
  width: calc(100% - 12mm) !important;
  max-width: calc(100% - 12mm) !important;
  overflow: visible !important;
}

#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table,
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table {
  width: 100% !important;
  min-width: 0 !important;
  max-width: 100% !important;
  table-layout: fixed !important;
  border-collapse: collapse !important;
}

#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(1),
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(1) { width: 14% !important; }
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(2),
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(2) { width: 20% !important; }
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(3),
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(3) { width: 7% !important; }
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(4),
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(4) { width: 8% !important; }
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(5),
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(5) { width: 10% !important; }
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(6),
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(6) { width: 9% !important; }
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(7),
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(7) { width: 9% !important; }
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(8),
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(8) { width: 13% !important; }
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(9),
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(9) { width: 10% !important; }

#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table th,
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table td,
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table th,
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table td {
  display: table-cell !important;
  visibility: visible !important;
  box-sizing: border-box !important;
  padding: .45mm .2mm !important;
  color: #000 !important;
  font-size: 8.4px !important;
  line-height: 1.2 !important;
  font-weight: 700 !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}

#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table th,
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table th {
  font-size: 8.8px !important;
  font-weight: 900 !important;
  white-space: nowrap !important;
}

#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table td,
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table td {
  white-space: normal !important;
  overflow-wrap: anywhere !important;
  word-break: break-all !important;
}
/* 20260728-quality-designer-v27 */
.quality-design-text-tools {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: 8px;
  font-weight: 700;
  color: #173b62;
}

.quality-design-text-tools label {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.quality-design-text-tools input {
  width: 58px;
  height: 30px;
}

.quality-design-text-tools button {
  min-width: 58px;
}

#qualityPreviewPage.quality-design-mode,
#qualityPreviewPage.quality-design-mode .quality-report,
#qualityPreviewPage.quality-design-mode .quality-report-canvas {
  overflow: visible !important;
}

#qualityPreviewPage.quality-design-mode .report-node {
  max-width: none !important;
  overflow: visible !important;
  touch-action: none;
}

.quality-report.sale-report .report-node:not([data-report-node="table"]) {
  font-size: var(--report-font-size, 10.5px) !important;
}

.quality-report.sale-report .report-node:not([data-report-node="table"]) .report-value,
.quality-report.sale-report .report-node:not([data-report-node="table"]) p,
.quality-report.sale-report .report-node:not([data-report-node="table"]) strong {
  font-size: inherit !important;
}

#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"],
.print-area .quality-report.sale-report .report-node[data-report-node="table"] {
  height: auto !important;
  min-height: 30mm !important;
  overflow: visible !important;
}

#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table th,
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table th {
  font-size: 17.6px !important;
  line-height: 1.15 !important;
}

#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table td,
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table td {
  font-size: 16.8px !important;
  line-height: 1.15 !important;
}

#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table th *,
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table td *,
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table th *,
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table td * {
  font-size: inherit !important;
}

/* 20260729-quality-designer-v28: one source of truth for preview and print. */
.quality-preview-dialog[open] {
  display: grid;
  grid-template-rows: auto auto auto minmax(0, 1fr);
}

.quality-preview-toolbar {
  box-sizing: border-box;
  height: auto;
  min-height: 44px;
  flex-wrap: wrap;
  align-items: center;
}

.quality-preview-stage {
  height: auto;
  min-height: 0;
}

.quality-design-text-tools {
  flex-wrap: wrap;
  max-width: min(1040px, calc(100vw - 40px));
}

.quality-design-content-label {
  align-items: flex-start !important;
}

.quality-design-text-tools textarea {
  box-sizing: border-box;
  width: 180px;
  min-height: 34px;
  padding: 4px 6px;
  resize: both;
  font: inherit;
}

.quality-report.sale-report .report-node:not([data-report-node="table"]),
#qualityPreviewPage .quality-report.sale-report .report-node:not([data-report-node="table"]),
.print-area .quality-report.sale-report .report-node:not([data-report-node="table"]) {
  max-width: none !important;
  overflow: visible !important;
  font-size: var(--report-font-size, 10px) !important;
  font-weight: inherit;
}

.quality-report.sale-report .report-node:not([data-report-node="table"]) .report-value,
.quality-report.sale-report .report-node:not([data-report-node="table"]) .report-editable-text,
.quality-report.sale-report .report-node:not([data-report-node="table"]) p,
.quality-report.sale-report .report-node:not([data-report-node="table"]) strong {
  max-width: none !important;
  overflow: visible !important;
  text-overflow: clip !important;
  font-size: inherit !important;
  line-height: 1.22 !important;
}

.quality-report.sale-report .report-editable-text {
  display: block;
  white-space: pre-wrap;
}

#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"],
.print-area .quality-report.sale-report .report-node[data-report-node="table"] {
  left: var(--report-node-left, 5mm) !important;
  top: var(--report-node-top, 32mm) !important;
  width: var(--report-node-width, 200mm) !important;
  max-width: none !important;
  height: auto !important;
  min-height: 30mm !important;
  overflow: visible !important;
  font-size: var(--report-font-size, 8.4px) !important;
}

#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table,
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table {
  width: 100% !important;
  min-width: 0 !important;
  max-width: 100% !important;
  table-layout: fixed !important;
  border-collapse: collapse !important;
  font-size: inherit !important;
  font-weight: inherit !important;
}

#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(1),
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(1) { width: 15% !important; }
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(2),
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(2) { width: 19% !important; }
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(3),
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(3) { width: 6% !important; }
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(4),
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(4) { width: 8% !important; }
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(5),
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(5) { width: 10% !important; }
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(6),
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(6) { width: 9% !important; }
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(7),
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(7) { width: 9% !important; }
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(8),
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(8) { width: 14% !important; }
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(9),
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table col:nth-child(9) { width: 10% !important; }

#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table th,
#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table td,
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table th,
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table td {
  display: table-cell !important;
  visibility: visible !important;
  box-sizing: border-box !important;
  min-width: 0 !important;
  max-width: none !important;
  min-height: 0 !important;
  height: auto !important;
  padding: .38mm .18mm !important;
  color: #000 !important;
  font-size: inherit !important;
  line-height: 1.15 !important;
  font-weight: inherit !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  overflow-wrap: normal !important;
  word-break: normal !important;
  text-overflow: clip !important;
  vertical-align: middle !important;
}

#qualityPreviewPage .quality-report.sale-report .report-node[data-report-node="table"] .report-table th,
.print-area .quality-report.sale-report .report-node[data-report-node="table"] .report-table th {
  font-weight: 800 !important;
}

/* Legacy templates may still contain these fields; they are permanently removed. */
#qualityPreviewPage [data-report-node="companyAddress"],
#qualityPreviewPage [data-report-node="companyPhone"],
.print-area [data-report-node="companyAddress"],
.print-area [data-report-node="companyPhone"] {
  display: none !important;
}
