.product-tag-workspace{display:grid;grid-template-columns:minmax(380px,460px) minmax(0,1fr);gap:18px;align-items:start}
.product-tag-panel{background:#fff;border:1px solid #e5e7eb;border-radius:14px;box-shadow:0 12px 34px rgba(15,23,42,.08);padding:18px}
.product-tag-settings-panel{position:sticky;top:76px;max-height:calc(100vh - 100px);min-height:0;overflow-y:auto;overflow-x:hidden;overscroll-behavior:contain;scrollbar-gutter:stable;padding-right:12px}
.product-tag-panel h2{margin:0 0 6px;font-size:18px;letter-spacing:0}
.product-tag-panel .muted{color:#64748b;font-size:13px}
.product-tag-options{display:grid;gap:12px;margin-top:16px}
.product-tag-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:14px}
.product-tag-search-results{display:grid;gap:8px;max-height:260px;overflow:auto;margin-top:10px}
.product-tag-result,.product-tag-selected{border:1px solid #e5e7eb;border-radius:10px;padding:10px;background:#fff;display:grid;gap:6px}
.product-tag-result:hover{border-color:#111827;box-shadow:0 8px 22px rgba(15,23,42,.08)}
.product-tag-result-title,.product-tag-selected-title{font-weight:900;color:#111827}
.product-tag-result-meta,.product-tag-selected-meta{display:flex;flex-wrap:wrap;gap:6px 10px;color:#64748b;font-size:12px;line-height:1.4}
.product-tag-selected-list{display:grid;gap:8px;margin-top:10px}
.product-tag-selected-head{display:grid;gap:10px;min-width:0}
.product-tag-selected-main{display:grid;grid-template-columns:minmax(0,1fr) minmax(142px,auto);align-items:center;gap:12px;min-width:0}
.product-tag-selected-info{min-width:0}
.product-tag-selected-title{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.product-tag-selected-vendor-brand,.product-tag-selected-english-name{display:block;min-height:17px;line-height:17px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#64748b;font-size:12px}
.product-tag-selected-details{display:flex;flex-wrap:wrap;gap:4px 10px;color:#64748b;font-size:12px;line-height:1.4}
.product-tag-selected-quantity{display:grid;justify-items:end;gap:6px;min-width:142px;overflow:visible}
.product-tag-selected-actions{display:flex;gap:6px;align-items:center}
.product-tag-selected-actions input{width:62px}
.product-tag-preview-toolbar{display:flex;justify-content:space-between;gap:12px;align-items:center;margin-bottom:12px}
.product-tag-preview-scroll{background:#f8fafc;border:1px solid #e5e7eb;border-radius:14px;overflow:auto;padding:18px;min-height:520px}
.formtec-sheet-preview{display:block;width:var(--product-tag-sheet-width, max-content);max-width:none;height:max-content;margin-left:auto;margin-right:auto;background:transparent;border:0;box-shadow:none;box-sizing:border-box;flex:0 0 auto}
.product-tag-sheet{width:var(--product-tag-sheet-width, max-content);height:var(--product-tag-sheet-height, max-content);background:transparent;margin-left:auto;margin-right:auto;box-shadow:none;position:relative;box-sizing:border-box;display:grid}
.product-tag-cell{box-sizing:border-box;padding:2mm;overflow:hidden}
.product-tag-label{width:100%;height:100%;box-sizing:border-box;border:1px solid #d7dce3;border-radius:6px;background:#fff;display:grid;grid-template-columns:1fr 18mm;grid-template-rows:auto 1fr auto;gap:1.2mm;padding:2.2mm;font-family:Arial,"Noto Sans KR",sans-serif;color:#111827}
.product-tag-label-empty{border-color:#eef2f7;background:#fbfdff}
.product-tag-name{font-size:8.2pt;font-weight:900;line-height:1.12;max-height:18px;overflow:hidden}
.product-tag-name-en{font-size:5.6pt;color:#64748b;line-height:1.1;max-height:13px;overflow:hidden}
.product-tag-brand{font-size:5.2pt;color:#475569;text-transform:uppercase;letter-spacing:.06em}
.product-tag-qr{grid-column:2;grid-row:1 / span 2;width:17mm;height:17mm;align-self:start;justify-self:end}
.product-tag-price{align-self:end}
.product-tag-original{font-size:5.6pt;color:#94a3b8;text-decoration:line-through;text-decoration-thickness:1px}
.product-tag-sale-row{display:flex;gap:3px;align-items:center;flex-wrap:wrap}
.product-tag-sale{font-size:10.4pt;font-weight:950;color:#020617;line-height:1}
.product-tag-discount{font-size:5.4pt;font-weight:950;color:#be123c;border:1px solid #fecdd3;background:#fff1f2;border-radius:999px;padding:1px 4px}
.product-tag-barcode{grid-column:1 / span 2;align-self:end}
.product-tag-bars{height:7mm;display:flex;align-items:end;gap:.45mm}
.product-tag-bars span{display:block;background:#111827;width:.55mm}
.product-tag-barcode-text{font-size:5pt;letter-spacing:.08em;text-align:center;color:#111827;margin-top:.5mm;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.product-tag-public-hint{font-size:12px;color:#64748b;margin-top:10px}
.product-tag-preview-scroll{background-color: var(--masta-card-soft);border:1px solid #E7D9CA!important;border-radius:18px!important;padding:26px!important;display:flex;justify-content:center;align-items:flex-start}
.product-tag-sheet{border:0!important;background:transparent!important;box-shadow:none!important}
.product-tag-cell{padding:1.25mm!important;border:1px dashed #E7D9CA;background:#fffdfd}
.product-tag-label{border-color:#e7d9c3!important;border-radius:5px!important;box-shadow:0 2px 8px rgba(15,23,42,.045)!important;grid-template-columns:1fr 16mm!important;grid-template-rows:auto 1fr auto!important;padding:1.7mm!important;gap:.8mm!important}
.product-tag-label-empty{border-style:dashed!important;border-color:#E5D8CA!important;background-color: var(--masta-card-soft);box-shadow:none!important}
.product-tag-name{font-size:7.6pt!important;max-height:19px!important;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}
.product-tag-name-en{font-size:5.2pt!important;max-height:12px!important}
.product-tag-qr{width:15mm!important;height:15mm!important}
.product-tag-sale{font-size:9.4pt!important}
.product-tag-barcode-svg{width:100%;height:7.8mm;display:block}
.product-tag-barcode-text{font-size:4.8pt!important;margin-top:.3mm!important}
.product-tag-search-card{border:1px solid var(--masta-border-soft);border-radius:14px;background:#fff;padding:12px;display:grid;gap:8px}
.product-tag-search-card .masta-product-picker{width:100%}
.product-tag-selected-summary{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:8px}
.product-tag-selected-total{font-size:12px;color:#64748b;font-weight:900}
.product-tag-guide{border:1px solid rgba(200,164,106,.26);background:var(--masta-gold-light);border-radius:12px;padding:10px 12px;font-size:12px;line-height:1.55;color:#6b4e1e}
.product-tag-selected-actions{flex-wrap:wrap;justify-content:flex-start}
.product-tag-selected-actions .btn{height:30px!important;min-height:30px!important;padding:0 9px!important}
.product-tag-clear-all{margin-left:auto}
.product-tag-spec-chips{display:flex;flex-wrap:wrap;gap:6px;margin-top:8px}
.product-tag-spec-chips span{display:inline-flex;align-items:center;min-height:24px;padding:0 9px;border:1px solid var(--masta-border-soft);border-radius:999px;background:#fff;color:var(--masta-text-sub);font-size:11px;font-weight:900;white-space:nowrap}
.tag-count-badge{display:inline-flex;align-items:center;justify-content:center;min-height:30px;padding:0 12px;border:1px solid var(--masta-primary-soft);border-radius:999px;background:var(--masta-primary-light);color:var(--masta-primary-dark);font-size:12px;font-weight:950;white-space:nowrap}
.tag-print-preview-stage{background-color: var(--masta-card-soft);border:1px solid var(--masta-border-soft);border-radius:18px;padding:24px;display:flex;justify-content:center;align-items:flex-start;overflow:auto;min-height:520px;max-height:calc(100vh - 220px)}
.formtec-sheet-preview .product-tag-sheet{width:var(--product-tag-sheet-width, max-content)!important;height:var(--product-tag-sheet-height, max-content)!important;margin-left:auto!important;margin-right:auto!important;border:0!important;box-shadow:none!important;background:transparent!important;display:grid!important;box-sizing:border-box;position:static!important}
.formtec-sheet-preview .product-tag-cell{background:#fffdfd}
.product-tag-print-sheet{width:var(--product-tag-sheet-width, max-content);box-sizing:border-box;margin-left:auto;margin-right:auto;break-after:page;page-break-after:always}
.product-tag-print-sheet:last-child{break-after:auto;page-break-after:auto}
.product-tag-print-sheet .product-tag-sheet{width:var(--product-tag-sheet-width, max-content)!important;height:var(--product-tag-sheet-height, max-content)!important;margin-left:auto!important;margin-right:auto!important;border:0!important;box-shadow:none!important;background:transparent!important;display:grid!important;box-sizing:border-box;position:static!important}
.product-tag-qty-label{display:block;font-size:12px;font-weight:950;color:var(--masta-text-sub);white-space:nowrap;word-break:keep-all}
.product-tag-stepper{display:inline-grid;grid-template-columns:32px 72px 32px;align-items:center;border:1px solid var(--masta-border);border-radius:999px;background:#fff;overflow:visible;white-space:nowrap}
.product-tag-stepper button{width:32px;height:30px;box-sizing:border-box;flex-shrink:0;border:0;background:#fff;color:var(--masta-text);font-weight:950;cursor:pointer}
.product-tag-stepper button:hover{background:var(--masta-primary-light);color:var(--masta-primary-dark)}
.product-tag-stepper input{width:72px;height:30px;box-sizing:border-box;border:0;border-left:1px solid var(--masta-border-soft);border-right:1px solid var(--masta-border-soft);text-align:center;font-weight:950;color:var(--masta-text);background:#fff}
.product-tag-sheet-control{display:grid;grid-template-columns:30px 70px 30px;align-items:center;width:max-content;border:1px solid var(--masta-border);border-radius:999px;background:#fff;overflow:hidden}
.product-tag-sheet-control button{height:30px;border:0;background:#fff;font-weight:950;cursor:pointer}
.product-tag-sheet-control button:hover{background:var(--masta-primary-light);color:var(--masta-primary-dark)}
.product-tag-sheet-control input{height:30px;border:0;border-left:1px solid var(--masta-border-soft);border-right:1px solid var(--masta-border-soft);text-align:center;font-weight:950}
.product-tag-preview-pager{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-top:8px}
.product-tag-preview-pager .btn{height:28px!important;min-height:28px!important;padding:0 9px!important}
.product-tag-overflow-note{border:1px solid rgba(239,68,68,.28);background:#fff1f2;color:#991b1b;border-radius:12px;padding:9px 11px;font-size:12px;font-weight:850;line-height:1.45}
.product-tag-print-pages{display:grid;gap:18px;justify-items:center}
.product-tag-print-output{position:absolute;left:-99999px;top:0;width:210mm}
@media(max-width:1100px){.product-tag-workspace{grid-template-columns:1fr}.product-tag-settings-panel{position:static;max-height:none;overflow:visible;padding-right:18px}.product-tag-preview-scroll{min-height:420px}.tag-print-preview-stage{justify-content:flex-start;min-height:420px;max-height:none}.formtec-sheet-preview .product-tag-sheet{transform:none!important;height:auto!important}}
@media(max-width:520px){.product-tag-selected-main{grid-template-columns:minmax(0,1fr)}.product-tag-selected-quantity{justify-items:start;min-width:0}.product-tag-qty-label{white-space:nowrap}}
@media print{
  @page{size:210mm 297mm;margin:0}
  html,body{margin:0!important;padding:0!important;background:#fff!important}
  body *{visibility:hidden!important}
  .tag-print-preview-stage{display:flex!important;justify-content:center!important;align-items:flex-start!important;width:100%!important;height:auto!important;padding:0!important;margin:0 auto!important;border:0!important;background:#fff!important;overflow:visible!important}
  .product-tag-print-output{position:absolute!important;left:0!important;top:0!important;width:210mm!important}
  #productTagPrintSheet,#productTagPrintSheet *{visibility:visible!important}
  #productTagPrintSheet{position:absolute!important;left:0!important;right:0!important;top:0!important;margin:0 auto!important;border:0!important;box-shadow:none!important;display:grid!important;justify-items:center!important}
  #productTagPrintSheet .product-tag-sheet{border:0!important;box-shadow:none!important}
  #productTagPrintSheet .product-tag-print-sheet{transform:none!important;margin-left:auto!important;margin-right:auto!important;border:0!important;box-shadow:none!important}
  .product-tag-cell{break-inside:avoid;background:#fff!important;border-color:transparent!important;-webkit-print-color-adjust:exact;print-color-adjust:exact}
  .product-tag-label{box-shadow:none!important;-webkit-print-color-adjust:exact;print-color-adjust:exact}
}
