/* Thermal-safe output is intentionally isolated from the main responsive shell. */
[data-bmi-pool-preview] {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.print-label .barcode-128 {
  display: block;
  width: 100%;
  height: 64px;
  background: #fff;
  shape-rendering: crispEdges;
}

.print-label-card {
  display: grid;
  gap: 8px;
  justify-items: start;
}

.print-label[data-label-preset] {
  box-sizing: border-box;
  margin: 0;
  overflow: hidden;
  color: #000;
  border-color: #000;
  background: #fff;
}

.print-label__qr {
  display: grid;
  place-items: center;
  background: #fff;
}

.print-label__qr svg {
  display: block;
  width: 100%;
  height: 100%;
}

.print-label__qr-unavailable {
  color: #b91c1c;
  font-weight: 800;
}

.print-label--bmi {
  width: 40mm;
  min-width: 40mm;
  height: 30mm;
  min-height: 30mm;
  grid-template-rows: auto 1fr auto;
  gap: 1mm;
  padding: 2mm;
}

.print-label--bmi strong {
  font-size: 9pt;
  letter-spacing: .08em;
  text-align: center;
}

.print-label--bmi .print-label__qr {
  min-height: 0;
}

.print-label--bmi code {
  padding: 0;
  overflow: visible;
  background: transparent;
  color: #000;
  font-size: 8pt;
  font-weight: 800;
  letter-spacing: .04em;
  text-align: center;
}

.print-label--bml {
  width: 4in;
  min-width: 4in;
  height: 2in;
  min-height: 2in;
  grid-template-columns: 1fr 1.1fr;
  grid-template-rows: auto auto 1fr auto auto;
  gap: 2mm;
  padding: 4mm;
}

.print-label--bml > strong,
.print-label--bml > b {
  grid-column: 1 / -1;
}

.print-label--bml > strong {
  font-size: 11pt;
  letter-spacing: .08em;
}

.print-label--bml > b {
  font-size: 24pt;
  line-height: 1;
}

.print-label--bml .print-label__qr {
  min-height: 0;
}

.print-label--bml .barcode-128 {
  align-self: center;
  height: 52px;
}

.print-label--bml code {
  grid-column: 1 / -1;
  padding: 0;
  overflow: visible;
  background: transparent;
  color: #000;
  font-size: 10pt;
  font-weight: 800;
}

.warehouse-label-preview.is-label-preview-revealed,
[data-bmi-pool-preview].is-label-preview-revealed {
  outline: 3px solid #14b8a6;
  outline-offset: 4px;
}

.barcode-camera-modal {
  position: fixed;
  z-index: 1300;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(2, 6, 23, .78);
}

.barcode-camera-modal[hidden] {
  display: none;
}

.barcode-camera-modal__panel {
  display: grid;
  gap: 12px;
  width: min(100%, 440px);
  padding: 16px;
  border-radius: 12px;
  background: #fff;
  color: #061b36;
}

.barcode-camera-modal__heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.barcode-camera-modal__panel video {
  width: 100%;
  max-height: min(58vh, 420px);
  border-radius: 8px;
  background: #020617;
  object-fit: cover;
}

.barcode-camera-modal__panel p {
  margin: 0;
  color: #475569;
}

@media print {
  .print-label {
    position: static;
    width: 92mm;
    max-width: 92mm;
    margin: 0 0 4mm;
    break-inside: avoid;
  }

  .print-label-card [data-print-barcode-label] {
    display: none !important;
  }

  [data-barcode-print-suppressed] {
    display: none !important;
  }

  .print-label[data-label-preset] {
    position: fixed;
    top: 0;
    left: 0;
    border: 0;
    box-shadow: none;
  }
}
