/* Layout stays compact; one discount control sits between camera and delete. */
html body #overlay .modal.cp-invoice-dialog #invoiceForm .invoiceLine.cp-invoice-row>.cp100-line-actions{display:flex!important;flex-wrap:wrap!important;align-items:flex-start!important;justify-content:space-between!important;grid-column:1/-1!important;order:6!important;gap:8px!important;width:100%!important;}
html body #overlay .modal.cp-invoice-dialog #invoiceForm .cp100-line-actions>.cp-line-photo{order:0!important;flex:0 0 64px!important;align-self:flex-start!important;min-width:64px!important;width:64px!important;max-width:64px!important;grid-column:auto!important;}
html body #overlay .modal.cp-invoice-dialog #invoiceForm .cp100-remove-line{order:2!important;flex:0 0 38px!important;align-self:flex-start!important;width:38px!important;min-width:38px!important;max-width:38px!important;}
.cp100-discount{order:1;flex:1;min-width:140px;max-width:460px;align-self:center;}
html body #overlay #invoiceForm .cp100-discount-toggle{display:flex!important;justify-content:center!important;gap:8px!important;margin:0!important;padding:8px!important;background:#f1e4ff!important;border:1px solid #d2b2ee!important;border-radius:9px!important;min-height:38px!important;cursor:pointer!important;color:#4b2373!important;}
.cp100-discount-entry{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:7px;}
.cp100-discount-entry>label{min-width:0;display:grid;gap:5px;font-size:11px;}
html body #overlay #invoiceForm .cp100-discount-entry input,html body #overlay #invoiceForm .cp100-discount-entry select{width:100%!important;max-width:100%!important;min-height:39px!important;box-sizing:border-box!important;font-size:16px!important;}
.cp100-price-summary{display:flex;flex-wrap:wrap;gap:8px 18px;line-height:1.8;}.cp100-price-error{color:#a51b31!important;font-weight:bold;}
.cp100-tax-fields{display:grid;grid-template-columns:minmax(160px,1fr) minmax(160px,1fr) minmax(100px,.6fr) auto;gap:12px;align-items:end;}
.cp100-tax-fields .field{min-width:0;margin:0}.cp100-tax-fields input{width:100%;box-sizing:border-box}.cp100-tax-fields input[readonly]{opacity:1;cursor:default}.cp100-tax-edit{align-self:end;flex-wrap:wrap;margin-bottom:2px;}
html body #root #cp100TaxSettingsForm .btn.hidden{display:none!important;}
html body #root .cp-section-settings #content .cp100-reference-actions{display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:9px!important;}
html body #root .cp-section-settings #content .cp100-reference-actions>button.btn{width:100%!important;max-width:none!important;min-width:0!important;}
html body #root #content .cp100-reference-journal{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:9px!important;}
html body #root #content .cp100-reference-journal>button.btn{width:100%!important;max-width:none!important;min-width:0!important;}
@media(max-width:760px){.cp100-tax-fields{grid-template-columns:1fr 1fr}.cp100-tax-edit{align-self:end;}.cp100-tax-fields input{font-size:16px!important;min-height:42px!important;}}
@media(max-width:420px){html body #overlay #invoiceForm .cp100-line-actions{gap:6px!important}.cp100-discount{min-width:130px}.cp100-discount-entry{grid-template-columns:1fr;}.cp100-tax-fields{gap:8px;}.cp100-tax-edit .btn{padding:8px 12px;}}

/* V101: the customer identity stays visible on small screens; company fields open on tap. */
html body #root .top .brandtext .cp-client-name{display:block;font-size:11px;line-height:1.5;max-width:min(45vw,340px);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#ffe28c;}
html body #root .cp100-tax-settings{margin-top:12px;border:1px solid #cce5e6;background:#f8fdfc;}
html body #root .cp100-tax-settings h3{margin-top:0;font-size:16px;}
html body #root .cp100-tax-settings .cp100-tax-fields{grid-template-columns:repeat(3,minmax(0,1fr));}
html body #root .cp100-tax-settings .cp100-tax-edit{grid-column:1/-1;justify-content:flex-start;}
@media(max-width:760px){html body #root .cp100-tax-settings .cp100-tax-fields{grid-template-columns:1fr 1fr;}html body #root .cp100-tax-settings .field:last-of-type{grid-column:1/-1;}}
@media(max-width:360px){html body #root .top .brandtext{display:block!important;font-size:13px!important;}html body #root .top .logo{max-width:48px;}html body #root .top .brandtext .cp-client-name{max-width:37vw;font-size:10px;}}
