:root{--paper:#f3f4f1;--card:#fff;--ink:#1c2a33;--muted:#66757f;--line:#d5d9d4;--blue:#1f3a4d;--steel:#2f5d73;--soft:#e3edf1;--accent:#c8501e;--ok:#2f7d4f;--warn:#a86a00;--bad:#b3261e;--glass:#cfe9f2}
*{box-sizing:border-box}
html,body{margin:0;background:var(--paper);color:var(--ink);font:15px/1.45 "Segoe UI",system-ui,sans-serif}
button,input,select,textarea{font:inherit;color:inherit}
h1{font-size:22px;margin:0 0 12px}h2{font-size:14px;margin:0 0 8px;color:var(--steel)}
a{color:var(--steel)}
.num{font-variant-numeric:tabular-nums}
.wrap{padding:14px;max-width:1500px;margin:0 auto}
.card{background:var(--card);border:1px solid var(--line);border-radius:6px;padding:12px}
.stack{display:grid;gap:12px}
label{display:block;font-size:12px;color:var(--muted);margin-bottom:2px}
input,select,textarea{width:100%;padding:6px 8px;border:1px solid var(--line);border-radius:4px;background:#fff}
input:focus,select:focus,textarea:focus,button:focus-visible{outline:2px solid var(--steel);outline-offset:1px}
input[type=checkbox],input[type=radio]{width:auto}
.g2{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.g3{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}.g4{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}.g2>*,.g3>*,.g4>*{min-width:0}
@media(max-width:800px){.g3,.g4{grid-template-columns:repeat(2,minmax(0,1fr))}}
.row{display:flex;gap:8px;flex-wrap:wrap;align-items:center}
.btn{background:var(--steel);color:#fff;border:0;padding:7px 12px;border-radius:4px;cursor:pointer}
.btn.alt{background:#fff;color:var(--steel);border:1px solid var(--steel)}
.btn.del{background:#fff;color:var(--bad);border:1px solid #e3b7b3}
.btn.accent{background:var(--accent)}
.btn:disabled{opacity:.5;cursor:default}
.chk{display:flex;align-items:center;gap:6px;font-size:14px;color:var(--ink);margin:0}
.hint{font-size:12px;color:var(--muted)}
table{width:100%;border-collapse:collapse}
th,td{padding:8px 10px;text-align:left;border-top:1px solid var(--line);vertical-align:top}
th{background:#eef1ee;font-size:13px;border-top:0}
td.r,th.r{text-align:right}
tr.click{cursor:pointer}tr.click:hover{background:#f6f8f6}
.tag{display:inline-block;font-size:11px;padding:1px 8px;border-radius:9px;background:#efe6d3;color:var(--warn)}
.tag.ok{background:#dcefe3;color:var(--ok)}.tag.bad{background:#fbe1de;color:var(--bad)}
.banner{padding:8px 10px;border-left:3px solid var(--bad);background:#fbe9e7;font-size:14px;margin-bottom:8px}
.banner.warn{border-color:var(--warn);background:#fbf3e2}
.err{color:var(--bad);font-size:13px}
.login{max-width:360px;margin:12vh auto}
.tabs{display:flex;gap:4px;border-bottom:2px solid var(--line);margin-bottom:12px;flex-wrap:wrap}
.tabs button{border:0;background:transparent;padding:8px 14px;cursor:pointer;font-size:15px;border-bottom:3px solid transparent;margin-bottom:-2px}
.tabs button.on{border-color:var(--accent);font-weight:600}
.builder{display:grid;grid-template-columns:220px minmax(380px,1fr) 340px;gap:12px;align-items:start}
@media(max-width:1150px){.builder{grid-template-columns:1fr}}
.items{list-style:none;margin:0;padding:0;display:grid;gap:6px}
.items li{border:1px solid var(--line);border-radius:5px;padding:7px 9px;cursor:pointer;background:#fff}
.items li.sel{border-color:var(--steel);background:var(--soft)}
.items .t{display:flex;justify-content:space-between;gap:6px;font-weight:600}.items .s{color:var(--muted);font-size:12px}
svg.cv{width:100%;height:auto;max-height:520px;background:#fbfcfb;border:1px solid var(--line);border-radius:5px;touch-action:none}
svg.cv .cellrect{cursor:move}svg.cv .cellrect:hover rect{fill:#bfe0ec}.handle{cursor:nwse-resize}.dimtag{cursor:text}.dimtag:hover text{fill:#0b5cff;text-decoration:underline}.dimtag:hover rect{stroke:#0b5cff}
.dimedit{position:fixed;z-index:1000;width:96px;padding:5px 7px;border:2px solid #0b5cff;border-radius:4px;background:#fff;box-shadow:0 2px 8px #0004}
.pal{padding:6px;border:1px dashed var(--line);border-radius:5px;background:#fbfcfb;margin-bottom:8px}
.pb{display:inline-block;cursor:grab;user-select:none;background:#fff;border:1px solid var(--steel);color:var(--steel);border-radius:4px;padding:2px}
.steps td{padding:3px 6px;border-top:0}.steps td.i{padding-left:18px;color:#3c4a53}.steps tr.sum td{border-top:1px solid var(--line);font-weight:600}
.big{font-size:22px;font-weight:700}
.compare{border:1px solid var(--steel);background:var(--soft);border-radius:5px;padding:8px 10px;margin-bottom:8px}
details summary{cursor:pointer;color:var(--steel);font-weight:600;margin:6px 0}
.saving{font-size:12px;color:var(--muted)}

.lead-grid{display:grid;grid-template-columns:minmax(320px,520px) minmax(300px,1fr);gap:14px;align-items:start}@media(max-width:900px){.lead-grid{grid-template-columns:1fr}}
.reps{display:grid;gap:6px}.rep{display:flex;justify-content:space-between;gap:10px;align-items:center;border:1px solid var(--line);border-radius:6px;padding:8px 10px}.rep.best{border-color:var(--ok);background:#f1f9f4}
textarea{font:inherit;width:100%;padding:8px;border:1px solid var(--line);border-radius:4px}code{background:#eef1ee;padding:1px 5px;border-radius:3px;word-break:break-all}

.pgrid{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:10px;margin-top:10px}.pcard{border:1px solid var(--line);border-radius:6px;padding:6px;display:grid;gap:6px;background:#fff}
.pcard img{width:100%;aspect-ratio:4/3;object-fit:cover;border-radius:4px;background:#eef1ee}.pcard input{font-size:13px}.pcard .btn{padding:4px 8px;font-size:13px}

.sg-body{background:#eef1ee;margin:0}.sg-wrap{max-width:720px;margin:0 auto;padding:14px 12px 40px}.sg-head{text-align:center;margin:8px 0 14px}.sg-logo{font:700 30px/1 Arial;letter-spacing:-1px;color:#3d3d3d}.sg-logo b{color:#6b8e3d}.sg-sub{color:#66757f;font-size:13px}
.sg-card{padding:16px}.sg-card h1{font-size:21px;margin:0 0 8px}.sg-step{display:flex;gap:10px;align-items:flex-start;margin:14px 0}.sg-n{display:inline-flex;flex:none;align-items:center;justify-content:center;width:26px;height:26px;border-radius:50%;background:#2f6a34;color:#fff;font-weight:700;font-size:14px}
.sg-actions{display:flex;gap:10px;flex-wrap:wrap;margin:14px 0}.sg-actions .btn{flex:1 1 200px;padding:13px;font-size:16px}.sg-tick{width:64px;height:64px;border-radius:50%;background:#2f6a34;color:#fff;display:flex;align-items:center;justify-content:center;font-size:36px;margin:6px auto 10px}
.tl{list-style:none;margin:8px 0 0;padding:0}.tl li{display:flex;gap:8px;font-size:13px;padding:3px 0;border-bottom:1px solid var(--line)}.tl time{color:var(--muted);flex:none;width:132px}.tag.warn{background:#fff3d6;color:#7a5a00}

.brand{display:block;flex:none;height:46px;width:auto;background:#fff;border-radius:8px;padding:3px 9px}.brand-big{display:block;height:96px;width:auto;margin:4px auto 2px}.sg-img{display:block;height:84px;width:auto;margin:0 auto}

.modalbg{position:fixed;inset:0;background:rgba(10,20,28,.55);display:flex;align-items:center;justify-content:center;z-index:3000;padding:16px}.modal{background:#fff;border-radius:10px;padding:18px 18px 14px;max-width:440px;width:100%;box-shadow:0 12px 40px rgba(0,0,0,.35)}.modal p{margin:0 0 12px;line-height:1.45}.modal .row{display:flex;gap:8px;flex-wrap:wrap}
.docview{position:fixed;inset:0;z-index:2500;background:#fff;display:flex;flex-direction:column}.docview .bar{display:flex;gap:8px;align-items:center;padding:8px 12px;background:#1c2a33;color:#fff}.docview .bar span{flex:1}.docview .frame{flex:1;min-height:0;overflow:auto;-webkit-overflow-scrolling:touch;background:#fff}.docview iframe{display:block;border:0;width:100%;height:100%;pointer-events:none}.docview .frame{overscroll-behavior:contain;touch-action:pan-y}.docview .bar{flex-wrap:wrap}

/* ================= header and menu: desktop, tablet, phone ================= */
:root{--brand-green:#87a84d}
header.top{background:var(--blue);color:#fff;position:sticky;top:0;z-index:100;box-shadow:0 1px 0 #00000030}
.top-bar{display:flex;align-items:center;gap:6px 14px;max-width:1560px;margin:0 auto;padding:8px 18px}
.brandlink{display:block;flex:none;line-height:0;border-radius:9px}.brand{display:block;height:44px;width:auto;background:#fff;border-radius:8px;padding:3px 9px}
.nav-main{display:flex;align-items:center;gap:2px;flex:1;min-width:0;flex-wrap:wrap}
.nav-main>a,.nav-more{color:#d5e0e6;background:transparent;border:0;border-radius:7px;padding:9px 13px;font:600 14.5px/1 inherit;text-decoration:none;cursor:pointer;display:inline-flex;align-items:center;gap:5px;white-space:nowrap}
.nav-main>a:hover,.nav-more:hover,.manage .menu a:hover{background:#ffffff1c;color:#fff}
.nav-main>a.dragging{opacity:.4}.nav-main>a.over{box-shadow:inset 3px 0 0 #fff}.nav-main>a[draggable=true]{cursor:grab}.nav-main>a.nav-arr{margin-left:auto;font-size:13px;font-weight:500;opacity:.8;border:1px dashed #ffffff55}
.nav-main>a.on,.nav-more.on{color:#fff;background:#ffffff14;box-shadow:inset 0 -3px 0 var(--brand-green)}
.nav-main a:focus-visible,.nav-more:focus-visible,.btn-out:focus-visible,.burger:focus-visible,.tabbar a:focus-visible,.tab-more:focus-visible{outline:2px solid #fff;outline-offset:2px}
.manage{position:relative}.manage .menu{position:absolute;top:calc(100% + 6px);left:0;min-width:200px;background:#fff;color:var(--ink);border-radius:10px;box-shadow:0 12px 32px #0000004d;padding:6px;z-index:200}
.manage .menu[hidden]{display:none}.manage .menu a{display:block;color:var(--ink);padding:11px 14px;border-radius:7px;text-decoration:none;font-weight:600;font-size:14.5px}.manage .menu a:hover{background:var(--soft)}.manage .menu a.on{background:var(--soft);box-shadow:inset 3px 0 0 var(--brand-green)}
.who{display:flex;align-items:center;gap:10px;margin-left:auto;flex:none}.who-name{font-size:14px;color:#e8eef1;max-width:220px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.who-role{font-size:11px;letter-spacing:.06em;text-transform:uppercase;background:#ffffff1f;color:#d5e0e6;border-radius:20px;padding:3px 9px}
.btn-out{display:inline-flex;align-items:center;gap:7px;color:#fff;background:transparent;border:1px solid #ffffff59;border-radius:7px;padding:8px 13px;font:600 14px/1 inherit;cursor:pointer}.btn-out:hover{background:#ffffff1c}
.ic.sm{width:16px;height:16px}.page-title,.burger,.sheet,.tabbar{display:none}
/* tablet: logo and your name on the first row, the tabs on the second */
@media (max-width:1060px) and (min-width:641px){
  .top-bar{flex-wrap:wrap;row-gap:4px}.who{order:2}.nav-main{order:3;flex:1 1 100%;border-top:1px solid #ffffff22;padding-top:6px;margin-top:2px}
}
/* phone: a slim bar, a bottom bar with the 4 main screens, and a side menu with everything */
@media (max-width:640px){
  .nav-main,.who{display:none}.top-bar{padding:6px 12px;gap:10px;flex-wrap:nowrap}.brand{height:36px;padding:2px 7px}
  .page-title{display:block;flex:1;min-width:0;font:700 17px/1.2 inherit;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  .burger{display:inline-flex;align-items:center;justify-content:center;width:44px;height:44px;border-radius:9px;border:1px solid #ffffff40;background:transparent;color:#fff;cursor:pointer;flex:none}
  .tabbar{display:flex;position:fixed;left:0;right:0;bottom:0;z-index:150;background:var(--blue);box-shadow:0 -1px 0 #00000040,0 -6px 18px #00000026;padding-bottom:env(safe-area-inset-bottom)}
  .tabbar a,.tab-more{flex:1;min-width:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;padding:8px 2px 7px;min-height:58px;color:#b9c8d0;text-decoration:none;background:transparent;border:0;font:600 11.5px/1.1 inherit;cursor:pointer;position:relative}
  .tabbar a.on,.tab-more.on{color:#fff}.tabbar a.on::before,.tab-more.on::before{content:"";position:absolute;top:0;left:22%;right:22%;height:3px;border-radius:0 0 3px 3px;background:var(--brand-green)}
  .tabbar span{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%;font-size:11px;letter-spacing:-.1px}
  @media (max-width:380px){.tabbar span{font-size:10.5px}}
  .wrap{padding-bottom:84px}
  .sheet{position:fixed;inset:0;z-index:2000;background:rgba(10,20,28,.55)}.sheet:not([hidden]){display:block}.sheet[hidden]{display:none}
  .sheet-panel{position:absolute;top:0;right:0;bottom:0;width:min(88vw,340px);background:#fff;overflow:auto;padding:14px 14px calc(18px + env(safe-area-inset-bottom));box-shadow:-8px 0 30px #00000040;animation:sheetin .18s ease-out}
  @keyframes sheetin{from{transform:translateX(24px);opacity:.4}to{transform:none;opacity:1}}
  .sheet-head{display:flex;justify-content:space-between;align-items:flex-start;gap:8px;margin-bottom:10px;padding-bottom:10px;border-bottom:1px solid var(--line)}.sheet-head b{display:block;font-size:16px}.sheet-head .who-role{display:inline-block;margin-top:5px;background:var(--soft);color:var(--steel)}
  .sheet-x{width:44px;height:44px;border-radius:9px;border:1px solid var(--line);background:#fff;color:var(--ink);display:inline-flex;align-items:center;justify-content:center;cursor:pointer;flex:none}
  .stitle{font-size:11.5px;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);margin:12px 6px 4px}
  .srow{display:flex;align-items:center;gap:14px;min-height:50px;padding:0 12px;border-radius:10px;color:var(--ink);text-decoration:none;font:600 16px/1 inherit}.srow:active{background:var(--soft)}.srow.on{background:var(--soft);box-shadow:inset 3px 0 0 var(--brand-green)}.srow .ic{color:var(--steel)}
  .btn-out.wide{width:100%;justify-content:center;margin-top:16px;color:var(--bad);border-color:#b3261e55;padding:14px;font-size:16px}
  body.sheet-open{overflow:hidden}
}
@media (min-width:641px){.sheet,.tabbar,.burger,.page-title{display:none!important}}
@media (prefers-reduced-motion:reduce){.sheet-panel{animation:none}}

/* ================= Customers table ================= */
.ctable{font-size:13.5px}.ctable th,.ctable td{white-space:nowrap;padding:8px 10px;vertical-align:middle}.ctable td.c-email,.ctable td.c-address{max-width:230px;overflow:hidden;text-overflow:ellipsis}
.ctable th.sortable{cursor:pointer;user-select:none}.ctable th.sortable:hover,.ctable th.on{color:var(--ink)}.ctable th.sortable:focus-visible{outline:2px solid var(--blue);outline-offset:-2px}
.ctable td.act{text-align:right;white-space:nowrap}.ctable td.act .btn{margin-left:6px}.btn.sm{padding:5px 10px;font-size:13px}.btn.del{background:#fff;color:var(--bad);border:1px solid #b3261e66}.btn.del:hover{background:#fdecea}
.ctable td a{color:var(--blue);text-decoration:none}.ctable td a:hover{text-decoration:underline}
@media (max-width:860px){
  .ctable thead{display:none}.ctable,.ctable tbody{display:block}
  .ctable tr{display:block;border:1px solid var(--line);border-radius:10px;margin:10px;padding:8px 12px;background:#fff}
  .ctable td{display:flex;justify-content:space-between;align-items:baseline;gap:14px;padding:4px 0;border:0;white-space:normal;text-align:right;max-width:none!important}
  .ctable td::before{content:attr(data-label);color:var(--muted);font-size:12px;text-align:left;flex:none}
  .ctable td:empty{display:none}.ctable td.act{justify-content:flex-end;gap:8px;padding-top:10px;border-top:1px solid var(--line);margin-top:6px}.ctable td.act::before{content:none}
  .ctable td.c-quote_no{font-size:15px}
  .ctable td.act .btn{min-height:42px;min-width:84px;padding:9px 16px;font-size:15px}
}

/* ================= New lead ================= */
.qno{font-size:15px;color:var(--muted);white-space:nowrap}.qno b{font-size:20px;color:var(--ink);letter-spacing:.02em}
.lead-form{max-width:760px}.lead-form select{width:100%}
.scheck:empty{display:none}.scheck{border:1px solid var(--line);border-radius:10px;padding:8px 12px;background:#fafbfa}.scheck.found{border-color:#9bb48a;background:#f3f8ef}.scheck.none{color:var(--muted);font-size:14px}
.sc-line{display:flex;justify-content:space-between;align-items:center;gap:10px;flex-wrap:wrap;font-size:14px}.sc-btns{display:inline-flex;gap:6px;flex-wrap:wrap}
.sc-list{margin-top:8px;max-height:168px;overflow:auto;border-top:1px solid #d6e2cc;padding-top:6px}.sc-list[hidden]{display:none}
.sc-job{display:grid;grid-template-columns:1.4fr 1fr 1fr;gap:8px;padding:5px 0;font-size:13px;border-bottom:1px solid #e6eee0}.sc-job:last-child{border-bottom:0}
.scheck .banner{margin:0 0 8px}
.srcbox{max-width:760px;margin-top:12px}.srcbox summary{cursor:pointer;padding:2px 0}.srclist{display:grid;gap:6px;margin:10px 0}.srcrow{display:flex;justify-content:space-between;align-items:center;gap:10px;border:1px solid var(--line);border-radius:8px;padding:6px 10px}.srcrow.off{opacity:.6}
.srcadd{display:grid;gap:10px;border-top:1px solid var(--line);padding-top:12px;margin-top:6px}.srcbonus{border-top:1px solid var(--line);padding-top:12px;margin-top:12px}
@media (max-width:640px){.sc-job{grid-template-columns:1fr 1fr}.sc-job .hint{grid-column:span 2}.qno b{font-size:18px}}

.statusbar{padding:10px 14px;margin-bottom:10px}.statusbar .row{gap:10px;align-items:center}.statusbar select{max-width:260px;width:auto}
.ro :is(input,select,textarea,button,.btn):not(a):not(.keep){pointer-events:none;opacity:.6}.ro a.btn{pointer-events:auto;opacity:1}
.sc-reps{display:flex;flex-wrap:wrap;gap:6px 14px;align-items:center;margin-top:8px;font-size:13px}.sc-rep{display:inline-flex;gap:6px;align-items:center}

/* ================= Schedule ================= */
.sched td.c-cal{min-width:190px;max-width:260px;white-space:normal}.sched .cal-text{font-size:12px;margin-top:2px;line-height:1.3}.sched input[type=date]{min-width:136px}.sched select{min-width:150px}
.instlist{display:grid;gap:8px;margin:10px 0}.instrow{display:grid;grid-template-columns:1.2fr 1.6fr 1fr auto;gap:8px;align-items:center}.instrow.off{opacity:.6}
.instadd{display:grid;grid-template-columns:1.2fr 1.6fr 1fr auto;gap:8px;border-top:1px solid var(--line);padding-top:12px;margin-top:6px}
.tag.warn{background:#fff3d6;color:#8a5a00;border-color:#e6c36b}
@media (max-width:860px){.sched input[type=date],.sched select{min-height:42px;font-size:16px}.sched td.c-cal{min-width:0;max-width:none}.sched td.act{justify-content:flex-start}.sched input[type=date],.sched select{min-width:0;max-width:60%}.instrow,.instadd{grid-template-columns:1fr}}

/* ================= Search ================= */
.gsearch{position:relative;display:flex;align-items:center;flex:0 1 330px;min-width:200px}.gsearch .gs-ic{position:absolute;left:11px;width:18px;height:18px;color:#8fa3ae;pointer-events:none}
.gsearch input[type=search]{width:100%;padding:10px 12px 10px 36px;border-radius:8px;border:1px solid #ffffff40;background:#ffffff1a;color:#fff;font-size:14.5px}.gsearch input::placeholder{color:#b9c8d0}.gsearch input:focus{background:#fff;color:var(--ink);outline:2px solid var(--brand-green)}.gsearch input:focus::placeholder{color:#7a8a94}
.gs-panel{position:absolute;top:calc(100% + 8px);right:0;width:min(560px,92vw);max-height:78vh;overflow:auto;background:#fff;color:var(--ink);border-radius:12px;box-shadow:0 16px 44px #00000059;padding:12px;z-index:300}.gs-panel[hidden]{display:none}
.gs-by{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-bottom:8px}.gs-chips{display:flex;gap:6px;flex-wrap:wrap}
.gs-chip{border:1px solid var(--line);background:#fff;color:var(--ink);border-radius:20px;padding:6px 12px;font:600 13px/1 inherit;cursor:pointer}.gs-chip:hover{background:var(--soft)}.gs-chip.on{background:var(--blue);color:#fff;border-color:var(--blue)}
.gs-empty,.gs-count{margin:8px 2px}.gs-all{display:inline-block;margin-top:8px;text-decoration:none}
.rc{border:1px solid var(--line);border-radius:10px;padding:10px 12px;margin:8px 0;background:#fff}.rc header{display:flex;gap:10px;align-items:baseline;flex-wrap:wrap;margin-bottom:4px}.rc-n{font-size:16px}.rc-co{color:var(--muted);font-size:13px}
.rc-grid{display:grid;gap:3px}.rc-row{display:grid;grid-template-columns:64px 1fr;gap:8px;font-size:14px}.rc-row .k{color:var(--muted);font-size:12.5px;padding-top:1px}.rc a{color:var(--blue);text-decoration:none}.rc a:hover{text-decoration:underline}
.rc-quotes{display:flex;flex-wrap:wrap;gap:6px;margin-top:8px;align-items:center}.qchip{display:inline-flex;gap:8px;align-items:center;flex-wrap:wrap;border:1px solid var(--line);border-radius:8px;padding:5px 9px;font-size:13px;background:#fafbfa;color:var(--ink)!important}.qchip:hover{background:var(--soft);text-decoration:none!important}.qchip.hit{border-color:#7fa05a;background:#f1f8ec}
mark{background:#ffe8a3;color:inherit;border-radius:3px;padding:0 1px}
.gs-page .row{gap:8px}.gs-page input[type=search]{flex:1;min-width:0}.gs-page #gspc{margin-top:10px}.rc-list{max-width:860px}
.searchbtn{display:none}
/* Alex 25 Oct 2026: on every screen from tablet up, logo + search + name on the first row, the tabs on one row under them (never wrapped beside the logo) */
@media (min-width:641px){.gsearch{order:1;flex:1 1 260px;max-width:460px}.who{order:2}.top-bar{flex-wrap:wrap}.nav-main{order:3;flex:1 1 100%;border-top:1px solid #ffffff22;padding-top:6px;margin-top:2px}}
@media (max-width:640px){.gsearch{display:none}.searchbtn{display:inline-flex;align-items:center;justify-content:center;width:44px;height:44px;border-radius:9px;border:1px solid #ffffff40;color:#fff;flex:none}.rc-row{grid-template-columns:58px 1fr}.gs-chip{padding:9px 13px;font-size:14px}}

/* ================= Options (sub-quotes) ================= */
.optbar{padding:10px 14px;margin-bottom:10px}.optbar .row{gap:10px;align-items:center;flex-wrap:wrap}.optbar select{max-width:100%;width:auto;min-width:260px;flex:1 1 280px}
.optname{display:inline-block;font:600 15px/1 inherit;color:var(--steel);background:var(--soft);border-radius:6px;padding:4px 9px;margin:0 6px;vertical-align:middle}
.opt-toggle{border:1px solid var(--line);background:#fff;color:var(--blue);border-radius:16px;padding:3px 10px;font:600 12.5px/1.2 inherit;cursor:pointer;margin-left:8px}.opt-toggle:hover{background:var(--soft)}.opt-toggle .car{display:inline-block;width:12px}
tr.opt-row td{background:#f7faf5}tr.opt-row td:first-child{padding-left:28px}.opt-ind{color:var(--muted);margin-right:6px}
@media (max-width:860px){.optbar select{min-width:0}}

.repbox{border:1px solid var(--line);border-radius:10px;padding:10px 12px;background:#f7faf5;max-width:520px}.repbox select{width:100%;margin-top:4px}

/* initials on every window and door */
.ini-count{margin:4px 0 8px;font-size:15px}
.ini-card{border:1.5px solid var(--line,#cfd6d9);border-radius:10px;padding:10px;margin:10px 0;background:#fff}
.ini-card.done{border-color:#2f6a34;background:#f2f9f2}
.ini-top{display:flex;gap:12px;align-items:flex-start}
.ini-pic{flex:0 0 96px;max-width:96px}.ini-pic svg{width:96px;height:auto;max-height:120px;display:block}
.ini-info{flex:1;min-width:0;font-size:14px;line-height:1.35;overflow-wrap:anywhere}
.ini-pad{margin-top:8px}.ini-pad canvas{display:block;width:100%;max-width:300px;aspect-ratio:300/110;height:auto;border:2px dashed #2f6a34;border-radius:8px;background:#fff;touch-action:none}
.ini-type{font-size:24px;max-width:170px;text-transform:uppercase;letter-spacing:.12em}
.ini-btns{display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin-top:6px}.ini-btns .btn{min-height:44px}
.ini-ok{color:#2f6a34;font-weight:700}
/* the logo sits top left on the customer's signing page too */
.sg-head{text-align:left}.sg-img{margin:0}
.ini-pad canvas[hidden],.ini-type[hidden],.ini-ok[hidden]{display:none!important}

/* who the quote is for: the same facts the old quote showed at the top of every page */
.qclient{display:flex;gap:14px;align-items:flex-start;justify-content:space-between;margin:10px 0}
.qc-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px 18px;flex:1;min-width:0}
.qc{min-width:0}.qc span{display:block;font-size:11.5px;color:var(--muted);text-transform:uppercase;letter-spacing:.04em}.qc b{font-weight:600;overflow-wrap:anywhere}.qc .none{color:var(--muted);font-weight:400}
.qc.wide{grid-column:span 2}.qc-act{flex:none}
@media (max-width:700px){.qclient{flex-direction:column;gap:8px;padding:12px}.qc-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:6px 14px}.qc.empty{display:none}.qc b{font-size:14.5px}.qc-act .btn{width:auto}}

/* Customers: every column visible on a laptop, no sideways scrolling. Names, city, phone and status stay on one line; street, company, sales person and e-mail may wrap at a space. */
@media (min-width:701px){.ctable{font-size:12.5px;width:100%}.ctable th,.ctable td{padding:8px 5px;overflow-wrap:normal;word-break:normal;white-space:nowrap}.ctable th{white-space:normal;vertical-align:bottom;line-height:1.2}
 .ctable td.c-address,.ctable td.c-company,.ctable td.c-sales_name{white-space:normal;max-width:150px;min-width:90px}.ctable td.c-email{white-space:nowrap;max-width:none;text-overflow:clip;overflow:visible}
 .ctable td.act{white-space:nowrap}.ctable td.act .btn{margin:2px 0 2px 4px;white-space:nowrap}}

/* the leads table has many columns: it scrolls sideways on a laptop and becomes cards on a phone */
.ltable{font-size:12.5px}.ltable th,.ltable td{white-space:nowrap;padding:7px 8px}.ltable td.c-note,.ltable td.c-street,.ltable td.c-email{white-space:normal;min-width:120px;max-width:220px}.ltable td a{color:var(--blue);text-decoration:none}
.paybox{border:1px solid var(--line);border-radius:10px;padding:8px 12px;background:#fafcf9}.paysum{display:flex;gap:18px;flex-wrap:wrap;margin-top:8px;font-size:14px}.paysum b{font-size:16px}

/* the money terms the customer initials: total amount, deposit, payment schedule */
.ini-term{background:#f7f9fb}.ini-term .ini-val{font-size:18px}.ini-term.done{background:#f2f9f2}
.sg-stage{display:flex;gap:8px;flex-wrap:wrap;margin:8px 0}.sg-stage span{border:1px solid var(--line);border-radius:999px;padding:3px 12px;font-size:13px;background:#fff}.sg-stage span.on{background:#2f6a34;color:#fff;border-color:#2f6a34}.sg-stage span.next{background:#fff6dd;border-color:#d7b14a}
.stagebox{border:1.5px solid var(--line);border-radius:10px;padding:10px 14px;margin:10px 0;background:#fff}.stagebox.wait{border-color:#d7b14a;background:#fffbea}.stagebox.ok{border-color:#2f6a34;background:#f2f9f2}

/* customers: the main button opens the quote on its windows and doors */
.ctable td.act a.btn{text-decoration:none;display:inline-flex;align-items:center}
.ctable td.c-quote_no a{text-decoration:underline;text-underline-offset:3px}
@media (max-width:700px){.ctable td.act{flex-wrap:wrap;justify-content:stretch;gap:8px}.ctable td.act .btn{flex:1 1 140px;justify-content:center;text-align:center;min-height:44px}}
.ctable td.act a.btn{color:#fff!important}.ctable td.act a.btn:hover{color:#fff;text-decoration:none}
.qlinks a.btn{color:#fff;text-decoration:none}

/* Quotes list: 22 columns. On a laptop it scrolls sideways and the quote number stays in view; on a phone each quote is a card without its empty fields. */
.qtable{font-size:12.5px}.qtable th,.qtable td{white-space:nowrap;padding:4px 8px;line-height:1.25}.qtable td.c-street{white-space:nowrap;max-width:200px;overflow:hidden;text-overflow:ellipsis}.qtable tr.st-sold td{background:#eef7ee}.qtable tr.st-lost td{background:#f9ecec;color:#7a4040}.qtable tr.st-prod td{background:#eaf1f8}.qtable tr.st-lead td{background:#fff6e6}.qtable tr.st-serv td{background:#f3eefa}.qfilt select,.qfilt input{min-height:26px}.qtable td.c-email{white-space:normal;min-width:120px;max-width:220px}.qtable th.r,.qtable td.r{text-align:right}
.qtable tr.click{cursor:pointer}.qtable tr.click:hover td{background:#f4f8f3}
@media (min-width:701px){.qtable th:nth-child(2),.qtable td:nth-child(2){position:sticky;left:0;z-index:2;background:#fff;box-shadow:1px 0 0 var(--line)}.qtable thead th:nth-child(2){background:#f0f2f1}.qtable tr.click:hover td:nth-child(2){background:#f4f8f3}.qtable tr.opt-row td:nth-child(2){background:#fafcf9}}
@media (max-width:700px){.qtable td.empty{display:none}.qtable td.act .btn{width:100%;min-height:44px}}

/* Audit log: one readable line per event, grouped by day; on a phone the time sits above the sentence */
.al-day{margin:14px 0 4px;font-size:13px;color:var(--muted);text-transform:uppercase;letter-spacing:.05em}.al-day:first-child{margin-top:4px}
.al-row{display:grid;grid-template-columns:86px 1fr;gap:10px;padding:9px 0;border-bottom:1px solid var(--line)}.al-row:last-child{border-bottom:0}
.al-t{font-size:13px;color:var(--muted);white-space:nowrap;padding-top:1px}.al-text{font-weight:600;overflow-wrap:anywhere}.al-who{font-size:13px;color:var(--muted);margin-top:2px}.al-who a{color:var(--blue)}
.al-row{border-left:4px solid transparent;padding-left:10px}.al-contract{border-left-color:#2f6a34}.al-quote{border-left-color:#2a5b73}.al-settings{border-left-color:#c0883a}.al-people{border-left-color:#7a6a9a}.al-signin{border-left-color:#c9d1d5}.al-bad{border-left-color:#b3261e;background:#fdf3f2}
@media (max-width:700px){.al-row{grid-template-columns:1fr;gap:2px}}

/* Purchase orders: one line per signed contract, the PO number typed on the line */
.po-row{display:flex;gap:12px;align-items:center;justify-content:space-between;padding:10px 0;border-bottom:1px solid var(--line);flex-wrap:wrap}.po-row:last-child{border-bottom:0}.po-info{flex:1 1 260px;min-width:0}.po-form{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.po-in{max-width:200px}
@media (max-width:700px){.po-form{width:100%}.po-in{flex:1;max-width:none}.po-form .btn{min-height:44px}}

/* The sales person's commission on the quote she is working on */
.mycomm{display:flex;justify-content:space-between;gap:10px;align-items:center;margin-top:8px;padding:8px 10px;border-radius:8px;background:#f2f8f2;border-left:4px solid #2f6a34}.mycomm b{font-size:18px;color:#2f6a34;white-space:nowrap}
/* Commission rates page */
.rate-row{display:flex;flex-wrap:wrap;gap:10px;align-items:center;justify-content:space-between;padding:10px 0;border-bottom:1px solid var(--line)}.rate-row:last-child{border-bottom:0}.rate-name{flex:1 1 180px}.rate-in{display:flex;gap:8px;align-items:center}.rate-in input{width:96px}.rate-in .pct{font-weight:600}.rate-msg{flex:1 1 100%;min-height:1em}.ok{color:#2f6a34;font-weight:600}
@media (max-width:700px){.rate-in{width:100%}.rate-in input{flex:1;width:auto}.rate-in .btn{min-height:44px}}

.ini-note{margin-top:8px;border-left:4px solid #c0883a;background:#fbf3e2;padding:6px 10px;border-radius:0 6px 6px 0;font-size:14px;overflow-wrap:anywhere}
.ini-facts{margin-top:4px;font-size:13.5px;line-height:1.4}.ini-f b{color:#555;font-weight:600;margin-right:4px}
.szrow{display:flex;gap:10px;align-items:center;margin:0}.sizebar .hint{margin-top:4px}.sizebar{border-left:4px solid #2a5b73}

/* the signing cards: the same look as the quote and the agreement (blueprint figure, soft bands) */
.ini-card{border:1px solid #d8dfe2;border-radius:12px;padding:0;overflow:hidden;background:#fff}.ini-card.done{border-color:#4f6e28;background:#f6faf0}
.ini-top{padding:10px;gap:12px}.ini-pic{background:none;border-radius:8px;padding:6px;flex:0 0 112px;max-width:112px}.ini-pic svg{width:100%;max-height:150px}
.ini-info>b{display:inline-block;background:#26343c;color:#fff;border-radius:6px;padding:1px 8px;font-size:13px;margin-bottom:4px}.ini-info>div:nth-of-type(1){font-weight:800;font-size:14.5px;line-height:1.2;margin-bottom:3px}
.ini-facts .ini-f b{color:#5a6870}
.ini-note{margin:0 10px 8px;border-radius:8px;border-left:4px solid #b9792c}
.ini-pad{margin:0;padding:8px 10px 10px;background:#f4f1e9;border-top:1px solid #d8dfe2}
.cchipw{position:sticky;top:calc(var(--hdrh,64px) + 6px);z-index:90;height:0;display:flex;justify-content:flex-end;pointer-events:none}
.cchip{pointer-events:auto;margin-top:-2px;border:1px solid #2f6a34;background:#f2f8f2;color:#2f6a34;font:700 13px/1 "Segoe UI",system-ui,sans-serif;border-radius:14px;padding:5px 10px;box-shadow:0 1px 4px #0003;min-height:26px;cursor:pointer;opacity:.95}
.cchip.hid{background:#eef1f2;border-color:#9aa6ab;color:#6b777d}.cchip.neg{border-color:#b3261e;background:#fdf3f2;color:#b3261e}

/* Cost and margin (Items tab): closed until opened */
.costcard{border:1px solid #cfd8dc;border-radius:12px;background:#fff;margin:6px 0 10px;padding:0}.costcard>summary{cursor:pointer;padding:10px 14px;list-style:none}.costcard>summary::-webkit-details-marker{display:none}.costcard>summary:before{content:"▸ ";color:#2a5b73}.costcard[open]>summary:before{content:"▾ "}
.cc-body{padding:0 14px 12px}.cc-t{font-size:14px}.cc-r{display:flex;justify-content:space-between;align-items:flex-start;gap:12px;padding:6px 0;border-bottom:1px dashed #d8dfe2}.cc-r>span{min-width:0}.cc-r>b{flex:none;white-space:nowrap}.cc-r.tot{border-bottom:2px solid #26343c;font-size:15px}.cc-r.pro{border-bottom:0;color:#2f6a34}.cc-t .hint{font-weight:400}
.cc-m{margin-top:12px;padding:10px 12px;background:#f4f1e9;border-radius:10px}.cc-row{display:flex;gap:8px;align-items:center;margin:6px 0;flex-wrap:wrap}.cc-row input{width:90px}.cc-row select{min-width:190px}.cc-res{font-size:14px;line-height:1.5;margin:6px 0}#ccapply{margin-top:4px}
.cchipw{gap:6px}.cchip.cost{border-color:#2a5b73;background:#eaf2f6;color:#2a5b73}.cchip.cost.hid{background:#eef1f2;border-color:#9aa6ab;color:#6b777d}
.cc-h{padding:10px 14px;display:flex;justify-content:space-between;align-items:center;gap:10px}.cc-h .btn{flex:none}.costcard{margin-top:6px}

.pgmenu{margin:6px 0 10px}.pgmenu>summary{list-style:none;cursor:pointer;display:inline-block}.pgmenu>summary::-webkit-details-marker{display:none}.pgl{display:flex;flex-wrap:wrap;gap:6px;margin:8px 0}.pgsec{margin-top:14px}.pgsec h3{margin:0 0 4px;font-size:16px}

.limbox{border:2px solid #b3261e;background:#fdf3f2;color:#8a1c14;border-radius:12px;padding:10px 14px;margin:8px 0;font-size:14px}.limbox ul{margin:6px 0 0 18px;padding:0}

.prod-row{text-decoration:none;color:inherit}.prod-row:hover{background:#f6f8f4}.pm-line{display:flex;gap:12px;align-items:center;justify-content:space-between;padding:10px 0;border-bottom:1px solid var(--line);flex-wrap:wrap}.pm-line:last-child{border-bottom:0}.pm-pick select{min-width:160px;min-height:44px}

.dots{display:inline-block;min-width:48px;min-height:28px;line-height:28px;padding:0 10px;text-align:center;border-radius:14px;background:#e9eef1;color:#2f5d73;font-weight:700;letter-spacing:2px;cursor:pointer;-webkit-tap-highlight-color:transparent;touch-action:manipulation}
.dots:active{background:#d5e0e6}

/* the Items tab (window designer) may use a wide desktop screen: up to 1880 px instead of 1500 px */
@media (min-width:1600px){.wrap.wide{max-width:1880px}body:has(.wrap.wide) .top-bar{max-width:1880px}}

/* the Items tab on a desktop: the customer cards above the designer are shorter, so the window designer starts higher on the screen (Alex, 15 Oct). Same information, same buttons; phones and tablets are unchanged. */
@media (min-width:1000px) and (pointer:fine){
.wrap.onitems .qclient{margin:6px 0;padding:8px 12px;gap:10px}
.wrap.onitems .qc-grid{grid-template-columns:repeat(6,minmax(0,1fr));gap:4px 14px}@media (min-width:1500px){.wrap.onitems .qc-grid{grid-template-columns:repeat(8,minmax(0,1fr))}}.wrap.onitems .qc.wide{grid-column:span 2}
.wrap.onitems .qc span{font-size:10px}.wrap.onitems .qc b{font-size:13.5px}
.wrap.onitems .optbar{padding:6px 12px;margin-bottom:6px}.wrap.onitems .optbar .hint{font-size:11px;margin-top:2px!important;line-height:1.3}
.wrap.onitems .statusbar{display:flex;flex-wrap:wrap;align-items:center;gap:4px 24px;padding:6px 12px;margin-bottom:6px}
.wrap.onitems .statusbar .sizebar{flex:1 1 520px;margin:0;padding:2px 0 2px 10px;border:0;border-left:4px solid #2a5b73;border-radius:0;box-shadow:none;background:transparent;display:flex;flex-wrap:wrap;align-items:baseline;gap:0 12px}
.wrap.onitems .statusbar .sizebar .hint{margin:0;font-size:11px;line-height:1.3}
.wrap.onitems #zbrbar .card{padding:6px 12px;margin:0 0 6px}.wrap.onitems #zbrbar .hint{display:inline;margin-left:10px}
.wrap.onitems .tabs{margin-top:4px}
}

/* the window designer is open on a computer: the menu gets slim and the customer cards step aside so the designer is shown big enough to read (All windows brings them back) */
@media (min-width:1000px) and (pointer:fine){
html.designing .top-bar{padding:3px 14px}html.designing .brand{height:28px;padding:2px 6px}
html.designing .nav-main>a,html.designing .nav-more{padding:6px 10px;font-size:13px}
html.designing .who-name{font-size:12px}html.designing .who-role{font-size:10px;padding:2px 7px}html.designing .btn-out{padding:5px 10px;font-size:12px}
html.designing .wrap.onitems .qclient,html.designing .wrap.onitems .optbar,html.designing .wrap.onitems .statusbar,html.designing .wrap.onitems #zbrbar{display:none}
}
@media (min-width:1000px) and (pointer:fine){
html.designing .top-bar{flex-wrap:nowrap}html.designing .nav-main{order:0;flex:1 1 auto;border:0;padding:0;margin:0;flex-wrap:nowrap}
html.designing .gsearch{order:0;flex:0 1 190px;min-width:130px;max-width:190px}html.designing .gsearch input[type=search]{padding:6px 8px 6px 32px;font-size:13px}
html.designing .who{order:0}html.designing .who-name{display:none}
}
/* designing: the quote title, its buttons and the tabs are the same small size as the designer, no big band above it */
@media (min-width:1000px) and (pointer:fine){
html.designing .wrap.onitems>.row:first-child{margin:0 0 2px;gap:6px}
html.designing .wrap.onitems>.row:first-child h1{font-size:15px;line-height:1.2}
html.designing .wrap.onitems>.row:first-child .tag{font-size:10px;padding:1px 7px}
html.designing .wrap.onitems>.row:first-child .btn{padding:3px 9px;font-size:11.5px;min-height:0;line-height:1.3}
html.designing .wrap.onitems .tabs{margin:0 0 4px;gap:0;border-bottom-width:1px}
html.designing .wrap.onitems .tabs button{padding:3px 11px;font-size:12px;border-bottom-width:2px;margin-bottom:-1px}
html.designing .wrap.onitems{padding-top:4px}
}

/* One type scale for the whole CRM on a computer screen (the designer screen and phones keep their own compact sizes):
   12 = tags, 13 = hints, labels and tables, 14 = text, buttons, fields and tabs, 15 = small headings, 17 = headings, 22 = page title */
@media (min-width:701px){
html:not(.designing) h2{font-size:17px}
html:not(.designing) h3{font-size:15px}
html:not(.designing) .tag{font-size:12px}
html:not(.designing) .hint,html:not(.designing) label,html:not(.designing) .saving,html:not(.designing) .items .s{font-size:13px}
html:not(.designing) .btn,html:not(.designing) .tabs button,html:not(.designing) summary.btn,html:not(.designing) input,html:not(.designing) select,html:not(.designing) textarea,html:not(.designing) .chk,html:not(.designing) .banner,html:not(.designing) .sc-line,html:not(.designing) .paysum{font-size:14px}
html:not(.designing) .btn.sm,html:not(.designing) .pcard .btn{font-size:13px}
html:not(.designing) .ctable,html:not(.designing) .ltable,html:not(.designing) .qtable,html:not(.designing) th,html:not(.designing) .ctable th{font-size:13px}
html:not(.designing) .qc span{font-size:12px}html:not(.designing) .qc b{font-size:14px}
html:not(.designing) .tl li,html:not(.designing) .sc-job,html:not(.designing) .sc-reps,html:not(.designing) .al-t,html:not(.designing) .al-who{font-size:13px}
html:not(.designing) .ini-facts,html:not(.designing) .ini-note,html:not(.designing) .ini-info,html:not(.designing) .cc-t,html:not(.designing) .limbox{font-size:14px}
}

/* customer card: compact. One line per fact ("TEL 416..."), empty facts are not drawn, tight padding */
@media (min-width:701px){
.qclient{padding:8px 14px;margin:6px 0;align-items:center}
.qclient .qc-grid,.wrap.onitems .qclient .qc-grid{grid-template-columns:repeat(auto-fill,minmax(210px,1fr));gap:2px 18px}
.qclient .qc{display:flex;gap:8px;align-items:baseline;white-space:nowrap}
.qclient .qc span{flex:none;font-size:10.5px}
.qclient .qc b{font-size:14px;overflow:hidden;text-overflow:ellipsis}
.qclient .qc.empty{display:none}
.qclient .qc.wide,.wrap.onitems .qclient .qc.wide{grid-column:span 2}
}

/* "Send to the customer": one row per quote, its own customer quote and contract buttons */
.sendcard{margin:8px 0}.sendrow{display:flex;justify-content:space-between;align-items:center;gap:10px;padding:6px 0;border-top:1px solid var(--line);flex-wrap:wrap}.sendrow:first-of-type{border-top:0}.sendwhat span{color:var(--muted)}.sendrow.cur{background:rgba(46,125,50,.05)}
.sendmk{border-top:1px solid var(--line);margin-top:6px;padding-top:6px}
/* page 1 of the contract: Yes / No per product or service */
/* energy audit and alarm inspection cards on the quote page: never wider than the screen */
#chkbar{max-width:100%;min-width:0}#chkbar .card,#auditcard,#alarmcard{box-sizing:border-box;max-width:100%;min-width:0}#auditsel{width:100%;max-width:420px;box-sizing:border-box}
#alarmcard .row label{white-space:nowrap}
.alarmcard{box-sizing:border-box;max-width:100%;min-width:0}.alarmcard h2{margin:0 0 4px}.alarmcard .alrow{display:flex;flex-wrap:wrap;gap:8px 28px;margin:8px 0 2px}.alarmcard .alrow label{display:inline-flex;align-items:center;gap:8px;white-space:nowrap}.alarmcard .alon{color:#b00020}

/* garage door glass design picker (21 Oct 2026) */
.gdtiles{display:flex;flex-wrap:wrap;gap:8px;margin-top:4px}.gdtile{border:2px solid var(--line);border-radius:8px;background:#fff;padding:4px;display:flex;flex-direction:column;align-items:center;gap:2px;font-size:11px;cursor:pointer;color:inherit;min-width:84px}.gdtile.on{border-color:var(--accent);box-shadow:0 0 0 2px var(--accent) inset}.gdtile svg{display:block}
.gdrow{display:block;width:100%;text-align:left;border:2px solid var(--line);border-radius:10px;background:#fff;padding:8px 10px;margin:0 0 10px;cursor:pointer;color:inherit}.gdrow.on{border-color:var(--accent);box-shadow:0 0 0 2px var(--accent) inset}.gdrow svg{display:block;margin-top:4px}

/* entrance door designer (22 Oct 2026) */
.edtiles{display:flex;flex-wrap:wrap;gap:8px;margin-bottom:8px}
.edtile{display:flex;flex-direction:column;align-items:center;gap:4px;width:92px;padding:6px 4px;border:1px solid #d8d4c8;border-radius:8px;background:#fff;font:inherit;font-size:11px;line-height:1.2;text-align:center;cursor:pointer;color:inherit}
.edtile.on{border-color:var(--green2,#4d7a1f);box-shadow:0 0 0 2px var(--green2,#4d7a1f) inset;background:#f3f8ea}
.edtile svg{max-width:100%;height:auto}
/* the entrance door designer: clean white form, the door on a light grey panel (like the plant's program) */
.edpic{background:#fff;border:1px solid #e4e4e4;box-shadow:0 1px 3px rgba(0,0,0,.07);border-radius:10px;padding:12px 14px;text-align:left!important}.edpic .edtt{font-size:15px;color:#222;margin:0 0 4px}
.edsec>summary{font-size:16px;color:#2b2b2b}.edsec label{font-weight:600;color:#333}.edsec select,.edsec input{border-radius:8px}
@media (min-width:900px){.edpic{position:sticky;top:calc(var(--hdrh,60px) + 16px);order:2;flex:0 0 300px;align-self:flex-start}.edrow>div:last-child{order:1;flex:1;min-width:0}.edrow{flex-wrap:nowrap!important}.edpic>svg:first-of-type{width:auto;max-width:100%;height:calc(100vh - var(--hdrh,60px) - 130px);max-height:290px;min-height:160px;display:block;margin:0 auto}.edpic>svg:not(:first-of-type){display:block;margin:-8px auto 0;max-width:100%;height:auto}}
.edgl{max-height:300px;overflow:auto;padding:4px;border:1px solid #e4e0d4;border-radius:8px;background:#fff}.edtile img{display:block;margin:0 auto 3px;max-width:100%}

.igbox{display:grid;grid-template-columns:minmax(0,1fr) 200px;gap:16px;align-items:start}.igbox.nodraw{grid-template-columns:minmax(0,1fr)}.igr{display:grid;gap:8px;margin-bottom:8px}.igr5{grid-template-columns:1.5fr 1fr .6fr .6fr 1.2fr}.igr4{grid-template-columns:1fr 1fr 1.5fr .9fr}.igdraw{text-align:center;padding-top:16px}.igdraw .hint{font-size:12px}@media(max-width:900px){.igbox{grid-template-columns:minmax(0,1fr)}.igdraw{padding-top:0;text-align:left}.igr5,.igr4{grid-template-columns:1fr 1fr}}

.xg{display:grid;grid-template-columns:80px minmax(0,190px) minmax(0,190px) 44px;gap:8px;margin:6px 0;align-items:end}.xg.xg3{grid-template-columns:80px minmax(0,220px) 44px}
.xline{display:grid;grid-template-columns:minmax(220px,1fr) 80px 150px 150px 44px;gap:8px;align-items:end;margin:6px 0}.xline.xl4{grid-template-columns:minmax(220px,1fr) 80px 190px 44px}.xline>.xg{display:contents}
.xrow>div>select[data-k=sub]{max-width:420px}
@media(max-width:800px){.xline,.xline.xl4{grid-template-columns:80px minmax(0,1fr) minmax(0,1fr) 44px}.xline.xl4{grid-template-columns:80px minmax(0,1fr) 44px}.xline>div:first-child{grid-column:1/-1}.xg,.xg.xg3{grid-template-columns:80px minmax(0,1fr) minmax(0,1fr) 44px}.xg.xg3{grid-template-columns:80px minmax(0,1fr) 44px}}
.xrow .swwrap{max-width:420px}

.zbox{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:20px;align-items:start}.zart{order:2}.zfields{order:1}
.zsh{grid-template-columns:150px minmax(0,1fr) 80px!important;margin:6px 0}.zrw{grid-template-columns:60px 120px 120px 130px auto!important;gap:8px;align-items:end;margin:6px 0}
@media(max-width:800px){.zbox{grid-template-columns:minmax(0,1fr)}.zart{order:0}.zsh{grid-template-columns:1fr 1fr!important}.zrw{grid-template-columns:1fr 1fr!important}}

/* compact boxes on a computer screen (Alex, 25 Oct: "why do I need such huge boxes on the whole quote page?"): smaller type and boxes, number boxes capped; phones keep the big touch sizes */
@media (min-width:801px){
  html,body{font-size:14px}
  input,select,textarea{padding:1px 7px;font-size:13.5px;min-height:26px;line-height:1.25}   /* 4 Nov 2026 (Alex): same letters, shorter boxes */
  textarea{padding:5px 7px}
  input[type=number]{max-width:150px}
  label{font-size:11.5px;margin-bottom:1px}
  .btn{padding:4px 10px;font-size:13px}
  .btn.sm{padding:3px 8px}
  .tabs button{padding:6px 12px;font-size:14px}
  .xg{grid-template-columns:64px minmax(0,150px) minmax(0,150px) 34px;gap:6px}.xg.xg3{grid-template-columns:64px minmax(0,170px) 34px}
  .xline{grid-template-columns:minmax(220px,1fr) 64px 130px 130px 34px;gap:6px}.xline.xl4{grid-template-columns:minmax(220px,1fr) 64px 150px 34px}
  .xg .btn.del,.xline .btn.del{padding:2px 0;min-height:26px}
  .igr5{grid-template-columns:1.4fr 1fr .5fr .5fr 1.1fr}.igr{gap:6px;margin-bottom:6px}
  .card{padding:12px}
  .xrow>div>select[data-k=sub]{max-width:340px}.xrow .swwrap{max-width:340px}
}

/* quote tabs sit right under the top menu, above the quote title, and stay in view while scrolling (Alex, 25 Oct 2026) */
#tabs.tabs{position:sticky;top:var(--hdrh,0px);z-index:6;background:var(--paper,#f3f4f1);margin-top:0;padding-top:2px}

/* initials: a SMALL box next to the item picture, top right of the card (Alex, 25 Oct 2026) */
.ini-card{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:start}
.ini-card>.ini-top{grid-column:1;grid-row:1}
.ini-card>.ini-note{grid-column:1 / -1;grid-row:2}
.ini-card>.ini-pad{grid-column:2;grid-row:1;background:none;border-top:0;padding:10px 10px 0 0;margin:0;width:112px}
.ini-pad label{display:block;font-size:10px;letter-spacing:.06em;text-transform:uppercase;color:#5a6870;margin:0 0 3px;line-height:1.2}
.ini-pad canvas{width:100px;max-width:100%;aspect-ratio:2/1;border-width:1.5px;border-radius:6px}
.ini-type{font-size:16px;max-width:100%;width:100px}
.ini-btns{gap:5px;margin-top:4px}.ini-btns .btn{min-height:30px;padding:2px 8px;font-size:12.5px}
.ini-term .ini-pad{align-self:center}
@media (max-width:480px){.ini-card>.ini-pad{width:100px;padding-right:8px}.ini-pad canvas,.ini-type{width:90px}.ini-pic{flex-basis:84px;max-width:84px}}

/* 4 Nov 2026 (Alex): compact option grid: two choices per row on a phone, three to five on a computer; small label, 34 px box, thin border, little padding. One choice costs about 60 px instead of 95. */
.pm-gh{font-size:11.5px;font-weight:700;text-transform:uppercase;letter-spacing:.06em;color:#56707f;margin:10px 0 4px;padding-bottom:2px;border-bottom:1px solid #d9e1e6}
.pm-fg{display:grid;grid-template-columns:repeat(auto-fill,minmax(170px,1fr));gap:6px}
.pm-f{display:flex;gap:6px;align-items:center;border:1px solid #dfe5e9;border-radius:8px;padding:4px 6px 5px;background:#fff;min-width:0}
.pm-f.pm-col .pm-pic{display:none}
.pm-fb select,.pm-fb input,.pm-fb .swbtn{min-height:32px;padding:3px 7px;font-size:15px;border-radius:7px}
.pm-fb .swbtn{gap:6px}.pm-fb .swbtn .swpic{width:30px;height:30px;flex:0 0 30px}.pm-fb .swbtn .swpic img,.pm-fb .swbtn .swpic svg{max-width:30px;max-height:30px}
@media (max-width:640px){.pm-fg{grid-template-columns:1fr 1fr}.pm-f:has(.pm-big),.pm-f.pm-wide{grid-column:1/-1}.pm-fb select,.pm-fb input,.pm-fb .swbtn{font-size:15px}}
@media (min-width:760px){.pm-fg{grid-template-columns:repeat(4,minmax(0,1fr));gap:4px 8px}.pm-f.pm-wide{grid-column:span 2}.pm-f{border:0;padding:0;background:transparent;border-radius:0}.pm-f.pm-ch{background:transparent}.pm-f.pm-ch select,.pm-f.pm-ch .swbtn,.pm-f.pm-ch input{border-color:#a86a00;background:#fff8e6}.pm-fb select,.pm-fb input,.pm-fb .swbtn{min-height:26px;padding:1px 6px;font-size:13.5px}.pm-fb .swbtn .swpic{width:22px;height:22px;flex:0 0 22px}.pm-fb .swbtn .swpic img,.pm-fb .swbtn .swpic svg{max-width:22px;max-height:22px}.pm-lb{font-size:11px}.pm-gh{margin:6px 0 2px;font-size:11px}.pm-pic{flex-basis:30px;width:30px;height:30px}.pm-pic svg{max-width:30px;max-height:30px}}
@media (min-width:1100px){.pm-fg{grid-template-columns:repeat(5,minmax(0,1fr))}}
@media (min-width:1400px){.pm-fg{grid-template-columns:repeat(6,minmax(0,1fr))}}
.pm-f.pm-ch{border-color:#a86a00;background:#fff8e6}
.pm-pic{flex:0 0 40px;width:40px;height:40px;display:flex;align-items:center;justify-content:center;overflow:hidden}
.pm-pic:empty{display:none}
.pm-pic svg{max-width:40px;max-height:40px;width:auto;height:auto}
.pm-fb{flex:1;min-width:0;display:flex;flex-direction:column;gap:2px}
.pm-lb{font-size:11.5px;color:#56707f;margin:0;line-height:1.15;overflow-wrap:anywhere}
.pm-fb select,.pm-fb input{width:100%;min-width:0}
.pm-draws svg{max-width:100%;height:auto}

.pm-redo-ov{position:fixed;inset:0;z-index:1000;background:#f4f4f2;display:flex;flex-direction:column}
.pm-redo-bar{display:flex;gap:10px;align-items:center;flex-wrap:wrap;padding:10px 14px;background:#fff;border-bottom:1px solid #d9e1e6}
.pm-redo-ov iframe{flex:1;width:100%;border:0;background:transparent;overflow:auto}

.pm-pic.pm-big{flex-basis:130px;width:130px;height:auto;min-height:70px}
.pm-pic.pm-big svg{max-width:130px;max-height:120px}
.pm-pic.pm-big img{height:auto!important;max-width:130px;max-height:84px}
.pm-cap{display:flex;flex-direction:column;font-size:12px;color:#33505f;line-height:1.3}
.pm-cap b{font-weight:700}
.pm-f:has(.pm-big){grid-column:1/-1}

.pm-redobar{display:flex;flex-wrap:wrap;gap:8px;align-items:center;margin:6px 0}
.pm-two{display:flex;flex-direction:column}.pm-two .pm-right{order:-1}.pm-two .pm-left{min-width:0}
@media (min-width:760px){.pm-two{flex-direction:row;gap:14px;align-items:flex-start}.pm-two .pm-left{flex:1 1 auto;min-width:0}.pm-two .pm-right{order:0;flex:0 0 170px;position:sticky;top:calc(var(--hdrh,96px) + 10px)}.pm-two .pm-right .pm-draws{flex-direction:column;margin:4px 0}.pm-two .pm-right figure{max-width:160px!important}.pm-two .pm-right .pm-redobar{margin:0}.pm-two .pm-right .pm-redo{font-size:13px;padding:5px 10px;min-height:30px}}   /* 4 Nov 2026: just the button, no green box */
.pm-redobar .pm-redo{font-size:14px;padding:7px 14px;min-height:36px}
.pm-redobar .hint{flex-basis:100%;margin:0}

.calbar{gap:8px;align-items:center;flex-wrap:wrap;margin-bottom:12px}.calbar b{min-width:170px;text-align:center}.calbar select{max-width:220px}
.calweek{display:grid;gap:14px}.calday h3{margin:0 0 8px;font-size:15px;display:flex;flex-direction:column;gap:1px;line-height:1.25;white-space:nowrap}.calday h3 .hint{font-size:12px;font-weight:400}.calday>.hint,.calday>p.hint{margin:0}.calday.today h3{color:var(--accent,#1a5fb4)}
.appt{padding:10px 12px;margin:0 0 8px;display:grid;gap:3px}.appt.done{opacity:.6}.appt.inst{border-left:4px solid var(--muted,#888)}
@media (min-width:900px){.calweek{grid-template-columns:repeat(7,1fr);align-items:start}}

.crew{border-collapse:collapse;width:100%;font-size:13px}.crew th,.crew td{border:1px solid var(--line,#ddd);padding:4px 6px;text-align:center;min-width:64px;vertical-align:top}.crew tbody th{text-align:left;white-space:nowrap;background:var(--soft,#f6f6f6)}
.crew td.busy{background:#e3f1e4}.crew td.clash{background:#f6d4d0;font-weight:bold}.crew th.wk{opacity:.6}.crew small{font-weight:normal;opacity:.8}.notice-cell{margin-top:6px;display:grid;gap:3px}.chk{display:flex;gap:8px;align-items:center}

.gkgrid{margin-top:6px;border:1px solid #e4e0d4;border-radius:8px;padding:6px;background:#fff}.gkhead{font-size:12px;margin-bottom:6px}
.gktiles{display:grid;grid-template-columns:repeat(auto-fill,minmax(84px,1fr));gap:6px;max-height:260px;overflow:auto}
.gktile{display:flex;flex-direction:column;align-items:center;gap:3px;padding:5px 3px;border:1px solid #d8d4c8;border-radius:8px;background:#fff;font:inherit;font-size:10.5px;line-height:1.15;text-align:center;cursor:pointer;color:inherit}
.gktile i{display:block;width:34px;height:34px;border-radius:50%;border:1px solid rgba(0,0,0,.3)}.gktile em{display:block;font-style:normal;color:#777;font-size:10px}
.gktile.on{border-color:var(--green2,#4d7a1f);box-shadow:0 0 0 2px var(--green2,#4d7a1f) inset;background:#f3f8ea}

.calmodes{display:inline-flex;gap:4px}.calmodes .btn.on{background:var(--green2,#4d7a1f);color:#fff;border-color:var(--green2,#4d7a1f)}
@media (min-width:900px){.calweek.calone{grid-template-columns:minmax(0,560px)}}
.calmonth{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:2px;margin-top:8px}.calmh{font-weight:600;font-size:12px;text-align:center;padding:4px 0;color:#666}
.calmc{display:flex;flex-direction:column;align-items:flex-start;gap:2px;min-height:78px;padding:3px 4px;border:1px solid var(--line,#ddd);border-radius:6px;background:#fff;font:inherit;text-align:left;cursor:pointer;overflow:hidden;color:inherit}
.calmc.out{opacity:.45}.calmc.today{border-color:var(--green2,#4d7a1f);box-shadow:0 0 0 1px var(--green2,#4d7a1f) inset}.calmc b{font-size:12px}
.calchip{display:block;max-width:100%;font-size:10.5px;line-height:1.25;padding:1px 4px;border-radius:4px;background:#e3eefb;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.calchip.inst{background:#e3f1e4}
@media (max-width:700px){.calmc{min-height:52px}.calchip{font-size:9px;padding:0 2px}}
.calyear{display:grid;grid-template-columns:repeat(auto-fill,minmax(200px,1fr));gap:14px;margin-top:8px}.calym{border:1px solid var(--line,#ddd);border-radius:8px;padding:6px;background:#fff}
.calymh{display:block;width:100%;text-align:left;background:none;border:0;font:inherit;font-weight:700;cursor:pointer;padding:2px 2px 4px;color:inherit}
.calyg{display:grid;grid-template-columns:repeat(7,1fr);gap:1px;text-align:center;font-size:11px}.calyg span{color:#888}.calyg i{display:block}
.calyd{border:0;background:none;font:inherit;font-size:11px;padding:3px 0;border-radius:4px;cursor:pointer;color:inherit}.calyd.has{background:#cfe3f8;font-weight:700}.calyd.today{outline:2px solid var(--green2,#4d7a1f)}

.rp-tiles{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:10px;margin:10px 0}.rp-tile{background:#fff;border:1px solid var(--line,#ddd);border-radius:10px;padding:10px 12px}
.rp-k{font-size:12px;color:#666}.rp-n{font-size:18px;font-weight:700;margin:2px 0}.rp-d{font-size:12px;color:#666}.rp-d.up{color:#2e7d32}.rp-d.down{color:#c62828}.rp-d small{color:#888}
.rp-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(340px,1fr));gap:12px;margin:12px 0}.rp-grid .card h2{margin-top:0;font-size:16px}
.rp-bars{display:grid;gap:8px}.rp-row{display:grid;grid-template-columns:minmax(70px,28%) 1fr auto;gap:8px;align-items:center;font-size:13px}.rp-t{background:#eef0ea;border-radius:5px;height:14px}.rp-t i{display:block;height:100%;background:var(--green2,#4d7a1f);border-radius:5px}
.rp-v{text-align:right;font-weight:600}.rp-v small{display:block;font-weight:400;color:#777;font-size:11px}
.rp-svg{width:100%;min-width:420px;height:auto}.rp-svg rect.c{fill:var(--green2,#4d7a1f)}.rp-svg rect.p{fill:#c9d8b4}.rp-svg text{font-size:10px;fill:#666}
@media (max-width:420px){.rp-grid{grid-template-columns:1fr}}
.calbar input[type=date],.calbar #rpu{width:auto;max-width:170px}

select.edreq,input.edreq{border-color:#d32f2f!important;box-shadow:0 0 0 1px #d32f2f inset}.edreqm{color:#d32f2f;font-size:12px;margin-top:2px}
/* Alex (29 Oct 2026): a drop-down menu is only as wide as its longest option, not as wide as the column */
select{width:auto!important;max-width:100%!important}
.optbar select{flex:0 1 auto!important}

/* Cobra-style slab carousel: one row of big cards that slides sideways, the chosen slab has a red frame and red name */
.edcar{display:flex;align-items:center;gap:6px}
.edcarv{flex:1;min-width:0;display:flex;gap:12px;overflow-x:auto;scroll-snap-type:x proximity;padding:6px 2px 10px;scrollbar-width:thin}
.edcarb{flex:none;width:30px;height:48px;border:1px solid #d8d4c8;border-radius:8px;background:#fff;cursor:pointer;color:#777;font-size:14px}
.edcard{flex:none;scroll-snap-align:start;display:flex;flex-direction:column;align-items:center;justify-content:space-between;gap:8px;width:150px;padding:14px 8px 10px;border:1px solid #e2e0da;border-radius:10px;background:#fff;font:inherit;font-size:14px;line-height:1.2;text-align:center;cursor:pointer;color:inherit}
.edcard svg{max-width:100%;height:auto}
.edcard:hover{background:#faf9f6}
.edcard.on{border:2px solid #e8463c;background:#fff6f4;color:#e8463c;font-weight:600}
.edcarv .edtile{flex:0 0 auto;width:150px;padding:10px 6px;font-size:14px}.edcarv .edtile img{height:170px!important;width:auto}

.edprice{background:#f3f7ee;border:1px solid #cfdcc0;border-radius:8px;padding:8px 10px;margin:0 0 10px;text-align:right}.edprice .edpt{font-size:11px;text-transform:uppercase;letter-spacing:.06em;color:#5a6b48}.edprice .edpv{font-size:24px;font-weight:700;color:#1d3a12;line-height:1.15}.edprice .edpn{font-size:12px;color:#555;margin-top:3px}.edprice .edpn.warn{color:#a55a00}.edinst{margin-top:10px;border-top:1px solid #e4e4e4;padding-top:8px}.edinst label{font-size:12px}
.edprice{padding:4px 10px;margin:0 0 6px}.edprice .edpv{font-size:13px;font-weight:700}.edinst.top{margin:0 0 10px;border-top:0;padding-top:0}.edinst.top input{width:100%;box-sizing:border-box}

.rp-pie{display:flex;gap:14px;align-items:center;flex-wrap:wrap}.rp-pie ul{list-style:none;margin:0;padding:0;font-size:13px;flex:1;min-width:150px}.rp-pie li{display:flex;align-items:center;gap:7px;margin:3px 0}.rp-pie li i{width:11px;height:11px;border-radius:3px;flex:none}.rp-pie li b{margin-left:auto}
.rp-grid>*{min-width:0}.rp-v small{white-space:normal;max-width:190px;margin-left:auto}.rp-row>*{min-width:0}

/* 4 Nov 2026 (Alex): plain list boxes as short as the others */
.pm-fb select{height:28px;min-height:28px;padding-top:1px;padding-bottom:1px}
@media (min-width:760px){.pm-fb select{height:26px;min-height:26px}}
.pm-pick select{height:28px;min-height:28px;padding-top:1px;padding-bottom:1px}
@media (min-width:760px){.pm-pick select{height:26px;min-height:26px}}

/* Contracts page (5 Nov 2026) */
.ct-chips{display:grid;grid-template-columns:1fr 1fr;gap:6px}
.ct-chip{display:flex;align-items:center;gap:6px;justify-content:space-between;text-align:left;border:1px solid #d5dde2;background:#fff;border-radius:8px;padding:5px 9px;font:inherit;font-size:13px;min-height:32px;cursor:pointer;color:#22343f}
.ct-chip b{background:#eef2f4;border-radius:99px;padding:0 7px;font-size:12px}.ct-chip .ct-n{color:#6a7f8b;font-size:11px}
.ct-chip.on{border-color:#2f5d73;background:#e7f0f4;box-shadow:inset 0 0 0 1px #2f5d73}.ct-chip.ct-attn b{background:#fbeed3;color:#a86a00}
.ct-card{padding:0!important;overflow:hidden}
.ct-row{display:grid;grid-template-columns:1fr auto;gap:6px 12px;padding:9px 12px;border-bottom:1px solid #e3e8eb;color:inherit;text-decoration:none}
.ct-row:hover{background:#f6f9fa}.ct-row .ct-mid{grid-column:1/-1}.ct-val{font-weight:700;white-space:nowrap;align-self:start}
.ct-bar{display:grid;grid-template-columns:repeat(8,1fr);gap:3px;margin:2px 0 4px}.ct-bar i{display:block;height:7px;border-radius:4px;background:#dde4e8}
.ct-bar i.ok{background:#4f8a53}.ct-bar i.now{background:#2f6f8f}.ct-bar i.bad{background:#b3261e}
.ct-st{font-size:13px}.ct-next{font-size:13px;color:#2f5d73}
.ct-late{border-left:4px solid #d08a00}.ct-late .ct-next{color:#a86a00}.ct-warn{border-left:4px solid #b3261e}.ct-warn .ct-next{color:#b3261e;font-weight:600}
@media (min-width:760px){.ct-chips{display:flex;flex-wrap:wrap}.ct-chip{justify-content:flex-start}
  .ct-row{grid-template-columns:minmax(200px,1.1fr) minmax(280px,1.6fr) 250px;align-items:center}.ct-row .ct-mid{grid-column:auto}.ct-val{text-align:right;align-self:center}}
.ct-chip{justify-content:flex-start}.ct-chip b{margin-left:auto}
@media (min-width:760px){.ct-chip b{margin-left:4px}}

/* Installer's sheet beside the measurement table (5 Nov 2026) */
.ms-pages{display:flex;gap:8px;flex-wrap:wrap}.ms-pg{margin:0;width:92px}.ms-pg img{width:92px;height:120px;object-fit:cover;border:1px solid #cfd8dd;border-radius:6px;cursor:zoom-in;background:#fff}.ms-pg figcaption{font-size:11px;color:#56707f;text-align:center}.ms-del{border:0;background:transparent;color:#b3261e;cursor:pointer;font-size:12px}
.ms-big{margin-top:8px;border:1px solid #cfd8dd;border-radius:8px;padding:6px;background:#fff}.ms-zoom{overflow:auto;max-height:70vh;touch-action:pan-x pan-y pinch-zoom}.ms-zoom img{display:block;width:100%;max-width:none}
.ms-read{margin-top:8px;border:1px solid #d9e1e6;border-radius:8px;padding:8px 10px;background:#f7fafb}.ms-flags{margin:4px 0;padding-left:18px}.ms-flags li.red{color:#b3261e;font-weight:600}.ms-flags li.warn{color:#a55a00}
.ms-bad{border:2px solid #b3261e!important;background:#fdecea!important}.ms-row-bad td:first-child{border-left:4px solid #b3261e}.ms-row-warn td:first-child{border-left:4px solid #d08a00}
.ms-why td{padding-top:0!important;font-size:12.5px}.ms-why .red{color:#b3261e;font-weight:600;margin-right:8px}.ms-why .warn{color:#a55a00;margin-right:8px}.ms-read .red{color:#b3261e;margin-top:4px}
@media (min-width:1000px){.ms-two.ms-open{display:grid;grid-template-columns:minmax(300px,38%) minmax(0,1fr);gap:16px;align-items:start}.ms-two.ms-open .ms-sheet{position:sticky;top:calc(var(--hdrh,60px) + 8px)}.ms-two.ms-open .ms-zoom{max-height:calc(100vh - 220px)}}

/* Measurements page (5 Nov 2026) */
.mm-card{padding:0!important;overflow:hidden}.mm-row{display:grid;grid-template-columns:minmax(180px,1fr) minmax(0,2fr);gap:6px 14px;padding:9px 12px;border-bottom:1px solid #e3e8eb;align-items:start}
.mm-row .mm-inst{max-width:220px}.mm-late{border-left:4px solid #d08a00}.mm-red{border-left:4px solid #b3261e}
@media (max-width:640px){.mm-row{grid-template-columns:1fr}}
.ms-ask{border:1px solid #d9e1e6;border-radius:8px;padding:8px 10px;background:#f7fafb;margin:0 0 10px}
.banner.ok{background:#eaf6ea;border-color:#2f7d32;color:#1f5a23}
.house{margin-top:6px}.house summary{cursor:pointer}.house-links{display:flex;gap:6px;flex-wrap:wrap;margin-top:6px}

/* Booking page (5 Nov 2026) */
.bk{border-collapse:collapse;width:100%;font-size:13px}.bk th,.bk td{border-bottom:1px solid #e3e8eb;border-right:1px solid #eef2f4;padding:6px 8px;vertical-align:top;text-align:left}.bk th{background:#f3f5f6;font-size:12px;white-space:nowrap}
.bk .bk-who{min-width:190px;position:sticky;left:0;background:#fff;z-index:1}.bk th:first-child{position:sticky;left:0;z-index:2}.bk .bk-none{background:#fafbfb}.bk .bk-cell{min-width:150px}.bk .bk-booked{background:#eef7ee}
.bk-n{white-space:nowrap}.bk-eta label{font-size:12px;display:flex;align-items:center;gap:4px;margin:3px 0}.bk-eta input{max-width:135px}.bk-tick{font-size:12px;display:flex;gap:4px;align-items:center}
.bk-book{min-width:300px}.bk-book input[type=date]{max-width:140px}.bk-visit{border-top:1px dashed #d5dde2;margin-top:6px;padding-top:4px;font-size:12.5px}
.bk-pick{display:grid;grid-template-columns:repeat(auto-fill,minmax(260px,1fr));gap:8px;margin-top:8px}.bk-pick label{font-size:12px}.bk-pick input{width:100%}
.bk .bk-none{color:#c5ced4;text-align:center}.bk .bk-cell{min-width:140px}

/* Charts tab on Reports (5 Nov 2026) */
.ch-grid{grid-template-columns:repeat(auto-fit,minmax(min(100%,440px),1fr))}
.ch-card h2{margin:0;font-size:16px}
.ch-head{display:flex;flex-wrap:wrap;gap:6px 10px;align-items:center;justify-content:space-between;margin-bottom:6px}
.ch-kinds{display:flex;gap:4px;flex-wrap:wrap}.ch-kinds .btn{padding:2px 8px;font-size:12px;min-height:26px}
.ch-wrap{overflow-x:auto}.ch-svg{width:100%;height:auto;display:block;min-width:300px}
.ch-grid line.ch-grid,.ch-svg .ch-grid{stroke:#d6dde3;stroke-width:1}
.ch-ax{font-size:10px;fill:#5b6773}.ch-val{font-size:10px;fill:#24323d;font-weight:600}.ch-pct{font-size:11px;fill:#fff;font-weight:700}
.ch-centre{font-size:15px;font-weight:700;fill:#24323d}.ch-fun{font-size:12px;fill:#24323d}
.ch-leg{display:flex;flex-wrap:wrap;gap:4px 14px;font-size:12px;margin-top:4px}.ch-leg i,.ch-donut li i{display:inline-block;width:11px;height:11px;border-radius:3px;margin-right:5px;vertical-align:-1px}
.ch-donut{display:flex;gap:14px;align-items:center;flex-wrap:wrap}.ch-donut svg{flex:0 0 180px}.ch-donut ul{list-style:none;margin:0;padding:0;font-size:13px;flex:1;min-width:160px}.ch-donut li{margin:2px 0}.ch-donut li small{color:#5b6773;margin-left:4px}
@media (max-width:640px){.ch-donut svg{flex-basis:150px;width:150px;height:150px}}

/* Production flow, five steps (6 Nov 2026) */
.pm-flowcard{border:2px solid #2f6f8f}
.pm-flow{display:inline-flex;flex-wrap:wrap;gap:4px 6px;align-items:center;font-size:13px}.pm-flow span{background:#eef3f6;border-radius:6px;padding:2px 8px}.pm-flow i{font-style:normal;color:#5b6773}
.pm-auto{display:flex;gap:8px;align-items:flex-start;font-size:14px;max-width:720px}.pm-auto input{margin-top:3px;width:18px;height:18px}
.pm-steps{display:flex;flex-wrap:wrap;gap:6px;margin:6px 0}.pm-steps.big{gap:8px}
.pm-step{display:inline-flex;align-items:center;gap:6px;font-size:12px;border-radius:999px;padding:3px 10px 3px 4px;background:#f0f2f4;color:#5b6773;border:1px solid #d6dde3}
.pm-steps.big .pm-step{font-size:13px;padding:5px 12px 5px 5px}
.button.pm-step,.pm-go{font:inherit;font-size:13px;cursor:pointer;text-align:left}.pm-go:hover{filter:brightness(.97);box-shadow:0 1px 4px rgba(0,0,0,.18)}.pm-gomsg{margin-top:4px}
.pm-step i{font-style:normal;font-weight:700;width:20px;height:20px;border-radius:50%;display:inline-flex;align-items:center;justify-content:center;background:#fff;border:1px solid #c4ccd3;font-size:11px}
.pm-step.done{background:#eaf6ea;color:#2f7d32;border-color:#b9dcbb}.pm-step.done i{background:#2f7d32;color:#fff;border-color:#2f7d32}
.pm-step.now{background:#fff7e6;color:#8a5a00;border-color:#f0c877;font-weight:700}.pm-step.now i{background:#d98e04;color:#fff;border-color:#d98e04}
.pm-step.red{background:#fdecea;color:#b3261e;border-color:#f0a8a2;font-weight:700}.pm-step.red i{background:#b3261e;color:#fff;border-color:#b3261e}
.pm-next{margin-top:6px;font-size:14px}
.pm-ack{border:1px dashed #a9b7c2;border-radius:8px;padding:10px 12px;margin:8px 0;background:#fbfcfd}
.pm-pick{cursor:pointer}
.pm-stamp{display:inline-block;border:2px solid #fff;border-radius:4px;padding:0 6px;font-weight:900;letter-spacing:1px;color:#fff;background:#b3261e;margin-right:6px;font-size:12px}
.pm-redlist li{color:#b3261e}
.pm-adjust textarea{width:100%;box-sizing:border-box;margin-top:4px}

/* v541 (Alex, 6 Nov 2026): ring scorecards, progress bars with the % at the end, tables */
.ch-glance{grid-column:1/-1}.ch-rings{display:grid;grid-template-columns:repeat(auto-fit,minmax(130px,1fr));gap:12px;margin:8px 0}
.ch-ring{text-align:center}.ch-ring svg{max-width:100%}.ch-rpc{font-size:22px;font-weight:700;fill:#1f2d3a}.ch-rn{font-weight:700;font-size:13px;margin-top:2px}.ch-rs{font-size:12px;color:#5b6773}
.ch-pb{display:flex;flex-direction:column;gap:9px;margin:6px 0}.ch-pbl{display:flex;justify-content:space-between;gap:8px;font-size:13px;margin-bottom:2px}.ch-pbl small{color:#5b6773;font-size:12px;text-align:right}
.ch-pbt{background:#eaeef1;border-radius:999px;height:22px;overflow:hidden}.ch-pbt i{display:flex;align-items:center;justify-content:flex-end;height:100%;border-radius:999px;min-width:40px}.ch-pbt b{color:#fff;font-size:12px;padding:0 9px}
.ch-tw{overflow-x:auto}.ch-table{width:100%;border-collapse:separate;border-spacing:0 3px;font-size:13px}.ch-table th{color:#fff;text-align:left;font-weight:700;padding:6px 10px;white-space:nowrap}.ch-table th:first-child{border-radius:8px 0 0 8px}.ch-table th:last-child{border-radius:0 8px 8px 0}
.ch-table td{padding:6px 10px;background:#f4f6f8}.ch-table td:first-child{border-radius:8px 0 0 8px}.ch-table td:last-child{border-radius:0 8px 8px 0}.ch-table .n{text-align:right;font-variant-numeric:tabular-nums}.ch-table tr.tot td{background:#e3eaef;font-weight:700}

/* Vendors page (6 Nov 2026) */
.vd-wrap{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,420px),1fr));gap:12px}
.vd-grid{display:grid;grid-template-columns:1fr 1fr;gap:6px 10px;margin-top:8px}
.vd-f{display:flex;flex-direction:column;gap:2px;font-size:12px;color:var(--muted,#5b6770);min-width:0}
.vd-f input{width:100%;min-width:0}
@media(max-width:380px){.vd-grid{grid-template-columns:1fr}}

.sv-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(210px,1fr));gap:10px 16px}.sv-g{min-width:0}.sv-t.on{background:var(--accent,#2f5d73);color:#fff}
@media(max-width:560px){#sv-form .vd-grid{grid-template-columns:1fr 1fr!important}}
.sv-thumbs{display:flex;flex-wrap:wrap;gap:8px;margin-top:8px}.sv-th{position:relative;width:96px;height:72px;border:1px solid var(--line,#d3dbe0);border-radius:6px;overflow:hidden;background:#111}.sv-th img,.sv-th video{width:100%;height:100%;object-fit:cover;display:block}.sv-x{position:absolute;top:2px;right:2px;width:24px;height:24px;border:0;border-radius:12px;background:rgba(0,0,0,.65);color:#fff;font-size:16px;line-height:22px;cursor:pointer;padding:0}.sv-play{position:absolute;left:6px;bottom:4px;color:#fff;font-size:14px;text-shadow:0 0 3px #000}
.sv-t .hint{color:inherit;opacity:.75;font-size:.8em}
.sv-sel.on{border-color:var(--accent,#2f5d73);box-shadow:0 0 0 2px rgba(47,93,115,.25);font-weight:600}
.sv-t,.sv-sel{min-height:42px;font-size:16px;padding:6px 12px;margin:0;box-sizing:border-box}.sv-t .hint{display:none}

/* initials step under the contract: one short row per item (the contract above has the details) */
.ini-compact .ini-facts,.ini-compact .ini-note{display:none}.ini-compact .ini-pic{flex-basis:64px;max-width:64px;padding:2px}.ini-compact .ini-pic svg{max-height:70px}.ini-compact .ini-top{align-items:center}

.sg-doc{border:1px solid #c9d1d5;border-radius:6px;background:#fff;padding:0 0 4px;margin-top:8px}.sg-ini{padding:4px 14px 8px}.sg-h{font-size:18px;margin:10px 0 2px}
.sg-sign{flex:1;min-width:0;display:grid;grid-template-columns:1fr 1fr;gap:14px 26px}.sg-sf{min-width:0}.sg-v{display:flex;align-items:flex-end;min-height:34px;border:0;border-bottom:1.5px solid #222;border-radius:0;padding:0 2px 2px;font-size:16px;background:none;width:100%;box-sizing:border-box}.sg-l{font-size:12.5px;margin-top:3px;color:#444}
@media (max-width:560px){.sg-sign{grid-template-columns:1fr}}

/* Trust Build signing page: green buttons, Begin / Go to next / Complete bar, "Your signature and initials" window (own look, 10 Nov 2026) */
.flag{display:inline-flex;align-items:center;gap:7px;background:#2f6a34;border:2px solid #1f4d24;color:#fff;font-weight:700;font-size:15px;border-radius:24px;padding:9px 14px;white-space:nowrap;min-height:44px;cursor:pointer;box-shadow:0 2px 0 #1f4d24}.flag:before{content:"\270E";font-size:15px}
.ini-flagpad{display:flex;flex-direction:column;align-items:flex-start;gap:6px;width:130px}.ini-mark{border-bottom:1.5px solid #222;min-height:44px;min-width:100px;display:flex;align-items:flex-end;padding:0 4px}.ini-mark img{max-height:44px;max-width:120px}.ini-script{font:italic 26px 'Segoe Script','Bradley Hand','Brush Script MT',cursive;color:#10143c}
.ini-undo{background:none;border:0;color:#2b5d7a;text-decoration:underline;cursor:pointer;font-size:12.5px;padding:2px}
.flash{outline:4px solid #2f6a34;outline-offset:3px;animation:sgflash .5s ease 3}@keyframes sgflash{50%{outline-color:#fff}}
.sg-sigbox{min-height:60px;border-bottom:1.5px solid #222;display:flex;align-items:flex-end;padding:0 2px 4px}.sg-sigbox img{max-height:70px;max-width:100%}
.sg-bar{position:sticky;bottom:0;z-index:50;margin:10px -16px -16px;background:#fff;border-top:2px solid #2f6a34;padding:4px 12px;padding-bottom:max(4px,env(safe-area-inset-bottom))}.sg-barin{max-width:900px;margin:0 auto;display:flex;align-items:center;gap:12px;flex-wrap:wrap}.sg-barin #sgleft{font-weight:700;flex:1;min-width:80px}.sg-barin .err{flex-basis:100%;order:3}.sg-barin .btn{min-width:130px;min-height:38px;font-size:15px;padding:4px 14px}
.sg-modal{position:fixed;inset:0;z-index:3000;background:rgba(20,30,36,.55);display:flex;align-items:center;justify-content:center;padding:12px;overflow:auto}.sg-dlg{background:#fff;border-radius:12px;max-width:560px;width:100%;padding:16px;max-height:100%;overflow:auto}.sg-dlg h2{margin:0 0 4px;font-size:20px}
.sg-dr{display:grid;grid-template-columns:1fr 130px;gap:10px;margin:8px 0}.sg-dr label{font-size:13px;color:#444}.sg-dr input{display:block;width:100%;box-sizing:border-box;font-size:17px;margin-top:3px}
.sg-tabs{display:flex;gap:6px;margin:6px 0}.sg-tabs button{flex:1;border:1.5px solid #9db0b8;background:#fff;border-radius:6px;padding:8px;font-size:15px;cursor:pointer}.sg-tabs button.on{background:#26343c;color:#fff;border-color:#26343c}
.sg-font{display:flex;align-items:center;gap:12px;border:1.5px solid #cfd6d9;border-radius:8px;padding:8px 12px;margin:6px 0;cursor:pointer;font-size:28px}.sg-font.on{border-color:#2f6a34;background:#f2f9f2}.sg-font span:first-of-type{flex:1;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.sg-fi{font-size:24px;color:#444}

/* 6 Nov 2026 (Alex: "I have to drag, letters and boxes unreasonably large"): the New quote page fits one screen on a computer: 4 columns of small boxes, Sales person and Referral check side by side */
@media (min-width: 800px) {
  .nqh { font-size: 20px; margin: 2px 0 6px; }
  .nq { max-width: 1180px !important; gap: 8px; }
  .nq .card { padding: 8px 14px 10px; }
  .nq h2 { font-size: 15px; margin: 0 0 6px; }
  .nq .hint { font-size: 12px; }
  .nq label { font-size: 12px; margin: 0 0 1px; }
  .nq input, .nq select { height: 28px; font-size: 14px; padding: 2px 7px; }
  .nq .btn { padding: 4px 12px; font-size: 14px; }
  .nq form.stack { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px 10px; align-items: end; }
  .nq form.stack .g3 { display: contents; }
  .nq form.stack .repbox, .nq form.stack .err, .nq form.stack .row, .nq #refauto { grid-column: 1 / -1; }
  .nq form.stack .err { margin: 0; min-height: 0; }
  .nq .repbox { max-width: none; display: flex; align-items: center; gap: 10px; padding: 5px 10px; }
  .nq .repbox select { width: auto; margin: 0; }
  .nq .nq2 { display: grid; grid-template-columns: minmax(260px, 1fr) minmax(0, 1.6fr); gap: 8px; align-items: start; }
  .nq .nq2 .card p.hint { margin: 0 0 4px !important; }
  .nq #refauto .banner { padding: 6px 10px; font-size: 13px; margin: 4px 0; }
  .nq #refauto .row { padding: 3px 0 !important; }
}
@media (min-width: 800px) {
  body:has(.nq) header.top { position: static; }   /* the top bar scrolls away on this page so the whole form is in view */
  .nqh { font-size: 17px; margin: 0 0 4px; }
  .nq { gap: 6px; }
  .nq .card { padding: 6px 12px 8px; }
  .nq .nq2 .card p.hint { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .nq #ne:empty { display: none; }
}
@media (min-width: 1100px) {
  .nq form.stack { grid-template-columns: repeat(6, 1fr); }
  .nq form.stack .repbox, .nq form.stack .err, .nq form.stack .row, .nq #refauto { grid-column: 1 / -1; }
}
.refreps{display:flex;flex-wrap:wrap;gap:6px}.refreps>.row{border:1px solid var(--line,#d9d9d4)!important;border-radius:8px;padding:3px 8px!important;background:#fff;flex:0 1 auto}.refnear{columns:1}@media(min-width:800px){.refnear{columns:2;column-gap:16px}}
/* 7 Nov 2026 (Alex's rule: two or three boxes per row, no one-per-row forms): the Calendars "New visit" form */
#apf .grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 8px 14px; align-items: end; }
#apf .grid2 input, #apf .grid2 select, #apf .grid2 textarea { width: 100%; box-sizing: border-box; max-width: none; }
/* 7 Nov 2026 (Alex: "can not slide to the right", the Book buttons were far off screen): the Schedule column (date, installer, Book buttons) stays pinned at the RIGHT edge while the supplier columns slide; supplier columns that no job uses are narrow; the sliding area has its own bar at the top of the screen height */
.bk .bk-book { position: sticky; right: 0; background: #fff; z-index: 1; box-shadow: -6px 0 8px -6px rgba(0,0,0,.18); min-width: 300px; }
.bk th:last-child { position: sticky; right: 0; z-index: 2; box-shadow: -6px 0 8px -6px rgba(0,0,0,.18); }
.bk th { max-width: 170px; }
.bk td.bk-none { min-width: 0; width: 1%; }
.bk-card { max-height: 78vh; overflow: auto; }
.bk thead th { position: sticky; top: 0; z-index: 3; }
.bk thead th:first-child, .bk thead th:last-child { z-index: 4; }
/* 8 Nov 2026 (Alex: Vendors page "too bulky"): compact vendor cards: three boxes per row, smaller type and boxes, smaller card padding */
.vd-wrap { grid-template-columns: repeat(auto-fill, minmax(min(100%, 400px), 1fr)); gap: 8px; }
.vd-card { padding: 8px 10px; }
.vd-card h2 { font-size: 16px; }
.vd-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px 8px; margin-top: 4px; }
.vd-f { font-size: 11px; gap: 1px; }
.vd-card input.vd, .vd-card .vd-f input { font-size: 12.5px; padding: 2px 6px; height: 26px; box-sizing: border-box; }
.vd-card .hint { font-size: 11.5px; }
.vd-card .btn.sm { padding: 3px 9px; font-size: 12px; }
@media (max-width: 560px) { .vd-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
/* 8 Nov 2026 (Alex: Vendors still huge on his screen, which shows about 850 CSS px wide at a large scale): smaller letters again */
.vd-card h2 { font-size: 14px; }
.vd-f { font-size: 10px; }
.vd-card input.vd, .vd-card .vd-f input { font-size: 11px; height: 22px; padding: 1px 5px; }
.vd-card .hint, .vd-card label.hint { font-size: 10px; line-height: 1.25; }
.vd-card .vd-pl, .vd-card .vd-on { width: 12px; height: 12px; }
.vd-card .btn.sm { padding: 2px 8px; font-size: 11px; }
.vd-grid { gap: 3px 6px; }
.vd-card { padding: 6px 8px; }

/* Contractors page (8 Nov 2026): compact like the Vendors page */
.ct-tabs{display:flex;gap:6px;align-items:center;flex-wrap:wrap;margin:6px 0}
.ct-tab{border:1px solid #c5ccd2;background:#f3f5f7;border-radius:6px;padding:4px 10px;font-size:12px;cursor:pointer}.ct-tab.on{background:#1e5aa8;color:#fff;border-color:#1e5aa8}
.ct-list{padding:4px 6px}.ct-row{display:grid;grid-template-columns:minmax(0,1.3fr) 90px minmax(0,2fr);gap:8px;align-items:center;padding:5px 4px;border-bottom:1px solid #e6eaee;cursor:pointer;font-size:12px}
.ct-row:last-child{border-bottom:0}.ct-row:hover{background:#f6f9fc}.ct-row.sel{background:#eaf1fb}.ct-row.off{opacity:.55}.ct-row .hint{font-size:10.5px;margin:0}
@media(max-width:640px){.ct-row{grid-template-columns:1fr 70px}.ct-row .ct-st{grid-column:1/-1}}
.ct-ok{color:#2f7d32;font-weight:600}.ct-ok0{color:#667}.ct-warn{color:#a55a00;font-weight:600}.ct-bad{color:#b3261e;font-weight:600}
.ct-form .vd-f select,.ct-files .vd-f select,.ct-ag .vd-f input{font-size:11px;height:22px;padding:1px 4px;width:100%;box-sizing:border-box}
.ct-fr{display:flex;justify-content:space-between;gap:8px;font-size:12px;padding:3px 0;border-bottom:1px solid #eef1f3}
.ct-ag p{font-size:12px;margin:4px 0}.ct-cs canvas{border:1px dashed #667;background:#fcfcfd;width:100%;max-width:420px;height:auto;display:block;border-radius:6px;touch-action:none}
.ct-ov{position:fixed;inset:0;z-index:1000;background:#eef1f3;overflow:auto}.ct-ovbar{position:sticky;top:0;z-index:6;background:#1c2a33;color:#fff;padding:8px 12px;display:flex;justify-content:space-between;align-items:center;gap:8px}
.ct-ovbody{padding:10px}
.ct-ov .ags-bar{top:42px}

.ct-form input[type=date],.ct-ag input[type=date]{-webkit-appearance:none;appearance:none;display:block;width:100%;min-width:0;max-width:100%;box-sizing:border-box;height:30px;line-height:20px;font-size:14px;padding:3px 6px;background:#fff;border:1px solid #c5ccd2;border-radius:6px}
.ct-form .vd-f,.ct-ag .vd-f{min-width:0}

/* Schedule, wide screens (Alex, 8 Nov 2026: "so much space wasted"): one tight row per job. The calendar note is one line (full text on hover), the three notice states sit side by side and the two buttons are small and inline. Phones keep their card layout. */
@media (min-width:861px) {
  .sched td, .sched th { padding: 4px 6px; vertical-align: middle; }
  .sched input[type=date] { min-width: 0; width: 128px; font-size: 13px; }
  .sched select { min-width: 0; max-width: 150px; font-size: 13px; }
  .sched td.act .btn { white-space: nowrap; }
  .sched td.c-cal { min-width: 310px; max-width: 330px; }
  .sched .cal-text { display: none; }   /* the full text stays in the tag's hover title */
  .sched .notice-cell { display: flex; flex-wrap: wrap; gap: 2px 10px; align-items: center; margin-top: 3px; }
  .sched .notice-cell .hint { margin: 0; font-size: 12px; white-space: nowrap; }
  .sched .notice-cell .btn.sm { min-height: 24px; padding: 1px 8px; font-size: 12px; }
  .sched .tag { padding-top: 1px; padding-bottom: 1px; }
}

/* Schedule uses the whole screen width so Total, Balance and the Work order button are not cut off (Alex, 8 Nov 2026) */
@media (min-width:861px) {
  body:has(.sched) .wrap { max-width: none; }
  body:has(.sched) .top-bar { max-width: none; }
}
@media (min-width:861px) and (max-width:1700px) {
  .sched input[type=date] { width: 112px; font-size: 12px; }
  .sched select { max-width: 120px; font-size: 12px; }
  .sched td.c-cal { min-width: 240px; max-width: 250px; }
  .sched td[data-label="Customer"], .sched td[data-label="City"] { max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
}
@media (min-width:861px) and (max-width:1700px) {
  .sched td select { width: 108px; min-width: 0; max-width: 108px; }
  .sched td.c-cal { min-width: 270px; max-width: 280px; }
  .sched td, .sched th { padding: 4px 4px; }
}
@media (min-width:861px) and (max-width:1700px) {
  .sched td select { width: 108px !important; max-width: 108px !important; }
}
@media (min-width:861px) and (max-width:1700px) {
  .sched td[data-label="Customer"] { max-width: 115px !important; }
  .sched td[data-label="City"] { max-width: 70px !important; }
  .sched input[type=date] { width: 104px; }
  .sched td.c-cal { min-width: 255px; max-width: 265px; }
}
/* Schedule: the table scrolls inside its own box that is never taller than the screen, so the sideways bar is always in view and the headings stay on top (Alex, 8 Nov 2026) */
@media (min-width:861px) {
  .schedwrap { max-height: calc(100vh - 260px); overflow: auto !important; }
  .schedwrap thead th { position: sticky; top: 0; z-index: 2; background: #eef1f3; }
}

/* 14 Nov 2026 (Alex, Customers): the Customers table is a .qtable (fixed columns, drag to resize, always-visible bar, thin one-line rows). It keeps the FIRST column (Quote #) pinned instead of the second; the buttons of the last column sit side by side. */
@media (min-width:701px){
  .custtable th:nth-child(2),.custtable td:nth-child(2){left:auto;box-shadow:none}
  .custtable td:nth-child(2){position:static}
  .custtable tr.click:hover td:nth-child(2){background:inherit}
  .custtable th:nth-child(1),.custtable td:nth-child(1){position:sticky;left:0;z-index:2;background:#fff;box-shadow:1px 0 0 var(--line)}
  .custtable thead th:nth-child(1){background:#f0f2f1;z-index:5}
  .custtable tbody tr:hover td{background:#f4f8f3}
  .custtable td.act{text-align:right;position:sticky;right:0;z-index:2;background:#fff;box-shadow:-1px 0 0 var(--line);overflow:visible!important}
  .custtable thead th:last-child{position:sticky;right:0;z-index:5;background:#f0f2f1}
  .custtable tbody tr:hover td.act{background:#f4f8f3}
  .custtable td.act .btn{display:inline-block!important;width:auto;margin:0 0 0 6px!important;padding:3px 10px;min-height:0}
}
/* 9 Nov 2026 (Alex, Quotes): tidy column widths and a table box with its own always-visible sideways bar */
@media (min-width:701px){
  .qwrap{max-height:calc(100vh - 140px)}
  .qtable thead th{position:sticky;top:0;z-index:3;background:#f0f2f1}
  .qtable thead th:nth-child(2){z-index:4}
  .qtable th,.qtable td{padding:4px 7px}
  .qtable th.c-n,.qtable td.c-n{min-width:34px;width:34px}
  .qtable th.c-quote_no,.qtable td.c-quote_no{min-width:92px}
  .qtable th.c-po_number,.qtable td.c-po_number{min-width:64px}
  .qtable th.c-rep_name,.qtable td.c-rep_name{min-width:170px}
  .qtable th.c-lead_status,.qtable td.c-lead_status{min-width:96px}
  .qtable th.c-order_date,.qtable td.c-order_date,.qtable th.c-install_date,.qtable td.c-install_date{min-width:96px}
  .qtable th.c-first_name,.qtable td.c-first_name,.qtable th.c-last_name,.qtable td.c-last_name{min-width:118px}
  .qtable th.c-street,.qtable td.c-street{min-width:170px;max-width:210px}
  .qtable th.c-city,.qtable td.c-city{min-width:100px}
  .qtable th.c-phone,.qtable td.c-phone{min-width:120px}
  .qtable th.c-email,.qtable td.c-email{min-width:200px}
  .qtable th.c-installer,.qtable td.c-installer,.qtable th.c-installer2,.qtable td.c-installer2{min-width:92px}
  .qtable th.c-grand,.qtable td.c-grand,.qtable th.c-paid,.qtable td.c-paid,.qtable th.c-balance,.qtable td.c-balance{min-width:86px}
  .qtable th.c-contract,.qtable td.c-contract{min-width:128px}
  .qtable th.c-lead_source,.qtable td.c-lead_source{min-width:120px}
  .qtable th.c-postal_code,.qtable td.c-postal_code{min-width:84px}
  .qtable th.c-days_open,.qtable td.c-days_open{min-width:74px}
}
@media (min-width:1101px){ body:has(.qtable) .wrap{max-width:none} body:has(.qtable) .top-bar{max-width:none} }

/* 9 Nov 2026 (Alex): drag-to-resize columns on Quotes. Widths come from the colgroup, so the per-column min-widths above are switched off. */
@media (min-width:701px){
  .qtable.qfixed{table-layout:fixed}
  .qtable.qfixed th,.qtable.qfixed td{min-width:0!important;max-width:none!important;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  .qtable th{position:sticky}
  .qtable th .rz{position:absolute;top:0;right:0;width:9px;height:100%;cursor:col-resize;user-select:none;touch-action:none;z-index:5}
  .qtable th .rz::after{content:"";position:absolute;right:3px;top:22%;height:56%;width:2px;background:#c3cbc7;border-radius:1px}
  .qtable th .rz:hover::after,.qtable th .rz.on::after{background:#2f6f8f;width:3px}
}

/* 9 Nov 2026 (Alex, 2nd try): the Quotes table has no height box and its own bar is hidden; the copy of the bar (#qbar) sticks to the bottom of the screen. */
@media (min-width:701px){
  .qwrap{max-height:none!important;scrollbar-width:none}
  .qwrap::-webkit-scrollbar{display:none}
  .qbar{position:sticky;bottom:0;z-index:30;overflow-x:scroll;overflow-y:hidden;height:18px;background:#e9ecea;border-top:1px solid var(--line);border-radius:0 0 8px 8px}
  .qbar>div{height:1px}
}
@media (max-width:700px){.qbar{display:none}}

/* Find jobs filters (9 Nov 2026, Alex): tidy rows, small boxes, Search next to the last box */
.jfilters .jf-row{display:flex;flex-wrap:wrap;gap:10px 14px;align-items:flex-end;margin-bottom:8px}.jfilters .jf-row:last-child{margin-bottom:0}
.jfilters .jf-row>div{flex:0 0 auto}.jfilters .jf-city{flex:1 1 220px;min-width:180px}.jfilters .jf-city input{width:100%}
.jfilters input[type=number]{width:96px}.jfilters select{width:auto;max-width:100%}.jfilters .jf-go{display:flex;gap:8px}
/* Customer box on the quote (9 Nov 2026, Alex: "text on text"): the details and the About this house links wrap onto their own full-width row instead of squeezing the details to nothing */
.qclient{flex-wrap:wrap}.qclient .qc-grid{flex:1 1 560px;min-width:0}.qclient .qc-act{flex:none}.qclient .house{flex:1 0 100%;order:3;margin-top:2px}

/* 9 Nov 2026 (Alex: text on text in the top menu while designing): the tabs may scroll instead of running under the search box */
html.designing .nav-main{min-width:0;overflow-x:auto;scrollbar-width:none}html.designing .nav-main::-webkit-scrollbar{display:none}html.designing .gsearch{flex:0 1 160px;min-width:90px}html.designing .who{flex:none}

/* 10 Nov 2026 (Alex): the preview before sending keeps more room for the contract: slim bars, and the signing bar is not repeated as a second sticky bar */
.pvdoc .sg-bar{position:static;margin:6px 0 0;padding:3px 10px}.pvdoc .sg-barin .btn{min-height:32px;font-size:14px}
/* 10 Nov 2026: the green "Add initials" button needs a wider right column than the old 112px box (it was cut off) */
.ini-card>.ini-pad.ini-flagpad{width:152px;flex:none}.ini-flagpad .flag{padding:9px 12px;font-size:14px}
@media (max-width:560px){.ini-card>.ini-pad.ini-flagpad{width:130px}.ini-flagpad .flag{padding:8px 8px;font-size:13px}}
/* 11 Nov 2026 (Alex's phone screenshot, big gap above "Edit customer"): the customer box is a column on a phone, so its "flex: 1 1 560px" meant 560px of HEIGHT. On a phone the grid takes only the height it needs. */
@media (max-width:700px){.qclient .qc-grid,.wrap.onitems .qclient .qc-grid{flex:none;width:100%}}

.wa-btn{display:inline-block;padding:3px 9px;border:1px solid #1f9d55;border-radius:999px;color:#17803f;background:#f1fbf5;font:600 12px/1.4 inherit;text-decoration:none;white-space:nowrap}.wa-btn:hover{background:#dff5e8}

.bk-ready{font-size:12px;display:inline-flex;gap:4px;align-items:center;margin:3px 8px 0 0;padding:1px 7px;border:1px solid #cfd8dc;border-radius:999px;color:#455a64;cursor:pointer}.bk-ready.on{background:#e3f5e8;border-color:#2f7d32;color:#1b5e20;font-weight:600}


/* Jobs Booking deliveries (Alex, 14 Nov 2026): a supplier can have more than one delivery/ETA under the same PO */
.bk-pt+.bk-pt{border-top:1px dashed #d5dde2;margin-top:6px;padding-top:4px}.bk-ptl{display:flex;justify-content:space-between;align-items:center}.bk-ddel{border:0;background:none;color:#8a2a2a;cursor:pointer;font-size:13px;padding:0 2px}.bk-dnote{width:100%;max-width:170px;font-size:12px;margin:2px 0}.bk-dadd{display:block;margin:6px 0 2px;padding:2px 8px;border:1px dashed #5b7a87;border-radius:999px;background:none;color:#2b5d73;font-size:12px;cursor:pointer}

.dup-found .dup-c{margin-top:8px;padding-top:6px;border-top:1px solid rgba(0,0,0,.12)}.dup-found .dup-q{margin:2px 0 0 12px}
.srcadd[hidden]{display:none}

.ct-val .ct-m{display:flex;justify-content:space-between;gap:12px;font-weight:400;font-size:12.5px;line-height:1.5}.ct-val .ct-m span{color:#5b6b73}.ct-val .ct-m b{font-weight:700}.ct-val .ct-m:first-child b{font-size:14px}.ct-val .ct-bal{border-top:1px solid #e3e8eb;margin-top:2px;padding-top:2px}.ct-val{white-space:normal;min-width:210px}
/* 14 Nov 2026 (Alex, Contracts): the row of the Contracts page is three columns (who, where it stands, the money); another page's .ct-row rule (90px middle column) was squeezing the middle one. */
@media (min-width:701px){.ct-card .ct-row{grid-template-columns:minmax(220px,1.1fr) minmax(300px,1.6fr) 260px;gap:8px 18px;padding:9px 12px;font-size:13px;cursor:pointer}.ct-card .ct-row .ct-mid{grid-column:auto}.ct-card .ct-row .ct-val{min-width:0}}
@media (max-width:700px){.ct-card .ct-row{grid-template-columns:1fr}.ct-card .ct-row .ct-val{display:grid;grid-template-columns:1fr 1fr;gap:2px 16px}.ct-card .ct-row .ct-val .ct-m{flex-direction:column;gap:0}}

/* 14 Nov 2026: financing indicator (Contracts rows and the Order info box) */
.ct-fin{display:inline-block;font-size:12px;font-weight:600;padding:2px 8px;border-radius:10px;margin:0 0 4px;background:#eef1f4;color:#44505c}
.ct-fin.on{background:#e65100;color:#fff}
.ct-fin.ask{background:#fff3cd;color:#7a5b00}
.ct-finchip.on{background:#e65100;color:#fff;border-color:#e65100}
.finbox{display:flex;flex-wrap:wrap;gap:8px;align-items:center;padding:8px 10px;border:1px solid #d5dbe1;border-radius:8px;margin:6px 0;background:#fafbfc}
.finbox.on{border-color:#e65100;background:#fff3e8}

/* 15 Nov 2026 (Alex: "calendar column is too messy"): Schedule Calendar column = one status tag, three equal boxes (Confirm, Reminder, Review: label above, state below; hover shows the text and the e-mail/text detail), two equal buttons underneath. */
.sched .notice-cell { display: block; margin-top: 5px; }
.sched .nt-states { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; }
.sched .nt-s { display: flex; flex-direction: column; gap: 1px; padding: 3px 6px; border: 1px solid #d5dbe1; border-radius: 6px; background: #fafbfc; font-size: 12px; line-height: 1.25; min-width: 0; }
.sched .nt-s .nt-l { color: #5b6772; font-size: 11px; text-transform: uppercase; letter-spacing: .03em; }
.sched .nt-s b { font-weight: 600; color: #7b8791; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sched .nt-s.ok { border-color: #9ccfa5; background: #eef8f0; } .sched .nt-s.ok b { color: #1d6b2e; }
.sched .nt-s.bad { border-color: #e0a8a3; background: #fdf1f0; } .sched .nt-s.bad b { color: #b3261e; }
.sched .nt-s.test { background: #f3f1ea; } .sched .nt-s.test b { color: #5b6772; }
.sched .nt-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; margin-top: 4px; }
.sched .nt-btns .btn.sm { min-height: 26px; padding: 2px 6px; font-size: 12px; white-space: nowrap; width: 100%; }
.sched td.c-cal .tag { display: inline-block; margin-bottom: 0; }
@media (min-width:861px) { .sched td.c-cal { min-width: 270px; max-width: 290px; } }
/* Phones: in the job card the Calendar cell stacks (label on top, then the tag, the three boxes and the two buttons at full width). */
@media (max-width:860px) {
  .sched td.c-cal { display: block; }
  .sched td.c-cal:empty { display: none; }
  .sched td.c-cal::before { display: block; margin-bottom: 4px; }
  .sched .nt-btns .btn.sm { min-height: 40px; font-size: 14px; }
  .sched .nt-s { padding: 5px 8px; font-size: 13px; }
}
/* Schedule: the Work order link button was white on white (invisible) on wide screens */
.sched td.act a.btn.alt { color: var(--steel); background: #fff; border: 1px solid var(--steel); }

/* 15 Nov 2026: credit card processing fee shown on its own line */
.feechip { background: #fff3e8; border: 1px solid #e0b27a; color: #7a3d00; border-radius: 8px; padding: 3px 9px; }
.paysum .feechip { display: block; flex-basis: 100%; }

/* 15 Nov 2026: one row per payment (amount, type, note) instead of one box per row */
.payrow { display: grid; grid-template-columns: 150px max-content minmax(0, 1fr); gap: 8px; align-items: end; margin-bottom: 6px; }
.payrow select { width: auto; max-width: 100%; }
@media (max-width: 700px) { .payrow { grid-template-columns: 1fr 1fr; } .payrow > div:last-child { grid-column: 1 / -1; } }

/* v668 (15 Nov 2026, Alex: Order info page "so not organized, boxes too big, wasted space"):
   summary strip, customer + installation + notes on the left, payments on the right, Save always in view; lead status / sizes / alarm checks compact on every tab. */
.statusbar{display:flex;flex-wrap:wrap;align-items:center;gap:4px 24px;padding:6px 12px;margin-bottom:6px}
.statusbar .sizebar{flex:1 1 520px;margin:0;padding:2px 0 2px 10px;border:0;border-left:4px solid #2a5b73;border-radius:0;box-shadow:none;background:transparent;display:flex;flex-wrap:wrap;align-items:baseline;gap:0 12px}
.statusbar .sizebar .hint{margin:0;font-size:11px;line-height:1.3}
#chkbar{display:grid;grid-template-columns:repeat(auto-fit,minmax(300px,1fr));gap:6px;margin:0 0 6px}
#chkbar .card.chk{padding:6px 12px;margin:0}
#chkbar .chk-h{display:flex;flex-wrap:wrap;align-items:center;gap:2px 10px}
#chkbar .chk-h h2{margin:0;font-size:14px}
#chkbar .chk-h select{width:auto;max-width:100%}
#chkbar .alarmcard .alrow{margin:4px 0 0}
#chkbar details.why{margin-top:2px}#chkbar details.why summary{cursor:pointer;font-size:11px;color:#2a5b73}#chkbar details.why p{margin:2px 0 0;font-size:11px}
#chkbar .almsg{margin:2px 0 0;font-size:11px}#chkbar .almsg:empty{display:none}
.ord{display:block}
.ord label{font-size:12px;margin-bottom:2px}
.ord .card{padding:8px 12px;margin:0 0 8px}
.ord h2{font-size:14px;margin:0 0 4px}
.ord-fields{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:6px 10px;align-items:start}
.ord-fields .hint{font-size:11px;margin-top:2px;line-height:1.3}
.ord-cols{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.15fr);gap:10px;align-items:start}
.ord-cust>div{margin:1px 0}.ord-act{display:flex;flex-wrap:wrap;gap:6px;margin:6px 0 2px;align-items:center}
.ord-pay .paybox{margin:0;padding:8px 12px}.ord-pay .paybox h3{margin:0 0 4px;font-size:14px}
.ord-sum .ord-fields{grid-template-columns:repeat(auto-fill,minmax(125px,1fr))}.ord-sum .ord-fields>div:nth-child(4){grid-column:span 2}.ord-sum select,.ord-sum input{width:100%}
.ord-job .ord-fields{grid-template-columns:repeat(4,minmax(0,1fr))}
@media (min-width:901px){.ord-pay .payrow{grid-template-columns:auto 100px max-content minmax(0,1fr);gap:4px 6px;align-items:center;margin-bottom:4px}.ord-pay .payrow>div:first-child{display:contents}.ord-pay .payrow>div:first-child label{margin:0;white-space:nowrap;min-width:78px}.ord-pay .payrow>div:not(:first-child) label{display:none}}
.ord-pay .recbox{margin-top:8px}
.ord-pay .paysum{gap:4px 14px;margin-top:4px;font-size:13px}.ord-pay .paysum b{font-size:14px}
.ord-pay .finbox{margin:0 0 6px;padding:5px 8px}
.ord-notes textarea{min-height:0}
.ord-save{position:sticky;bottom:0;z-index:20;display:flex;gap:10px;align-items:center;padding:8px 0;background:var(--bg,#f4f6f8);border-top:1px solid var(--line)}
@media (max-width:900px){.ord-cols{grid-template-columns:1fr}.ord-job .ord-fields{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media (max-width:640px){.ord-fields{grid-template-columns:repeat(2,minmax(0,1fr))}.ord-save{bottom:calc(58px + env(safe-area-inset-bottom))}}

/* v669 (15 Nov 2026, Alex: the block above every tab is too big): the compact header the Items tab already had is now on EVERY tab; option text folded under Info; checks are real blocks (the e-mail sentence was squeezed into a column). */
.qclient{margin:6px 0;padding:8px 12px;gap:10px}
.qc-grid{grid-template-columns:repeat(6,minmax(0,1fr));gap:4px 14px}@media (min-width:1500px){.qc-grid{grid-template-columns:repeat(8,minmax(0,1fr))}}.qc.wide{grid-column:span 2}
.qc span{font-size:10px}.qc b{font-size:13.5px}
@media (max-width:700px){.qc-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.qc.wide{grid-column:span 2}.qc b{font-size:14px}}
.optbar{padding:6px 12px;margin-bottom:6px}.optbar select{min-width:0;flex:0 1 260px}
details.optinfo{margin-top:2px}details.optinfo summary{cursor:pointer;font-size:11px;color:#2a5b73}details.optinfo .hint{font-size:11px;line-height:1.3;margin-top:2px!important}
#chkbar .card.chk{display:block!important}
#chkbar .card.chk .hint{max-width:none}

/* v669 Products & Services: compact tiles and aligned product rows */
.pgtiles .btn{padding:7px 10px!important;line-height:1.25}
.pgtiles .btn .hint{font-size:12px}
.pgsec .row .scrcol{min-width:220px;flex:0 1 320px}
.pgsec .row .scrcol select{width:100%}
.pgsec details.why{margin:2px 0 6px}
.pgsec .xrow{padding:6px 0!important}
.pgsec>p.hint{margin:2px 0 6px;font-size:12px;line-height:1.35}
#tab .card>h2{margin:6px 0 4px}
#tab .card>.pgsec{border-top:1px solid var(--line);margin-top:4px;padding-top:4px}
@media (max-width:640px){.igbox{grid-template-columns:minmax(0,1fr)}.igr5,.igr4{grid-template-columns:repeat(2,minmax(0,1fr))!important}.igr select,.igr input{max-width:100%;min-width:0}}

/* v670 Customer box on two columns, Send rows as short as their content */
.ord-cgrid{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:2px 18px;margin:2px 0 4px}
.ord-cust{padding-top:8px;padding-bottom:8px}.ord-cust h2{margin:0 0 4px}
.ord-cust .ord-act{margin:4px 0 0;gap:6px 10px}.ord-cust .ord-act .btn{padding:3px 10px}
.ord-cust .ord-act label{font-size:13px;margin:0}
@media (max-width:640px){.ord-cgrid{grid-template-columns:1fr}}
.sendcard .sendrow{justify-content:flex-start;gap:6px 18px;padding:4px 0}
.sendcard .sendinfo{margin:0 0 4px}.sendcard .sendinfo summary{font-size:12px;cursor:pointer}
.ord-sum .ord-fields{grid-template-columns:repeat(auto-fill,minmax(104px,1fr))}
.ord-sum .ord-fields .hint{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:11px;margin-top:2px}
#chkbar{align-items:start}
.sendcard .sendchips{display:flex;flex-wrap:wrap;gap:6px;margin:6px 0 2px}

/* v675 (15 Nov 2026, Alex): name and signature on ONE line: every field of the sign block has the same height so the lines meet */
.sg-sign{align-items:start}.sg-sign .sg-v{height:62px;min-height:62px;align-items:flex-end;box-sizing:border-box}.sg-sign .sg-sigbox{height:62px;min-height:62px;box-sizing:border-box}.sg-sign .sg-sigbox img{max-height:56px}.sg-sign .sg-sigbox .flag{margin-bottom:2px}
.sg-sign input.sg-v{padding:30px 2px 2px;font-family:inherit}
.sg-wrap>.sg-bar{margin-left:-12px;margin-right:-12px}

/* ===== v680 (15 Nov 2026, Alex): ONE text size across the desktop CRM, and a slim header ===================
   --fs is the one size for menus, tabs, buttons, labels, boxes, drop-downs, tables and notes. Only the page title
   and section headings (h1-h3), the big numbers on Reports, the drawings (svg), the logo and the customer pages
   (contract and signing page, body.sg-body and .sg-wrap) keep their own sizes. Phone (up to 640 px) is unchanged. */
:root{--fs:13px}
@media (min-width:641px){
  body:not(.sg-body){font-size:var(--fs)}
  body:not(.sg-body) *:not(h1):not(h2):not(h3):not(svg):not(svg *):not(.brand):not(.rp-n):not([style*="font-size:2"]):not(.sg-wrap):not(.sg-wrap *){font-size:var(--fs)!important}
  /* header: one slim bar of boxes, all tabs from Quotes to Arrange on one row */
  .top-bar{padding:5px 18px;gap:4px 12px}
  .brand{height:34px;padding:2px 7px}
  .gsearch{flex:0 1 350px;min-width:180px}.gsearch input[type=search]{padding:6px 10px 6px 32px}.gsearch .gs-ic{width:15px;height:15px;left:10px}
  .who{gap:8px}.who-role{padding:2px 8px}.btn-out{padding:5px 10px}
  .nav-main{padding-top:2px;margin-top:0;gap:0}
  .nav-main>a,.nav-more{padding:7px 10px;font-weight:600}
  .nav-main>a.nav-arr{font-weight:600;opacity:.85}
  .manage .menu a{padding:8px 12px}
  /* smaller boxes */
  input,select,textarea{padding:4px 7px}.btn{padding:5px 11px}
}

/* v683 (15 Nov 2026, Alex: 'fit all in one line'): logo, tabs, search and your name on ONE row when the screen is wide enough; otherwise the tabs drop to their own row as before */
@media (min-width:641px){
  .top-bar{max-width:none;flex-wrap:wrap;gap:4px 10px;padding:4px 14px}
  .brandlink{order:0}.nav-main{order:1;flex:1 1 1330px;min-width:0;flex-wrap:nowrap;border-top:0;padding:0;margin:0}
  .nav-main>a,.nav-more{padding:7px 6px}
  .gsearch{order:2;flex:0 1 190px;min-width:120px}.who{order:3;margin-left:0}
}
/* v684 (15 Nov 2026, Alex: 'i asked to arrange everything in one row'): below 1700 px the header is ALWAYS one row: search becomes a small icon (opens the Search page), the name moves into the Log out tooltip and Log out is an icon; the tabs never wrap */
@media (min-width:641px) and (max-width:1699px){
  .top-bar{flex-wrap:nowrap;gap:6px;padding:4px 10px}
  .nav-main{flex:1 1 0;overflow-x:auto;scrollbar-width:none}.nav-main::-webkit-scrollbar{display:none}
  .nav-main>a,.nav-more{padding:7px 5px}
  .gsearch{display:flex;order:2;flex:0 1 150px;min-width:90px;max-width:none}.gsearch input[type=search]{padding:5px 6px 5px 28px}.gsearch .gs-ic{left:8px;width:14px;height:14px}   /* Alex 15 Nov: the search box stays in the row */
  .searchbtn{display:none}
  .who-name,.who-role,.btn-out span{display:none}.who{order:3;gap:0}.btn-out{padding:6px 8px}
}
/* v687 (15 Nov 2026, Alex: Reports 'too wastefully large'): smaller tiles and cards so the whole page is seen at once */
.rp-tiles{grid-template-columns:repeat(auto-fill,minmax(120px,1fr));gap:8px;margin:6px 0}.rp-tile{padding:6px 10px;border-radius:8px}
.rp-n{font-size:15px;margin:0}.rp-d{line-height:1.2}
.rp-grid{grid-template-columns:repeat(auto-fit,minmax(280px,1fr));gap:8px;margin:8px 0}.rp-grid .card{padding:8px 12px;margin:0}.rp-grid .card h2{font-size:14px;margin:0 0 4px}
.rp-bars{gap:4px}.rp-row{gap:6px}.rp-t{height:10px}.rp-svg{min-width:300px}
.rp-pie{gap:8px}.rp-pie li{margin:1px 0}
/* v688 (15 Nov 2026, Alex: page titles and section titles 'huge, wasted space'): on a computer the page title is 17px and section titles 14px, close to the 13px text; customer pages are not touched */
@media (min-width:641px){
  body:not(.sg-body) h1{font-size:17px!important;margin:2px 0 6px!important;line-height:1.2}
  body:not(.sg-body) h2{font-size:14px!important;margin:8px 0 4px!important;line-height:1.2}
  body:not(.sg-body) h3{font-size:13px!important;line-height:1.2}
  body:not(.sg-body) .tag{padding:1px 8px}
}
@media (min-width:641px){.mm-card>p.hint{margin:0!important;padding:4px 6px!important}}
/* v689 (15 Nov 2026, Alex: window options for the vendor 'all over the place, I need to slide down'): on a computer ALL the options of one window flow in one tight grid (group names are small cells in the flow), vendor and size sit on one line, the note box is short, so the whole window is seen without sliding */
@media (min-width:1000px){
  .pm-opts .pm-body{display:flex;flex-wrap:wrap;gap:4px 22px;align-items:flex-start}
  .pm-opts .pm-grp{flex:var(--n) 1 calc(var(--n)*150px);min-width:0}
  .pm-opts .pm-fg{display:grid;grid-template-columns:repeat(auto-fill,minmax(140px,1fr));gap:3px 8px;align-items:end}
  .pm-opts .pm-gh{margin:2px 0 2px;padding:0 0 1px;border-bottom:1px solid #d9e1e6;font-size:10.5px;line-height:1.1}
  .pm-opts .pm-f:has(.pm-big){grid-column:span 2}
  .pm-line .po-info>.pm-pick{display:flex;align-items:center;gap:8px;margin:2px 0 !important}.pm-line .po-info>.pm-pick label{margin:0}
  .pm-size{margin:2px 0 4px !important}.pm-size .row{margin-top:2px !important}
  .pm-lnote{margin-top:4px !important}.pm-lnote textarea{height:34px;min-height:34px;resize:vertical}.pm-lnote label{display:inline-block!important}
  .pm-line{padding:6px 0}
}
@media (min-width:1000px){
  .pm-vs{display:flex;flex-wrap:wrap;align-items:center;gap:4px 24px}.pm-vs .pm-pick{margin:0!important}.pm-vs .pm-size{margin:0!important}
  .pm-lnote{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:4px 8px}.pm-lnote>div:not(:last-child){grid-column:1/-1}.pm-lnote .pm-notetx{grid-column:2}
}
/* v692 (15 Nov 2026, Alex: sign-in box too low, the Sign in button was cut off): the box sits near the top and is more compact */
.login{margin:12px auto 20px}.login .brand-big{max-height:96px;width:auto;display:block;margin:0 auto}
.login .hint{margin:4px 0 6px!important}
/* v693 (15 Nov 2026, Alex: 'you must fit per window without dragging regardless'): changed options keep their size: the 'changed (contract ...)' line and the part description are ONE line each (full text on hover), the pictures are smaller, boxes line up at the top */
@media (min-width:1000px){
  .pm-opts .pm-fg{align-items:start;gap:2px 8px}
  .pm-opts .pm-fb>.pm-was,.pm-opts .pm-cap{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:11px;line-height:1.2;margin:0}
  .pm-opts .pm-cap span{margin-left:6px}.pm-opts .pm-cap b{font-weight:600}
  .pm-opts .pm-pic.pm-big{flex-basis:84px;width:84px;min-height:0;height:52px}.pm-opts .pm-pic.pm-big svg{max-width:84px;max-height:52px}.pm-opts .pm-pic.pm-big img{max-width:84px;max-height:52px}
  .pm-opts .pm-gh{margin:1px 0 1px}
  .pm-line .po-info>div:first-of-type:not(.pm-pick):not(.pm-two){display:inline;margin-left:8px}
  .pm-line .pm-pick label{display:none!important}.pm-vs .pm-pick::before{content:"Vendor";font-size:11.5px;color:#56707f;margin-right:6px}
}
/* v694 (15 Nov 2026, Alex: 'make fit page better'): more, slimmer columns so Window and Trim take ONE row each; the size title sits on the same line as the size boxes */
@media (min-width:1000px){
  .pm-opts .pm-fg{grid-template-columns:repeat(auto-fill,minmax(112px,1fr))}
  .pm-opts .pm-grp{flex:var(--n) 1 calc(var(--n)*112px)}
  .pm-size[open]{display:flex;align-items:center;gap:10px}.pm-size[open]>summary{white-space:nowrap}.pm-size[open]>.row{margin:0!important}
  .pm-lnote textarea{height:30px;min-height:30px}
  .pm-lnote{margin-top:2px!important}
}
@media (min-width:1000px){
  .pm-opts .pm-grp:nth-child(1){order:1;flex:9 1 1000px}.pm-opts .pm-grp:nth-child(3){order:2;flex:2 1 220px}
  .pm-opts .pm-grp:nth-child(2){order:3;flex:10 1 1100px}.pm-opts .pm-grp:nth-child(4){order:4;flex:2 1 220px}
}
@media (min-width:1000px){.pm-opts .pm-grp:nth-child(1){flex:9 1 960px}.pm-opts .pm-grp:nth-child(3){flex:2 1 250px}.pm-opts .pm-grp:nth-child(2){flex:10 1 1000px}.pm-opts .pm-grp:nth-child(4){flex:2 1 250px}}
/* v696 per-PO automatic sending */
.pm-rowwrap{display:flex;align-items:stretch;gap:0}.pm-rowwrap>a{flex:1;min-width:0}.pm-rowauto{display:flex;align-items:center;gap:6px;padding:0 12px;white-space:nowrap;cursor:pointer;font-size:12px;color:#56707f}.pm-rowauto i{font-style:normal;color:#8a5a00}
.pm-pagetick{display:inline-flex;margin:0 0 6px;padding:0}.pm-pagetick i{font-style:normal;color:#56707f}
.pm-rowwrap .pm-rowauto{min-width:118px}
/* v699 Services page: small "Who does the service" boxes on a computer screen (Alex, 15 Nov 2026) */
@media (min-width:641px){.sv-t,.sv-sel{min-height:0!important;height:28px!important;font-size:13px!important;padding:3px 10px!important;line-height:1.2}.sv-sel{padding-right:6px!important}}#sv-mas[hidden]{display:none!important}
/* v700 Reports monthly target: ONE row, smaller boxes (Alex, 15 Nov 2026) */
@media (min-width:1100px){#tgcard{display:flex!important;flex-wrap:nowrap;align-items:center;gap:18px;padding:6px 12px!important;margin:6px 0 8px!important}#tgcard>.row{display:contents!important}#tgcard>.row:first-child>div:first-child{flex:0 1 340px;min-width:0}#tgcard>.row:first-child>div:first-child .hint{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}#tgcard h2{margin:0!important}#tgcard form{order:9;margin-left:auto;display:flex;align-items:center;gap:6px}#tgcard form label{display:flex;align-items:center;gap:6px;white-space:nowrap}#tgcard form br{display:none}#tgcard #tgIn{width:132px!important}#tgcard [role=progressbar]{order:5;flex:1 1 90px;min-width:60px;height:8px!important}#tgcard #tgmsg{order:6;margin:0!important;white-space:nowrap;flex:0 1 auto;min-width:0;overflow:hidden;text-overflow:ellipsis}}
/* v701 Reports target: no long hint, nothing wraps or is cut (Alex, 15 Nov 2026) */
@media (min-width:1100px){#tgcard>.row:first-child>div:first-child .hint{display:none!important}#tgcard>.row:first-child>div:first-child{flex:0 0 auto!important}#tgcard .hint,#tgcard h2{white-space:nowrap}#tgcard form{flex-wrap:nowrap!important;flex:0 0 auto}#tgcard #tgmsg{overflow:hidden!important;text-overflow:ellipsis!important;flex:0 1 auto;min-width:0}#tgcard [role=progressbar]{flex:1 1 60px;min-width:40px}#tgcard>.row>div{white-space:nowrap}}
/* v705 Reports: tabs, periods, dates and sales person in ONE row (Alex, 15 Nov 2026) */
@media (min-width:1100px){.rp-one{display:flex;flex-wrap:nowrap;align-items:center;gap:14px;margin:6px 0}.rp-one>.calmodes,.rp-one>.calbar{margin:0!important;flex-wrap:nowrap!important;white-space:nowrap}.rp-one .calbar{display:flex;gap:6px;align-items:center}.rp-one input[type=date]{width:128px}}
/* v707 New customer page: everything on ONE screen, no scrolling (Alex, 15 Nov 2026). Desktop only; phones keep the stacked form. */
@media (min-width:1100px){
.nl-top{display:grid;grid-template-columns:1fr 1fr;gap:10px;align-items:stretch}.nl-top>.card{margin:0!important;padding:8px 12px!important}.nl-top h2{margin:0 0 2px!important}.nl-top .hint{margin:0 0 4px!important;line-height:1.25}
.nl-top input{max-width:none!important}
form.lead-form{display:grid!important;grid-template-columns:repeat(12,minmax(0,1fr));gap:6px 12px;width:100%!important;max-width:none!important;padding:10px 14px!important;margin-top:8px!important}
form.lead-form>.g2,form.lead-form>.g3{display:contents!important}
form.lead-form label{margin:0 0 2px!important}
form.lead-form select,form.lead-form input:not([type=checkbox]){width:100%;max-width:none}
form.lead-form>.g2:nth-child(1)>div,form.lead-form>div:nth-child(2),form.lead-form>.g3:nth-child(3)>div,form.lead-form>.g3:nth-child(4)>div{grid-column:span 2}
form.lead-form>.g2:nth-child(5)>div{grid-column:span 3}
form.lead-form>.g3:nth-child(6)>div:nth-child(1){grid-column:span 1}form.lead-form>.g3:nth-child(6)>div:nth-child(2){grid-column:span 3}
form.lead-form>.g2:nth-child(7)>div:nth-child(1){grid-column:span 3}form.lead-form>.g2:nth-child(7)>div:nth-child(2){grid-column:span 2}
form.lead-form>div:nth-child(10){grid-column:span 3}
form.lead-form>#spanel,form.lead-form>#dupbox{grid-column:1/-1;order:20}form.lead-form>#spanel:empty,form.lead-form>#dupbox:empty{display:none}
form.lead-form>div:nth-child(11){grid-column:span 8;align-self:end}
form.lead-form>p.err{grid-column:1/-1;order:21;margin:0!important}form.lead-form>p.err:empty{display:none}
form.lead-form>.row{grid-column:span 4;justify-self:end;align-self:end}
form.lead-form .hint:empty{display:none}
#lf2 #rbform{grid-column:1/-1}
}
/* v708 New customer page: much smaller boxes (Alex, 15 Nov 2026) */
@media (min-width:1100px){
.nl-top{gap:8px}.nl-top>.card{display:flex!important;flex-wrap:wrap;align-items:center;gap:6px 10px;padding:6px 10px!important}
.nl-top .hint:not(#refmsg){display:none!important}.nl-top h2{font-size:13px!important;margin:0!important;white-space:nowrap;cursor:help}
.nl-top input{flex:1 1 140px;min-width:0;height:26px!important;padding:2px 8px!important}.nl-top .row{display:flex;flex:1 1 200px;flex-wrap:nowrap!important;gap:6px;align-items:center}.nl-top .row input{max-width:none!important}.nl-top .btn{height:26px!important;padding:0 12px!important}
.nl-top #cres,.nl-top #refres{flex:1 1 100%}
form.lead-form{gap:3px 10px!important;padding:6px 10px!important;margin-top:6px!important}
form.lead-form label,form.lead-form .chk{margin:0!important;line-height:1.15}
form.lead-form input:not([type=checkbox]),form.lead-form select{height:26px!important;padding:2px 7px!important}
form.lead-form select{width:auto!important;max-width:100%}
form.lead-form .hint{margin:0!important}
#lf2 #rbform{margin-top:2px!important}#lf2 #rbform>div{gap:4px 10px!important}
}
@media (min-width:1100px){#lf2 #rbform>div{grid-template-columns:repeat(5,minmax(0,1fr))!important}}

/* v709 ITEMS TAB, computer only (Alex 15 Nov 2026): the top of the quote is ONE tidy strip so the windows, the price, the discount and the totals are all seen without scrolling. Client on one slim line; Option, Lead status, the sizes tick, the zebra button and Save sit side by side. Nothing is removed: the long explanations are tooltips-free hints hidden here (they stay on Order info). */
@media (min-width:1100px){
#view.onitems{display:flex;flex-wrap:wrap;align-items:center;gap:4px 8px}
#view.onitems>*{flex:1 1 100%;order:1;margin-top:0!important;margin-bottom:0!important}
#view.onitems>#tabs{order:0}
#view.onitems>.optbar{flex:0 1 auto;order:4}
#view.onitems>.statusbar{flex:0 1 auto;order:5}
#view.onitems>#zbrbar{flex:0 1 auto;order:6}
#view.onitems>#tab{display:contents}
#view.onitems>#tab>#bsaverow{flex:0 0 auto;order:7;margin:0!important}
#view.onitems>#tab>#blk,#view.onitems>#tab>#bmiss{order:8}
#view.onitems>#tab>iframe{order:9;flex:1 1 100%}
#view.onitems>#sendslot{order:10}
#view.onitems>.qclient details,#view.onitems .optbar details,#view.onitems .optbar .hint,#view.onitems .statusbar .hint,#view.onitems #szhint,#view.onitems #zbrbar .hint,#view.onitems #zbrbar small,#view.onitems #zbrbar span{display:none!important}
#view.onitems>.card{padding:4px 10px!important}
#view.onitems .statusbar{display:flex;flex-wrap:nowrap;align-items:center;gap:14px;padding:2px 10px}#view.onitems .statusbar>.row,#view.onitems .statusbar>.card{flex:0 0 auto;margin:0}#view.onitems .statusbar #chkbar{display:none}
#view.onitems .statusbar .sizebar{border:0;box-shadow:none;background:none;padding:0!important;margin:0}
#view.onitems .statusbar .chk b{font-size:12.5px;font-weight:600}
#view.onitems #zbrbar,#view.onitems #zbrbar>*{display:flex;align-items:center;gap:8px;padding:0;border:0;background:none;box-shadow:none}
#view.onitems #bsave{padding:5px 12px}#view.onitems #bstate{font-size:12px}
}

/* v709 round 4 (Alex 15 Nov): no wasted space on the Items tab. Client = one line; Send to the customer = two lines. Items tab only, computer only. */
@media (min-width:1100px){
#view.onitems>.qclient{display:flex!important;align-items:center;gap:8px;padding:4px 10px!important}
#view.onitems .qclient .qc-grid{display:flex!important;flex-wrap:wrap;align-items:center;gap:2px 22px;flex:1 1 auto;min-width:0}
#view.onitems .qclient .qc{display:flex!important;align-items:baseline;gap:6px;width:auto!important;min-width:0;grid-column:auto!important}
#view.onitems .qclient .qc.empty{display:none!important}
#view.onitems .qclient .qc b{font-weight:600}
#view.onitems .qclient .qc-act{flex:0 0 auto;margin:0!important}
#view.onitems #sendslot .sendcard{display:flex;flex-wrap:wrap;align-items:center;gap:4px 16px;padding:6px 12px!important}
#view.onitems #sendslot .sendcard>b{flex:0 0 auto}
#view.onitems #sendslot .sendcard>details,#view.onitems #sendslot .sendrow{margin:0!important;flex:0 0 auto}
#view.onitems #sendslot .sendcard>details[open]{flex-basis:100%}
#view.onitems #sendslot .sendrow{display:flex;align-items:center;gap:10px;padding:2px 8px;background:var(--rowbg,#f2f6f2);border-radius:6px}
#view.onitems #sendslot .sendgo{display:flex!important;flex-wrap:wrap;align-items:end;gap:4px 14px;flex:1 1 100%;border-top:0!important;margin:0!important;padding:0!important}
#view.onitems #sendslot .sendgo>.row{display:contents}
#view.onitems #sendslot .sendgo .vd-f{min-width:200px;margin:0}
#view.onitems #sendslot .sendgo>.hint{flex:1 1 100%}
}

@media (min-width:1100px){
#view.onitems #sendslot .sendgo .vd-f{display:flex!important;flex-direction:row;align-items:center;gap:6px;white-space:nowrap}
#view.onitems #sendslot .sendgo .vd-f input{flex:1 1 auto;min-width:120px}
#view.onitems #sendslot .sendgo{align-items:center}
}
.calchip.fup{background:#fdecc8}.appt.fup{border-left:4px solid #d97706}
