:root {
  --ink: #23262a;
  --wire: #66707a;
  --line: #d3d8dc;
  --paper: #eceff1;
  --panel: #ffffff;
  --amp: #3f7d2c;
  --amp-dark: #2c5a1f;
  --amp-soft: #e2efd9;
  --go: #2e7a4d;
  --go-soft: #dcefe3;
  --stop: #ad3838;
  --stop-soft: #f6dddd;
  --radius: 6px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --ink: #e8eaec; --wire: #9aa3ab; --line: #3a4046; --paper: #1b1e21; --panel: #25292d;
    --amp: #4a97e0; --amp-dark: #85b9ec; --amp-soft: #1c2c3d;
    --go: #6cc08f; --go-soft: #1f3528; --stop: #e07c7c; --stop-soft: #3d2222;
    color-scheme: dark;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 17px/1.5 "Barlow", system-ui, sans-serif;
}
a { color: var(--amp-dark); }
h1, h2, h3 { font-family: "Barlow Semi Condensed", "Barlow", sans-serif; line-height: 1.15; margin: 0 0 .5em; }
h1 { font-size: 2rem; font-weight: 700; }
h2 { font-size: 1.35rem; font-weight: 600; }
h3 { font-size: 1.1rem; font-weight: 600; }
:focus-visible { outline: 3px solid var(--amp); outline-offset: 2px; }

/* top bar (phone and tablet); becomes a sidebar on wide screens, see the end of this file */
.top .grp, .top .who { display: none; }

.top {
  background: var(--ink); color: var(--paper);
  display: flex; align-items: center; gap: 1.25rem; padding: .5rem 1.25rem;
  padding-top: calc(.5rem + env(safe-area-inset-top, 0px));
  border-bottom: 4px solid var(--amp);
}
@media (prefers-color-scheme: dark) { .top { background: #111315; color: #e8eaec; } }
.top .brand { display: flex; align-items: center; }
.top .brand img { height: 40px; background: #fff; border-radius: 4px; padding: 2px 6px; }
.top nav { display: flex; gap: .25rem; flex-wrap: wrap; flex: 1; }
.top nav a { color: inherit; text-decoration: none; padding: .4rem .7rem; border-radius: var(--radius); font-weight: 500; }
.top nav a:hover, .top nav a.on { background: rgba(255,255,255,.12); }
.top .new { background: var(--amp); color: #fff; }
.top .new:hover { background: var(--amp-dark) !important; }

@media (max-width: 720px) {
  .top { flex-wrap: wrap; gap: .5rem; padding-left: .75rem; padding-right: .75rem; }
  .top .brand { flex: 1; }
  .top nav { order: 3; flex: 1 0 100%; flex-wrap: nowrap; overflow-x: auto; margin: 0 -.25rem; }
  .top nav a { white-space: nowrap; }
  .top nav { -webkit-mask-image: linear-gradient(to right, #000 85%, transparent); mask-image: linear-gradient(to right, #000 85%, transparent); padding-right: 2rem; }
}

main { max-width: 1060px; margin: 0 auto; padding: 1.5rem 1.25rem 4rem; }
.row { display: flex; gap: 1rem; flex-wrap: wrap; align-items: center; }
.row.between { justify-content: space-between; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.grid2 > *, .grid3 > *, .grid4 > * { min-width: 0; }  /* lets wide tables scroll inside their panel */
@media (max-width: 720px) { .grid2 { grid-template-columns: 1fr; } }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.25rem; margin-bottom: 1.25rem; }
.muted { color: var(--wire); }
.small { font-size: .9rem; }
.num { font-variant-numeric: tabular-nums; }
.right { text-align: right; }

/* readouts on the dashboard */
.readouts { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1px; background: var(--line);
  border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin-bottom: 1.5rem; }
.readouts > div { background: var(--panel); padding: 1rem 1.25rem; }
.readouts .v { font: 600 1.9rem/1.1 "Barlow Semi Condensed", sans-serif; font-variant-numeric: tabular-nums; }
@media (max-width: 640px) { .readouts { grid-template-columns: 1fr; } }

/* buttons & forms */
.btn, button {
  font: inherit; font-weight: 600; display: inline-flex; align-items: center; gap: .4rem;
  border: 1px solid var(--line); background: var(--panel); color: var(--ink);
  padding: .55rem 1rem; border-radius: var(--radius); cursor: pointer; text-decoration: none; min-height: 44px;
}
.btn:hover, button:hover { border-color: var(--wire); }
.btn.primary, button.primary { background: var(--amp); border-color: var(--amp); color: #fff; }
.btn.primary:hover, button.primary:hover { background: var(--amp-dark); border-color: var(--amp-dark); }
.btn.go, button.go { background: var(--go); border-color: var(--go); color: #fff; }
.btn.danger, button.danger { color: var(--stop); }
.btn.link, button.link { border: 0; background: none; padding: .3rem; min-height: 0; color: var(--amp-dark); }
form.inline { display: inline; }
label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: .25rem; }
input, textarea, select {
  font: inherit; width: 100%; padding: .55rem .7rem; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--panel); color: var(--ink); min-height: 44px;
}
textarea { min-height: 80px; resize: vertical; }
.field { margin-bottom: 1rem; }
.check { display: flex; gap: .5rem; align-items: center; font-weight: 400; }
.check input { width: auto; min-height: 0; }

/* tables */
table { width: 100%; border-collapse: collapse; }
th { text-align: left; font-weight: 600; color: var(--wire); font-size: .9rem; border-bottom: 2px solid var(--line); padding: .5rem; }
td { padding: .6rem .5rem; border-bottom: 1px solid var(--line); vertical-align: top; }
tr.click { cursor: pointer; }
tr.click:hover td { background: var(--paper); }
.scroll { overflow-x: auto; }

/* status */
.tag { display: inline-block; padding: .1rem .55rem; border-radius: 99px; font-size: .85rem; font-weight: 600;
  background: var(--paper); color: var(--wire); border: 1px solid var(--line); white-space: nowrap; }
.tag.sent { background: var(--amp-soft); color: var(--amp-dark); border-color: transparent; }
.tag.approved, .tag.paid { background: var(--go-soft); color: var(--go); border-color: transparent; }
.tag.invoiced { background: var(--ink); color: var(--paper); border-color: transparent; }
.tag.declined, .tag.fail, .tag.cancelled { background: var(--stop-soft); color: var(--stop); border-color: transparent; }
.tag.pass { background: var(--go-soft); color: var(--go); border-color: transparent; }
.tag.issues { background: var(--amp-soft); color: var(--amp-dark); border-color: transparent; }
.tag.fac { background: transparent; border-style: dashed; font-weight: 500; }

/* the job's progress, start to paid */
.stages { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; margin: .75rem 0 1.25rem; }
.stages div { padding-top: .5rem; border-top: 6px solid var(--line); font-size: .85rem; color: var(--wire); font-weight: 500; }
.stages div.done { border-top-color: var(--amp); color: var(--ink); }
.stages div.now { border-top-color: var(--amp); font-weight: 700; color: var(--ink); }
.stages.declined div.now { border-top-color: var(--stop); }

/* line item editor */
.items td { border: 0; padding: .3rem .25rem; }
.items .desc { min-width: 220px; }
.items .qty { width: 80px; } .items .price { width: 120px; } .items .tax { width: 90px; } .items .tot { width: 110px; }
.items textarea { min-height: 44px; height: 44px; }
.items select.unit { margin-top: .3rem; font-size: .85rem; padding: .3rem .4rem; min-height: 36px; width: 100%; }
tr.unithead td { background: var(--paper, #f3f5f7); font-weight: 600; padding-top: .55rem; padding-bottom: .4rem; border-top: 2px solid var(--line, #d3d8dc); }
tr.unithead td small { font-weight: 400; color: var(--wire, #66707a); margin-left: .35rem; }
.totals { margin-left: auto; max-width: 320px; }
.totals div { display: flex; justify-content: space-between; padding: .3rem 0; }
.totals .grand { border-top: 2px solid var(--ink); font-weight: 700; font-size: 1.2rem; margin-top: .3rem; padding-top: .5rem; }
@media (max-width: 720px) {
  .items thead { display: none; }
  .items tr { display: grid; grid-template-columns: 1fr 1.4fr 1fr; gap: .35rem; padding: .6rem 0; border-bottom: 1px solid var(--line); }
  .items td { padding: 0; }
  .items td.dcell { grid-column: 1 / -1; }
  .items td.tot { text-align: left; padding-top: .4rem; font-weight: 600; grid-column: 1 / 3; }
  .items td:last-child { text-align: right; }
  .items .qty, .items .price, .items .tax { width: 100%; }
}

/* photos */
.photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: .75rem; }
.photos figure { margin: 0; background: var(--paper); border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); }
.photos img { display: block; width: 100%; aspect-ratio: 4/3; object-fit: cover; }
.photos figcaption { padding: .5rem; font-size: .9rem; }
.photos figcaption input { min-height: 36px; padding: .3rem .5rem; margin-bottom: .3rem; }
.drop { border: 2px dashed var(--line); border-radius: var(--radius); padding: 1rem; text-align: center; margin-bottom: 1rem; }
.drop.over { border-color: var(--amp); background: var(--amp-soft); }

.flash { padding: .7rem 1rem; border-radius: var(--radius); margin-bottom: 1rem; background: var(--go-soft); color: var(--go); font-weight: 500; }
.flash.err { background: var(--stop-soft); color: var(--stop); }
details summary { cursor: pointer; font-weight: 600; padding: .3rem 0; }
.empty { padding: 2rem 1rem; text-align: center; color: var(--wire); }

/* public page */
.public { max-width: 820px; }
.public .head { text-align: center; margin-bottom: 1rem; }
.public .head img { max-width: 320px; width: 70%; }
@media (prefers-color-scheme: dark) { .public .head img, .login img { background: #fff; border-radius: 8px; padding: 8px; } }
.login { max-width: 380px; margin: 8vh auto; }
.login img { width: 100%; margin-bottom: 1.5rem; }
@media print { .top, .noprint { display: none !important; } body { background: #fff; } .panel { border: 0; } }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* ---------- shared bits added with compliance ---------- */
.nowrap { white-space: nowrap; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 1rem; }
.grid4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0 1rem; }
@media (max-width: 720px) { .grid3, .grid4 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .grid3 { grid-template-columns: 1fr; } }
.panel.flush { padding: 0; overflow: hidden; }
.panel.flush .pad { padding: 1.25rem 1.25rem 0; }
.panel.flush .empty { padding: 2rem 1.25rem; }
.panel.flush .scroll table th:first-child, .panel.flush .scroll table td:first-child { padding-left: 1.25rem; }
form.narrow, section.narrow { max-width: 720px; }
.btn.small-btn { min-height: 36px; padding: .3rem .75rem; font-size: .92rem; }
tr.off td { opacity: .55; }
h1.portal { text-align: center; font-size: 1.4rem; margin: -.75rem 0 1.25rem; }
.readouts > a.gen { color: inherit; text-decoration: none; background: var(--panel); display: block; padding: 1rem 1.25rem; }
.readouts > a.gen:hover { background: var(--paper); }
.readouts > a.gen.alarm { box-shadow: inset 4px 0 var(--stop); }
.readouts .over { color: var(--stop); font-weight: 600; }

/* status chips: one per requirement */
.chip { display: inline-block; padding: .12rem .55rem; border-radius: 4px; font-size: .85rem; font-weight: 600; white-space: nowrap;
  border: 1px solid transparent; }
.chip.ok { background: var(--go-soft); color: var(--go); }
.chip.soon { background: var(--amp-soft); color: var(--amp-dark); }
.chip.overdue { background: var(--stop); color: #fff; }
.chip.never { background: var(--paper); color: var(--wire); border-color: var(--line); }
.chip.na { background: none; color: var(--wire); font-weight: 400; padding-left: 0; padding-right: 0; }
.tally { display: flex; flex-wrap: wrap; gap: .4rem; margin: -.25rem 0 1rem; }

/* list rows that lead with a status stripe: dashboard, customer page */
.duelist { list-style: none; margin: 0; padding: 0; }
.duelist li { border-left: 4px solid var(--line); margin-bottom: .4rem; background: var(--paper); border-radius: 0 var(--radius) var(--radius) 0; }
.duelist li.overdue { border-left-color: var(--stop); }
.duelist li.soon { border-left-color: var(--amp); }
.duelist li.ok { border-left-color: var(--go); }
.duelist a { display: block; padding: .5rem .75rem; color: inherit; text-decoration: none; }
.duelist a:hover { background: var(--line); }
.duelist .who-line, .duelist .what { display: block; }
.duelist .what { font-size: .92rem; }
.duelist li.overdue .what { color: var(--stop); font-weight: 600; }

/* generator list: cards on a phone, aligned columns on a computer */
.genlist { list-style: none; margin: 0; padding: 0; }
.genlist li { padding: .9rem 1.25rem; border-bottom: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: .4rem .5rem; align-items: center; }
.genlist li:last-child { border-bottom: 0; }
.genlist .genhead { display: none; }
.genlist .gname { flex: 1 0 100%; color: inherit; text-decoration: none; }
.genlist .gname strong, .genlist .gname > span { display: block; }
.genlist .gname:hover strong, .genlist .gname:hover > span { color: var(--amp-dark); }
.genlist .cell .chip.na { display: none; }
.genlist .cell:not(.epa):not(.act) { display: inline-flex; align-items: center; gap: .3rem; font-size: .85rem; color: var(--wire); }
.genlist .cell:not(.epa):not(.act)::before { content: attr(data-label); }
.genlist .cell:has(.chip.na) { display: none; }
.genlist .epa { font-size: .9rem; color: var(--wire); }
.genlist .epa::before { content: "EPA "; }
.genlist .epa::after { content: " h"; }
.genlist .epa.warn { color: var(--amp-dark); font-weight: 600; }
.genlist .act { margin-left: auto; }

/* generator page */
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 1px; background: var(--line);
  border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin: 1rem 0 1.25rem; }
.facts > div { background: var(--panel); padding: .6rem 1rem; }
.facts .wide { grid-column: 1 / -1; }
.facts dt { font-size: .85rem; color: var(--wire); }
.facts dd { margin: 0; font-weight: 600; }
.logbtns { display: flex; flex-wrap: wrap; gap: .5rem; }
.reqs { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: .75rem; }
.reqs li { border: 1px solid var(--line); border-top: 5px solid var(--line); border-radius: var(--radius); padding: .75rem .9rem; display: grid; gap: .3rem; align-content: start; }
.reqs li.ok { border-top-color: var(--go); }
.reqs li.soon { border-top-color: var(--amp); }
.reqs li.overdue { border-top-color: var(--stop); }
.rq-top { display: flex; justify-content: space-between; gap: .5rem; align-items: baseline; }
.meter { height: 8px; background: var(--paper); border: 1px solid var(--line); border-radius: 99px; overflow: hidden; }
.meter span { display: block; height: 100%; background: var(--go); }
.reqs li.soon .meter span { background: var(--amp); }
.reqs li.overdue .meter span { background: var(--stop); }
.flag { font-size: .8rem; font-weight: 600; color: var(--amp-dark); border: 1px solid var(--amp); border-radius: 4px; padding: 0 .35rem; }

/* test form */
.checklist { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: .25rem 1.5rem; margin-bottom: .5rem; }
.ckrow { border: 0; border-bottom: 1px solid var(--line); margin: 0; padding: .45rem 0; display: flex; align-items: center; justify-content: space-between; gap: .75rem; }
.ckrow legend { float: left; padding: 0; font-weight: 500; }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; flex-shrink: 0; }
.seg label { margin: 0; font-weight: 500; cursor: pointer; }
.seg input { position: absolute; opacity: 0; pointer-events: none; width: 1px; height: 1px; min-height: 0; }
.seg span { display: block; padding: .5rem .8rem; min-width: 3.2rem; text-align: center; border-left: 1px solid var(--line); }
.seg label:first-child span { border-left: 0; }
.seg input:focus-visible + span { outline: 3px solid var(--amp); outline-offset: -3px; }
.seg input[value=ok]:checked + span, .seg input[value=pass]:checked + span { background: var(--go); color: #fff; }
.seg input[value=issue]:checked + span, .seg input[value=fail]:checked + span { background: var(--stop); color: #fff; }
.seg input[value=issues]:checked + span { background: var(--amp); color: #fff; }
.seg input[value=na]:checked + span { background: var(--wire); color: #fff; }
.seg.big { display: flex; }
.seg.big label { flex: 1; }
.seg.big span { padding: .7rem .5rem; }
.readings td { border: 0; padding: .25rem; }
.readings input { min-width: 70px; }
.readings td:first-child input { min-width: 130px; }
.readings .pct { color: var(--wire); padding-top: .8rem; min-width: 3rem; }
.panel.sign { border-top: 4px solid var(--amp); }

/* test record */
.result-band { display: flex; flex-wrap: wrap; gap: .25rem 1rem; align-items: baseline; padding: .8rem 1.1rem; border-radius: var(--radius);
  margin: 1rem 0; background: var(--go-soft); color: var(--go); }
.result-band strong { font: 700 1.35rem/1.1 "Barlow Semi Condensed", sans-serif; }
.result-band span { color: var(--ink); }
.result-band.issues { background: var(--amp-soft); color: var(--amp-dark); }
.result-band.fail { background: var(--stop-soft); color: var(--stop); }
.kv td { padding: .4rem .25rem; }
.cklist { list-style: none; margin: 0; padding: 0; columns: 2 280px; column-gap: 2rem; }
.cklist li { display: flex; justify-content: space-between; gap: .5rem; padding: .35rem 0; border-bottom: 1px solid var(--line); break-inside: avoid; }
.cklist li.issue span:first-child { color: var(--stop); font-weight: 600; }
.co-lines { border-top: 1px dashed var(--line); padding-top: .75rem; margin-bottom: 1rem; }
.co-lines h3 { margin-bottom: 0; }
.tag.draft { background: var(--paper); }


/* tap to call, tap for directions */
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
a.tel { white-space: nowrap; }
a.addr { display: inline-flex; flex-direction: column; gap: .15rem; text-decoration: none; color: inherit; }
a.addr > span:first-child { white-space: pre-line; }
a.addr .dir { color: var(--amp-dark); font-weight: 600; font-size: .92rem; }
a.addr .dir::before { content: "\2197\00a0"; }
a.addr:hover .dir { text-decoration: underline; }
a.addr.big { display: flex; padding: .75rem .9rem; border: 1px solid var(--line); border-left: 4px solid var(--amp); border-radius: var(--radius); margin-bottom: .75rem; }
.kv { margin-top: .6rem; }
.plainlist { margin: .25rem 0 0; padding-left: 1.1rem; }
.note { font-style: italic; }
.terms p { margin: 0 0 .6rem; }
.checks { display: grid; gap: .4rem; }

/* visits */
.tag.requested { background: var(--amp-soft); color: var(--amp-dark); border-color: transparent; }
.tag.scheduled { background: var(--ink); color: var(--paper); border-color: transparent; }
.tag.done, .tag.active { background: var(--go-soft); color: var(--go); border-color: transparent; }
.tag.ended { background: var(--paper); color: var(--wire); }
.visits { list-style: none; margin: 0; padding: 0; }
.visits li { border-bottom: 1px solid var(--line); }
.visits li:last-child { border-bottom: 0; }
.visits li > a, .visits li > div { display: grid; grid-template-columns: 8.5rem 1fr auto; gap: .2rem .75rem; align-items: baseline;
  padding: .55rem .25rem; color: inherit; text-decoration: none; }
.visits li > a:hover { background: var(--paper); }
.visits li.cancelled, .visits li.done { opacity: .6; }
.visits .meta { text-align: right; font-size: .92rem; }
@media (max-width: 560px) {
  .visits li > a, .visits li > div { grid-template-columns: 1fr auto; }
  .visits .what { grid-column: 1 / -1; grid-row: 2; }
}
.today-panel h2 { margin: 0; }
.today-panel .row.between { margin-bottom: .5rem; }
.nudges { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: .6rem; }
.nudge { padding: .35rem .7rem; border-radius: var(--radius); background: var(--amp-soft); color: var(--amp-dark); font-weight: 600; text-decoration: none; font-size: .95rem; }
.nudge.quiet { background: var(--paper); color: var(--ink); font-weight: 500; }
.rq-act { margin-top: .2rem; }
.rq-act .booked { font-size: .9rem; font-weight: 600; color: var(--go); }
a.chiplink { text-decoration: none; }
a.chiplink .chip { box-shadow: 0 1px 0 var(--wire); }
a.chiplink:hover .chip { filter: brightness(.95); text-decoration: underline; }

/* schedule */
.requests { border-left: 4px solid var(--amp); }
.requests .count { display: inline-block; min-width: 1.6rem; text-align: center; background: var(--amp); color: #fff; border-radius: 99px; font-size: .9rem; padding: 0 .4rem; vertical-align: middle; }
.reqlist { list-style: none; margin: 0; padding: 0; }
.reqlist li { display: flex; gap: .75rem; align-items: center; justify-content: space-between; padding: .6rem 0; border-bottom: 1px solid var(--line); }
.reqlist li:last-child { border-bottom: 0; }
.reqlist .rq-main a { color: inherit; }
.weekbar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .6rem; margin: 1.25rem 0 .75rem; }
.weekbar .wk { font: 600 1.2rem/1.2 "Barlow Semi Condensed", sans-serif; margin-left: .35rem; }
.weekbar select { width: auto; min-height: 36px; padding: .3rem .5rem; }
.week { display: grid; gap: .6rem; margin-bottom: 1rem; }
.day { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: .5rem .6rem .6rem; }
.day header { display: flex; align-items: baseline; gap: .35rem; padding-bottom: .35rem; }
.day .dn { font-weight: 600; } .day .dd { font: 600 1.15rem/1 "Barlow Semi Condensed", sans-serif; }
.day .tdy { font-size: .8rem; font-weight: 600; color: #fff; background: var(--amp); border-radius: 4px; padding: 0 .35rem; }
.day .add { margin-left: auto; text-decoration: none; font-weight: 700; font-size: 1.25rem; line-height: 1; padding: .1rem .5rem; border-radius: var(--radius); color: var(--amp-dark); }
.day .add:hover { background: var(--amp-soft); }
.day.today { border-color: var(--amp); box-shadow: inset 0 3px var(--amp); }
.day.empty.past { display: none; }
.day.empty { padding-bottom: .35rem; }
.day.empty header { padding-bottom: 0; }
.day .none { display: none; }
.appt { display: grid; gap: 0; margin-top: .35rem; padding: .45rem .6rem; border-radius: 4px; text-decoration: none; color: inherit;
  background: var(--paper); border-left: 4px solid var(--ink); font-size: .95rem; line-height: 1.3; }
.appt:hover { background: var(--line); }
.appt .tm { font-size: .85rem; font-weight: 600; color: var(--wire); }
.appt .tech { font-size: .85rem; color: var(--wire); }
.appt.unassigned { border-left-color: var(--amp); }
.appt.unassigned .tech { color: var(--amp-dark); font-weight: 600; }
.appt.done { border-left-color: var(--go); opacity: .7; }
.when-block { margin: 1rem 0 1.25rem; padding: .9rem 1.1rem; border-radius: var(--radius); background: var(--panel); border: 1px solid var(--line); border-left: 6px solid var(--ink); }
.when-block .big { font: 700 1.5rem/1.15 "Barlow Semi Condensed", sans-serif; }
.when-block.requested { border-left-color: var(--amp); }
.when-block.done { border-left-color: var(--go); }
.when-block.cancelled { border-left-color: var(--stop); }
.askbox { border-left: 4px solid var(--amp); display: grid; gap: .25rem; }
.mini-status { list-style: none; margin: 0 0 .5rem; padding: 0; }
.mini-status li { display: flex; justify-content: space-between; gap: .5rem; padding: .3rem 0; border-bottom: 1px solid var(--line); }


/* sales */
@media (max-width: 640px) { .readouts.two { grid-template-columns: 1fr 1fr; } .readouts.two .v { font-size: 1.6rem; } .readouts.two > div { padding: .8rem 1rem; } }
.lbl { display: block; font-weight: 600; font-size: .92rem; margin-bottom: .25rem; }
.lead { font-size: .75rem; font-weight: 600; color: var(--amp-dark); border: 1px dashed var(--amp); border-radius: 4px; padding: 0 .3rem; vertical-align: middle; }
.tag.ps-new { background: var(--paper); }
.tag.ps-contacted { background: var(--panel); }
.tag.ps-interested { background: var(--amp-soft); color: var(--amp-dark); border-color: transparent; }
.tag.ps-meeting { background: var(--ink); color: var(--paper); border-color: transparent; }
.tag.ps-won { background: var(--go-soft); color: var(--go); border-color: transparent; }
.tag.ps-lost, .tag.ps-dnc { background: var(--stop-soft); color: var(--stop); border-color: transparent; }
.tally a.chip { text-decoration: none; background: var(--panel); color: var(--ink); border-color: var(--line); }
.tally a.chip.ink { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.filters { margin-bottom: 1rem; gap: .5rem; }
.filters select { width: auto; }
.over { color: var(--stop); font-weight: 600; }
.pager { justify-content: center; padding: .9rem 1rem; border-top: 1px solid var(--line); }
.plist { list-style: none; margin: 0; padding: 0; }
.plist li { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem .75rem; padding: .7rem 1.25rem; border-bottom: 1px solid var(--line); }
.plist li:last-child { border-bottom: 0; }
.plist .phead { display: none; }
.plist .pname { flex: 1 0 100%; color: inherit; text-decoration: none; }
.plist .pname strong, .plist .pname span { display: block; }
.plist .pname:hover strong { color: var(--amp-dark); }
.plist .pphone a { font-weight: 600; }
.calllist { list-style: none; margin: .5rem 0 0; padding: 0; }
.calllist li { display: flex; align-items: center; gap: .75rem; padding: .6rem 1.25rem; border-top: 1px solid var(--line); border-left: 4px solid transparent; }
.calllist li.late { border-left-color: var(--stop); }
.calllist .cl-main { flex: 1; min-width: 0; color: inherit; text-decoration: none; display: grid; gap: .1rem; }
.calllist .cl-main:hover strong { color: var(--amp-dark); }
.calllist .cl-call a.btn { text-decoration: none; }
.queuebar { display: flex; flex-wrap: wrap; gap: .4rem 1rem; align-items: center; background: var(--ink); color: var(--paper);
  padding: .55rem 1rem; border-radius: var(--radius); margin-bottom: 1rem; }
.queuebar span { font-weight: 600; margin-right: auto; }
.queuebar a { color: var(--paper); }
.bigcall { display: flex; justify-content: center; font-size: 1.15rem; width: 100%; padding: .8rem 1rem; text-decoration: none; }
.callcard .kv:first-of-type { margin-top: .9rem; }
.outcomes { border: 0; margin: 0 0 1rem; padding: 0; display: flex; flex-wrap: wrap; gap: .4rem; }
.outcomes label, .fuchips label { margin: 0; font-weight: 500; cursor: pointer; }
.outcomes input, .fuchips input { position: absolute; opacity: 0; width: 1px; height: 1px; min-height: 0; pointer-events: none; }
.outcomes span, .fuchips span { display: inline-block; padding: .45rem .7rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); font-size: .95rem; }
.outcomes input:checked + span { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.outcomes input[value=interested]:checked + span, .outcomes input[value=booked]:checked + span { background: var(--go); border-color: var(--go); color: #fff; }
.outcomes input[value=not_interested]:checked + span, .outcomes input[value=dnc]:checked + span { background: var(--stop); border-color: var(--stop); color: #fff; }
.fuchips { display: flex; flex-wrap: wrap; gap: .35rem; }
.fuchips span { font-size: .88rem; padding: .3rem .6rem; }
.fuchips input:checked + span { background: var(--amp-soft); border-color: var(--amp); color: var(--amp-dark); font-weight: 600; }
.outcomes input:focus-visible + span, .fuchips input:focus-visible + span { outline: 3px solid var(--amp); outline-offset: 2px; }
.calllog { list-style: none; margin: 0; padding: 0; }
.calllog li { border-left: 3px solid var(--line); padding: .35rem 0 .6rem .8rem; }
.calllog li.o-interested, .calllog li.o-booked { border-left-color: var(--go); }
.calllog li.o-not_interested, .calllog li.o-dnc { border-left-color: var(--stop); }
.calllog li.o-talked { border-left-color: var(--amp); }
.calllog .cl-head { display: flex; flex-wrap: wrap; gap: .1rem .5rem; align-items: baseline; }
.mapgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 0 1rem; }
.inline-checks { display: flex; flex-wrap: wrap; gap: .4rem 1rem; }
.tplgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: .9rem; margin: 1rem 0; }
.tplcard { display: flex; flex-direction: column; gap: .35rem; padding: 1rem 1.1rem; background: var(--panel); border: 1px solid var(--line);
  border-top: 4px solid var(--amp); border-radius: var(--radius); color: inherit; text-decoration: none; }
.tplcard:hover { border-color: var(--amp); }
.tplcard ul { margin: .25rem 0; padding-left: 1.1rem; font-size: .92rem; }
.tplcard .price { margin-top: auto; font: 600 1.25rem/1.2 "Barlow Semi Condensed", sans-serif; }
.tplcard.blank { border-top-color: var(--line); border-style: dashed; justify-content: center; }


/* site maps */
.sitemap { position: relative; width: 100%; background: #2b2f33; border-radius: var(--radius); overflow: hidden; user-select: none; -webkit-user-select: none; }
.sitemap img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: fill; pointer-events: none; }
.sitemap svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.sitemap .smempty { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: #bbb; }
[hidden] { display: none !important; }
.smscroll { overflow: auto; max-height: 78vh; border-radius: var(--radius); -webkit-overflow-scrolling: touch; }
.smscroll .sitemap { border-radius: 0; }
.smzoom { display: flex; gap: .3rem; align-items: center; margin-bottom: .4rem; }
.smzoom button { min-height: 32px; padding: .15rem .6rem; font-size: .88rem; }
.smzoom button.on { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.sitemap.editing svg { touch-action: pan-x pan-y; cursor: default; }
.sitemap.editing .mk { touch-action: none; cursor: grab; }
.sitemap.editing.placing svg { cursor: crosshair; touch-action: none; }
.sitemap .m-sym { stroke: #fff; stroke-width: 3; }
.sitemap .m-abbr { fill: #fff; font-weight: 700; font-family: "Barlow", sans-serif; pointer-events: none; }
.sitemap .m-abbr.dark { fill: #23262a; }
.sitemap .m-text { fill: #fff; font-weight: 600; font-family: "Barlow", sans-serif; paint-order: stroke; stroke: rgba(0,0,0,.75); stroke-width: 4; stroke-linejoin: round; pointer-events: none; }
.sitemap .m-text.big { pointer-events: auto; }
.sitemap .m-outline { fill: rgba(255,255,255,.12); stroke: #fff; stroke-dasharray: 12 8; }
.sitemap .m-line { fill: none; stroke-linecap: round; stroke-linejoin: round; }
.sitemap .k-electric { stroke: #e8742f; }
.sitemap .k-gas { stroke: #f2c94c; stroke-dasharray: 18 10; }
.sitemap .k-other { stroke: #fff; stroke-dasharray: 4 8; }
.sitemap .m-measure { fill: none; stroke: #7fd1ff; stroke-dasharray: 6 6; }
.sitemap .hit { fill: transparent; stroke: transparent; }
.sitemap polygon.hit { fill: rgba(0,0,0,0); }
.sitemap .mk.sel .m-sym, .sitemap .mk.sel .m-line, .sitemap .mk.sel .m-outline { filter: drop-shadow(0 0 6px #7fd1ff); }
.sitemap .handle { fill: #7fd1ff; stroke: #fff; stroke-width: 3; cursor: grab; }
.sitemap .draft { fill: rgba(127,209,255,.15); stroke: #7fd1ff; stroke-dasharray: 10 6; }
.sitemap polyline.draft { fill: none; }
.smtools { display: flex; flex-wrap: wrap; gap: .5rem .9rem; margin: 1rem 0 .4rem; }
.smtools .tgroup { display: flex; flex-wrap: wrap; gap: .3rem; align-items: center; }
.smtools button { min-height: 36px; padding: .3rem .65rem; font-size: .9rem; }
.smtools button.on { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.smtools select { width: auto; min-height: 36px; padding: .25rem .4rem; font-size: .9rem; }
.smhint { margin: 0 0 .6rem; color: var(--wire); font-size: .92rem; }
@media (max-width: 720px) {
  .smtools { flex-direction: column; gap: .35rem; }
  .smtools .tgroup { min-width: 0; max-width: 100%; flex-wrap: nowrap; overflow-x: auto; padding-bottom: .15rem; -webkit-mask-image: linear-gradient(to right, #000 88%, transparent); mask-image: linear-gradient(to right, #000 88%, transparent); padding-right: 1.5rem; }
  .smtools button, .smtools select { flex-shrink: 0; }
}
.smwrap { display: grid; gap: 1rem; }
.smside .panel { margin-bottom: 1rem; }
.smthumb { display: block; position: relative; margin-top: .4rem; text-decoration: none; }
.smthumb .sitemap { pointer-events: none; }
.smthumb > span { position: absolute; left: .4rem; top: .4rem; background: rgba(0,0,0,.6); color: #fff; font-size: .78rem; font-weight: 600; padding: 0 .4rem; border-radius: 3px; }
.smthumb.wide { margin: 0 0 .75rem; }
.printonly { display: none; }
@media print { .printonly { display: block; } .smwrap { display: block; } .sitemap { border-radius: 0; } }
@media (min-width: 1024px) { .smwrap { grid-template-columns: minmax(0, 1fr) 320px; align-items: start; } }

/* transfer switches */
.swrows { display: grid; gap: .5rem; margin-bottom: .5rem; }
.swrow { display: grid; grid-template-columns: 1.4fr 1.2fr .7fr 1fr auto; gap: .5rem; align-items: end; padding: .6rem .75rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); }
.swrow .field { margin: 0; }
.swrow .link { margin-bottom: .55rem; }
@media (max-width: 720px) { .swrow { grid-template-columns: 1fr 1fr; } .swrow .field:first-child { grid-column: 1 / -1; } }
.swlist { list-style: none; margin: 0; padding: 0; }
.swlist li { padding: .15rem 0; }
.genlist .svconly { color: var(--wire); font-size: .92rem; }
@media (min-width: 1024px) { .genlist .svconly { grid-column: span 6; } }

/* saved items, documents, repair, hours */
.addlines { margin: .5rem 0 1rem; gap: .5rem; }
.savedpick select { width: auto; max-width: 100%; }
.credlist { list-style: none; margin: 0; padding: 0; }
.credlist li { display: grid; grid-template-columns: 1fr auto; gap: .3rem .75rem; padding: .8rem 1.1rem; border-bottom: 1px solid var(--line); border-left: 4px solid var(--line); }
.credlist li:last-child { border-bottom: 0; }
.credlist li.cs-expired { border-left-color: var(--stop); }
.credlist li.cs-soon { border-left-color: var(--amp); }
.credlist li.cs-ok { border-left-color: var(--go); }
.credlist .cl-main { display: grid; gap: .1rem; min-width: 0; }
.credlist .cl-main a { color: inherit; }
.credlist .cl-edit { grid-column: 1 / -1; }
.credform { display: grid; gap: 0; margin: .75rem 0; padding-top: .75rem; border-top: 1px dashed var(--line); }
.hourwarn { grid-column: 1 / -1; margin: -.25rem 0 .75rem; padding: .5rem .75rem; border-radius: var(--radius); background: var(--amp-soft); color: var(--amp-dark); font-weight: 600; font-size: .92rem; }
.repairbox { border-left: 4px solid var(--stop); }

/* addresses */
.addrgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: .9rem; margin: .9rem 0 1rem; }
.addrcard { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--panel); display: flex; flex-direction: column; }
.addrcard .sv { position: relative; aspect-ratio: 16 / 10; background: var(--paper); }
.addrcard .sv img { display: block; width: 100%; height: 100%; object-fit: cover; }
.addrcard .sv .svdate { position: absolute; right: .4rem; bottom: .35rem; font-size: .72rem; color: #fff; background: rgba(0,0,0,.55); padding: 0 .35rem; border-radius: 3px; }
.addrcard .sv .svfail { display: none; }
.addrcard .sv.failed img, .addrcard .sv.failed .svdate { display: none; }
.addrcard .sv.failed .svfail, .addrcard .svnone { display: flex; height: 100%; align-items: center; justify-content: center; text-align: center;
  padding: 1rem; color: var(--wire); font-size: .9rem; }
.addrbody { padding: .75rem .9rem .8rem; display: grid; gap: .3rem; }
.addracts { gap: .4rem .8rem; margin-top: .2rem; }
.addracts .link { padding: 0; }
.addracts a { font-weight: 600; text-decoration: none; color: var(--amp-dark); }
.svvisit { display: block; margin: 0 0 .75rem; border-radius: var(--radius); overflow: hidden; }
.svvisit img { display: block; width: 100%; aspect-ratio: 2 / 1; object-fit: cover; }

/* travel */
.travelbox.over { border-left: 4px solid var(--stop); }
.travelnote { margin: -.25rem 0 1rem; color: var(--wire); }
.travelgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 0 1rem; }
.unit { display: flex; align-items: center; gap: .4rem; }
.unit span { color: var(--wire); }

/* jobs */
.jobstages { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: 1rem; }
.jobstages a { display: flex; align-items: baseline; gap: .4rem; padding: .4rem .75rem; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--panel); color: inherit; text-decoration: none; font-weight: 500; font-size: .95rem; }
.jobstages a .n { font: 600 1.15rem/1 "Barlow Semi Condensed", sans-serif; font-variant-numeric: tabular-nums; }
.jobstages a.on { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.jobstages a.st-done:not(.on) { border-color: var(--go); }
.tag.js-approved { background: var(--amp-soft); color: var(--amp-dark); border-color: transparent; }
.tag.js-scheduled { background: var(--ink); color: var(--paper); border-color: transparent; }
.tag.js-in_progress { background: var(--panel); border-color: var(--amp); color: var(--amp-dark); }
.tag.js-done { background: var(--go); color: #fff; border-color: transparent; }
.tag.js-invoiced { background: var(--paper); color: var(--wire); }
.joblist { list-style: none; margin: 0; padding: 0; }
.joblist li { border-bottom: 1px solid var(--line); border-left: 4px solid var(--line); }
.joblist li:last-child { border-bottom: 0; }
.joblist li.st-approved { border-left-color: var(--amp); }
.joblist li.st-scheduled, .joblist li.st-in_progress { border-left-color: var(--ink); }
.joblist li.st-done { border-left-color: var(--go); }
.joblist a { display: grid; grid-template-columns: 1fr auto; gap: .2rem .75rem; padding: .7rem 1.1rem; color: inherit; text-decoration: none; }
.joblist a:hover { background: var(--paper); }
.joblist .jl-main strong, .joblist .jl-main .small { display: block; }
.joblist .jl-main .small { margin-top: .1rem; }
.joblist .jl-when { grid-column: 1; }
.joblist .jl-amt { grid-column: 2; grid-row: 1; text-align: right; font-weight: 600; }
.joblist .jl-tag { grid-column: 2; grid-row: 2; text-align: right; }
.over-soft { color: var(--amp-dark); font-weight: 600; }
.jobpanel { border-top: 4px solid var(--ink); }
.jobbar { margin: .75rem 0 1rem; }
.worklist { list-style: none; margin: 0; padding: 0; }
.worklist li { display: flex; justify-content: space-between; gap: .75rem; padding: .45rem 0; border-bottom: 1px solid var(--line); }
.worklist li::before { content: "\25A1"; color: var(--wire); margin-right: .1rem; }
.worklist li span:first-child { flex: 1; }
.signed-off { display: grid; gap: .5rem; padding: .75rem .9rem; background: var(--go-soft); border-radius: var(--radius); }
.sigimg { max-width: 320px; width: 100%; height: auto; background: #fff; border: 1px solid var(--line); border-radius: 4px; }
.sigtext { font-weight: 600; }
#signbox .seg input:checked + span { background: var(--ink); color: var(--paper); }
.sigpad { position: relative; border: 2px dashed var(--wire); border-radius: var(--radius); background: #fff; margin: .25rem 0; touch-action: none; }
.sigpad canvas { display: block; width: 100%; height: 180px; touch-action: none; cursor: crosshair; }
.sigpad .sighint { position: absolute; left: 0; right: 0; bottom: 2.2rem; text-align: center; color: #888; pointer-events: none; border-top: 1px solid #ccc; margin: 0 1.25rem; padding-top: .3rem; font-size: .9rem; }

/* ---------- computers: sidebar layout. Nothing below changes phones or tablets. ---------- */
.top .m-only { display: inline-block; }
@media (min-width: 1024px) {
  body:has(> header.top) { padding-left: 248px; }   /* 1.38.1: only when the menu is on the page */
  .top {
    position: fixed; top: 0; bottom: 0; left: 0; width: 248px; z-index: 5;
    flex-direction: column; align-items: stretch; gap: .75rem; overflow-y: auto;
    padding: calc(1.25rem + env(safe-area-inset-top, 0px)) .9rem 1rem;
    border-bottom: 0; border-right: 4px solid var(--amp);
  }
  .top .brand img { height: auto; width: 100%; padding: 6px 10px; border-radius: 6px; }
  .top .new { order: 1; justify-content: center; margin-top: .25rem; }
  .top nav { order: 2; flex-direction: column; flex-wrap: nowrap; flex: 1; gap: 1px; }
  .top nav a { padding: .5rem .75rem; }
  .top nav a.on { background: rgba(255,255,255,.1); box-shadow: inset 3px 0 var(--amp); }
  .top .grp { display: block; font-size: .8rem; font-weight: 600; color: rgba(236,239,241,.5); margin: 1.1rem .75rem .3rem; }
  .top .grp:first-child { margin-top: .5rem; }
  .top .m-only { display: none; }
  .top .who { order: 3; display: flex; flex-direction: column; gap: .25rem; border-top: 1px solid rgba(255,255,255,.12); padding-top: .75rem; }
  .top .who a { color: inherit; text-decoration: none; padding: .4rem .75rem; border-radius: var(--radius); }
  .top .who a:hover, .top .who a.on { background: rgba(255,255,255,.1); }
  .top .who strong { display: block; }
  .top .who span { display: block; font-size: .85rem; color: rgba(236,239,241,.6); }
  .top .who .out { font-size: .92rem; color: rgba(236,239,241,.75); }

  main { max-width: 1320px; margin: 0; padding: 2rem 2.5rem 4rem; }
  main.public { max-width: 820px; margin: 0 auto; }
  body:not(:has(> header.top)) main { margin: 0 auto; }   /* 1.38.1: sign-in and other pages without the menu */
  h1 { font-size: 2.1rem; }
  td.right.num, td.right.muted, .panel table td:first-child a { white-space: nowrap; }
  .readouts .v { font-size: 2.1rem; }
  .readouts > div, .readouts > a { padding: 1.1rem 1.4rem; }

  /* dashboard: money on the left, what needs doing on the right */
  .dash { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 1.25rem; align-items: start; }
  .dash .grid2 { grid-template-columns: 1fr; gap: 0; }
  .dash-side { position: sticky; top: 1.5rem; }

  /* generator list as aligned columns */
  .genlist li { display: grid; grid-template-columns: minmax(200px, 1.6fr) repeat(5, minmax(0, 1fr)) 5rem 6.5rem; gap: .75rem; padding: .75rem 1.25rem; }
  .genlist .genhead { display: grid; font-size: .85rem; font-weight: 600; color: var(--wire); background: var(--paper); padding-top: .6rem; padding-bottom: .6rem; }
  .genlist .gname { flex: none; }
  .genlist .cell .chip.na { display: inline-block; }
  .genlist .cell:has(.chip.na) { display: inline-flex; }
  .genlist .cell:not(.epa):not(.act)::before { content: none; }
  .genlist .epa::before, .genlist .epa::after { content: none; }
  .genlist .epa { font-size: 1rem; }
  .genlist .act { margin: 0; text-align: right; }
}
@media (min-width: 1024px) {
  .joblist a { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1.2fr) 7rem 10rem; align-items: center; }
  .joblist .jl-when, .joblist .jl-amt, .joblist .jl-tag { grid-column: auto; grid-row: auto; }
  .plist li { display: grid; grid-template-columns: minmax(240px, 2fr) 10rem 8.5rem 6.5rem 6rem; gap: .75rem; padding: .65rem 1.25rem; }
  .plist .phead { display: grid; font-size: .85rem; font-weight: 600; color: var(--wire); background: var(--paper); }
  .plist .pname { flex: none; }
}
@media (min-width: 1024px) and (max-width: 1279px) {
  .dash { grid-template-columns: 1fr; }
  .dash-side { position: static; display: grid; grid-template-columns: 1fr 1fr; gap: 0 1rem; }
  .genlist li { grid-template-columns: minmax(170px, 1.4fr) repeat(5, minmax(0, 1fr)) 4rem 6rem; gap: .5rem; }
  .genlist .chip { white-space: normal; }
}
@media (min-width: 1024px) {
  .week { grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 0; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--line); gap: 1px; }
  .day { border: 0; border-radius: 0; min-height: 14rem; }
  .day.empty.past { display: block; }
  .day.past { background: var(--paper); }
  .day .none { display: block; color: var(--wire); font-size: .85rem; margin: .5rem 0 0; }
  .day.empty { padding-bottom: .6rem; }
  .day.today { box-shadow: inset 0 4px var(--amp); }
  .appt { font-size: .9rem; }
}
@media print { body { padding-left: 0 !important; } }
.fuelwarn { margin: .35rem 0 0; padding: .35rem .6rem; border-radius: var(--radius); background: var(--amp-soft); color: var(--amp-dark); font-weight: 600; }
.fuelspec { margin-bottom: .5rem; }

/* ---------- profiles and messages (1.9) ---------- */
.badge { display: inline-block; min-width: 1.3em; padding: 0 .35em; border-radius: 999px; background: var(--amp); color: #fff; font-size: .75rem; font-weight: 700; line-height: 1.3em; text-align: center; vertical-align: 1px; }
.av { display: inline-flex; align-items: center; justify-content: center; flex: none; width: 2.5rem; height: 2.5rem; border-radius: 50%; overflow: hidden; background: var(--amp-soft); color: var(--amp-dark); font-weight: 700; font-size: .95rem; letter-spacing: .02em; }
.av img { width: 100%; height: 100%; object-fit: cover; display: block; }
.av.sm { width: 2rem; height: 2rem; font-size: .8rem; }
.av.lg { width: 7rem; height: 7rem; font-size: 2.2rem; }
.top .who a.me { display: flex; align-items: center; gap: .6rem; }
.top .who .av { display: inline-flex; font-size: .8rem; color: var(--amp-dark); }
.top .who .me-t span { display: block; }
.people { list-style: none; margin: 0; padding: 0; display: grid; gap: 1px; background: var(--line); }
.people li { background: var(--panel); }
.people a { display: flex; align-items: center; gap: .85rem; padding: .75rem 1rem; color: inherit; text-decoration: none; }
.people a:hover { background: var(--paper); }
.people .p-t { min-width: 0; flex: 1; }
.people .p-t strong, .people .p-t span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.person-head { display: flex; align-items: center; gap: 1.25rem; flex-wrap: wrap; }
.person-head h1 { margin: 0; }
.profile-photo { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; margin-bottom: 1rem; }
.inbox { list-style: none; margin: 0; padding: 0; }
.inbox li + li { border-top: 1px solid var(--line); }
.inbox a { display: flex; gap: .85rem; align-items: center; padding: .8rem 1rem; color: inherit; text-decoration: none; }
.inbox a:hover { background: var(--paper); }
.inbox .i-t { flex: 1; min-width: 0; }
.inbox .i-t strong, .inbox .i-t .snip { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.inbox .snip { color: var(--wire); font-size: .92rem; }
.inbox .unread strong { font-weight: 700; }
.inbox .unread .snip { color: var(--ink); font-weight: 600; }
.inbox .i-when { font-size: .8rem; color: var(--wire); white-space: nowrap; align-self: flex-start; padding-top: .2rem; }
.inbox .dot { width: .6rem; height: .6rem; border-radius: 50%; background: var(--amp); flex: none; }
.avstack { display: inline-flex; flex: none; }
.avstack .av + .av { margin-left: -.9rem; box-shadow: 0 0 0 2px var(--panel); }
.thread { display: flex; flex-direction: column; gap: .6rem; padding: 1rem; }
.msg { display: flex; gap: .6rem; align-items: flex-end; max-width: 85%; }
.msg.mine { align-self: flex-end; flex-direction: row-reverse; }
.msg .bubble { background: var(--paper); border-radius: 14px 14px 14px 4px; padding: .5rem .8rem; min-width: 0; overflow-wrap: anywhere; }
.msg.mine .bubble { background: var(--amp); color: #fff; border-radius: 14px 14px 4px 14px; }
.msg .meta { font-size: .75rem; color: var(--wire); margin-bottom: .15rem; }
.msg.mine .meta { color: rgba(255,255,255,.85); }
.msg .text { white-space: pre-wrap; }
.msg img.mphoto { display: block; max-width: 100%; max-height: 320px; border-radius: 8px; margin-top: .35rem; }
.newmark { text-align: center; font-size: .78rem; color: var(--amp-dark); font-weight: 700; display: flex; gap: .5rem; align-items: center; }
.newmark::before, .newmark::after { content: ""; flex: 1; border-top: 1px solid var(--amp-soft); }
.composer { position: sticky; bottom: 0; display: flex; gap: .5rem; align-items: flex-end; padding: .75rem; border-top: 1px solid var(--line); background: var(--panel); border-radius: 0 0 var(--radius) var(--radius); }
.composer textarea { flex: 1; min-height: 2.6rem; max-height: 10rem; resize: none; margin: 0; }
.composer .attach { cursor: pointer; padding: .5rem .6rem; border-radius: var(--radius); border: 1px solid var(--line); line-height: 1; }
.composer .attach input { display: none; }
.composer .attach.has { border-color: var(--amp); color: var(--amp-dark); }
.pickpeople { display: grid; gap: .25rem; max-height: 22rem; overflow-y: auto; }
.pickpeople label { display: flex; align-items: center; gap: .65rem; padding: .4rem .5rem; border-radius: var(--radius); cursor: pointer; }
.pickpeople label:hover { background: var(--paper); }
.danger-zone { border-color: var(--stop-soft); margin-top: 1.25rem; }
.danger-zone h2 { color: var(--stop); }
.usertabs { display: flex; gap: .4rem; flex-wrap: wrap; margin: .5rem 0 1rem; }
.mailresult { padding: .75rem 1rem; border-radius: var(--radius); margin-bottom: 1rem; }
.mailresult.ok { background: var(--go-soft); color: var(--go); }
.mailresult.bad { background: var(--stop-soft); color: var(--stop); }
.mailresult code { display: block; margin-top: .4rem; font-size: .8rem; color: var(--ink); opacity: .75; white-space: pre-wrap; overflow-wrap: anywhere; }
.histtabs { display: flex; gap: .35rem; flex-wrap: wrap; }
.histtabs .chip { border: 1px solid var(--line); background: var(--panel); cursor: pointer; }
.history { list-style: none; margin: 0; padding: 0; }
.history li + li { border-top: 1px solid var(--line); }
.history a { display: grid; grid-template-columns: 6.5rem 1fr auto; gap: .75rem; align-items: start; padding: .65rem .25rem; color: inherit; text-decoration: none; }
.history a:hover { background: var(--paper); }
.history .h-when { color: var(--wire); font-size: .9rem; white-space: nowrap; }
.history .h-what { min-width: 0; }
.history .h-what .small { display: block; margin-top: .15rem; }
.history .h-amt { text-align: right; white-space: nowrap; }
@media (max-width: 560px) { .history a { grid-template-columns: 1fr auto; } .history .h-when { grid-column: 1 / -1; } }
.histtabs .chip.ink, .usertabs .chip.ink { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.usertabs .chip { border: 1px solid var(--line); background: var(--panel); color: inherit; text-decoration: none; }
.readouts .v.over { color: var(--stop); }
.pcrop { margin-bottom: 1rem; }
.pc-now { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }
.pc-btns { display: flex; flex-direction: column; align-items: flex-start; gap: .4rem; }
.pc-pick { cursor: pointer; }
.pc-editor { margin-top: 1rem; max-width: 22rem; }
.pc-view { position: relative; width: 100%; aspect-ratio: 1; overflow: hidden; border-radius: var(--radius); background: #111; touch-action: none; cursor: grab; user-select: none; }
.pc-view:active { cursor: grabbing; }
.pc-view:focus-visible { outline: 3px solid var(--amp); outline-offset: 2px; }
.pc-view img { position: absolute; left: 0; top: 0; max-width: none; transform-origin: 0 0; pointer-events: none; }
.pc-ring { position: absolute; inset: 0; border-radius: 50%; box-shadow: 0 0 0 999px rgba(0,0,0,.55); border: 2px solid rgba(255,255,255,.85); pointer-events: none; }
.pc-tools { display: flex; align-items: center; gap: .75rem; margin-top: .6rem; flex-wrap: wrap; }
.pc-zoom { display: flex; align-items: center; gap: .5rem; flex: 1; min-width: 10rem; }
.pc-zoom input { flex: 1; }
.profile { overflow: hidden; }
.profile-band { height: 5.5rem; background: linear-gradient(120deg, var(--ink) 0%, #3a3f45 60%, var(--amp) 160%); }
.profile-body { padding: 0 1.5rem 1.5rem; }
.profile .person-head { margin-top: -2.75rem; align-items: flex-end; }
.profile .person-head .av.lg { box-shadow: 0 0 0 4px var(--panel); }
.profile .person-head h1 { margin-top: 2.9rem; }
.profile-actions { gap: .5rem; }
.profile-bio { margin: 1.25rem 0 0; max-width: 65ch; white-space: pre-line; line-height: 1.55; }
.skills { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .9rem; }
.skill { padding: .2rem .65rem; border-radius: 999px; background: var(--amp-soft); color: var(--amp-dark); font-size: .85rem; font-weight: 600; }
.profile-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(8rem, 1fr)); gap: .75rem; }
.profile-stats > div { display: flex; flex-direction: column; }
.profile-stats .v { font: 600 1.8rem/1.1 "Barlow Semi Condensed", sans-serif; }
@media (max-width: 560px) { .profile .person-head h1 { margin-top: .5rem; } .profile-body { padding: 0 1rem 1rem; } }
.px h3 { margin: 1.5rem 0 .25rem; font-size: 1.05rem; }
.px .pxhint { margin: 0 0 .6rem; }
.pxrows { display: grid; gap: .5rem; margin-bottom: .6rem; }
.pxrow { display: flex; gap: .5rem; align-items: center; }
.pxrow input { margin: 0; flex: 1; min-width: 0; }
.pxrow.exp input[name=exp_since] { flex: 0 0 8.5rem; }
.pxcert { border: 1px solid var(--line); border-radius: var(--radius); padding: .75rem .9rem .5rem; background: var(--paper); }
.pxfile { display: flex; flex-wrap: wrap; gap: .5rem 1rem; align-items: center; margin-bottom: .4rem; }
.pxfile input[type=file] { display: block; margin-top: .2rem; max-width: 100%; }
.pxfile .pxdel { margin-left: auto; color: var(--stop); }
.tagin { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; padding: .5rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); }
.tagin .skill button { border: 0; background: none; color: inherit; padding: 0 0 0 .15rem; font-size: 1rem; line-height: 1; cursor: pointer; min-height: 0; }
.tagin input { flex: 1; min-width: 9rem; border: 0; margin: 0; padding: .35rem; background: transparent; }
.tagin input:focus { outline: none; }
@media (max-width: 560px) { .pxrow.exp { flex-wrap: wrap; } .pxrow.exp input[name=exp_trade] { flex-basis: 100%; } }
.exp-line { display: flex; flex-wrap: wrap; gap: .25rem 1rem; margin-top: .3rem; font-size: .95rem; }
.certlist, .achlist { margin: 0; padding: 0; list-style: none; }
.certlist li { padding: .6rem 0 .6rem .8rem; border-left: 3px solid var(--go); }
.certlist li + li { margin-top: .5rem; }
.certlist li.soon { border-left-color: var(--amp); }
.certlist li.expired { border-left-color: var(--stop); }
.achlist li { padding: .35rem 0 .35rem 1.4rem; position: relative; }
.achlist li::before { content: "\2605"; position: absolute; left: 0; color: var(--amp); }
.tagsug { display: flex; flex-wrap: wrap; gap: .35rem; align-items: center; margin-top: .5rem; }
.tagsug .sug { padding: .2rem .6rem; border-radius: 999px; font-size: .85rem; border: 1px dashed var(--line); background: none; min-height: 0; color: var(--wire); }
.tagsug .sug:hover { border-color: var(--amp); color: var(--amp-dark); }
.mini-av { width: 1.4rem; height: 1.4rem; border-radius: 50%; object-fit: cover; vertical-align: -.35rem; margin: 0 .3rem 0 .15rem; }
.survey { max-width: 640px; margin-left: auto; margin-right: auto; }
.stars { border: 0; padding: 0; margin: .5rem 0 1rem; display: inline-flex; flex-direction: row-reverse; gap: .15rem; }
.stars legend { font-weight: 600; margin-bottom: .25rem; width: 100%; }
.stars input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.stars label { font-size: 2.6rem; line-height: 1; color: var(--line); cursor: pointer; padding: 0 .1rem; }
.stars input:checked ~ label, .stars label:hover, .stars label:hover ~ label { color: #f2a93b; }
.stars input:focus-visible + label { outline: 3px solid var(--amp); border-radius: 4px; }
.bigstars span, .starrow span { color: var(--line); }
.bigstars span.on, .starrow span.on { color: #f2a93b; }
.bigstars { font-size: 2.4rem; letter-spacing: .1rem; }
.starrow { font-size: 1.05rem; letter-spacing: .05rem; }
.google-ask { margin-top: 1.25rem; padding: 1.25rem; border-radius: var(--radius); background: var(--paper); }
.reviewlist { list-style: none; margin: 0; padding: 0; }
.reviewlist li { padding: 1rem 1.25rem; }
.reviewlist li + li { border-top: 1px solid var(--line); }
.reviewlist li.new { background: var(--amp-soft); }
.rv-comment { margin: .5rem 0; white-space: pre-line; }
.ratebar { display: grid; grid-template-columns: 2.2rem 1fr 2rem; gap: .5rem; align-items: center; font-size: .9rem; }
.ratebar .bar { height: .5rem; background: var(--paper); border-radius: 999px; overflow: hidden; }
.ratebar .bar span { display: block; height: 100%; background: #f2a93b; }
.survey-cta { margin-top: 1rem; padding: .9rem 1rem; border-radius: var(--radius); background: var(--paper); display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1rem; }
.ctastars a { font-size: 2rem; color: var(--line); text-decoration: none; padding: 0 .1rem; }
.ctastars:hover a { color: #f2a93b; }
.ctastars a:hover ~ a { color: var(--line); }
.pjrows { display: grid; gap: .5rem; margin-bottom: .6rem; }
.pjrow { display: grid; grid-template-columns: 1fr 4.5rem 7rem; gap: .5rem; }
.pjrow input { margin: 0; min-width: 0; }
.choice { border: 0; padding: 0; margin: 0 0 1rem; }
.choice legend { font-weight: 600; margin-bottom: .35rem; }
.choice label { display: inline-flex; align-items: center; gap: .4rem; margin: 0 .5rem .4rem 0; padding: .45rem .8rem; border: 1px solid var(--line); border-radius: 999px; font-weight: 500; cursor: pointer; }
.choice label:has(input:checked) { border-color: var(--amp); background: var(--amp-soft); color: var(--amp-dark); }
.choice input { margin: 0; accent-color: var(--amp); }
.choice label { min-height: 0; line-height: 1.2; width: auto; }
.choice input[type=radio], .choice input[type=checkbox] { width: auto; height: auto; min-height: 0; padding: 0; border: 0; box-shadow: none; }
.payrows { display: grid; gap: .6rem; margin-bottom: .6rem; }
.payrow { display: grid; grid-template-columns: 9.5rem 7rem 7.5rem 1fr auto; gap: .5rem; align-items: end; padding: .6rem .75rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); }
.payrow .field { margin: 0; }
.payrow .payx { margin-bottom: .55rem; }
.paysum { display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; margin: .75rem 0 1rem; font-size: .95rem; }
.paysum .over { color: var(--stop); }
.paysum .ok { color: var(--go); }
@media (max-width: 640px) { .payrow { grid-template-columns: 1fr 1fr; } .payrow .payx { grid-column: 1 / -1; justify-self: start; margin: 0; } }
.certthumb { display: inline-block; margin-top: .5rem; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: #fff; line-height: 0; box-shadow: 0 1px 2px rgba(0,0,0,.08); }
.certthumb img { display: block; width: 100%; max-width: 15rem; max-height: 12rem; object-fit: contain; }
.certthumb:hover { border-color: var(--amp); }
.certthumb.sm img { max-width: 8rem; max-height: 6rem; }
.certthumb .certfile, .certfile { display: inline-block; padding: .5rem .75rem; line-height: 1.3; font-size: .9rem; }
.panelrows { display: grid; gap: .6rem; margin-bottom: .6rem; }
.panelrow { display: grid; grid-template-columns: 1.3fr 5.5rem 1.2fr 1fr; gap: .5rem; align-items: end; padding: .6rem .75rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); }
.panelrow .field { margin: 0; }
.panelrow > button { margin-bottom: .55rem; justify-self: start; }
.panelrow .field:has([name=p_loc]) { grid-column: span 2; }
@media (max-width: 760px) { .panelrow { grid-template-columns: 1fr 1fr; } .panelrow .field:has([name=p_loc]) { grid-column: auto; } .panelrow > button { grid-column: 1 / -1; justify-self: start; margin: 0; } }
button.chip { border: 1px solid var(--line); background: var(--panel); cursor: pointer; min-height: 0; }
.svclist { list-style: none; margin: 0; padding: 0; display: grid; gap: .6rem; }
.svclist li a { display: block; padding: .75rem 1rem; border: 1px solid var(--line); border-left: 4px solid var(--amp); border-radius: var(--radius); color: inherit; text-decoration: none; }
.svclist li a:hover { background: var(--paper); }
.svclist .svc-panels { display: flex; flex-wrap: wrap; gap: .35rem; margin-top: .4rem; }
.svclist .svc-panels span { padding: .15rem .55rem; border-radius: 999px; background: var(--paper); border: 1px solid var(--line); font-size: .82rem; }

/* Smart Management Modules on the generator form (1.13) */
.smmrow { display: grid; grid-template-columns: 5.5rem 1.4fr 5.5rem 1.2fr auto; gap: .5rem; align-items: end; padding: .6rem .75rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); }
.smmrow .field { margin: 0; }
.smmrow .link { margin-bottom: .55rem; }
.smmquick { gap: .4rem; align-items: center; margin-bottom: .6rem; flex-wrap: wrap; }
.smmquick input { width: 4.5rem; }
@media (max-width: 720px) { .smmrow { grid-template-columns: 1fr 1fr; } .smmrow > .link { grid-column: 1 / -1; justify-self: start; margin: 0; } }

/* gate code (1.13.2) */
.gatecode { margin: .35rem 0; }
.gatecode strong { font-size: 1.15rem; letter-spacing: .04em; font-variant-numeric: tabular-nums; }

/* contact card (1.14) */
.cc-h { font-size: 1.05rem; margin: 0 0 .6rem; }
.cc-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0 1rem; align-items: start; }
.cc-grid .field { margin-bottom: .7rem; }
.cc-first { grid-column: 1; grid-row: 1; } .cc-last { grid-column: 2; grid-row: 1; }
.cc-disp { grid-column: 1 / span 2; grid-row: 2; }
.cc-emails { grid-column: 1 / span 2; grid-row: 3 / span 3; }
.cc-phones { grid-column: 3; grid-row: 1 / span 5; }
.cc-side { grid-column: 4; grid-row: 1 / span 5; }
.cc-xrow { display: flex; gap: .4rem; align-items: center; }
.cc-xrow input { flex: 1; min-width: 0; }
.cc-xrow select { width: auto; flex: 0 0 auto; }
.cc-xrow .link { flex: 0 0 auto; }
.pillbtn { border-radius: 999px; padding: .35rem .9rem; font-weight: 600; color: var(--amp-dark); border-color: var(--amp); background: transparent; margin-bottom: .7rem; }
.cc-type { margin-bottom: .4rem; }
.dnscheck { margin-top: .2rem; }
.dnstag { display: inline-block; background: var(--stop-soft); color: var(--stop); font-weight: 600; font-size: .85em; padding: .05rem .5rem; border-radius: 4px; }
.dnsbanner { background: var(--stop-soft); color: var(--stop); border: 1px solid var(--stop); border-radius: var(--radius); padding: .7rem 1rem; margin: 0 0 1rem; }
.dnsbanner strong { color: var(--stop); }
.btn.off, a.btn.off { opacity: .45; pointer-events: none; }
.cc-facts { display: flex; flex-wrap: wrap; gap: .3rem .5rem; margin: .35rem 0 0; }
.cc-facts .tag { font-weight: 500; }
.cc-lines div { margin-bottom: .15rem; }
.cc-lines .lbl { display: inline-block; min-width: 3.6rem; color: var(--wire); font-size: .85rem; }
@media (max-width: 980px) {
  .cc-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cc-first, .cc-last, .cc-disp, .cc-emails, .cc-phones, .cc-side { grid-row: auto; }
  .cc-disp, .cc-emails { grid-column: 1 / -1; }
  .cc-phones { grid-column: 1; } .cc-side { grid-column: 2; }
}
@media (max-width: 600px) {
  .cc-grid { grid-template-columns: 1fr; }
  .cc-first, .cc-last, .cc-disp, .cc-emails, .cc-phones, .cc-side { grid-column: 1; }
}
.cc-xrow .xbtn { flex: 0 0 auto; width: 2.2rem; min-height: 2.2rem; padding: 0; font-size: 1.3rem; line-height: 1; color: var(--stop); background: transparent; border-color: transparent; }
.cc-xrow select { max-width: 5.6rem; }
h1 .dnstag { font-size: .5em; }
.cc-xrow button.xbtn { font-size: 1.45rem; font-weight: 600; width: 1.8rem; }
.cc-xrow select { max-width: 4.9rem; padding-left: .45rem; padding-right: .2rem; }

/* email log on documents (1.14.2) */
.emailog ul { list-style: none; padding: 0; margin: 0; }
.emailog li { padding: .35rem 0; border-top: 1px solid var(--line); font-size: .95rem; }
.flash.ok { background: var(--go-soft); color: var(--go); }

/* version at the bottom of every page (1.14.3) */
.appver { text-align: center; color: var(--wire); font-size: .8rem; padding: 1.5rem 1rem 1.25rem; }
@media print { .appver { display: none; } }

/* no signal, saved copies, and the test outbox (1.16) */
.netbar { position: sticky; top: 0; z-index: 60; background: #fff4d6; color: #6b4a00; border-bottom: 1px solid #e8c766; padding: .55rem 1rem; font-size: .92rem; }
@media (prefers-color-scheme: dark) { .netbar { background: #3a2e10; color: #f1d58a; border-color: #6b5420; } }
.outpill { position: fixed; right: 1rem; bottom: calc(1rem + env(safe-area-inset-bottom)); z-index: 70; background: var(--amp); color: #fff; font-weight: 600; text-decoration: none;
           padding: .6rem 1rem; border-radius: 999px; box-shadow: 0 2px 10px rgba(0,0,0,.25); }
.outpill.stuck { background: var(--stop); }
.nettoast { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(4.5rem + env(safe-area-inset-bottom)); z-index: 80; background: var(--go); color: #fff;
            padding: .6rem 1rem; border-radius: var(--radius); box-shadow: 0 2px 10px rgba(0,0,0,.25); font-weight: 500; max-width: 90vw; }
.oblist { list-style: none; padding: 0; margin: 0; }
.oblist li { padding: .7rem 0; border-top: 1px solid var(--line); }
.oblist li:first-child { border-top: 0; }

/* price book (1.17) */
.pbsearch { margin: 0 0 1rem; }
.pbsearch input { width: 100%; }
.pbtable td { vertical-align: top; }
.pbtable td.num { white-space: nowrap; }
.pbsec h2 { margin-top: 0; }
.pbrows { display: grid; gap: .6rem; margin-bottom: .6rem; }
.pbrow { display: grid; grid-template-columns: 2.4fr 1.3fr .8fr .8fr .6fr .8fr; gap: .5rem; align-items: end; padding: .6rem .75rem;
         border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); }
.pbrow .field { margin: 0; }
.pbrow .field label { font-size: .8rem; }
.pbrow .pb-notes { grid-column: 1 / span 4; }
.pbrow .pb-flags { grid-column: 5 / span 2; display: flex; gap: .75rem; align-items: center; justify-content: flex-end; padding-bottom: .4rem; }
.pbrow .pb-flags select { width: auto; min-height: 0; padding: .3rem .4rem; font-size: .85rem; }
.pbrow .pb-flags .check input { width: auto; }
.pbrow.gone { opacity: .45; }
.danger-text { color: var(--stop); }
.pbsave { position: sticky; bottom: 0; background: var(--paper); padding: .75rem 0; z-index: 5; }
@media (max-width: 760px) {
  .pbrow { grid-template-columns: 1fr 1fr 1fr; }
  .pbrow .pb-desc, .pbrow .pb-notes { grid-column: 1 / -1; }
  .pbrow .pb-cat { grid-column: 1 / span 2; }
  .pbrow .pb-flags { grid-column: 1 / -1; justify-content: space-between; }
}
.savedpick .matpick { display: inline-flex; align-items: center; gap: .4rem; margin-left: .25rem; font-size: .9rem; white-space: nowrap; }
.savedpick .matpick input { width: auto; min-height: 0; }
.pbtable td.num { width: 7.5rem; }
@media (max-width: 600px) {
  .pbtable thead { display: none; }
  .pbtable, .pbtable tbody, .pbtable tr, .pbtable td { display: block; width: auto; }
  .pbtable tr.pbline { padding: .6rem 0; border-top: 1px solid var(--line); display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 0 .5rem; }
  .pbtable tr.pbline td { border: 0; padding: 0; text-align: left; width: auto; }
  .pbtable tr.pbline td:first-child { grid-column: 1 / -1; margin-bottom: .25rem; }
  .pbtable tr.pbline td.num::before { display: block; font-size: .75rem; color: var(--wire); }
  .pbtable tr.pbline td:nth-child(2)::before { content: "Labor"; }
  .pbtable tr.pbline td:nth-child(3)::before { content: "Materials"; }
  .pbtable tr.pbline td:nth-child(4)::before { content: "With materials"; }
  .pbtable tr.pbline[hidden] { display: none; }
}

/* time clock (1.18) */
.clockbar { display: flex; flex-direction: column; gap: .35rem; margin: 0 0 1rem; }
.clockbar a { display: flex; align-items: center; gap: .5rem; background: var(--go-soft); color: var(--go); font-weight: 600; text-decoration: none;
              padding: .55rem .9rem; border-radius: var(--radius); border: 1px solid var(--go); }
.clockbar .dot, .clockrow.on .tag::before { width: .6rem; height: .6rem; border-radius: 50%; background: var(--go); display: inline-block; animation: tcpulse 1.6s infinite; }
@keyframes tcpulse { 50% { opacity: .3; } }
.clockrow { display: flex; justify-content: space-between; align-items: center; gap: .75rem; padding: .6rem .75rem; border: 1px solid var(--go);
            background: var(--go-soft); border-radius: var(--radius); margin-bottom: .6rem; }
.clockrow .tag { background: var(--go); color: #fff; }
.clockstart { margin: .25rem 0 .5rem; }
.timelog summary { cursor: pointer; font-weight: 600; margin: .5rem 0; }
.timebill { border-top: 1px solid var(--line); margin-top: .5rem; }
.timereport td { vertical-align: top; }

/* drag to reorder the price book (1.18.2) */
.pbrow { position: relative; padding-left: 2.4rem; }
.pbgrip { position: absolute; left: .3rem; top: 50%; transform: translateY(-50%); width: 1.8rem; height: 3rem; min-height: 0; padding: 0;
          border: 0; background: transparent; color: var(--wire); font-size: 1.1rem; letter-spacing: -.2em; cursor: grab; touch-action: none; }
.pbgrip:hover, .pbgrip:focus-visible { color: var(--amp-dark); background: var(--amp-soft); border-radius: 4px; }
.pbrow.dragging { opacity: .35; outline: 2px dashed var(--amp); }
.pbrow.moved { box-shadow: 0 0 0 2px var(--amp); transition: box-shadow .8s; }
.pbghost { position: fixed; z-index: 100; pointer-events: none; box-shadow: 0 10px 28px rgba(0,0,0,.28); opacity: .95; cursor: grabbing; }
.pbrows:empty { min-height: 3rem; border: 2px dashed var(--line); border-radius: var(--radius); }
.pbsave #pbdirty { margin-right: auto; color: var(--amp-dark); }

/* 1.19: location check on the time clock, helpers on a visit */
.tag.geo-far { background: var(--stop-soft); color: var(--stop); border-color: transparent; }
.tag.geo-unsure { background: transparent; color: var(--wire); border-color: var(--line); }
.geodetail { margin: .4rem 0; padding: .5rem .6rem; border-radius: 8px; background: var(--paper); border: 1px solid var(--line); }
.geodetail ul { margin: .3rem 0 0; padding-left: 1.1rem; }
.geodetail .geomap { display: block; width: 100%; max-width: 600px; height: auto; margin-top: .5rem; border-radius: 6px; }
.crewpick { border: 0; padding: 0; margin: 0 0 1rem; }
.crewpick legend { font-weight: 600; font-size: .9rem; margin-bottom: .25rem; }
.crewpick .check { display: inline-flex; margin-right: 1rem; }
.visitphotos label.btn { cursor: pointer; }

/* 1.20: discount on estimates */
.discbox { display: flex; gap: .75rem; align-items: flex-end; flex-wrap: wrap; margin-top: 1rem; }
.discbox .field { margin: 0; }
.totals .disc span:last-child { color: var(--go); }
.bonuslist { margin: .5rem 0 0; padding-left: 1.1rem; }
.discbox .discwhy { flex: 1 1 14rem; }
.addlines .savedpick { min-width: 0; max-width: 100%; }

/* 1.21: call scripts */
.callcol { display: flex; flex-direction: column; gap: 1rem; min-width: 0; }
.callcol > .panel { margin: 0; }
.scriptchips { display: flex; flex-wrap: wrap; gap: .4rem; margin: .6rem 0 .8rem; }
.schip { cursor: pointer; font: inherit; font-size: .9rem; font-weight: 600; padding: .35rem .75rem; border-radius: 999px; border: 1px solid var(--line); background: var(--panel); color: var(--ink); min-height: 0; width: auto; }
.schip.on { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.script h3 { margin: 0; font-size: 1.05rem; }
.script .lbl { display: block; font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--wire); margin-bottom: .2rem; }
.script .say { border-left: 3px solid var(--amp); background: var(--amp-soft); padding: .55rem .75rem; border-radius: 0 8px 8px 0; margin: .6rem 0; }
.script .say p { margin: 0; font-size: 1.02rem; line-height: 1.45; }
.script .say.close { border-left-color: var(--go); background: var(--go-soft); }
.script .ask ol { margin: .2rem 0 .4rem; padding-left: 1.3rem; }
.script .ask li { margin: .25rem 0; }
.script .pushback { margin: .6rem 0; }
.script .pushback details { border: 1px solid var(--line); border-radius: 8px; padding: .45rem .7rem; margin: .35rem 0; background: var(--panel); }
.script .pushback summary { cursor: pointer; font-weight: 600; }
.script .pushback p { margin: .4rem 0 .1rem; }
.script .tips { color: var(--wire); margin: .6rem 0 0; }
.obrow { display: grid; grid-template-columns: 1fr 2fr auto; gap: .5rem; align-items: start; margin-bottom: .5rem; }
@media (max-width: 640px) { .obrow { grid-template-columns: 1fr; } }
.scriptlist { list-style: none; margin: 0; padding: 0; }
.scriptlist li { padding: .75rem 1rem; border-bottom: 1px solid var(--line); }
.scriptlist li:last-child { border-bottom: 0; }

/* 1.24: portal service request */
.kindpick { border: 0; padding: 0; margin: 0 0 1rem; }
.kindpick legend { font-weight: 600; margin-bottom: .35rem; }
.kindpick .check { display: flex; padding: .3rem 0; }

/* 1.25: view as another role */
.previewbar { position: sticky; top: 0; z-index: 60; display: flex; gap: .75rem; align-items: center; justify-content: space-between;
  flex-wrap: wrap; padding: .55rem 1rem; background: #6b3fa0; color: #fff; font-size: .92rem; }
.previewbar form { margin: 0; }
.previewbar button { min-height: 0; padding: .35rem .8rem; background: #fff; color: #4a2a72; border-color: #fff; }
.viewas { position: relative; font-size: .85rem; }
.viewas summary { cursor: pointer; color: inherit; opacity: .85; list-style: none; padding: .15rem 0; }
.viewas summary::-webkit-details-marker { display: none; }
.viewas .viewmenu { display: flex; flex-direction: column; gap: .15rem; padding: .4rem 0; }
.viewas .viewmenu a, .viewas .viewmenu button { color: inherit; text-align: left; font: inherit; padding: .2rem 0; text-decoration: none; }
.viewas .viewmenu form { margin: 0; }
.top .who .viewas summary, .top .who .viewas .viewmenu a, .top .who .viewas .viewmenu button { padding: .3rem .75rem; border-radius: var(--radius); background: none; border: 0; width: 100%; }
.top .who .viewas .viewmenu a:hover, .top .who .viewas .viewmenu button:hover { background: rgba(255,255,255,.1); }

/* 1.26: generator problem reports */
.tag.emergency { background: var(--stop); color: #fff; border-color: var(--stop); }
.portalbtns { gap: .5rem; flex-wrap: wrap; margin-bottom: .75rem; }
.emergencybox { padding: .5rem .7rem; border: 1px solid var(--stop); border-radius: 8px; background: var(--stop-soft); }
img.reqphoto { max-width: 260px; width: 100%; height: auto; border-radius: 6px; border: 1px solid var(--line); }
.nudge.urgent { background: var(--stop); color: #fff; }

/* customer portal */
/* 1.28: staff video calls */
.joincall { margin-top: .4rem; display: inline-flex; }
.callbtn { white-space: nowrap; }

/* 1.31: editable test fields */
.tfrow { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) 6.5rem; gap: .5rem; align-items: center; padding: .45rem 0; border-top: 1px solid var(--line); }
.tfrow:first-child { border-top: 0; }
.tfrow .tflabel { margin: 0; font-weight: 500; }
.tfrow .tfval, .tfrow .tfstat { margin: 0; }
.tfrow.gone .tflabel { color: var(--wire); }
.tfstat option[value=fail] { color: var(--stop); }
.failnote { background: var(--stop-soft); color: var(--stop); padding: .5rem .75rem; border-radius: var(--radius); }
@media (max-width: 560px) { .tfrow { grid-template-columns: 1fr 6rem; } .tfrow .tflabel { grid-column: 1 / -1; } }
.tfview td.st { width: 5rem; text-align: right; }
.tabs { display: flex; gap: .25rem; flex-wrap: wrap; margin-bottom: 1rem; }
.tabs a { padding: .45rem .8rem; border-radius: 999px; border: 1px solid var(--line); text-decoration: none; color: var(--ink); background: var(--panel); font-weight: 600; font-size: .92rem; }
.tabs a.on { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.tabs a.on .muted { color: inherit; opacity: .7; }
.tfedit, .tfedit-head { display: grid; grid-template-columns: 3.2rem minmax(0, 2fr) minmax(0, .7fr) 8rem 4.2rem 4.2rem 9rem 6rem; gap: .5rem; align-items: center; padding: .35rem 0; }
.tfedit .tfhintin { grid-column: 2 / -2; font-size: .85rem; }
.tfedit { border-bottom: 1px solid var(--line); }
.tfedit-head { font-size: .8rem; font-weight: 600; color: var(--wire); }
.tfedit input, .tfedit select { margin: 0; }
.tfedit.gone input[name=label] { text-decoration: line-through; opacity: .6; }
.tfmove { display: flex; gap: .2rem; } .tfmove button { padding: .2rem .35rem; min-height: 0; font-size: 1.05rem; }
@media (max-width: 640px) { .tfedit-head { display: none; } .tfedit { grid-template-columns: 5rem 1fr auto; border-bottom: 1px solid var(--line); padding: .6rem 0; }
  .tfedit input[name=label] { grid-column: 2 / -1; } }
/* 1.32 Tests page */
.ttype.off { opacity: .7; }
.tt-head { display: flex; gap: .5rem; align-items: center; margin-bottom: .6rem; }
.tt-head .tt-name { font-weight: 600; font-size: 1.05rem; margin: 0; flex: 1; }
.tt-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 8.5rem), 1fr)); gap: .6rem .75rem; }
.tt-grid label { margin: 0; font-weight: 600; font-size: .88rem; display: flex; flex-direction: column; gap: .25rem; }
.tt-grid label[hidden] { display: none; }
.tt-grid select, .tt-grid input { margin: 0; font-weight: 400; }
.tt-unit { display: flex; align-items: center; gap: .4rem; font-weight: 400; }
.tt-unit input { width: 5rem; }
.tt-fixed { font-weight: 400; padding: .55rem 0; color: var(--wire); }
.wkhead { font-size: 1rem; margin: 1rem 0 .4rem; }
/* 1.32 parts, job costs, profit */
.ptrow, .pthead { display: grid; grid-template-columns: minmax(0, 2.2fr) minmax(0, 1fr) minmax(0, 1fr) 6rem 6rem minmax(0, 1fr) 5.5rem; gap: .45rem; align-items: center; padding: .3rem 0; }
.pthead { font-size: .8rem; font-weight: 600; color: var(--wire); }
.ptrow input, .ptrow select { margin: 0; }
.ptrow.gone input[name=name] { text-decoration: line-through; opacity: .6; }
.iprow { display: grid; grid-template-columns: minmax(0, 1fr) 5rem 5.5rem 6rem; gap: .5rem; align-items: center; padding: .4rem 0; border-bottom: 1px solid var(--line); }
.iprow input { margin: 0; }
.money-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr)); gap: .75rem; }
.money-grid div { display: flex; flex-direction: column; gap: .15rem; }
.money-grid span { font-size: .82rem; color: var(--wire); font-weight: 600; }
.money-grid strong { font: 600 1.35rem/1.1 "Barlow Semi Condensed", sans-serif; }
.money-grid .loss, td.loss { color: #ad3838; }
.money-grid .gain { color: #2e7a4d; }
.matform { display: grid; grid-template-columns: minmax(0, 2fr) 5rem 6.5rem minmax(0, 1.4fr) auto; gap: .45rem; align-items: end; margin-top: .75rem; }
.matform .field { margin: 0; }
@media (max-width: 640px) {
  .pthead { display: none; }
  .ptrow { grid-template-columns: 1fr 1fr; border-bottom: 1px solid var(--line); padding: .6rem 0; }
  .ptrow input[name=name] { grid-column: 1 / -1; }
  .iprow { grid-template-columns: 1fr 4.5rem; }
  .matform { grid-template-columns: 1fr 1fr; }
  .matform .mf-desc, .matform .mf-note { grid-column: 1 / -1; }
}
.pb-parts { display: block; padding: .55rem .2rem; font-size: .88rem; white-space: nowrap; }
.pb-parts.on { font-weight: 600; }
.pbrow input[readonly] { background: var(--paper); color: var(--wire); }
.xbtn { font-size: 1.3rem; line-height: 1; padding: .1rem .4rem; }
/* 1.33 pay online */
.paybox .payopt { border-top: 1px solid var(--line); padding-top: .75rem; margin-top: .75rem; }
.paybox > p + .payopt { border-top: 0; padding-top: 0; }
.paybox .payopt h3 { margin: 0 0 .4rem; font-size: 1rem; }
.paybox #paypal-buttons { max-width: 420px; }
.paybox form button.go { width: 100%; max-width: 420px; }
.zelle-to { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: .6rem .8rem; max-width: 420px; word-break: break-all; }
.zelle-claim { border: 1px solid var(--amp); background: var(--amp-soft); border-radius: var(--radius); padding: .75rem; margin-bottom: 1rem; }
.paybox .pp-later { max-width: 420px; margin: .25rem 0 .75rem; min-height: 1.2rem; }
/* 1.38 forms */
.formrow { display: flex; justify-content: space-between; align-items: center; gap: .75rem; padding: .55rem 0; border-bottom: 1px solid var(--line); }
.formrow.off { opacity: .6; }
.ffrow { display: grid; grid-template-columns: 3.2rem minmax(0, 2.2fr) 9rem 5rem minmax(0, 1.6fr) 6.5rem 5.5rem; gap: .45rem; align-items: center; padding: .3rem 0; }
.ffrow input, .ffrow select { margin: 0; }
.ffrow input[hidden], .ffrow label[hidden] { display: none; }
.ffrow.head input[name=flabel] { font-weight: 700; }
.ffrow.gone input[name=flabel] { text-decoration: line-through; opacity: .6; }
.formfill h2 { margin: 1.25rem 0 .5rem; padding-top: .75rem; border-top: 1px solid var(--line); }
.formfill h2:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.formfill .req { color: #ad3838; }
.segs { display: flex; flex-wrap: wrap; gap: .35rem; }
.seg { margin: 0; cursor: pointer; }
.seg input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.seg span { display: inline-block; padding: .5rem .9rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); font-weight: 600; min-width: 3rem; text-align: center; }
.seg input:checked + span { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.seg.fail input:checked + span { background: #ad3838; border-color: #ad3838; }
.seg input:focus-visible + span { outline: 2px solid var(--amp); outline-offset: 2px; }
.seg.clear span { min-width: 2rem; font-weight: 400; color: var(--wire); }
.ffbar { position: sticky; bottom: 0; background: var(--panel); padding: .75rem 0; margin-top: 1rem; border-top: 1px solid var(--line); }
.ffval { padding: .3rem 0; white-space: pre-line; }
@media (max-width: 640px) {
  .ffrow { grid-template-columns: 3rem 1fr 1fr; border-bottom: 1px solid var(--line); padding: .6rem 0; }
  .ffrow input[name=flabel], .ffrow input[name=fopts] { grid-column: 2 / -1; }
}
/* 1.38 install tools */
.toolgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr)); gap: 1rem; }
.toolcard { display: flex; flex-direction: column; gap: .35rem; text-decoration: none; color: var(--ink); margin: 0; }
.toolcard strong { font: 600 1.2rem/1.2 "Barlow Semi Condensed", sans-serif; color: var(--amp-dark); }
.toolcard span { color: var(--wire); font-size: .92rem; }
.toolcard:hover { border-color: var(--amp); }
.result .steps { padding-left: 1.2rem; margin: .25rem 0; } .result .steps li { margin: .2rem 0; }
.result tr.pick td { font-weight: 700; background: var(--amp-soft); }
.loadgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr)); gap: .4rem 1rem; }
.loadrow { display: grid; grid-template-columns: 1fr 4rem; gap: .5rem; align-items: center; margin: 0; font-weight: 400; }
.loadrow input { margin: 0; text-align: center; }
.startest { border-top: 1px solid var(--line); margin-top: 1rem; padding-top: 1rem; }
.crsearch { margin-bottom: 1rem; max-width: 30rem; }
.cr .plainlist li { margin: .35rem 0; } .crtable { max-width: 36rem; margin-bottom: .75rem; }
.boardrow { display: grid; grid-template-columns: minmax(12rem, 1.2fr) 3fr auto; gap: .75rem; align-items: center; padding: .65rem 0; border-bottom: 1px solid var(--line); }
.b-chips { display: flex; flex-wrap: wrap; gap: .3rem; } .b-chips .chip { font-size: .78rem; }
.b-act { display: flex; gap: .35rem; }
.tally a.chip { text-decoration: none; } .tally a.chip.on { outline: 2px solid var(--ink); }
.reqdl { display: grid; grid-template-columns: 9rem 1fr; gap: .4rem 1rem; margin: .75rem 0 0; }
.reqdl dt { font-weight: 600; color: var(--wire); } .reqdl dd { margin: 0; }
@media (max-width: 640px) { .boardrow { grid-template-columns: 1fr; } .reqdl { grid-template-columns: 1fr; } }
.tally a.chip.overdue { background: var(--stop); color: #fff; border-color: var(--stop); }
.tally a.chip.ok { background: var(--go-soft); color: var(--go); }
.tally a.chip.soon, .tally a.chip.never { background: var(--amp-soft); color: var(--amp-dark); }
.seg.clear input:checked + span { background: var(--paper); color: var(--wire); border-color: var(--line); }

/* SwathRoute additions */
.top .brand .wordmark { display: block; font: 700 1.15rem/1.15 "Barlow Semi Condensed", "Barlow", sans-serif; color: #fff; text-decoration: none; padding: .35rem .25rem; max-width: 220px; }
.public .head .wordmark, .login .wordmark { display: block; font: 700 1.8rem/1.15 "Barlow Semi Condensed", "Barlow", sans-serif; color: var(--amp-dark); text-align: center; margin: .25rem 0 .75rem; }
.tfhint { display: block; font-size: .8rem; color: var(--wire); font-weight: 400; }
.tfwarn { display: block; font-size: .8rem; color: var(--stop); font-weight: 600; }
.tfrow.tfcheck .tfval { visibility: hidden; }
.calcnote { background: var(--amp-soft); border-radius: var(--radius); padding: .4rem .6rem; }
.warnbox { background: var(--amp-soft); border-left: 3px solid var(--amp); padding: .4rem .6rem; border-radius: var(--radius); }
.recbox { border-left: 4px solid var(--amp); }
.addref { margin-top: .75rem; }
.addref summary { cursor: pointer; font-weight: 600; color: var(--amp-dark); }
.addref form { margin-top: .75rem; }
.tag.member { background: var(--amp-soft); color: var(--amp-dark); }
.statgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .75rem; margin-bottom: 1rem; }
.statgrid .stat { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: .6rem .8rem; }
.statgrid .stat strong { display: block; font-size: 1.4rem; }
.statgrid .stat span { color: var(--wire); font-size: .85rem; }
/* route planner (1.2) */
.routegrid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 1rem; align-items: start; }
@media (max-width: 900px) { .routegrid { grid-template-columns: 1fr; } }
.routelist { list-style: none; margin: .75rem 0 0; padding: 0; }
.routelist li { display: flex; gap: .7rem; padding: .55rem 0; border-top: 1px solid var(--line); }
.routelist li:first-child { border-top: 0; }
.routelist.compact li { padding: .35rem 0; }
.routelist .pinlbl { flex: 0 0 1.7rem; height: 1.7rem; border-radius: 50%; background: var(--ink); color: var(--panel, #fff); display: grid; place-items: center; font-weight: 700; font-size: .8rem; margin-top: .1rem; }
.routelist li.shop .pinlbl { background: var(--wire); }
.routelist li.done { opacity: .6; }
.routelist li.late .pinlbl { background: var(--stop); }
.routelist li.here .pinlbl, .routelist li.next .pinlbl { background: var(--amp); }
.routelist .leg { margin-bottom: .15rem; }
.routelist .warn { color: #a35a00; }
.routemap { display: block; width: 100%; max-height: 460px; height: auto; background: var(--paper); border-radius: 8px; }
.routemap polyline { fill: none; stroke-width: 4; stroke-linejoin: round; }
.routemap polyline.booked { stroke: var(--wire); }
.routemap polyline.better { stroke: var(--amp); stroke-dasharray: 8 6; }
.routemap .pin circle { fill: var(--ink); stroke: var(--panel, #fff); stroke-width: 2; }
.routemap .pin.shop circle { fill: var(--wire); }
.routemap .pin.late circle { fill: var(--stop); }
.routemap .pin.done circle { opacity: .5; }
.routemap .pin text { fill: #fff; font: 700 14px system-ui, sans-serif; text-anchor: middle; }
.tag.late { background: var(--stop-soft); color: var(--stop); border-color: transparent; }
.routebar select { width: auto; min-width: 12rem; }
.key { display: inline-block; width: 1.4rem; height: 0; border-top: 3px solid var(--wire); vertical-align: middle; }
.key.better { border-top: 3px dashed var(--amp); }
.routebar .btn { min-width: 2.5rem; justify-content: center; }
.day header .routelink { margin-left: auto; margin-right: .35rem; color: var(--amp-dark); text-decoration: none; }
.day header .routelink + .add { margin-left: 0; }
.key.better.solid { border-top-style: solid; }
.pindot { display: inline-block; width: .7rem; height: .7rem; border-radius: 50%; background: var(--stop); vertical-align: middle; }
img.routemap { aspect-ratio: 640 / 420; object-fit: cover; }

/* 1.2.7: bank wire instructions on the invoice */
.wire-to { display: grid; grid-template-columns: max-content 1fr; gap: .25rem 1rem; margin: 0; padding: .6rem .8rem; background: var(--paper, #f4f5f7); border-radius: 8px; }
.wire-to dt { color: var(--muted, #666); font-size: .875rem; }
.wire-to dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.wire-warn { border-left: 3px solid #ff9f0a; padding-left: .6rem; margin: .6rem 0; }

/* 1.2.7: the demo's stand-in PayPal and Venmo buttons */
.demo-pp { display: grid; gap: .5rem; max-width: 26rem; }
.demo-pp button { min-height: 44px; border-radius: 6px; border: 0; font-weight: 700; font-size: 1rem; cursor: pointer; }
.demo-pp .pp-paypal { background: #ffc439; color: #111; }
.demo-pp .pp-venmo { background: #008cff; color: #fff; }
.demo-pp .pp-card { background: #2c2e2f; color: #fff; }

/* the demo pay buttons stack with a little room */
.payopt .go + .go { margin-top: .5rem; }

/* 1.2.7: the public demo's bar and guided tour */
.demobar { position: sticky; top: 0; z-index: 60; display: flex; flex-wrap: wrap; gap: .5rem 1rem; align-items: center; justify-content: space-between;
  padding: .5rem 1rem; background: #12355b; color: #fff; font-size: .9rem; }
.demobar .demoviews { display: flex; flex-wrap: wrap; gap: .25rem; align-items: center; }
.demobar .demoviews a { color: #fff; text-decoration: none; padding: .2rem .55rem; border-radius: 999px; border: 1px solid rgba(255,255,255,.35); }
.demobar .demoviews a.on { background: #fff; color: #12355b; border-color: #fff; font-weight: 600; }
.demobar .btn.primary { min-height: 0; padding: .35rem .9rem; background: #f5a623; border-color: #f5a623; color: #1b1b1b; }
@media (max-width: 640px) { .demobar { font-size: .82rem; } }
.tour { position: fixed; right: 1rem; bottom: 1rem; z-index: 70; width: min(24rem, calc(100vw - 2rem)); background: var(--panel);
  color: inherit; border: 2px solid #f59e0b; border-radius: 10px; box-shadow: 0 10px 30px rgba(0,0,0,.25); padding: 1rem 1.1rem; }
.tour h2 { margin: .1rem 0 .4rem; font-size: 1.15rem; }
.tour p { margin: 0 0 .75rem; }
.tour .tour-n { margin: 0; }
.tour-spot { outline: 3px solid #f59e0b !important; outline-offset: 4px; border-radius: 6px; scroll-margin: 6rem; }
@media (max-width: 640px) { .tour { left: .5rem; right: .5rem; bottom: .5rem; width: auto; padding: .7rem .85rem; font-size: .9rem; }
  .tour h2 { font-size: 1rem; } .tour p { margin-bottom: .5rem; } }
.tour .row { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; }

/* ---------- SwathRoute: the landscape designer ---------- */
.ba { position: relative; width: 100%; background: #2b2f33; border-radius: var(--radius); overflow: hidden; user-select: none; -webkit-user-select: none; }
.ba img, .ba svg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: fill; pointer-events: none; }
.ba .m-text, .sitemap .m-text { fill: #fff; font-weight: 600; font-family: "Barlow", sans-serif; paint-order: stroke; stroke: rgba(0,0,0,.75); stroke-width: 4; stroke-linejoin: round; pointer-events: none; }
.ba-line { position: absolute; top: 0; bottom: 0; width: 3px; margin-left: -1.5px; background: #fff; box-shadow: 0 0 6px rgba(0,0,0,.6); pointer-events: none; }
.ba-line span { position: absolute; top: 50%; left: 50%; width: 38px; height: 38px; margin: -19px 0 0 -19px; border-radius: 50%; background: #fff; box-shadow: 0 1px 6px rgba(0,0,0,.5); }
.ba-line span::before { content: "\2194"; position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: #23262a; font-weight: 700; }
.ba-tag { position: absolute; top: .6rem; padding: .15rem .6rem; border-radius: 999px; background: rgba(0,0,0,.65); color: #fff; font-size: .85rem; font-weight: 600; pointer-events: none; }
.ba-tag.l { left: .6rem; } .ba-tag.r { right: .6rem; }
.ba-range { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; }
.dz-tools { display: flex; flex-wrap: wrap; gap: .5rem .9rem; margin: .8rem 0 .3rem; align-items: center; }
.dz-tools .tgroup { display: flex; flex-wrap: wrap; gap: .3rem; align-items: center; }
.dz-tools .tgroup > span { font-size: .78rem; text-transform: uppercase; letter-spacing: .05em; color: var(--wire); margin-right: .1rem; }
.dz-tools button { min-height: 38px; padding: .25rem .7rem; font-size: .92rem; }
.dz-tools button.on { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.dz-tools button.go { background: var(--go); color: #fff; border-color: var(--go); }
.dz-tools button i { display: inline-block; width: .8em; height: .8em; border-radius: 2px; margin-right: .35em; vertical-align: -.05em; border: 1px solid rgba(0,0,0,.35); }
.dz-wrap { display: grid; grid-template-columns: minmax(0, 1fr) 21rem; gap: 1rem; align-items: start; }
@media (max-width: 1000px) { .dz-wrap { grid-template-columns: minmax(0, 1fr); } }
.dz-side .panel { margin: 0 0 .8rem; }
.dz-side h2 { font-size: 1.05rem; margin: 0 0 .5rem; }
.dz-plants { max-height: 19rem; overflow: auto; border: 1px solid var(--line); border-radius: var(--radius); }
.dz-plants button { display: flex; width: 100%; gap: .5rem; align-items: center; text-align: left; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: none; padding: .4rem .55rem; min-height: 0; font-size: .92rem; }
.dz-plants button:last-child { border-bottom: 0; }
.dz-plants button.on { background: var(--amp-soft); }
.dz-plants button i { flex: none; width: 14px; height: 14px; border-radius: 50%; border: 1px solid rgba(0,0,0,.3); }
.dz-plants button span { flex: 1; min-width: 0; }
.dz-plants button small { color: var(--wire); white-space: nowrap; }
.dz-live { font-size: .92rem; margin: 0; padding: 0; list-style: none; }
.dz-live li { display: flex; justify-content: space-between; gap: .75rem; padding: .15rem 0; border-bottom: 1px dotted var(--line); }
.sitemap.editing .d-area { cursor: grab; }
.sitemap.editing .mk.sel .d-shape { filter: drop-shadow(0 0 6px #7fd1ff); stroke: #7fd1ff; }
.sitemap.before svg { visibility: hidden; }
.dthumb { display: block; width: 100%; max-width: 15rem; }
@media print { .dz-side, .dz-tools { display: none !important; } .dz-wrap { display: block; } }
#quantities .num, .plantlist .num { text-align: right; }

/* ---------- SwathRoute: mowing ---------- */
.mowstop { display: grid; grid-template-columns: 2.4rem minmax(0, 1fr) auto; gap: .8rem; align-items: start; margin: 0 0 .6rem; }
.mownum { width: 2.2rem; height: 2.2rem; border-radius: 50%; background: var(--ink); color: var(--paper); display: flex; align-items: center; justify-content: center; font-weight: 700; }
.mowstop.done { border-left: 4px solid var(--go); } .mowstop.done .mownum { background: var(--go); }
.mowstop.skipped { opacity: .7; } .mowstop.skipped .mownum { background: var(--wire); }
.mowacts { display: flex; flex-direction: column; gap: .35rem; align-items: stretch; min-width: 7.5rem; }
.mowacts button.primary { min-height: 48px; font-size: 1.05rem; }
.mowacts details input { margin-top: .3rem; }
@media (max-width: 560px) { .mowstop { grid-template-columns: 2.4rem minmax(0, 1fr); } .mowacts { grid-column: 1 / -1; } }
.lawnfields { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .6rem; margin-top: .6rem; }
@media (max-width: 800px) { .lawnfields { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.lawnrow { margin: 0 0 .7rem; }
.mowlist .num, .lawnrow .num { text-align: right; }

/* ---------- SwathRoute: the crew's check-off ---------- */
.instbar { height: 10px; border-radius: 999px; background: var(--line); overflow: hidden; margin-top: .6rem; }
.instbar span { display: block; height: 100%; background: var(--go); }
.instrow { display: flex; flex-wrap: wrap; gap: .5rem 1rem; align-items: center; justify-content: space-between; margin: 0 0 .5rem; padding: .7rem .9rem; }
.instrow.done { border-left: 4px solid var(--go); }
.instname { flex: 1; min-width: 12rem; }
.instname .dot { display: inline-block; width: .8em; height: .8em; border-radius: 50%; margin-right: .4em; }
.instcount { display: flex; gap: .5rem; align-items: center; }
.instcount button { min-height: 46px; min-width: 46px; font-size: 1.1rem; }
.instcount button.primary { font-size: 1rem; }
.instcard { display: flex; justify-content: space-between; gap: 1rem; align-items: center; text-decoration: none; color: inherit; margin: 0 0 .6rem; }
.mownav { display: flex; flex-wrap: nowrap; gap: .5rem; align-items: center; margin: .6rem 0; }
.mownav strong { font-size: 1.1rem; white-space: nowrap; }
.mownav .btn { min-width: 44px; text-align: center; }

/* 1.3.0: Mail */
.mailtabs { display: flex; gap: .3rem; flex-wrap: wrap; margin: 0 0 .5rem; border-bottom: 1px solid var(--line); }
.mailtabs a { padding: .5rem .8rem; text-decoration: none; color: inherit; border-bottom: 3px solid transparent; margin-bottom: -1px; }
.mailtabs a.on { border-bottom-color: var(--amp); font-weight: 600; }
.mailwrap { display: grid; grid-template-columns: 13rem minmax(0, 1fr); gap: 1rem; align-items: start; }
.mailfolders { display: flex; flex-direction: column; gap: .15rem; }
.mailfolders a { display: flex; justify-content: space-between; gap: .5rem; padding: .45rem .6rem; border-radius: var(--radius); text-decoration: none; color: inherit; overflow-wrap: anywhere; }
.mailfolders a:hover { background: var(--panel); }
.mailfolders a.on { background: var(--amp-soft); color: var(--amp-dark); font-weight: 600; }
.mailpick { display: none; }
.mailmain { margin: 0; min-width: 0; }
.mailsearch { gap: .5rem; margin-bottom: .7rem; }
.mailbar { gap: .4rem; }
.mailbar button, .mailbar .btn, .mailbar select { min-height: 2.2rem; padding: .3rem .65rem; font-size: .92rem; }
.mailbar select { width: auto; max-width: 11rem; }
.maillist { list-style: none; margin: .6rem 0 0; padding: 0; border-top: 1px solid var(--line); }
.maillist li { display: flex; align-items: center; gap: .6rem; border-bottom: 1px solid var(--line); }
.maillist li input { width: auto; min-height: 0; flex-shrink: 0; margin-left: .2rem; }
.maillist li a { flex: 1; min-width: 0; display: grid; grid-template-columns: 13rem minmax(0, 1fr) auto; gap: .8rem; padding: .6rem .3rem; text-decoration: none; color: inherit; }
.maillist li a:hover { background: var(--panel); }
.maillist .mwho, .maillist .msub { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.maillist .mwhen { color: var(--wire); font-size: .9rem; white-space: nowrap; }
.maillist li.unread .mwho, .maillist li.unread .msub { font-weight: 700; }
.maillist .dot { display: inline-block; width: .55rem; height: .55rem; border-radius: 50%; background: var(--amp); margin-right: .4rem; }
.mailhead { display: flex; flex-direction: column; gap: .15rem; padding-bottom: .6rem; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
.mailatts { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; margin: 0 0 .7rem; }
.mailframe { width: 100%; height: 70vh; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.mailtext { white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.5; }
.mailbox { border: 1px solid var(--line); border-radius: var(--radius); padding: .6rem .8rem; margin-bottom: .6rem; }
.mailbox summary { cursor: pointer; }
.tickgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr)); gap: .3rem .8rem; }
@media (max-width: 820px) {
  .mailwrap { grid-template-columns: 1fr; gap: .6rem; }
  .mailfolders { display: none; }
  .mailpick { display: block; }
  .maillist li a { grid-template-columns: minmax(0, 1fr) auto; gap: .1rem .6rem; }
  .maillist .msub { grid-column: 1 / -1; grid-row: 2; }
  .mailframe { height: 60vh; }
}

/* conversations, Previous and Next, the formatted editor */
.badge[hidden] { display: none; }
.mailnav { margin: 0 0 .6rem; gap: .5rem; }
.mailnav .btn { min-height: 2.2rem; padding: .3rem .7rem; font-size: .92rem; }
.mcount { display: inline-block; min-width: 1.4rem; padding: 0 .35rem; border: 1px solid var(--line); border-radius: 1rem; font-size: .78rem; font-weight: 600; text-align: center; color: var(--wire); vertical-align: middle; }
.mailcard { border: 1px solid var(--line); border-radius: var(--radius); margin: 0 0 .6rem; padding: 0 .8rem; }
.mailcard[open] { padding-bottom: .8rem; }
.mailcard.mine { border-left: 3px solid var(--amp); }
.mailcard > summary { display: grid; grid-template-columns: minmax(8rem, 14rem) minmax(0, 1fr) auto; gap: .8rem; padding: .65rem 0; cursor: pointer; align-items: baseline; list-style: none; }
.mailcard > summary::-webkit-details-marker { display: none; }
.mailcard > summary .mwho { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mailcard > summary .msnip { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .92rem; }
.mailcard[open] > summary .msnip { visibility: hidden; }
.mailcard > summary .mwhen { color: var(--wire); font-size: .88rem; white-space: nowrap; }
.mailcard .mailhead { padding-top: .2rem; }
.rte { border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); }
.rte:focus-within { border-color: var(--amp); }
.rtebar { display: flex; flex-wrap: wrap; gap: .25rem; padding: .35rem; border-bottom: 1px solid var(--line); align-items: center; }
.rtebar button { min-height: 2.1rem; min-width: 2.1rem; padding: .2rem .55rem; font-size: .9rem; }
.rtebar button[aria-pressed="true"] { background: var(--amp-soft); color: var(--amp-dark); border-color: var(--amp); }
.rtesep { width: 1px; align-self: stretch; background: var(--line); margin: 0 .2rem; }
.rtelink { gap: .4rem; padding: .4rem .5rem; border-bottom: 1px solid var(--line); }
.rtebody { min-height: 16rem; max-height: 70vh; overflow-y: auto; padding: .7rem .8rem; line-height: 1.5; outline: none; overflow-wrap: anywhere; }
.rtebody img { max-width: 100%; height: auto; }
.rtebody blockquote { margin: .3rem 0 .3rem .4rem; padding-left: .8rem; border-left: 3px solid var(--line); color: var(--wire); }
.rtebody h2 { font-size: 1.2rem; margin: .4rem 0; }
.rtebody ul, .rtebody ol { margin: .3rem 0; padding-left: 1.6rem; }
@media (max-width: 820px) {
  .mailcard > summary { grid-template-columns: minmax(0, 1fr) auto; gap: .1rem .6rem; }
  .mailcard > summary .msnip { grid-column: 1 / -1; grid-row: 2; }
  .mailcard[open] > summary .msnip { display: none; }
}

/* blocked senders */
.mailoffer { border-left: 3px solid var(--amp); margin-bottom: .8rem; }
.mailoffer button { min-height: 2.2rem; padding: .3rem .65rem; font-size: .92rem; }
.blocklist { list-style: none; margin: 0; padding: 0; }
.blocklist li { display: flex; justify-content: space-between; align-items: center; gap: .8rem; padding: .5rem 0; border-top: 1px solid var(--line); }
.blocklist li:first-child { border-top: 0; }

/* 1.3.1: what photos.js says while it gets photos ready on the phone */
.photostatus { margin: .4rem 0 0; color: var(--muted, #666); }
.photostatus:empty { display: none; }
.photostatus.err { color: var(--bad, #b3261e); font-weight: 600; }

/* Line items on a phone: fit the screen (they ran off the right edge) and give the quantity stepper its own row */
@media (max-width: 720px) {
  table.items { display: block; width: 100%; min-width: 0; }
  table.items tbody { display: block; width: 100%; }
  table.items tr { width: 100%; box-sizing: border-box; grid-template-columns: 1fr 1fr; }
  table.items td { min-width: 0; }
  table.items .desc { min-width: 0; width: 100%; box-sizing: border-box; }
  table.items td:has(.qty) { grid-column: 1 / -1; }
  table.items td.tot { grid-column: auto; align-self: center; }
  table.items tr > td:last-child { align-self: center; }
}

/* ===================== 1.4.0: the landscaping look ===================== */
:root {
  --ink: #1f2a22; --wire: #5f6b62; --line: #dfdacd; --paper: #f4f2ec; --panel: #ffffff;
  --amp: #3d7a2a; --amp-dark: #2a5a1c; --amp-soft: #e4f0da;
  --go: #2e7a4d; --go-soft: #dcefe3;
  --clay: #a95a31; --clay-soft: #f6e7dc; --sun: #e3a72f; --sun-soft: #fbf0d6;
  --forest: #16301f; --forest-2: #1e3d28;
  --radius: 10px;
  --shadow: 0 1px 2px rgba(22, 48, 31, .06), 0 6px 18px rgba(22, 48, 31, .06);
}
@media (prefers-color-scheme: dark) {
  :root {
    --ink: #e5ebe4; --wire: #9daa9f; --line: #2f3b32; --paper: #121814; --panel: #1b231d;
    --amp: #69ad4b; --amp-dark: #9bd07c; --amp-soft: #1f3320;
    --go: #6cc08f; --go-soft: #1f3528;
    --clay: #e19468; --clay-soft: #3a2519; --sun: #f0bf55; --sun-soft: #3a2f14;
    --forest: #0d1710; --forest-2: #132218;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3);
  }
  .top { background: var(--forest); }
}
body { background: var(--paper); }
.top { background: linear-gradient(180deg, var(--forest-2), var(--forest)); color: #eef3ec; border-color: var(--amp); }
.top nav a:hover { background: rgba(255, 255, 255, .08); }
.top nav a.on { background: rgba(140, 200, 110, .16); }
@media (min-width: 1024px) {
  .top { border-right: 0; box-shadow: inset -1px 0 rgba(255,255,255,.06); }
  .top nav a.on { box-shadow: inset 3px 0 #8cc86e; }
  .top .grp { color: rgba(220, 235, 214, .5); letter-spacing: .06em; text-transform: uppercase; font-size: .72rem; }
}
.panel { border: 1px solid rgba(31, 42, 34, .06); box-shadow: var(--shadow); border-radius: 12px; }
@media (prefers-color-scheme: dark) { .panel { border-color: var(--line); } }
h1 { letter-spacing: -.01em; }
th { text-transform: uppercase; letter-spacing: .05em; font-size: .74rem; border-bottom-width: 1px; }
tbody tr:hover td { background: rgba(61, 122, 42, .035); }
.btn, button { border-radius: 8px; }
.btn.primary, button.primary { box-shadow: 0 1px 0 rgba(0,0,0,.08); }
.tag.invoiced { background: var(--clay-soft); color: var(--clay); }
.tag.scheduled { background: var(--forest-2); color: #eef3ec; }
.readouts { background: transparent; gap: .9rem; border: 0; box-shadow: none; grid-template-columns: repeat(auto-fit, minmax(165px, 1fr)); }
.readouts > div, .readouts > a.gen { border-radius: 12px; box-shadow: var(--shadow); border: 1px solid rgba(31, 42, 34, .06); position: relative; overflow: hidden; }
.readouts > div::before, .readouts > a.gen::before { content: ""; position: absolute; left: 0; top: 0; right: 0; height: 4px; background: var(--amp); }
.readouts > div:nth-child(2)::before { background: var(--clay); }
.readouts > div:nth-child(3)::before { background: var(--sun); }
.readouts > a.gen::before { background: #5c8f86; }
.readouts > a.gen.alarm::before { background: var(--stop); }
.readouts > a.gen.alarm { box-shadow: var(--shadow); }
.demobar { background: linear-gradient(90deg, var(--forest), #2a5a1c); }
.demobar .demoviews a.on { color: var(--forest); }

/* the dashboard's at-a-glance row */
.glance { display: grid; gap: 1.25rem; margin-bottom: 1.25rem; }
.glance .panel { margin-bottom: 0; }
.glance h2 { margin: 0; }
@media (min-width: 900px) {
  .glance { grid-template-columns: minmax(0, 1.75fr) minmax(0, 1fr); grid-template-rows: auto auto; }
  .gl-route { grid-row: span 2; }
}
.gl-bar { height: 8px; border-radius: 99px; background: var(--amp-soft); margin: .7rem 0 .9rem; overflow: hidden; }
.gl-bar span { display: block; height: 100%; background: linear-gradient(90deg, #6aad48, var(--amp)); border-radius: 99px; }
.gl-route-body { display: grid; gap: 1rem; }
.gl-route-body .gl-stops { grid-template-columns: 1fr; }
@media (min-width: 700px) { .gl-route-body .gl-stops { grid-template-columns: 1fr 1fr; column-gap: 1.25rem; } }
.gl-map { width: 100%; height: auto; display: block; border-radius: 12px; }
.gl-ground { fill: #dcebcf; }
.gl-stripe { fill: rgba(255, 255, 255, .22); }
.gl-road { fill: none; stroke: #f6f3ea; stroke-width: 11; stroke-linecap: round; opacity: .95; }
.gl-path { fill: none; stroke: var(--amp-dark); stroke-width: 3.5; stroke-dasharray: 2 7; stroke-linecap: round; }
.gl-stop circle { fill: #fff; stroke: var(--amp-dark); stroke-width: 3; }
.gl-stop text { font: 700 13px "Barlow", sans-serif; text-anchor: middle; fill: var(--amp-dark); }
.gl-stop.done circle { fill: var(--amp); stroke: #fff; }
.gl-stop.done text { fill: #fff; }
.gl-stop.skip circle { fill: #eee; stroke: #aaa; } .gl-stop.skip text { fill: #888; }
.gl-shop circle { fill: var(--clay); stroke: #fff; stroke-width: 3; }
.gl-shop path { fill: #fff; }
@media (prefers-color-scheme: dark) {
  .gl-ground { fill: #22382a; } .gl-stripe { fill: rgba(255,255,255,.04); } .gl-road { stroke: #31463a; }
  .gl-stop circle { fill: #1b231d; } .gl-stop text { fill: #b6e09c; } .gl-path { stroke: #9bd07c; }
}
.gl-stops { list-style: none; margin: 0; padding: 0; display: grid; gap: .15rem; }
.gl-stops li { display: flex; gap: .6rem; align-items: center; padding: .35rem .2rem; border-bottom: 1px solid var(--line); }
.gl-stops li:last-child { border-bottom: 0; }
.gl-stops li > span:last-child { display: flex; flex-direction: column; line-height: 1.25; min-width: 0; }
.gl-stops li strong { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gl-n { flex: none; width: 1.7rem; height: 1.7rem; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: .85rem;
  border: 2px solid var(--amp-dark); color: var(--amp-dark); }
.gl-stops li.done .gl-n { background: var(--amp); border-color: var(--amp); color: #fff; }
.gl-stops li.done strong { color: var(--wire); }
.gl-stops li.more { justify-content: center; }
.gl-people { list-style: none; margin: .6rem 0 0; padding: 0; display: grid; gap: .55rem; }
.gl-people li { display: flex; align-items: center; gap: .7rem; }
.gl-people li > span:nth-child(2) { display: flex; flex-direction: column; line-height: 1.25; flex: 1; min-width: 0; }
.gl-av { flex: none; width: 2.3rem; height: 2.3rem; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: .9rem;
  background: var(--amp-soft); color: var(--amp-dark); }
.gl-people li:nth-child(3n+2) .gl-av { background: var(--clay-soft); color: var(--clay); }
.gl-people li:nth-child(3n) .gl-av { background: var(--sun-soft); color: #8a5c08; }
.gl-live { width: .6rem; height: .6rem; border-radius: 50%; background: #4caf50; box-shadow: 0 0 0 4px rgba(76, 175, 80, .18); flex: none; }
.gl-weektop .v { font: 600 1.9rem/1.1 "Barlow Semi Condensed", sans-serif; margin-top: .5rem; }
.gl-weektop .up { color: var(--go); font-weight: 600; } .gl-weektop .down { color: var(--clay); font-weight: 600; }
.gl-bars { display: grid; grid-template-columns: repeat(7, 1fr); gap: .45rem; height: 110px; align-items: end; margin-top: .9rem; }
.gl-b { height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: .25rem; }
.gl-b span { width: 100%; max-width: 34px; border-radius: 6px 6px 3px 3px; background: linear-gradient(180deg, #7dbb5a, var(--amp)); min-height: 4px; }
.gl-b.today span { background: linear-gradient(180deg, #e9b955, var(--sun)); }
.gl-b em { font-style: normal; font-size: .72rem; color: var(--wire); white-space: nowrap; }
@media (max-width: 699px) { .gl-stops li:nth-child(n+6):not(.more) { display: none; } }

/* ---------- 1.4.3: job chat ---------- */
.chatlist { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); overflow: hidden; }
.chatrow { display: flex; gap: .8rem; justify-content: space-between; align-items: center; padding: .7rem .9rem; border-top: 1px solid var(--line); color: inherit; text-decoration: none; }
.chatrow:first-child { border-top: 0; }
.chatrow:hover { background: var(--amp-soft); }
.chatrow .ct { min-width: 0; display: flex; flex-direction: column; }
.chatrow .ct span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chatrow.unread strong { color: var(--amp-dark); }
.chatrow .cw { white-space: nowrap; }
.dot { display: inline-block; width: .55rem; height: .55rem; border-radius: 50%; background: var(--amp); vertical-align: middle; }
.chatwrap { display: grid; grid-template-columns: 15rem minmax(0, 1fr); gap: 1rem; height: calc(100vh - 6rem); height: calc(100dvh - 6rem); }
.chatside { display: flex; flex-direction: column; gap: 2px; overflow-y: auto; border-right: 1px solid var(--line); padding-right: .6rem; }
.chatside a { color: inherit; text-decoration: none; padding: .45rem .55rem; border-radius: 6px; font-size: .92rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chatside a.on { background: var(--amp-soft); font-weight: 600; }
.chatside a.unread { font-weight: 700; }
.chatside a .dot { margin-right: .35rem; }
.chatmainpane { display: flex; flex-direction: column; min-height: 0; }
.chathead { display: flex; gap: .6rem; align-items: center; padding-bottom: .6rem; border-bottom: 1px solid var(--line); }
.chathead h1 { margin: 0; font-size: 1.3rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chatback { display: none; text-decoration: none; font-size: 1.4rem; }
.chatthread { flex: 1; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; gap: .6rem; padding: .8rem .2rem; }
.chatthread .av { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 50%; background: var(--amp-soft); color: var(--amp-dark); font-size: .75rem; font-weight: 700; flex-shrink: 0; }
.chatthread .msg.hl .bubble { outline: 2px solid var(--amp); }
.chatpics { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .35rem; }
.chatpics figure { margin: 0; }
.chatpics img { display: block; max-width: 220px; max-height: 220px; border-radius: 8px; object-fit: cover; }
.chatpics button.link, .msgdel button.link { color: inherit; opacity: .85; padding: .1rem 0; min-height: 0; }
.msg.mine .chatpics button.link, .msg.mine .msgdel button.link { color: #fff; }
.msgdel { margin-top: .15rem; }
.chatform { display: flex; gap: .45rem; align-items: flex-end; flex-wrap: wrap; border-top: 1px solid var(--line); padding-top: .6rem; }
.chatform textarea { flex: 1; min-width: 0; resize: none; max-height: 200px; }
.chatform .chatpic { cursor: pointer; padding: .5rem .7rem; }
.chatpreview { flex-basis: 100%; }
@media (max-width: 1023px) {
  .chatwrap { grid-template-columns: 1fr; height: calc(100dvh - 12rem); }
  .chatside { display: none; }
  .chatback { display: inline-block; }
  .chatpics img { max-width: 46vw; }
}
.chatthread .msg:not(.mine) .bubble { background: var(--panel); border: 1px solid var(--line); }

/* 1.4.4: Mail's fonts and colours, and the new-mail alert */
.rtebar select { min-height: 2.1rem; padding: .15rem .3rem; font-size: .9rem; max-width: 8.5rem; width: auto; }
.rtebar label.rtecolor { display: inline-flex; align-items: center; gap: .25rem; font-size: .85rem; border: 1px solid var(--line); border-radius: 6px; padding: 0 .4rem; min-height: 2.1rem; cursor: pointer; }
.rtebar label.rtecolor input[type=color] { width: 1.5rem; height: 1.5rem; padding: 0; border: 0; background: none; cursor: pointer; }
.mailbell { font-size: .9rem; }
.mailbell[aria-pressed="true"] { background: var(--amp-soft); color: var(--amp-dark); border-color: var(--amp); }

/* Vendors and price requests (from Junction Pro) */
.prline { display: grid; grid-template-columns: 1.6rem minmax(0, 3fr) minmax(0, 1.3fr) 5rem 5rem; gap: .5rem; align-items: center; padding: .35rem 0; border-bottom: 1px solid var(--line); }
.prline input { min-height: 2.3rem; }
.prline.head { font-size: .8rem; color: var(--wire); font-weight: 600; border-bottom: 2px solid var(--line); }
@media (max-width: 700px) { .prline { grid-template-columns: 1.6rem minmax(0, 1fr) 4.2rem 4.6rem; } .prline .pn { display: none; } }
@media (max-width: 700px) {
  .prline.ed { grid-template-columns: 1.6rem 1fr 1fr; }
  .prline.ed > span:nth-child(2) { grid-column: 2 / -1; }
  .prline.ed > input[name^="qty_"], .prline.ed > input[name="new_qty"] { grid-column: 2; }
}
td .gain, div.gain { color: #2e7a4d; }
.tag.soon { background: var(--amp-soft); color: var(--amp-dark); border-color: transparent; }
