 :root{--red:#bd101b;--ink:#252c34;--line:#e4e7eb}*{box-sizing:border-box}body{margin:0;background:#f4f5f7;color:var(--ink);font:14px -apple-system,BlinkMacSystemFont,"PingFang SC","Hiragino Sans",Arial,sans-serif}aside{position:fixed;width:232px;height:100vh;background:#20262e;color:white;padding:38px 25px}.brand{font-size:33px;font-weight:800}aside small{font-size:9px;letter-spacing:2px;color:#a7adb6}nav{margin-top:50px}button{cursor:pointer;border:1px solid var(--line);border-radius:6px;background:white;padding:11px 18px;color:inherit}nav button{display:block;width:100%;text-align:left;background:none;color:#c3c8ce;border:0;margin:8px 0}nav button.active{background:#3a3036;color:white;border-left:3px solid #ed3845}footer{position:absolute;bottom:30px;font-size:11px;line-height:2;color:#acb2b9}main{margin-left:232px;padding:0 42px 50px}header{height:86px;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid var(--line);color:#79828d}.tag{background:#fff1e9;color:#9a5930;padding:6px 12px;border-radius:20px;font-size:12px}h1{font-size:28px;letter-spacing:-1px;margin-bottom:8px}p{color:#7b838e}.bar{display:flex;justify-content:space-between;align-items:center;margin:28px 0}.primary{background:var(--red);color:white;border-color:var(--red)}.cards{display:flex;gap:20px;margin:30px 0}.card,.panel{background:white;border:1px solid var(--line);border-radius:9px;padding:24px}.card{flex:1}.card b{display:block;font-size:30px;margin-top:16px}.panel{margin-top:22px}input,select,textarea{border:1px solid #dce0e5;border-radius:5px;padding:10px;background:white;font:inherit;color:inherit;max-width:100%}input:focus,textarea:focus{outline:1px solid var(--red)}table{border-collapse:collapse;width:100%;font-size:13px}th{text-align:left;background:#f7f8fa;color:#78818b;font-size:11px;font-weight:500}td,th{padding:16px 12px;border-bottom:1px solid var(--line)}td input{width:100%}.grid{display:grid;grid-template-columns:repeat(3,1fr);gap:20px}label{display:flex;flex-direction:column;gap:9px;color:#737c86;font-size:12px}.total{text-align:right;font-size:24px;margin:25px 0}.paper{background:white;width:210mm;min-height:297mm;margin:25px auto;padding:16mm;color:#262b30;position:relative}.letterhead{display:flex;justify-content:space-between;align-items:center;border-bottom:3px solid var(--red);padding-bottom:18px}.letterhead img{width:310px;height:68px;object-fit:cover;object-position:center}.paper h1{font-size:29px;margin:30px 0}.paper .meta{display:flex;justify-content:space-between;line-height:1.9;margin-bottom:25px}.paper table{font-size:10px}.paper th{background:#292f37;color:white}.paper td,.paper th{padding:12px 7px}.paper .terms{margin-top:30px;line-height:2;font-size:12px}.paper .foot{margin-top:50px;border-top:1px solid #ddd;padding-top:12px;font-size:10px;color:#888}.paper tr{break-inside:avoid}.paper thead{display:table-header-group}@page{size:A4;margin:0}@media print{aside,header,.noprint{display:none!important}main{margin:0;padding:0}body{background:white}.paper{margin:0 auto;zoom:1;box-shadow:none;min-height:0;break-after:page}.paper:last-child{break-after:auto}}@media screen and (max-width:1000px){aside{width:180px}main{margin-left:180px;padding:0 20px}.grid{grid-template-columns:1fr 1fr}.paper{zoom:.75}}.company{font-size:10px;line-height:1.8}.paper table{table-layout:fixed}.paper td{overflow-wrap:anywhere;vertical-align:top;line-height:1.5}.paper th{font-size:10px}.paper .foot{display:flex;justify-content:space-between}.paper .meta{font-size:12px}.paper .meta>div:first-child{max-width:53%;overflow-wrap:anywhere}.paper .terms{overflow-wrap:anywhere}.paper{min-height:297mm}.paper .foot{margin-top:35px}#status{position:sticky;top:0;z-index:10}#status:not(:empty){background:#eaf5ed;border:1px solid #bbd8c3;padding:12px;margin-top:10px}#status.error{background:#fff0f0;border-color:#e7b7b7;color:#a00}.actions{display:flex;gap:8px;flex-wrap:wrap}.muted{color:#818892;font-size:12px}.danger{color:#b31020}.toolbar{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.line-input{min-width:75px}.item-name{min-width:140px}.row-editor{overflow:auto}dialog{border:1px solid #ddd;border-radius:12px;width:760px;max-width:95vw;padding:28px}dialog::backdrop{background:#0007}.history-price{font-size:12px;padding:10px;background:#faf4ef;line-height:1.8}.paper .total{font-size:22px}.paper td:nth-child(n+3),.paper th:nth-child(n+3){text-align:right}.paper h1{height:35px}.paper .meta{min-height:90px}.paper .terms{white-space:normal}.field-wide{grid-column:1/-1}.quote-form input,.quote-form textarea{width:100%}textarea{min-height:80px}.quote-form h3{margin-top:0}@media print{#status{display:none!important}.paper{zoom:1;min-height:297mm;padding:16mm;print-color-adjust:exact;-webkit-print-color-adjust:exact}.paper .foot{break-inside:avoid}}@media screen and (max-width:1000px){.paper{zoom:.75}}@media screen and (max-width:700px){aside{width:130px;padding:25px 10px}.brand{font-size:25px}aside small{font-size:7px}main{margin-left:130px;padding:0 12px}.grid{grid-template-columns:1fr}.bar{gap:12px;flex-wrap:wrap}.cards{flex-direction:column}.paper{zoom:.5}}

/* Show the supplied artwork; crop only its surrounding white canvas. */
.brand{height:52px;width:100%;position:relative;overflow:hidden;background:white;border-radius:4px;margin-bottom:12px}.brand img{position:absolute;width:112%;max-width:none;height:auto;left:-6%;top:50%;transform:translateY(-50%)}

.attachment-row{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:14px 0;border-bottom:1px solid var(--line)}.attachment-row>span{overflow-wrap:anywhere;min-width:0}.attachment-row .actions{flex-shrink:0}.paper td:nth-child(2),.paper th:nth-child(2){text-align:right}

.login-panel{max-width:500px;margin:60px auto}.login-panel label,dialog form label{margin:14px 0}.form-message{color:#b31020;min-height:20px}.signed-out aside{display:none}.signed-out main{margin-left:0}.signed-out #status{display:none}header{min-height:86px;height:auto;gap:16px;flex-wrap:wrap;padding:12px 0}#accountControls{font-size:12px}#accountControls button{padding:7px 10px}@media print{#accountControls{display:none}}
