/* Live 尺寸重量 parameter card (IBR / PaiShuJiaGe / Glazed / staff IBR).
   Card adapts to table width; table adapts to text width. */
.size-weight-card,
#parametersSection .size-weight-card,
#parametersSection.quote-backend-params-flat > .size-weight-card,
.parameter-group-grid .size-weight-card,
.parameter-group-grid > .size-weight-card {
  width: max-content !important;
  max-width: 100% !important;
  min-width: 0 !important;
  flex: 0 0 auto !important;
  box-sizing: border-box !important;
  overflow: visible !important;
}
.size-weight-card .calc-table-wrap,
#parametersSection .size-weight-card .calc-table-wrap,
#parametersSection.quote-backend-params-flat .size-weight-card .calc-table-wrap,
.parameter-group-grid .size-weight-card .calc-table-wrap {
  width: max-content !important;
  max-width: 100% !important;
  min-width: 0 !important;
  overflow-x: auto !important;
  overflow-y: visible !important;
  -webkit-overflow-scrolling: touch;
}
.size-weight-card .calc-table,
#parametersSection .size-weight-card .calc-table,
#parametersSection.quote-backend-params-flat .size-weight-card .calc-table,
.parameter-group-grid .size-weight-card .calc-table {
  width: max-content !important;
  min-width: 0 !important;
  max-width: none !important;
  table-layout: auto !important;
}
.size-weight-card .calc-table th:nth-child(1),
.size-weight-card .calc-table td:nth-child(1),
.size-weight-card .calc-table th:nth-child(2),
.size-weight-card .calc-table td:nth-child(2),
.size-weight-card .calc-table th:nth-child(4),
.size-weight-card .calc-table td:nth-child(4) {
  width: 1% !important;
  white-space: nowrap !important;
}
.size-weight-card .calc-table th:nth-child(3),
.size-weight-card .calc-table td:nth-child(3),
.size-weight-card .calc-table th:nth-child(5),
.size-weight-card .calc-table td:nth-child(5),
#parametersSection .size-weight-card .calc-table td:nth-child(3),
#parametersSection .size-weight-card .calc-table td:nth-child(5) {
  white-space: nowrap !important;
  min-width: 0 !important;
  max-width: none !important;
  line-height: 1.35 !important;
}

.size-weight-card .calc-table thead th {
  text-align: center !important;
  white-space: nowrap !important;
}

/* Staff IBR: same values, hide the formula columns; card can shrink to content. */
.size-weight-card.is-staff {
  width: max-content !important;
  overflow: visible !important;
}
.size-weight-card.is-staff .calc-table-wrap,
.size-weight-card.is-staff .calc-table {
  width: max-content !important;
  table-layout: auto !important;
}
.size-weight-card.is-staff .calc-table th:nth-child(3),
.size-weight-card.is-staff .calc-table td:nth-child(3),
.size-weight-card.is-staff .calc-table th:nth-child(5),
.size-weight-card.is-staff .calc-table td:nth-child(5) {
  display: none !important;
}

.parameter-group-card .parameter-group-grid > .size-weight-card {
  width: max-content !important;
  max-width: 100% !important;
  justify-self: start !important;
}
