/* ═══════════════════════════════════════════════════════════════════════════
   MATERIAL 3 — the layer that reshapes the CRM's own components.
   Loaded LAST, on purpose. Nothing in the other four stylesheets was edited:
   this file only overrides. Delete its <link> and the app is exactly as it was.

   Every number here was measured on m3.material.io, loaded in a real browser
   because that site renders in JavaScript and hands a plain fetch an empty page.
   The COLOURS are Indohose's — Material's shape, not Google's palette.

   What is here, and the number that drives it:
     buttons ............ 40dp, fully rounded, five styles
     tabs ............... 48dp, 3dp rounded indicator inset 2dp
     segmented buttons .. 40dp, fully rounded, a tick on the chosen one
     chips .............. 32dp, 8dp corner, 18dp icon
     form fields ........ 56dp outlined, the label sits in the outline, 4dp gap
     dialogs ............ 28dp corner, 280–560dp wide
     bottom sheets ...... under 600px a dialog becomes a sheet: 28dp top corners,
                          full width, a 32×4dp grab handle
     icon buttons ....... 40dp round, 48dp target
     switch ............. 52 × 32dp, thumb 16dp → 24dp
     tooltips ........... 24dp tall, 8dp padding, appears at once
   ═══════════════════════════════════════════════════════════════════════════ */

:root{ --m3-state:rgba(var(--shade-rgb),.08); }

/* ── BUTTONS ─────────────────────────────────────────────────────────────
   Five styles in a deliberate order. The CRM has two class names, so filled
   maps to .btn-primary and outlined to .btn-line; the other three are opt-in
   with .m3-tonal, .m3-elevated and .m3-text. */
.btn-line{
  display:inline-flex;align-items:center;justify-content:center;gap:8px;
  min-height:40px;padding:9px 20px;border-radius:20px;line-height:1.3;white-space:nowrap;
  font-family:'Inter',sans-serif;font-size:13px;font-weight:600;
  border:1px solid var(--rule);background:none;color:var(--ink);
  transition:background .12s ease,border-color .12s ease}
.btn-line:hover{background:var(--m3-state);border-color:var(--rule);color:var(--ink)}
/* The dark button — the one main action of an area. ⚠ ITS HOVER FADES, IT NEVER CHANGES COLOUR.
   It used to live in files.css as background:var(--stage), and --stage is black in BOTH themes:
   in dark mode the text is near-black too, so a hovered — or on a phone, just-tapped — "Save
   changes" went black on black (30 Sep, his screenshot). The colours are restated because the
   .btn-line:hover above would otherwise turn the text to --ink. */
.btn-line.strong,.btn-line.strong:hover{background:var(--ink);border-color:var(--ink);color:var(--on-ink)}
.btn-line.strong:hover{opacity:.88}
.btn-line.off{opacity:.5;pointer-events:none}
.btn-primary{
  min-height:40px;padding:9px 20px;border-radius:20px;line-height:1.3;white-space:nowrap;
  /* ⚠ the app declares this button width:100%, because it was born in the rail.
     Anywhere else that makes it eat the whole row and shove its neighbour onto a
     second line — which is what "Close / Edit" was doing in the job dialog. It
     sizes to its words here; the places that really want a full-width button say so. */
  width:auto;
  font-family:'Inter',sans-serif;font-size:13px;font-weight:600;
  background:var(--accent);color:var(--on-accent);border:0}
.btn-primary:hover{background:var(--accent-deep)}
.m3-tonal{background:var(--accent-soft)!important;color:var(--accent)!important;border-color:transparent!important}
.m3-elevated{background:var(--surface)!important;color:var(--accent)!important;border-color:transparent!important;
  box-shadow:0 1px 3px rgba(var(--shade-rgb),.22)}
.m3-text{background:none!important;border-color:transparent!important;color:var(--accent)!important;padding:0 12px!important}
.m3-text:hover{background:var(--accent-soft)!important}
/* a button that is only an icon keeps its own size below */
.btn-line.m3-icon,.btn-primary.m3-icon{width:40px;height:40px;padding:0}

.sb .btn-primary,.sb-foot .btn-primary,#authForm .btn-primary,.jf-q .btn-primary{width:100%}

/* ── TABS — 48dp tall, a 3dp fully-rounded indicator inset 2dp each side ── */
.tabbar{align-items:stretch;gap:0}
.tab{position:relative;min-height:48px;padding:0 16px;font-size:13px;font-weight:500;
  color:var(--ink-soft);border-bottom:0;justify-content:center;
  transition:color .12s ease,background .12s ease}
.tab:hover{background:var(--m3-state)}
.tab.on{color:var(--accent);border-bottom:0}
.tab::after{content:"";position:absolute;left:2px;right:2px;bottom:0;height:3px;min-width:24px;
  background:var(--accent);border-radius:3px 3px 0 0;transform:scaleX(0);
  transition:transform .25s cubic-bezier(.23,1,.32,1)}
.tab.on::after{transform:scaleX(1)}

/* ── THE BRANCH STRIP — REVERTED ──────────────────────────────────────────
   ⚠ "u forgot the branch color too." Its colours were already right — white
   buttons, the chosen one filled dark, exactly as this app has always drawn
   them. What was wrong was the SHAPE: I had turned a small 6px strip into a
   40px fully-rounded pill, so the dark fill on the first segment became a big
   black lozenge. That blob is what he was looking at and calling the colour.
   Every size and corner rule is gone; the app's own stylesheet draws it again.
   The tick is all that is left of Material, and he has never objected to it. */
.mseg button.on::before,.seg2 button.on::before{
  content:"";display:inline-block;width:5px;height:9px;margin:-2px 7px 0 0;
  border:solid currentColor;border-width:0 2px 2px 0;transform:rotate(45deg)}

/* ── CHIPS — 32dp, 8dp corner ────────────────────────────────────────────
   .dtab is the CRM's view switcher: a row of separate pills. Material calls a
   row of separate, filtering pills a CHIP SET, so that is what it becomes.
   ⚠ Material would call the Maintenance view switcher TABS, but turning those
   eight pills into tabs rebuilds the whole toolbar — left alone deliberately. */
.chip,.mcatchip,.dtab{
  display:inline-flex;align-items:center;gap:8px;min-height:32px;padding:6px 16px;line-height:1.3;
  border-radius:8px;border:1px solid var(--rule);background:var(--surface);
  font-family:'Inter',sans-serif;font-size:13px;color:var(--ink);
  transition:background .12s ease,color .12s ease}
.chip:hover,.mcatchip:hover,.dtab:hover{border-color:var(--ink-faint)}
.chip.on,.mcatchip.on,.dtab.on{background:var(--ink);color:var(--on-ink);font-weight:600;
  border-color:var(--ink);padding-left:8px}
.chip.on::before,.mcatchip.on::before,.dtab.on::before{
  content:"";display:inline-block;width:5px;height:9px;margin:-2px 2px 0 0;
  border:solid currentColor;border-width:0 2px 2px 0;transform:rotate(45deg);flex-shrink:0}
.dtab.hot{color:var(--accent);border-color:var(--rule)}
/* the one exception, and it earns it: a view with something overdue behind it */
.dtab.hot.on{background:var(--accent);color:var(--on-accent);border-color:var(--accent)}

/* ── FORM FIELDS — outlined, white, 56dp, the label sitting in the outline ─
   The wrapper and the floating label are built at runtime by m3.js, which pairs
   every `<label class="field">` with the input that follows it. A field with no
   label still gets the shape. */
/* ⚠ 56px is Material's figure and it is a THUMB target. On a laptop it made every
   field stand 16px taller than the buttons next to it, and any row holding both
   wrapped before it had to. The phone keeps 56; the pointer gets 40, which is what
   every button in this app already measures. The floating label rides the field's
   own box (half height at rest, top edge when up), so it follows on its own. */
.inp,select.inp,textarea.inp{
  min-height:40px;border:1px solid var(--ink-faint);border-radius:4px;
  background:var(--surface);padding:0 16px;font-size:15px;
  transition:border-color .12s ease}
@media (max-width:760px){
  .inp,select.inp{min-height:56px}
}
textarea.inp{padding:16px;min-height:96px}
/* a textarea is inline by default, so the line it sits on left 4px under it and the
   wrapper was taller than the field — which is what the label's rest position is
   measured against */
.m3f textarea.inp{display:block}
.inp:focus{border:2px solid var(--accent);box-shadow:none;padding:0 15px}
textarea.inp:focus{padding:15px}
select.inp{appearance:none;-webkit-appearance:none;padding-right:44px;
  background-image:url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2362615c' stroke-width='2'%3E%3Cpath d='M7 10l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat:no-repeat;background-position:right 14px center;background-size:20px}
/* the floating label */
.m3f{position:relative;display:block}
.m3f .field{position:absolute;left:12px;top:50%;transform:translateY(-50%);margin:0;
  max-width:calc(100% - 24px);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
  pointer-events:none;background:var(--surface);padding:0 4px;
  font-family:'Inter',sans-serif;font-size:15px;font-weight:400;letter-spacing:0;
  text-transform:none;color:var(--ink-faint);
  transition:top .13s cubic-bezier(.23,1,.32,1),font-size .13s cubic-bezier(.23,1,.32,1),color .13s}
/* ⚠ THE ONE THAT WENT WRONG AND SHOWED ON THE SIGN-IN SCREEN. The climb used to be
   a fixed 28px up from the wrapper's middle, which is only the top border when the
   wrapper is exactly the 56px field. Twenty-five fields in this app carry a margin
   on the input, so their wrapper was 60, 68 or 70px tall and the label came to rest
   INSIDE the box instead of on its edge. Now the label rides the field's own top:
   50% of the wrapper when resting, 0 when up — and m3.js moves any margin off the
   input and onto the wrapper, so 0 is always the field's top border. */
.m3f.up .field{top:0;transform:translateY(-50%);font-size:13px}
/* ⚠ the label rests where the placeholder lives, so the placeholder waits its
   turn — it appears only once the label has climbed into the outline. Without
   this, eleven fields show two greys stacked on each other. */
.m3f .inp::placeholder{color:transparent;transition:color .12s ease}
.m3f.up .inp::placeholder{color:var(--ink-faint)}
.m3f.focus .field{color:var(--accent)}
.m3f.bad .field{color:var(--accent)}
.m3f.bad .inp{border-color:var(--accent)}
.m3f textarea.inp+.field,.m3f.ta .field{top:28px}
.m3f.ta.up .field{top:0}
/* ⚠ THE YELLOW. Chrome paints its own background on a field it filled for you,
   so the sign-in box went mustard while the label's little white chip stayed white —
   which is what the screen looked wrong for. The colour cannot be set directly; the
   only thing that covers it is an inset shadow the height of the field. And an
   autofill fires no input event, so the label is told to climb by the selector. */
.inp:-webkit-autofill,.inp:-webkit-autofill:hover,
.inp:-webkit-autofill:focus,.inp:-webkit-autofill:active{
  -webkit-text-fill-color:var(--ink);
  -webkit-box-shadow:0 0 0 1000px var(--surface) inset;
          box-shadow:0 0 0 1000px var(--surface) inset;
  caret-color:var(--ink);
  transition:background-color 9999s ease-out 0s}
.m3f .inp:-webkit-autofill+.field{top:0;transform:translateY(-50%);font-size:13px}
.m3f .inp:-webkit-autofill::placeholder{color:var(--ink-faint)}

/* ── FORM FIELDS IN THE SEARCH BAR'S LANGUAGE — every form, 24 Sep 2026 ─────────────────────
   His ask: the boxes you type in should look like the top bar's search. One family, not twins:
   the same soft fill (--band-fill), hairline (--band-line), placeholder grey and focus as
   .tb-search, but 10px corners instead of a pill (a column of pills reads as buttons) and 15px
   type (people type names and serials here). The name sits ABOVE the box, not on its border — a
   label climbing onto the edge of a grey box would carry a white patch with it.
   ⚠ EVERY FORM — he approved it on Manage team first ("yes looks right"), then it went app-wide.
   Placed ABOVE the dense-row rules further down (.mrow .inp …), so a small field in a dense row
   keeps its own smaller size and only takes the colours from here. */
.m3f{display:flex;flex-direction:column-reverse}
.m3f .field,.m3f.up .field,.m3f.focus .field,.m3f.ta .field,.m3f .inp:-webkit-autofill+.field{
  position:static;top:auto;transform:none;max-width:none;background:none;padding:0;margin:0 0 6px;
  font-size:13px;font-weight:600;color:var(--ink-soft);white-space:normal;transition:none}
.m3f.focus .field{color:var(--ink)}
.m3f.bad .field{color:var(--accent)}
.m3f .inp::placeholder,.m3f.up .inp::placeholder{color:var(--band-dim)}
.inp,select.inp,textarea.inp{
  border:1px solid var(--band-line);background-color:var(--band-fill);border-radius:10px;
  padding:0 14px;min-height:42px;color:var(--ink);font-size:15px}
textarea.inp{padding:11px 14px}
.inp:hover{border-color:var(--rule-strong)}
.inp:focus{border:1px solid var(--accent);background-color:var(--surface);padding:0 14px}
textarea.inp:focus{padding:11px 14px}
select.inp{padding-right:40px;background-position:right 12px center;background-size:18px}
select.inp:focus{padding-right:40px}
/* ⚠ A TYPE-OR-PICK FIELD (an input with a suggestion list — Machine on Add machine, Customer on
   Add a visit) drew Chrome's own heavy black ▼. It gets the dropdown's thin arrow instead; the
   browser's own button stays where it was, see-through, so pressing the arrow still opens the list. */
input.inp[list]{padding-right:40px;
  background-image:url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2362615c' stroke-width='2'%3E%3Cpath d='M7 10l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat:no-repeat;background-position:right 12px center;background-size:18px}
input.inp[list]:focus{padding-right:40px}
input.inp[list]::-webkit-calendar-picker-indicator{opacity:0;cursor:pointer}
/* Chrome's autofill paints its own colour; the inset shadow that covers it now matches the fill */
.inp:-webkit-autofill,.inp:-webkit-autofill:hover{-webkit-box-shadow:0 0 0 1000px var(--band-fill) inset;box-shadow:0 0 0 1000px var(--band-fill) inset}
.inp:-webkit-autofill:focus{-webkit-box-shadow:0 0 0 1000px var(--surface) inset;box-shadow:0 0 0 1000px var(--surface) inset}
/* ⚠ the phone keeps a thumb-sized field — the 42px above sits later than the old phone rule
   and would otherwise have shrunk every field on a phone */
@media (max-width:760px){.inp,select.inp{min-height:48px}}

.m3-help{font-family:'Inter',sans-serif;font-size:13px;color:var(--ink-soft);margin:4px 16px 0}
.m3-help.bad{color:var(--accent)}

/* ── A DATE IN A TOOLBAR IS A CONTROL, NOT A FORM FIELD ──────────────────
   Material 3 gives a form field 56dp, and this layer applied that to every .inp —
   including the two date boxes in the Reports tool row, which stand beside a 30px
   segmented strip. The result was the tallest thing on the row being the least
   important thing on it. In a FORM a date stays a 56dp field; on a tool row it
   matches the strip it sits with. */
/* ⚠ BOTH BOXES — the hidden real one and the text box in front of it (js/datefield.js).
   The text box keeps its room for the calendar button on the right. Rounded to the
   control corner (6px) of the shell's scale; it was 4px, which read as a square. */
.msort input[type=date],.drange input[type=date],.mtool input[type=date],
.msort .dfw>input[type=text],.drange .dfw>input[type=text],.mtool .dfw>input[type=text]{
  min-height:30px;height:30px;padding:0 9px;font-size:13px;border-radius:6px;
  border:1px solid var(--rule);background:var(--surface);align-self:center}
.msort .dfw>input[type=text],.drange .dfw>input[type=text],.mtool .dfw>input[type=text]{padding-right:38px;width:132px}
.msort .dfw>.dfb,.drange .dfw>.dfb,.mtool .dfw>.dfb{width:26px;height:26px;right:3px}
.msort input[type=date]:focus,.drange input[type=date]:focus,.mtool input[type=date]:focus,
.msort .dfw>input[type=text]:focus,.drange .dfw>input[type=text]:focus,.mtool .dfw>input[type=text]:focus{
  outline:none;border:1px solid var(--accent)}
.msort{align-items:center}

/* ── THE ONE RULE BEHIND THREE COMPLAINTS ────────────────────────────────
   A Material button is 40dp and a Material field is 56dp. That is right when the
   control IS the thing you came for — a form, a dialog, a toolbar of its own. It is
   wrong inside a dense row or card, where the control is a small action attached to
   a line of data. Applied there it makes the least important thing the tallest,
   pushes rows onto two lines, and leaves every card a different height.
   Three separate complaints — the date boxes on Reports, the photo captions, the
   two buttons on Review — were all this. Every dense host is named here, once. */
.mrow .btn-line,.mrow .btn-primary,.rvrow .btn-line,.rvrow .btn-primary,
.dirrow .btn-line,.dirrow .btn-primary,.mlrow .btn-line,.mlrow .btn-primary,
.ov-frow .btn-line,.ov-frow .btn-primary,.ii-row .btn-line,.ii-row .btn-primary{
  min-height:28px;padding:4px 12px;border-radius:14px;font-size:13px}
.mrow .inp,.rvrow .inp,.dirrow .inp,.mlrow .inp,.ii-row .inp{min-height:30px;padding:0 9px;font-size:13px}

/* ── A CAPTION UNDER A PHOTO IS NOT A FORM FIELD ─────────────────────────
   Same fault as the date boxes, one screen further in. Material gives a textarea
   96dp and 16dp of padding, and this layer put that on the little note under every
   photo: a box three times taller than its text, the sentence cut mid-word behind
   a scrollbar, and — because the arrows and Hapus are 40dp pills — a control row
   that wraps, so no two cards were the same height.
   The box now grows to fit what is written (field-sizing, with a floor and a
   ceiling for browsers that ignore it), the arrows are small squares, and delete
   is quiet text rather than a pill competing with the photo. */
.mgrMediaCell textarea.inp{flex:1 1 auto;margin-top:5px;
  field-sizing:content;min-height:46px;max-height:150px;overflow:auto;
  padding:7px 9px;border-radius:6px;font-size:13px;line-height:1.4;display:block}
.mgrMediaCell textarea.inp:focus{padding:6px 8px}
.mgrMediaCell .btn-line{min-height:26px;padding:1px 7px;border-radius:6px;font-size:13px;font-weight:400}
.mgrMediaCell .mgrArrow{width:26px;padding:0;justify-content:center}
.mgrMediaCell .mgrThumb{position:relative;display:block}
/* delete lives on the picture, not in the row: five things on one 170px line is what
   pushed the row onto two, and made every card a different height */
.mgrMediaCell .mgrDel{position:absolute;top:4px;right:4px;width:26px;height:26px;border:0;
  border-radius:50%;background:rgba(var(--veil-rgb),.55);color:var(--on-dark);font-size:13px;line-height:1;
  display:flex;align-items:center;justify-content:center;cursor:pointer;padding:0}
.mgrMediaCell .mgrDel:hover{background:var(--accent)}

/* ── DIALOGS — 28dp corner, 280–560dp ───────────────────────────────────── */
.modal{border-radius:28px;border:0;min-width:280px;
  box-shadow:0 8px 30px rgba(var(--shade-rgb),.22)}
/* ⚠ THE SCROLLBAR POKED OUT PAST THE ROUND CORNER — his report, 24 Sep 2026, on a job's photo
   report: "some popup has a scroll indicator … some of it is popping out on the bottom". A
   dialog is its own scroller, and Chrome does not clip a styled scrollbar to border-radius, so
   in every dialog long enough to scroll the bar ran straight past the 28px curve. Reproduced on
   a throwaway copy before this line was written. The track now stops short of both curves. */
.modal::-webkit-scrollbar-track{margin:26px 0}

/* ── BOTTOM SHEETS ───────────────────────────────────────────────────────
   ⚠ THE ONE THAT MATTERS IN THE FIELD. Under 600px every dialog in the app
   becomes a sheet that arrives from the bottom, under the thumb of a man
   holding a phone in one hand. It is the same markup — only the shape and the
   direction change. */
@media (max-width:600px){
  .ov{align-items:flex-end;padding:0}
  /* ⚠ IT STOPS SHORT OF THE TOP, ON PURPOSE. A sheet that reaches the ceiling is a
     screen that replaced the one underneath; leaving the top of the page showing is
     what tells you it is a layer over something, and it is the first thing in his
     picture. The gap clears the status bar as well, so the sheet's own corners are
     never cut by the island. */
  .modal{max-width:none;width:100%;border-radius:28px 28px 0 0;
    max-height:calc(100vh - var(--sat) - 20px);
    animation:m3sheet .3s cubic-bezier(.32,.72,0,1)}
  /* a sheet is only round at the top — so the scrollbar stays clear of the top only */
  .modal::-webkit-scrollbar-track{margin:26px 0 0}
  /* ⚠ AND THE PAGE BEHIND IS PUSHED BACK. iOS shrinks the screen underneath and
     darkens it, which is what makes a sheet feel lifted rather than pasted on. Only
     the app is scaled — the sheet itself is a child of .ov, outside it. */
  body.m3-sheeted > .app{
    transform:scale(.94);transform-origin:50% 0;border-radius:14px;overflow:hidden;
    transition:transform .3s cubic-bezier(.32,.72,0,1)}
  /* the handle is a real element (m3.js puts it there) because a drawn-on
     ::before cannot be dragged, and he asked what the line was for. Its strip is
     48px tall so a thumb catches it; the bar inside is Material's 32×4. */
  /* ⚠ touch-action:none, or the browser scrolls the page at the same time as the
     sheet moves and you get both at once. 48px so a thumb catches it; the bar drawn
     inside is Material's 32×4. */
  .m3-grab{display:block;height:30px;position:relative;touch-action:none;cursor:grab;
    margin:0}
  /* ⚠ 36 x 5, AND NEAR THE TOP. iOS puts a 36pt x 5pt grey bar about 8px below the
     edge; this was 32 x 4 sitting 22px down, which reads as a line in the content
     rather than a handle on the sheet. The strip around it stays 48px tall — that
     is what a thumb lands on, and it is not the same thing as the bar you see. */
  .m3-grab::before{content:"";position:absolute;left:50%;top:8px;width:36px;height:5px;
    margin-left:-18px;border-radius:3px;background:var(--ink-faint);opacity:.45;
    transition:opacity .12s,width .12s}
  .m3-grab:active{cursor:grabbing}
  .m3-grab:active::before{opacity:.9;width:44px;margin-left:-22px}
  /* ⚠ will-change ONLY WHILE THE FINGER IS DOWN. Left on permanently it keeps a
     layer for every sheet in the page, which costs memory on the cheap phones the
     technicians carry. */
  .modal.m3-dragging{animation:none;transition:none;will-change:transform}
  .modal.m3-springing{animation:none;transition:transform .26s cubic-bezier(.23,1,.32,1)}
  /* the grey behind a dialog is faded by the drag too, the same as the other kind */
  .ov{transition:opacity .22s cubic-bezier(.23,1,.32,1)}
  /* ⚠ THE BODY OF THE SHEET DRAGS AS WELL, not only the handle — but only while its
     content is already at the top, which m3.js works out per gesture. Keeping the
     browser's own panning off the sheet is what stops the two fighting. */
  .ov > .modal{overscroll-behavior:contain}
}
/* above the sheet breakpoint there is no sheet, so there is no handle */
/* above the sheet breakpoint there is no sheet, so there is no handle — and no
   dragging either: m3.js asks sheetMode() before it starts one. */
@media (min-width:601px){ .m3-grab{display:none} }
@keyframes m3sheet{from{transform:translateY(100%)}to{transform:none}}

/* ── ICON-ONLY BUTTONS — 40dp round, and the target never under 48dp ───── */
.ckdel,.fdel,.tvlb-x,.pvlb-x,.x{
  width:40px;height:40px;border-radius:50%;display:inline-flex;align-items:center;
  justify-content:center;padding:0;position:relative;transition:background .12s ease}
.ckdel:hover,.fdel:hover,.x:hover{background:var(--m3-state)}
.tvlb-x:hover,.pvlb-x:hover{background:rgba(var(--lift-rgb),.12)}
.ckdel::after,.fdel::after,.tvlb-x::after,.pvlb-x::after,.x::after{
  content:"";position:absolute;inset:-4px;border-radius:50%}

/* ── A TARGET A THUMB ACTUALLY HITS ──────────────────────────────────────
   Material asks for 48dp. The phone sweep found about forty-five controls under
   32px: an 18px-tall Rp/USD switch, a 17px favourite star, a Back inside a
   delivery 16px tall, a Cancel measuring 8 × 12. Nothing here moves or resizes
   what is DRAWN — each small control gets an invisible 44px band centred on it,
   the same trick the icon buttons above already use.
   ⚠ The band grows in HEIGHT only. Two of these sit side by side (Rp next to
   USD, A–Z next to Most spent) and a 44px-WIDE band would reach into its
   neighbour, so a thumb aimed at one would fire the other. Width is taken only
   where a control stands alone. */
@media (max-width:760px){
  .seglink,.star,.crumb,.mrlink,.mm-link,.mm-mini,.foot-link,.back,.tv-back,.tv-ghost,.mtg-chip{position:relative}
  .seglink::before,.star::before,.crumb::before,.mrlink::before,.mm-link::before,
  .mm-mini::before,.foot-link::before,.back::before,.tv-back::before,.tv-ghost::before,
  .mtg-chip::before{content:"";position:absolute;left:50%;top:50%;
    transform:translate(-50%,-50%);width:100%;height:44px}
  /* ⚠ these two are narrow as well as short, and a 44px-WIDE invisible band on
     them reaches outside the button — harmless to look at, but it makes the
     button report itself as wider than it is. They are given real padding
     instead: the star grows to the LEFT so its ink stays on the row's right edge. */
  .star{padding:4px 2px 4px 14px}
  .crumbs .crumb{padding:4px 6px}
  /* a tick box on a phone is a target, not a decoration: 13px is smaller than the
     ink of the word beside it */
  input[type=checkbox],input[type=radio]{width:20px;height:20px}
}

/* ── SWITCH — 52 × 32dp, the thumb grows from 16dp to 24dp and takes a tick ─
   ⚠ Only for a setting that acts at once. Material is explicit that a choice
   inside a form you still have to save stays a TICKBOX — which is what the
   other ten in this app are. */
.m3sw{width:52px;height:32px;border-radius:16px;border:2px solid var(--ink-faint);
  background:var(--field,var(--field));position:relative;cursor:pointer;padding:0;flex-shrink:0;
  transition:background .16s cubic-bezier(.23,1,.32,1),border-color .16s}
.m3sw i{position:absolute;top:50%;left:6px;transform:translateY(-50%);width:16px;height:16px;
  border-radius:50%;background:var(--ink-faint);display:flex;align-items:center;
  justify-content:center;font-style:normal;
  transition:left .18s cubic-bezier(.23,1,.32,1),width .18s cubic-bezier(.23,1,.32,1),
             height .18s cubic-bezier(.23,1,.32,1),background .16s}
.m3sw i::before{content:"";display:block;width:4px;height:8px;margin-top:-1px;
  border:solid var(--accent);border-width:0 2px 2px 0;transform:rotate(45deg);opacity:0;
  transition:opacity .12s}
.m3sw.on{background:var(--accent);border-color:var(--accent)}
.m3sw.on i{left:24px;width:24px;height:24px;background:var(--surface)}
.m3sw.on i::before{opacity:1;color:var(--accent)}

/* ── TOOLTIPS — 24dp tall, 8dp padding, and they appear at once ──────────
   m3.js takes the browser's `title` off every element that has one and shows
   this instead, so all of them change with no markup edits. */
#m3tip{position:fixed;z-index:2000;height:24px;display:flex;align-items:center;padding:0 8px;
  border-radius:4px;background:var(--ink);color:var(--on-ink);
  font-family:'Inter',sans-serif;font-size:13px;white-space:nowrap;pointer-events:none;
  opacity:0;transform:translateY(3px);transition:opacity .12s ease,transform .12s ease}
#m3tip.on{opacity:1;transform:none}

/* ── PROGRESS — 4dp on a tinted track ───────────────────────────────────── */
.prog,.progbar{height:4px;background:var(--accent-soft);border-radius:2px;overflow:hidden}
.prog i,.progbar i{border-radius:2px}

/* a row that holds more than one button is allowed to wrap — see m3.js, which
   finds them; the class is set there so nothing in the markup had to change */
.m3-btnrow{flex-wrap:wrap;row-gap:8px}

/* ── ICONS ARE DRAWINGS, NOT LETTERS ──────────────────────────────────────
   Every icon in this app is inline, so nothing here waits on a font, a network
   or a phone that has neither. .msym is only a box that positions one. */
.msym{display:inline-flex;align-items:center;justify-content:center;line-height:0}
.msym-svg{width:1em;height:1em;fill:none;stroke:currentColor;stroke-width:2;
  stroke-linecap:round;stroke-linejoin:round}

/* ── 44px UNDER EVERY THUMB ──────────────────────────────────────────────
   Measured by hit-testing at 375px, not by reading the boxes — several controls
   in this app are drawn small on purpose and already carry an invisible 44px band
   (see the ::before block further down), and those were already fine. These were
   not: the bell and the hamburger at 34, the tab strips at 32, the technician's
   tabs at 38, outlined buttons at 40, the customer-card links at 17. */
@media(max-width:760px){

  /* chrome that stands on its own simply grows */
  .nbell{min-width:44px;min-height:44px}
  .reopen-btn{width:44px;height:44px}

  /* anything already shaped like a button gets a floor, and keeps its own padding */
  .btn-line,.btn-primary,.dtab,.tv-tab,.tv-acct,.ms-filter,.ms-x,.msadd,
  .m3s input,.editdel{min-height:44px}
  /* a floor alone leaves the label sitting at the top of a taller box */
  .btn-line,.btn-primary,.dtab,.tv-tab,.tv-acct,.msadd,.editdel{
    display:inline-flex;align-items:center;justify-content:center}

  /* ⚠ NOT A BAND. These sit in a dense card a row apart, so a 44px invisible band
     centred on a 17px link reaches into the rows above and below and the wrong one
     answers the tap. Real padding grows the row instead, which is honest about the
     space it takes. */
  .cc-add{padding-top:13px;padding-bottom:13px}
  .more{display:inline-block;padding:14px 0}

  /* the bare "Ubah" on a customer — 15px of ink and nothing around it */
  .cc-val button,.cf button{min-height:44px;padding:0 4px}
}

/* ── A PHONE HAS NO HOVER, BUT IT LATCHES ONE ──────────────────────────────
   A touch screen has no pointer, so the browser fakes :hover on tap and leaves it
   applied until you tap elsewhere. The last row you touched therefore stays shaded,
   which reads as "this one is selected" when nothing is. Plainest on the four-figure
   band: tap Due visits and that cell stays grey while the other three do not.
   (hover:none) is the device saying it has no pointer. The lit states are untouched
   on a laptop and simply never arm on a phone, where the tap is its own feedback. */
@media (hover:none){
  .ov-stat:hover,.jrow:hover,.mrow:hover,.mtrow:hover,.mlrow:hover,.custrow:hover,
  .dirrow:hover,.ov-frow:hover,.ov-nrow:hover,.ov-sumrow:hover,.rlrow:hover,
  .msrow:hover,.tv-jrow:hover{background:transparent}
  /* an outlined control keeps its own resting border rather than the pointer one */
  .btn-line:hover{border-color:var(--rule);color:var(--ink-soft)}
  .nbell:hover{border-color:var(--rule)}
}

/* ── THE DATE BOX THE APP DRAWS ITSELF ────────────────────────────────────────
   Chrome writes a native date in whatever order its own language uses, which on his
   machine is the American one. So every date box gains a plain text box in front of
   it — always dd/mm/yyyy — and the real one stays behind it, one pixel wide and
   invisible, because Chrome will not open a calendar for a box it is not drawing.
   See js/datefield.js. */
/* ⚠ THE SHAPE OF THE FIELD IT REPLACED, never wider. A date sitting inside a sentence
   stayed inside it; only a field that really filled its row gets .wide. */
.dfw{position:relative;display:inline-flex;align-items:center;vertical-align:top;max-width:100%}
.dfw.wide{display:flex;width:100%}
.dfw.wide>input[type="text"]{flex:1 1 auto;width:100%;min-width:0}
.dfw>input[type="text"]{padding-right:40px}
.dfw>.dfh{position:absolute;right:34px;bottom:0;width:1px;height:1px;padding:0;margin:0;
  border:0;opacity:0;pointer-events:none;overflow:hidden}
.dfw>.dfb{position:absolute;right:6px;top:50%;transform:translateY(-50%);
  display:flex;align-items:center;justify-content:center;width:30px;height:30px;
  border:0;border-radius:8px;background:transparent;color:var(--ink-faint);cursor:pointer}
.dfw>.dfb:hover{background:var(--field);color:var(--ink-soft)}
.dfw>input[type="text"].df-bad{border-color:var(--alert);color:var(--alert)}
