/* ═══════════════════════════════════════════════════════════════════════════
   THE BUTTON FAMILY AND THE POP-UP — the restyle he approved (21 Oct 2026).
   Looks: design-gallery tries/buttons (20 Oct) and tries/popups "New".
   Linked straight after m3.css, at the same strength as m3.css's own rules, so the
   cascade behaves as if m3.css had been edited in place: a screen sheet that already
   overrides m3 still overrides, and is fixed screen by screen (jobs J3-J6).

   ⚠ THE FENCE. Every rule here starts with
       :where(body:not(.role-tech):not(.role-driver))
   :where() weighs nothing, so the strength is the same as without it. The technician's
   and the driver's own phone screens (body.role-tech / body.role-driver, set by
   reports-team.js applyRoleUI) keep today's buttons, tabs and bottom sheets: his law.
   Old rules are not deleted, because those screens still use them.

   The family:
     .btn-primary, .btn-line.strong  the main action: red, one per area
     .btn-line                        outline: Cancel, Close, the default second button
     + .bt-neu   grey   download, print, share, export, copy link
     + .bt-ok    green  mark done, approve
     + .bt-del   red edge, red words: delete or remove off a list
     + .bt-wine  "Delete for good": ONLY in the question box
     .bt-ghost, .m3-text              quiet words, a grey wash on hover
     sizes: 44px / 15px; .bt-sm 32 / 14; .bt-lg 52 / 16; .bt-ic round, icon only
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── THE SHAPE ─────────────────────────────────────────────────────────────
   min-height, never height: the dense hosts (.mrow, .ov-frow, .cg-rec ...) set a
   smaller min-height and padding at a higher strength and keep their size. */
:where(body:not(.role-tech):not(.role-driver)) .btn-primary,
:where(body:not(.role-tech):not(.role-driver)) .btn-line,
:where(body:not(.role-tech):not(.role-driver)) .bt-ok,
:where(body:not(.role-tech):not(.role-driver)) .bt-neu,
:where(body:not(.role-tech):not(.role-driver)) .bt-del,
:where(body:not(.role-tech):not(.role-driver)) .bt-wine,
:where(body:not(.role-tech):not(.role-driver)) .bt-ghost{
  min-height:44px;padding:0 20px;gap:8px;border-radius:999px;border:1.5px solid transparent;
  font-family:'Inter',system-ui,sans-serif;font-size:15px;font-weight:600;line-height:1.2;
  white-space:nowrap;cursor:pointer;user-select:none;-webkit-tap-highlight-color:transparent;
  touch-action:manipulation;outline:2px solid transparent;outline-offset:2px}
/* a .bt-* used on its own (no btn-line / btn-primary) still lines its words up.
   Zero strength, so .btn-primary's own display:flex is never overruled. */
:where(body:not(.role-tech):not(.role-driver)) :where(.bt-ok,.bt-neu,.bt-del,.bt-wine,.bt-ghost){
  display:inline-flex;align-items:center;justify-content:center}
/* ⚠ motion.css (loaded later) gives every button transition:transform only, which would
   drop the colour fades. One class more strength, for this one property. */
:where(body:not(.role-tech):not(.role-driver)) :is(.btn-primary,.btn-line,.bt-ok,.bt-neu,.bt-del,.bt-wine,.bt-ghost):not(.bt-x){
  transition:background-color .15s ease,border-color .15s ease,color .15s ease,box-shadow .15s ease,transform .16s cubic-bezier(.23,1,.32,1)}
@media (prefers-reduced-motion:reduce){
  :where(body:not(.role-tech):not(.role-driver)) :is(.btn-primary,.btn-line,.bt-ok,.bt-neu,.bt-del,.bt-wine,.bt-ghost):not(.bt-x){transition:none}
}

/* ── SIZES ── */
:where(body:not(.role-tech):not(.role-driver)) .bt-sm{min-height:32px;padding:0 14px;font-size:14px;gap:6px}
:where(body:not(.role-tech):not(.role-driver)) .bt-lg{min-height:52px;padding:0 26px;font-size:16px;gap:10px}
:where(body:not(.role-tech):not(.role-driver)) .bt-ic{padding:0;width:44px;min-width:44px;border-radius:50%;justify-content:center}
:where(body:not(.role-tech):not(.role-driver)) .bt-ic.bt-sm{width:32px;min-width:32px}
:where(body:not(.role-tech):not(.role-driver)) .bt-ic.bt-lg{width:52px;min-width:52px}
:where(body:not(.role-tech):not(.role-driver)) .bt-ic svg{width:20px;height:20px;flex:none}
:where(body:not(.role-tech):not(.role-driver)) .bt-ic.bt-sm svg{width:17px;height:17px}

/* ── THE COLOURS ───────────────────────────────────────────────────────────
   Each one three times: at rest; under :hover OUTSIDE the hover media, so a tap on a
   phone (a sticky :hover) never shows m3/app's hover colours; and the real hover,
   for a mouse only. Order matters: the variants come after main and outline so
   `btn-line bt-neu` / `btn-primary bt-wine` take the variant. */

/* main: red */
:where(body:not(.role-tech):not(.role-driver)) .btn-primary,
:where(body:not(.role-tech):not(.role-driver)) .btn-line.strong,
:where(body:not(.role-tech):not(.role-driver)) .btn-primary:hover,
:where(body:not(.role-tech):not(.role-driver)) .btn-line.strong:hover{
  background:var(--accent);color:var(--on-accent);border-color:transparent;opacity:1}
/* outline */
:where(body:not(.role-tech):not(.role-driver)) .btn-line{background:transparent;color:var(--ink);border-color:var(--bt-edge)}
:where(body:not(.role-tech):not(.role-driver)) .btn-line:hover{background:transparent;color:var(--ink);border-color:var(--bt-edge)}
/* grey */
:where(body:not(.role-tech):not(.role-driver)) .bt-neu,
:where(body:not(.role-tech):not(.role-driver)) .bt-neu:hover{background:var(--bt-neu);color:var(--ink);border-color:transparent}
/* pale green */
:where(body:not(.role-tech):not(.role-driver)) .bt-ok,
:where(body:not(.role-tech):not(.role-driver)) .bt-ok:hover{background:var(--bt-ok);color:var(--bt-ok-ink);border-color:transparent}
/* delete: red edge, red words */
:where(body:not(.role-tech):not(.role-driver)) .bt-del,
:where(body:not(.role-tech):not(.role-driver)) .bt-del:hover{background:transparent;color:var(--bt-del-ink);border-color:var(--accent)}
/* delete for good: wine */
:where(body:not(.role-tech):not(.role-driver)) .bt-wine,
:where(body:not(.role-tech):not(.role-driver)) .bt-wine:hover{background:var(--bt-wine);color:var(--bt-on-wine);border-color:transparent}
/* ghost. ⚠ m3.css paints .m3-text with !important (accent words), so this has to as well. */
:where(body:not(.role-tech):not(.role-driver)) .bt-ghost,
:where(body:not(.role-tech):not(.role-driver)) .bt-ghost:hover{background:transparent;color:var(--ink-soft);border-color:transparent}
:where(body:not(.role-tech):not(.role-driver)) .m3-text,
:where(body:not(.role-tech):not(.role-driver)) .m3-text:hover{background:transparent!important;color:var(--ink-soft)!important;border-color:transparent!important}

@media (hover:hover) and (pointer:fine){
  :where(body:not(.role-tech):not(.role-driver)) .btn-primary:hover,
  :where(body:not(.role-tech):not(.role-driver)) .btn-line.strong:hover{background:var(--bt-main-h)}
  :where(body:not(.role-tech):not(.role-driver)) .btn-line:not(:is(.strong,.bt-neu,.bt-ok,.bt-del,.bt-wine,.bt-ghost,.m3-text)):hover{background:var(--bt-line-h);border-color:var(--ink)}
  :where(body:not(.role-tech):not(.role-driver)) .bt-neu:hover{background:var(--bt-neu-h);border-color:transparent}
  :where(body:not(.role-tech):not(.role-driver)) .bt-ok:hover{background:var(--bt-ok-h);border-color:transparent}
  :where(body:not(.role-tech):not(.role-driver)) .bt-del:hover{background:var(--bt-del-wash);border-color:var(--accent)}
  :where(body:not(.role-tech):not(.role-driver)) .bt-wine:hover{background:var(--bt-wine-h);border-color:transparent}
  :where(body:not(.role-tech):not(.role-driver)) .bt-ghost:hover{background:var(--bt-neu);color:var(--ink)}
  :where(body:not(.role-tech):not(.role-driver)) .m3-text:hover{background:var(--bt-neu)!important;color:var(--ink)!important}
}

/* pressed */
:where(body:not(.role-tech):not(.role-driver)) .btn-primary:active,
:where(body:not(.role-tech):not(.role-driver)) .btn-line.strong:active{background:var(--bt-main-p)}
:where(body:not(.role-tech):not(.role-driver)) .btn-line:not(:is(.strong,.bt-neu,.bt-ok,.bt-del,.bt-wine,.bt-ghost,.m3-text)):active{background:var(--bt-line-p);border-color:var(--ink)}
:where(body:not(.role-tech):not(.role-driver)) .bt-neu:active{background:var(--bt-neu-p);border-color:transparent}
:where(body:not(.role-tech):not(.role-driver)) .bt-ok:active{background:var(--bt-ok-p);border-color:transparent}
:where(body:not(.role-tech):not(.role-driver)) .bt-del:active{background:var(--bt-del-wash-p);border-color:var(--accent)}
:where(body:not(.role-tech):not(.role-driver)) .bt-wine:active{background:var(--bt-wine-p);border-color:transparent}
:where(body:not(.role-tech):not(.role-driver)) .bt-ghost:active{background:var(--bt-neu-p)}
:where(body:not(.role-tech):not(.role-driver)) .m3-text:active{background:var(--bt-neu-p)!important}

/* the keyboard ring: a gap in the panel's colour, then a ring in the ink, so it shows
   on red, grey and outline alike */
:where(body:not(.role-tech):not(.role-driver)) :is(.btn-primary,.btn-line,.bt-ok,.bt-neu,.bt-del,.bt-wine,.bt-ghost,.m3-text):focus-visible{
  box-shadow:0 0 0 2px var(--surface),0 0 0 4.5px var(--ink)}

/* can't be pressed: the app's dead grey, never a faded colour (a pale red still reads
   as "press me"). Last, so it beats every hover above. */
:where(body:not(.role-tech):not(.role-driver)) :is(.btn-primary,.btn-line,.bt-ok,.bt-neu,.bt-del,.bt-wine,.bt-ghost):disabled:not(.bt-x),
:where(body:not(.role-tech):not(.role-driver)) :is(.btn-primary,.btn-line,.bt-ok,.bt-neu,.bt-del,.bt-wine,.bt-ghost)[aria-disabled="true"]:not([data-state]):not(.bt-x){
  background:var(--bt-off-bg);color:var(--bt-off-ink);border-color:transparent;cursor:not-allowed;transform:none;box-shadow:none;opacity:1}

/* ── SAVING… / SAVED ─────────────────────────────────────────────────────────
   btnSaving() in ui.js wraps the button's words once into three stacked labels,
   so the button keeps the width of the longest. data-state busy -> done -> cleared.
   (Named .bt-lab/.bt-s1.. rather than the page's .lab/.s1: .spin and .tick are
   already taken in listkit.css, popups.css and others.) */
:where(body:not(.role-tech):not(.role-driver)) .bt-lab{display:inline-grid}
:where(body:not(.role-tech):not(.role-driver)) .bt-lab > span{grid-area:1/1;display:inline-flex;align-items:center;justify-content:center;gap:8px;white-space:nowrap;
  transition:opacity .18s ease-out,transform .24s cubic-bezier(.23,1,.32,1)}
:where(body:not(.role-tech):not(.role-driver)) .bt-lab > .bt-s2,
:where(body:not(.role-tech):not(.role-driver)) .bt-lab > .bt-s3{opacity:0;transform:translateY(8px)}
:where(body:not(.role-tech):not(.role-driver)) [data-state="busy"] > .bt-lab > .bt-s1,
:where(body:not(.role-tech):not(.role-driver)) [data-state="done"] > .bt-lab > .bt-s1,
:where(body:not(.role-tech):not(.role-driver)) [data-state="done"] > .bt-lab > .bt-s2{opacity:0;transform:translateY(-8px)}
:where(body:not(.role-tech):not(.role-driver)) [data-state="busy"] > .bt-lab > .bt-s2,
:where(body:not(.role-tech):not(.role-driver)) [data-state="done"] > .bt-lab > .bt-s3{opacity:1;transform:none}
:where(body:not(.role-tech):not(.role-driver)) [data-state="busy"]{cursor:progress}
:where(body:not(.role-tech):not(.role-driver)) .bt-spin{width:15px;height:15px;border-radius:50%;border:2px solid currentColor;border-right-color:transparent;flex:none;animation:btSpin .7s linear infinite}
:where(body:not(.role-tech):not(.role-driver)) .bt-sm .bt-spin{width:13px;height:13px}
:where(body:not(.role-tech):not(.role-driver)) .bt-tick{width:12px;height:7px;border-left:2px solid currentColor;border-bottom:2px solid currentColor;transform:rotate(-45deg) translate(1px,-2px);flex:none}
@keyframes btSpin{to{transform:rotate(360deg)}}
@media (prefers-reduced-motion:reduce){
  :where(body:not(.role-tech):not(.role-driver)) .bt-lab > span{transition:none}
  :where(body:not(.role-tech):not(.role-driver)) .bt-spin{animation-duration:2s}
}

/* ── THE CHROME KEEPS ITS SHAPE ──────────────────────────────────────────────
   The rail's "New customer" tile (app.css .sb-foot .btn-primary, a 38px square) is not
   a family button: it keeps today's size and words (m3.css's 40px floor, 13px, no edge).
   It is hidden behind the username menu today (apppanel.css .rail-moved), kept right anyway. */
:where(body:not(.role-tech):not(.role-driver)) .sb-foot .btn-primary{min-height:40px;font-size:13px;line-height:1.3;border:0;gap:7px}
/* ⚠ THE SIGN-IN BUTTON STAYS EXACTLY AS TODAY. Before signing in the body has no role
   class, so the fence cannot tell a technician from the office, and technicians and
   drivers see this screen: his law says their screens are untouched. Today's values
   (m3.css .btn-primary, app.css hover and :focus-visible, motion.css press), restated
   at the id's strength so no family rule reaches it. */
#authForm .btn-primary{min-height:40px;padding:9px 20px;border-radius:20px;border:0;gap:7px;
  font-family:'Inter',sans-serif;font-size:13px;font-weight:600;line-height:1.3;
  background:var(--accent);color:var(--on-accent);user-select:auto;touch-action:auto;
  outline:none;outline-offset:0;box-shadow:none;transition:transform .08s var(--ease-out)}
#authForm .btn-primary:hover,#authForm .btn-primary:active:hover{background:var(--accent-deep);box-shadow:0 3px 10px -3px rgba(var(--shade-rgb),.5)}
#authForm .btn-primary:active{background:var(--accent)}
#authForm .btn-primary:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
@media (prefers-reduced-motion:reduce){ #authForm .btn-primary{transition:none} }
/* today a phone's sign-in button is 44 tall (m3.css, 760px and below): keep it */
@media (max-width:760px){ #authForm .btn-primary{min-height:44px} }

/* ═══ THE POP-UP ═══════════════════════════════════════════════════════════
   One white box in the middle, the page dimmed (no blur), 16px corners.
   (tries/popups "New", lines 116-138.)
   The SURFACE is for every .modal at once. The STRUCTURE (title and buttons stay put,
   the middle scrolls) is opt-in: class .dlg on the box with .dlg-hd / .dlg-bd / .dlg-ft
   children, added host by host. Making every .modal a flex column at once would stop
   the form hosts scrolling: their <form> is the only child. */
:where(body:not(.role-tech):not(.role-driver)) .ov{background:var(--bt-veil);-webkit-backdrop-filter:none;backdrop-filter:none}
:where(body:not(.role-tech):not(.role-driver)) .modal{border-radius:16px;border:0;box-shadow:var(--bt-pop-shadow);background:var(--surface)}
/* the scrollbar stops short of the round corners (m3.css's 26px was for 28px corners) */
:where(body:not(.role-tech):not(.role-driver)) .modal::-webkit-scrollbar-track{margin:14px 0}

:where(body:not(.role-tech):not(.role-driver)) .modal.dlg{display:flex;flex-direction:column;overflow:hidden;padding:0;max-height:min(88vh,900px)}
:where(body:not(.role-tech):not(.role-driver)) .dlg-form{display:flex;flex-direction:column;flex:1;min-height:0}
:where(body:not(.role-tech):not(.role-driver)) .dlg-hd{display:flex;gap:16px;align-items:flex-start;padding:24px 24px 18px;flex:none}
/* the title takes the room; an icon-only close (.bt-ic) sits in the top corner */
:where(body:not(.role-tech):not(.role-driver)) .dlg-hd > :first-child{flex:1;min-width:0}
:where(body:not(.role-tech):not(.role-driver)) .dlg-hd > .bt-ic:last-child{margin:-6px -8px 0 0}
:where(body:not(.role-tech):not(.role-driver)) .dlg-t{font-size:24px!important;font-weight:600;line-height:1.2;letter-spacing:-.01em;margin:0;overflow-wrap:anywhere}
:where(body:not(.role-tech):not(.role-driver)) .dlg-m{font-size:15px;color:var(--ink-soft);margin:6px 0 0}
:where(body:not(.role-tech):not(.role-driver)) .dlg-bd{padding:4px 24px 24px;overflow:auto;flex:1;min-height:0;overscroll-behavior:contain}
:where(body:not(.role-tech):not(.role-driver)) .dlg-ft{display:flex;justify-content:flex-end;align-items:center;gap:10px;padding:16px 24px;flex:none;border-top:1px solid var(--rule);background:var(--surface)}
/* drafts.js puts "your draft is back" straight into the box, which has no padding of its own */
:where(body:not(.role-tech):not(.role-driver)) .modal.dlg > .draftbar{margin:12px 24px 0}

/* ── ON AN OFFICE PHONE IT STAYS A BOX ──────────────────────────────────────
   m3.css turns every dialog into a bottom sheet under 600px, and m3.js drags it and
   scales the page behind. That stays for the technician and the driver (fence);
   an office phone gets the same box as the laptop, in the middle, with the same
   arrival (app.css modalIn), and m3.js sheetMode() no longer drags it. */
@media (max-width:600px){
  :where(body:not(.role-tech):not(.role-driver)) .ov{align-items:center;padding:12px}
  :where(body:not(.role-tech):not(.role-driver)) .modal,
  :where(body:not(.role-tech):not(.role-driver)) .modal.dlg{width:100%;max-width:none;border-radius:16px;max-height:calc(100dvh - 24px);
    animation:modalIn var(--mo-pop-in)}
  :where(body:not(.role-tech):not(.role-driver)) .modal::-webkit-scrollbar-track{margin:14px 0}
  :where(body:not(.role-tech):not(.role-driver)) .m3-grab{display:none}
  /* body.m3-sheeted still LOCKS the page behind on every phone (phone-deck.css: it takes no
     touches and does not scroll); on the office side only the push-back goes, because a box
     in the middle is not a sheet. Same strength as m3.css's rule, and later. */
  body.m3-sheeted:where(:not(.role-tech):not(.role-driver)) > .app{transform:none;border-radius:0}
  /* the buttons at the foot of a box are big enough for a thumb, and share the row */
  :where(body:not(.role-tech):not(.role-driver)) .dlg-ft :is(.btn-primary,.btn-line,.bt-ok,.bt-neu,.bt-del,.bt-wine){flex:1 1 auto;min-height:52px;font-size:16px;padding:0 14px}
  /* (tries/popups phone values) */
  :where(body:not(.role-tech):not(.role-driver)) .dlg-hd{padding:20px 16px 14px}
  /* ⚠ app.css sets every phone h2 to --m4 !important; a pop-up title keeps its own size */
  :where(body:not(.role-tech):not(.role-driver)) .dlg-t{font-size:22px!important;line-height:1.2}
  :where(body:not(.role-tech):not(.role-driver)) .dlg-bd{padding:4px 16px 20px}
  :where(body:not(.role-tech):not(.role-driver)) .modal.dlg > .draftbar{margin:12px 16px 0}
  :where(body:not(.role-tech):not(.role-driver)) .dlg-ft{padding:12px 16px 14px}
}

/* ═══ THE QUESTION BOX (#m-ask, ui.js askConfirm / askText) ═══════════════════
   Office: the new pop-up, 460 wide (tries/popups "Delete a machine"), the question in
   15px ink, Cancel outlined then the red (or wine) OK, both on the right. */
:where(body:not(.role-tech):not(.role-driver)) #m-ask > .modal{max-width:460px}
:where(body:not(.role-tech):not(.role-driver)) #askBody{font-size:15px;line-height:1.5;color:var(--ink)}
:where(body:not(.role-tech):not(.role-driver)) #askBody:empty{display:none}
:where(body:not(.role-tech):not(.role-driver)) #askFieldWrap{margin-top:14px}
:where(body:not(.role-tech):not(.role-driver)) #askBody:empty + #askFieldWrap{margin-top:0}

/* ── THE QUESTION BOX ON THE FIELD SIDE: exactly today's look ────────────────
   ⚠ NOT behind the fence: these are the technician's and the driver's own rules. The box
   had its look as inline styles; the markup is shared now, so the same values live here,
   scoped to those two screens only (ui.js askDress keeps their inline button paint and
   makes Cancel a .foot-link again). The fence proof compares these screens to the pixel. */
body.role-tech #m-ask > .modal,body.role-driver #m-ask > .modal{max-width:440px;padding:24px}
body.role-tech #askTitle,body.role-driver #askTitle{font-size:15px}
body.role-tech #askBody,body.role-driver #askBody{font-size:13px;color:var(--ink-soft);line-height:1.6;margin-top:9px}
body.role-tech #askFieldWrap,body.role-driver #askFieldWrap{margin-top:15px}
body.role-tech #m-ask .dlg-ft,body.role-driver #m-ask .dlg-ft{display:flex;gap:10px;margin-top:20px;align-items:center}
body.role-tech #askOk,body.role-driver #askOk{width:auto;order:-1}
body.role-tech #askCancel,body.role-driver #askCancel{width:auto;margin-left:auto}

/* a round icon button in a pop-up footer keeps its shape */
:where(body:not(.role-tech):not(.role-driver)) .mp-foot .btn-line.bt-ic.su-round{width:44px;min-width:44px;height:44px;min-height:44px;padding:0;border-radius:50%;flex:none}
#mtAllBtn{min-width:104px;justify-content:center}  /* the word changes, the row beside it must not move */

/* ── FEWER WORDS ON FORMS (7 Nov) ──────────────────────────────────────────
   Inside .pj (Settings, Data Bank, Projects) the generated projects.css paints every .btn-line
   square and white, loaded after this file at equal strength: the round icon says so again, one class up. */
:where(body:not(.role-tech):not(.role-driver)) :is(.btn-line,.btn-primary).bt-ic{display:inline-flex;align-items:center;justify-content:center;flex:none;padding:0!important;width:44px!important;min-width:44px!important;min-height:44px!important;height:44px!important;border-radius:50%!important}
:where(body:not(.role-tech):not(.role-driver)) :is(.btn-line,.btn-primary).bt-ic.bt-sm{width:32px!important;min-width:32px!important;min-height:32px!important;height:32px!important}
:where(body:not(.role-tech):not(.role-driver)) .pj .btn-line.bt-ic:not(.bt-del):not(.bt-neu):not(.bt-ghost):not(.strong){background:transparent;color:var(--ink);border:1.5px solid var(--bt-edge)}
:where(body:not(.role-tech):not(.role-driver)) .pj .btn-line.bt-ic.bt-del{background:transparent;color:var(--bt-del-ink);border:1.5px solid var(--accent)}
:where(body:not(.role-tech):not(.role-driver)) label.bt-ic{cursor:pointer}
.bt-ic[hidden]{display:none!important}
@media (max-width:760px){
  :where(body:not(.role-tech):not(.role-driver)) :is(.btn-line,.btn-primary).bt-ic.bt-sm{width:44px!important;min-width:44px!important;min-height:44px!important;height:44px!important}
}
/* in the side panel the screen's own buttons are word rows; the add is a round red plus, not a row */
#appside .as-end .btn-primary.bt-ic{width:32px!important;min-width:32px!important;height:32px!important;min-height:32px!important;margin:6px 0 0 9px!important;padding:0!important;border-radius:50%!important;background:var(--accent)!important;color:var(--on-accent)!important;align-self:flex-start;font-size:0;display:inline-flex!important;align-items:center!important;justify-content:center!important}
#appside .as-end .btn-primary.bt-ic svg{width:17px;height:17px}
.pj .pj-fileadd,.db-lab .db-actr{margin-left:auto}
.tp-badd-r{margin:8px 0 0 4px}
.us-thumbs .us-addph{align-self:center;margin-left:4px}
/* the job form's foot stays on one line on a phone */
@media (max-width:600px){#m-maint-record .mp-foot{gap:8px}#m-maint-record #mrThink{padding:0 6px}}
/* a round button beside a box on one line */
.rb-line{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
/* the tag entry that replaced "(comma sep)": the real box stays hidden, its value is what Save reads */
.tagbox{display:flex;flex-wrap:wrap;align-items:center;gap:6px;height:auto;min-height:44px;padding:6px 10px;cursor:text}
.tagbox input{flex:1;min-width:90px;border:0;outline:0;background:none;padding:2px 0;font:inherit;color:var(--ink)}
.tagbox-t{display:inline-flex;align-items:center;gap:2px;max-width:100%;padding:2px 2px 2px 10px;border-radius:999px;background:var(--bt-neu);color:var(--ink);font-size:14px;line-height:1.4;overflow-wrap:anywhere}
.tagbox-t button{display:inline-flex;align-items:center;justify-content:center;width:24px;height:24px;flex:none;padding:0;border:0;border-radius:50%;background:none;color:var(--ink-soft);cursor:pointer}
.tagbox-t button svg{width:12px;height:12px}
@media (hover:hover) and (pointer:fine){.tagbox-t button:hover{color:var(--ink)}}
