/* Label harga rak — dipakai pratinjau di aplikasi & halaman cetak. Selalu kertas putih, tinta hitam.
 * Semua ukuran dalam mm/pt agar presisi saat dicetak. */
.plabel {
  --pl-pad: 2mm; box-sizing: border-box; display: flex; flex-direction: column; overflow: hidden;
  padding: var(--pl-pad); background: #fff; color: #000; font-family: "Helvetica Neue", Arial, system-ui, sans-serif;
  line-height: 1.15; text-align: left; border: .2mm dashed #9ca3af; break-inside: avoid; page-break-inside: avoid;
  -webkit-print-color-adjust: exact; print-color-adjust: exact;
}
.plabel .pl-store { font-size: .62em; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: #374151; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-bottom: .2em; }
.plabel .pl-name { font-weight: 700; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; overflow-wrap: anywhere; }
.plabel .pl-price { display: flex; align-items: baseline; gap: .12em; margin-top: auto; padding-top: .1em; white-space: nowrap; font-variant-numeric: tabular-nums; }
.plabel .pl-price b { font-size: 2.5em; font-weight: 800; letter-spacing: -.02em; line-height: 1; }
.plabel .pl-price.len-m b { font-size: 2.1em; }
.plabel .pl-price.len-l b { font-size: 1.7em; }
.plabel .pl-cur { font-size: 1em; font-weight: 800; align-self: flex-start; margin-top: .15em; }
.plabel .pl-per { font-size: .85em; font-weight: 600; margin-left: .3em; overflow: hidden; text-overflow: ellipsis; }
.plabel .pl-extra { font-size: .72em; font-weight: 600; color: #111; margin-top: .25em; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.plabel .pl-foot { display: flex; align-items: flex-end; justify-content: space-between; gap: 1.5mm; margin-top: .35em; min-height: 0; }
.plabel .pl-bc { display: flex; flex-direction: column; align-items: center; flex: none; }
.plabel .pl-bc span { font-size: .55em; letter-spacing: .08em; line-height: 1; margin-top: .2mm; font-variant-numeric: tabular-nums; }
.plabel .pl-bars { display: block; width: 30mm; height: 5.5mm; fill: #000; }
.plabel .pl-meta { font-size: .55em; color: #374151; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-left: auto; text-align: right; }

/* ---------- ukuran ---------- */
.plabel.sz-small  { height: 28mm; font-size: 7.5pt; --pl-pad: 1.6mm; }
.plabel.sz-small .pl-bars { width: 24mm; height: 4mm; }
.plabel.sz-small .pl-extra { -webkit-line-clamp: 1; }
.plabel.sz-medium { height: 40mm; font-size: 9.5pt; --pl-pad: 2.4mm; }
.plabel.sz-medium .pl-bars { width: 31mm; height: 6mm; }
.plabel.sz-large  { height: 56mm; font-size: 13pt; --pl-pad: 3.5mm; }
.plabel.sz-large .pl-bars { width: 38mm; height: 8mm; }
.plabel.sz-thermal { font-size: 9.5pt; --pl-pad: 2mm 1mm 2.5mm; border: 0; border-bottom: .3mm dashed #000; min-height: 24mm; }
.plabel.sz-thermal .pl-price { margin-top: 1mm; }
.plabel.sz-thermal .pl-bars { width: 30mm; height: 6mm; }

/* ---------- lembar ---------- */
.pl-page { display: grid; align-content: start; break-after: page; page-break-after: always; }
.pl-page:last-child { break-after: auto; page-break-after: auto; }
.pl-page.sz-small  { grid-template-columns: repeat(4, 48.5mm); }
.pl-page.sz-medium { grid-template-columns: repeat(3, 64.66mm); }
.pl-page.sz-large  { grid-template-columns: repeat(2, 97mm); }
.pl-page .plabel { margin: 0 -.2mm -.2mm 0; } /* garis potong tidak dobel */
.pl-strip { display: block; }

/* ---------- pratinjau di aplikasi ---------- */
.label-preview { display: flex; flex-wrap: wrap; gap: 10px; padding: 14px; border-radius: 16px; background: repeating-conic-gradient(rgba(127,127,127,.12) 0% 25%, transparent 0% 50%) 50% / 16px 16px; overflow-x: auto; }
.label-preview .plabel { border: 0; border-radius: 1mm; box-shadow: 0 6px 18px -6px rgba(0, 0, 0, .45); flex: none; }
.label-preview .plabel.sz-small  { width: 48.5mm; }
.label-preview .plabel.sz-medium { width: 64.66mm; }
.label-preview .plabel.sz-large  { width: 97mm; }
.label-preview .plabel.sz-thermal { width: 54mm; border-bottom: 0; }
