.ticket-preview{overflow:auto;background:#f5f5f4;border:1px solid var(--line);border-radius:10px;margin:16px 0;padding:12px}
.ticket{box-sizing:border-box;width:var(--ticket-width,80mm);padding:3mm 2mm;background:white;color:black;font:12px/1.35 ui-monospace,SFMono-Regular,Consolas,monospace;overflow-wrap:anywhere;white-space:normal;margin:0 auto}
.ticket *{box-sizing:border-box;color:black}
.ticket-head{text-align:center;display:block;padding-bottom:3mm;border-bottom:1px dashed black}
.ticket-head>strong{font-size:15px;display:block}
.ticket-head h2{font:800 20px/1.2 ui-monospace,monospace;letter-spacing:0;margin:2mm 0}
.ticket-head b{display:block;margin-top:2mm}
.ticket-items{padding:1mm 0 3mm;border-bottom:1px dashed black}
.ticket-item{margin-top:3mm;break-inside:avoid}
.ticket-item>strong{font-size:14px}
.ticket-detail{padding-left:2mm;margin-top:1mm}
.ticket-customer{padding:3mm 0;border-bottom:1px dashed black}
.ticket-customer>div{margin-top:1mm}
.ticket-notes{margin:2mm 0!important}
.ticket-total{display:flex;justify-content:space-between;gap:2mm;padding-top:3mm;font-size:15px}
.ticket[data-ticket-design="kitchen"]{font:14px/1.4 system-ui,sans-serif}
.ticket[data-ticket-design="kitchen"] .ticket-head{text-align:left;border-bottom:2px solid black}
.ticket[data-ticket-design="kitchen"] .ticket-item{padding-bottom:2mm;border-bottom:1px dotted black}
.ticket[data-ticket-design="kitchen"] .ticket-item>strong{font-size:17px}
.ticket[data-ticket-design="kitchen"] .ticket-item>strong::before{content:"";display:inline-block;border:1.5px solid black;width:3mm;height:3mm;margin-right:2mm}
.ticket[data-ticket-design="kitchen"] .ticket-detail{padding-left:5mm}
.ticket[data-ticket-design="dispatch"] .ticket-head{border-bottom:2px solid black;text-align:left}
.ticket[data-ticket-design="dispatch"] .ticket-customer{font:14px/1.35 system-ui,sans-serif;border-bottom:2px solid black}
.ticket[data-ticket-design="dispatch"] .ticket-customer>strong{font-size:18px}
@media print{
  html,body{margin:0!important;padding:0!important;background:white!important;width:var(--ticket-width,auto)}
  body>*{display:none!important}
  body>.print-only{display:block!important;padding:0!important;margin:0!important;white-space:normal!important;font-size:12px!important;width:var(--ticket-width)}
  .ticket{margin:0;print-color-adjust:exact;-webkit-print-color-adjust:exact}
}
