/* views-catalog: products, product editor, labels, stock, moves, serials, counts, damages */
.field-label { font-size: var(--fs-13); font-weight: 600; color: var(--text); }
.nowrap { white-space: nowrap; }
.sub-title { font-size: var(--fs-14); font-weight: 600; margin-block-start: var(--sp-2); }
.plain-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--sp-2); }
.plain-list li { display: flex; flex-wrap: wrap; gap: var(--sp-1); align-items: center; }
.chip--sm { height: 22px; padding-inline: 8px; font-size: var(--fs-12); }
.chip-x { border: 0; background: none; color: inherit; padding: 4px; margin-inline-end: -6px; display: inline-grid; place-items: center; border-radius: 50%; }
.chip-x .ic { width: 14px; height: 14px; }

/* products list */
.prod-cell { display: inline-flex; align-items: center; gap: var(--sp-2); min-width: 0; }
.prod-thumb { width: 40px; height: 40px; border-radius: var(--r-sm); object-fit: cover; flex: none; background: var(--surface-3); }
.prod-thumb--empty { display: inline-grid; place-items: center; color: var(--text-3); }
.col-check { width: 40px; }
.row-check { width: 18px; height: 18px; }
.bulk-bar { display: flex; flex-wrap: wrap; gap: var(--sp-2); align-items: center; padding: var(--sp-2) var(--sp-3); margin-block-end: var(--sp-3); background: var(--primary-soft); border-radius: var(--r-md); }

/* product editor */
.seg-radio { position: relative; display: inline-flex; align-items: center; cursor: pointer; }
.seg-radio input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.seg-radio:has(input:checked) { background: var(--surface); color: var(--text); font-weight: 600; box-shadow: var(--shadow-1); }
.seg-radio:has(input:focus-visible) { box-shadow: var(--focus-ring); }
.img-upload { display: grid; gap: var(--sp-2); justify-items: start; }
.img-prev { width: 100%; max-width: 240px; aspect-ratio: 1; object-fit: contain; border-radius: var(--r-md); background: var(--surface-3); display: grid; place-items: center; color: var(--text-3); }
.img-prev--empty .ic { width: 48px; height: 48px; }
.swatch--green { background: var(--qt-green); } .swatch--teal { background: var(--qt-teal); } .swatch--blue { background: var(--qt-blue); }
.swatch--indigo { background: var(--qt-indigo); } .swatch--purple { background: var(--qt-purple); } .swatch--pink { background: var(--qt-pink); }
.swatch--red { background: var(--qt-red); } .swatch--orange { background: var(--qt-orange); } .swatch--yellow { background: var(--qt-yellow); }
.swatch--grey { background: var(--qt-grey); }
.tile-prev { width: 140px; min-height: var(--tile-h); border: 1px solid var(--line); border-radius: var(--r-md); border-block-start: 5px solid var(--tp, var(--qt-grey)); background: var(--tp-bg, var(--qt-grey-bg)); padding: var(--sp-2); display: flex; flex-direction: column; justify-content: space-between; }
.tile-prev-name { font-weight: 600; font-size: var(--fs-14); overflow: hidden; max-height: 2.8em; }
.tile-prev-price { font-weight: 700; font-size: var(--fs-13); }
.tile-prev--green { --tp: var(--qt-green); --tp-bg: var(--qt-green-bg); } .tile-prev--teal { --tp: var(--qt-teal); --tp-bg: var(--qt-teal-bg); }
.tile-prev--blue { --tp: var(--qt-blue); --tp-bg: var(--qt-blue-bg); } .tile-prev--indigo { --tp: var(--qt-indigo); --tp-bg: var(--qt-indigo-bg); }
.tile-prev--purple { --tp: var(--qt-purple); --tp-bg: var(--qt-purple-bg); } .tile-prev--pink { --tp: var(--qt-pink); --tp-bg: var(--qt-pink-bg); }
.tile-prev--red { --tp: var(--qt-red); --tp-bg: var(--qt-red-bg); } .tile-prev--orange { --tp: var(--qt-orange); --tp-bg: var(--qt-orange-bg); }
.tile-prev--yellow { --tp: var(--qt-yellow); --tp-bg: var(--qt-yellow-bg); } .tile-prev--grey { --tp: var(--qt-grey); --tp-bg: var(--qt-grey-bg); }
.vopt-list { display: grid; gap: var(--sp-3); }
.vopt { display: grid; grid-template-columns: minmax(100px, 160px) 1fr auto; gap: var(--sp-2); align-items: start; }
.vopt-values { display: flex; flex-wrap: wrap; gap: var(--sp-1); align-items: center; border: 1px solid var(--line-strong); border-radius: var(--r-sm); padding: 4px; min-height: var(--h-md); }
.vopt-in { border: 0; flex: 1; min-width: 120px; }
.vbar-in { margin-block-start: 4px; min-width: 120px; }
.pk-qty { max-width: 90px; }
@media (max-width: 639px) { .vopt { grid-template-columns: 1fr auto; } .vopt-values { grid-column: 1 / -1; } }

/* labels */
.labels-layout { display: grid; gap: var(--sp-4); grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); align-items: start; }
@media (max-width: 1023px) { .labels-layout { grid-template-columns: minmax(0, 1fr); } }
.lbl-items { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--sp-2); }
.lbl-item { display: flex; align-items: center; gap: var(--sp-2); padding: var(--sp-2); border: 1px solid var(--line); border-radius: var(--r-md); flex-wrap: wrap; }
.start-grid { display: grid; gap: 3px; max-width: 220px; }
.start-grid--c1 { grid-template-columns: repeat(1, 1fr); } .start-grid--c2 { grid-template-columns: repeat(2, 1fr); }
.start-grid--c3 { grid-template-columns: repeat(3, 1fr); } .start-grid--c4 { grid-template-columns: repeat(4, 1fr); }
.start-cell { height: 22px; border: 1px solid var(--line-strong); background: var(--surface); border-radius: 3px; font-size: 10px; color: var(--text-3); padding: 0; }
.start-cell[aria-checked="true"] { background: var(--primary); color: var(--primary-ink); border-color: var(--primary); }
.lbl-preview-box { overflow: hidden; border: 1px dashed var(--line-strong); border-radius: var(--r-md); background: var(--surface-3); padding: var(--sp-2); max-height: 520px; }
.lbl-scale { zoom: .5; }
.lbl-scale--roll { zoom: 1; }
@media (max-width: 639px) { .lbl-scale { zoom: .4; } }
.lbl--empty { background: repeating-linear-gradient(45deg, transparent 0 6px, rgba(0,0,0,.04) 6px 12px); }
.lbl-cur { font-size: .6em; font-weight: 600; }
.lbl-roll-list { display: grid; gap: 2mm; justify-items: center; }
.lbl-preview { display: grid; gap: var(--sp-4); justify-items: center; }
.lbl-tip { text-align: center; margin-block-start: var(--sp-2); }
@media (max-width: 860px) { .print-stage .lbl-preview { zoom: .45; } }

/* stock, moves, serials */
.serial-lookup .input-group { max-width: 520px; }
.moves-pick { margin-block-end: var(--sp-2); }
.moves-pick .picker { max-width: 480px; }
.timeline { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--sp-3); }
.tl-item { display: flex; gap: var(--sp-3); align-items: flex-start; }
.tl-dot { width: 32px; height: 32px; border-radius: 50%; background: var(--surface-3); display: grid; place-items: center; flex: none; }
.tl-body { display: grid; gap: 2px; }

/* counts */
.count-screen { display: grid; gap: var(--sp-4); grid-template-columns: minmax(280px, 420px) minmax(0, 1fr); align-items: start; }
@media (max-width: 1023px) { .count-screen { grid-template-columns: minmax(0, 1fr); } }
.count-scan { display: grid; gap: var(--sp-3); position: sticky; inset-block-start: calc(var(--topbar-h) + var(--sp-2)); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); padding: var(--sp-3); }
@media (max-width: 1023px) { .count-scan { position: static; } }
.count-cam .camscan-view { max-height: 45vh; }
.count-last { display: grid; gap: var(--sp-2); }
.count-last-msg { font-size: var(--fs-20); font-weight: 700; min-height: 1.5em; border-radius: var(--r-sm); padding-inline: var(--sp-1); }
.count-last-msg.is-hit { animation: hit 600ms var(--ease-out); }
@keyframes hit { from { background: var(--positive-bg); color: var(--positive); } to { background: transparent; } }
.count-stepper { display: grid; grid-template-columns: 56px 1fr 56px; gap: var(--sp-2); }
.count-qty { height: var(--h-xl); font-size: var(--fs-24); text-align: center; }
.count-progress { display: grid; gap: var(--sp-1); font-size: var(--fs-13); }
.count-progress progress { width: 100%; height: 10px; accent-color: var(--primary); }
.count-in, .dmg-qty { max-width: 110px; }

/* products grid view (design 6.5) */
.prod-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--sp-3); grid-template-columns: repeat(auto-fill, minmax(min(100%, 180px), 1fr)); }
.prod-card { display: grid; gap: 4px; padding: var(--sp-3); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); color: var(--text); text-decoration: none; height: 100%; }
.prod-card:hover { border-color: var(--line-strong); }
.prod-card-img { width: 100%; aspect-ratio: 4 / 3; object-fit: contain; border-radius: var(--r-sm); background: var(--surface-2); display: grid; place-items: center; color: var(--text-3); }
.prod-card-img .ic { width: 32px; height: 32px; }
.prod-card-name { font-weight: 600; overflow-wrap: anywhere; }
.prod-card-foot { display: flex; justify-content: space-between; gap: var(--sp-2); flex-wrap: wrap; align-items: center; }
