/* VOICE: shop tool, quick and plain — a work order clipboard
   IDEA: navy shop header, white work-order sheet, orange as the action colour
   PICTURE: the jobs table itself, coloured by status
   COLOUR and TYPE: navy #14213D, white, orange #F28C28; Inter, compact
   LAYOUT: one column app, header + list / card, bottom bar */
:root{color-scheme:light dark;
--navy:#14213D;--orange:#F28C28;
--bg:light-dark(#f3f4f6,#0f1420);--card:light-dark(#fff,#18202f);--ink:light-dark(#1b2333,#e8ecf3);
--mute:light-dark(#6b7385,#9aa3b5);--line:light-dark(#e3e6eb,#2a3344);
--prog:light-dark(#d9730d,#f5a04b);--unpaid:light-dark(#b58900,#e5c04a);--paid:light-dark(#2e8b3e,#5cc56c)}
:root[data-theme=light]{color-scheme:light}:root[data-theme=dark]{color-scheme:dark}
*{box-sizing:border-box;min-width:0}
body{margin:0;background:var(--bg);color:var(--ink);font:14px/1.4 Inter,system-ui,sans-serif;overflow-x:clip}
button,input,select,textarea{font:inherit;color:inherit}
header{position:sticky;top:0;z-index:5;background:var(--navy);color:#fff;display:flex;align-items:center;gap:8px;padding:10px 12px;min-height:52px}
header h1{font-size:17px;font-weight:600;margin:0;flex:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.hb{background:none;border:0;color:#fff;width:40px;height:40px;border-radius:8px;cursor:pointer;display:grid;place-items:center}
.hb:hover{background:#ffffff1a}.hb svg{width:22px;height:22px}
main{max-width:900px;margin:0 auto;padding:10px 10px 90px}
.bar{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:8px}
.search{flex:1 1 200px;height:40px;border:1px solid var(--line);border-radius:8px;padding:0 12px;background:var(--card);font-size:16px}
.chip{height:32px;padding:0 12px;border-radius:16px;border:1px solid var(--line);background:var(--card);cursor:pointer;font-size:13px}
.chip.on{background:var(--navy);color:#fff;border-color:var(--navy)}
.card{background:var(--card);border:1px solid var(--line);border-radius:10px;overflow:hidden;margin-bottom:10px}
table{width:100%;border-collapse:collapse}
th,td{padding:7px 8px;text-align:left;border-bottom:1px solid var(--line);vertical-align:top}
th{font-size:12px;font-weight:600;color:var(--mute);cursor:pointer;user-select:none;white-space:nowrap;background:var(--card)}
th.num,td.num{text-align:right;white-space:nowrap}
tbody tr{cursor:pointer}tbody tr:hover{background:light-dark(#f7f8fa,#1e2738)}
.fn{font-weight:600;font-size:13px}
.s-prog{color:var(--prog)}.s-unpaid{color:var(--unpaid)}.s-paid{color:var(--paid)}
.sub{color:var(--mute);font-size:12px}
.rows{padding:2px 12px}
.r{display:grid;grid-template-columns:110px 1fr auto;gap:8px;align-items:center;padding:7px 0;border-bottom:1px solid var(--line)}
.r:last-child{border-bottom:0}.r .l{color:var(--mute);font-size:12px}
.pill{border:0;border-radius:14px;padding:5px 12px;font-weight:600;font-size:13px;cursor:pointer;color:#fff}
.pill.s-prog{background:var(--prog)}.pill.s-unpaid{background:var(--unpaid)}.pill.s-paid{background:var(--paid)}
.sec{display:flex;align-items:center;justify-content:space-between;padding:10px 12px 4px;font-weight:600}
.lnk{background:none;border:0;color:var(--orange);font-weight:600;cursor:pointer;padding:6px}
.tot td{border:0;padding:4px 8px}.tot .big td{font-size:16px;font-weight:700;padding-top:8px}
.fab{position:fixed;right:18px;bottom:18px;width:56px;height:56px;border-radius:50%;border:0;background:var(--orange);color:#fff;font-size:30px;box-shadow:0 4px 14px #0004;cursor:pointer}
.btn{height:44px;border-radius:8px;border:0;padding:0 18px;font-weight:600;cursor:pointer;background:var(--orange);color:#fff}
.btn.ghost{background:none;border:1px solid var(--line);color:var(--ink)}
form.f{display:grid;gap:10px;padding:12px}
form.f label{display:grid;gap:4px;font-size:12px;color:var(--mute)}
form.f input,form.f select,form.f textarea{height:42px;border:1px solid var(--line);border-radius:8px;padding:0 10px;background:var(--bg);font-size:16px;color:var(--ink)}
form.f textarea{height:80px;padding:8px 10px}
.g2{display:grid;grid-template-columns:repeat(auto-fit,minmax(130px,1fr));gap:10px}
.acts{display:flex;gap:8px;justify-content:flex-end}
.msg{padding:16px;text-align:center;color:var(--mute)}
.err{background:light-dark(#fdecea,#3a1d1d);color:light-dark(#9b2c22,#f4a79f);padding:10px 12px;border-radius:8px;margin-bottom:10px}
.toast{position:fixed;left:50%;bottom:86px;transform:translateX(-50%);background:var(--navy);color:#fff;padding:8px 16px;border-radius:20px;font-size:13px;opacity:0;transition:opacity .2s;pointer-events:none}
.toast.on{opacity:1}
.del{background:none;border:0;color:#e5484d;cursor:pointer;font-size:22px;line-height:1;font-weight:600;width:32px;height:32px;display:inline-grid;place-items:center;border-radius:6px;padding:0}
.del:hover{background:#e5484d1f}
.wt td{vertical-align:middle}
.wt td:last-child{width:40px;text-align:center;padding-left:0}
:focus-visible{outline:2px solid var(--orange);outline-offset:2px}
@media(max-width:520px){.r{grid-template-columns:96px 1fr auto}th,td{padding:7px 6px}.hide-s{display:none}}
.sug{position:absolute;z-index:30;background:var(--card);border:1px solid var(--line);border-radius:8px;box-shadow:0 8px 24px #0005;max-height:260px;overflow:auto}
.sug div{padding:12px 14px;font-size:16px;color:var(--ink);cursor:pointer;border-bottom:1px solid var(--line);white-space:nowrap}
.sug div:last-child{border-bottom:0}
.sug div:active,.sug div:hover{background:color-mix(in srgb,var(--orange) 18%,transparent)}
.wt td.tg{cursor:pointer}
.chip input{display:none}
@media(max-width:480px){.wt th,.wt td{font-size:13px;padding-left:4px;padding-right:4px}}
