:root { --blue: #005495; --accent: #4169E1; --on-accent: #ffffff; --bg: #f7f5f0; --card: #fff; --ink: #1a1a1a; }
* { box-sizing: border-box; }
body { margin: 0; font-family: system-ui, -apple-system, sans-serif; background: var(--bg); color: var(--ink); }
/* The app window must never slide sideways (Rob, v45): clip any stray
   horizontal overflow at the root. `clip` (not `hidden`) keeps the
   sticky header working. */
html, body { overflow-x: hidden; overflow-x: clip; max-width: 100%; }
/* v159 (Rob): z-index 30 so the sticky bar stays ABOVE page content —
   positioned elements (e.g. .photo-row) were painting over it while
   scrolling. 30 sits above content and the bottom nav (10) but below
   the overlay stack: update banner 50, modals 100, toast 200. */
header { background: var(--blue); color: #fff; padding: 12px 16px; position: sticky; top: 0; z-index: 30; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
#niLogo { height: 30px; display: block; box-sizing: border-box;
  /* v89: the lockup (orange check-nail + white wordmark) rides on a
     fixed brand-blue plaque so it stays visible on ANY header color a
     theme or company chooses (Rob). Same treatment as the app icon. */
  background: #005495; border-radius: 8px; padding: 4px 8px; }
/* Company logo sits directly on the header blue — no white halo box
   (Rob, v47). Slightly larger than before. */
#brandLogo { height: 38px; max-width: 160px; object-fit: contain; background: transparent; border-radius: 0; padding: 0; }
header h1 { margin: 0; font-size: 1.2rem; }
main { padding: 16px; max-width: 720px; margin: 0 auto; }
.card { background: var(--card); border-radius: 10px; padding: 14px; margin-bottom: 12px;
        border: 1.5px solid var(--accent);
        box-shadow: 0 1px 3px rgba(0,0,0,.08); }
.card.tap { cursor: pointer; }
.card.done { opacity: .65; }
/* Line items (v46): the description rides in a brand-color band with
   the item number — scannable at a glance, and a completed item's
   band turns green instead of striking the text through. */
.card.item-card { padding: 0; overflow: hidden; }
.card.item-card.done { opacity: 1; }
/* Report-items section divider (Rob, v53): a labeled band between
   the report action row and the first item, so it's obvious where
   the items begin. */
/* Accent halo (Rob): v56 put it on nested cards only; v67 puts it on
   EVERY card (see the .card rule above) so white boxes on the light
   background read clearly on every page. This nested rule stays as
   the slightly stronger shadow for cards inside cards. */
.login-slogan { text-align: center; font-weight: 600; color: var(--blue); letter-spacing: .02em; margin: 10px 0 2px; }
.person-row { padding: 8px 0 2px; }
.person-row + .person-row { border-top: 1px solid #e7edf2; margin-top: 6px; }
.card .card { border: 1.5px solid var(--accent); box-shadow: 0 1px 4px rgba(0, 0, 0, .05); }
/* v144 (Rob): the bar takes the same accent section-bar treatment
   as .form-sec — v53's navy text (var(--blue)) on a blue-tinted bar
   vanished in the dark theme (navy on navy, heading and count
   unreadable). v157: the bar rides the ACTIVE THEME's accent pair
   (var(--accent) / var(--on-accent)) instead of v144's fixed
   Meritage hex — under Meritage colors that pair IS #00A1FF /
   #002F55; under Nail It (dark) it's the logo orange with dark
   text. The old 3px top border stays dropped: the accent bar
   itself carries the separation, and the radius is uniform 8px
   like .form-sec. The count rides at 85% like .form-sec's
   .fm-count. */
.items-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin: 22px 0 10px; padding: 10px 12px; background: var(--accent); border-radius: 8px; }
.items-head h3 { margin: 0; font-size: 17px; color: var(--on-accent); }
.items-head .meta { color: var(--on-accent); opacity: .85; }
/* v160 (Rob): the band no longer fills with the bright primary blue —
   in the dark themes it read as a leftover Meritage strip amid the
   navy + accent. It takes a deep tint of the theme's own accent mixed
   into the card tone instead, with the theme's ink for the title
   (near-white on dark themes, near-black on light ones — card and ink
   are always a matched pair, so the title stays readable in every
   theme). The number bubble keeps the full accent. A completed
   item's band keeps its semantic green, with white text as before. */
.item-band { background: color-mix(in srgb, var(--accent) 30%, var(--card)); color: var(--ink); font-weight: 700; font-size: 1.05rem;
  line-height: 1.35; padding: 12px 14px; }
.item-card.done .item-band { background: #2e7d32; color: #fff; }
.item-num { display: inline-block; background: var(--num-bg, rgba(255,255,255,.25)); color: var(--accent-ink, #fff); border-radius: 999px;
  min-width: 24px; height: 24px; line-height: 24px; text-align: center; font-size: .85rem;
  vertical-align: 2px; margin-right: 8px; padding: 0 5px; }
.item-body { padding: 12px 14px 14px; }
/* Standard-locations picker rows (v48, Rob): checkbox on the LEFT,
   name lined up with it — the global input{width:100%} rule stretched
   bare checkboxes out of their rows. The box's own size and look live
   in the global checkbox rule (v168: the drawn box). */
.std-row { display: flex; align-items: center; gap: 10px; padding: 7px 4px; margin: 0; cursor: pointer; }
.std-row + .std-row { border-top: 1px solid #eee; }
.loc-row { display: flex; align-items: center; gap: 12px; cursor: pointer; }
/* The .loc-row / .theme-row radio discs are drawn by the global
   input[type="radio"] rule (v166's treatment, globalized in
   v170) — no separate rule lives here anymore. */
.loc-row.selected { background: color-mix(in srgb, var(--accent) 10%, var(--card)); box-shadow: inset 0 0 0 2px var(--accent); }
/* v195: Trades list vendor group header — one per vendor name when
   the vendor carries several specialty entries. */
.dir-group-head { margin: 16px 2px 6px; font-weight: 700; font-size: 15px; }
.dir-group-head:first-child { margin-top: 2px; }
/* User 1.5.43 (Rob): the Trades list alphabet selector — a row of
   small letter buttons over the vendor groups; the active letter
   fills with the accent. */
.dir-alpha { display: flex; flex-wrap: wrap; gap: 4px; margin: 4px 0 8px; }
.dir-alpha button.active { background: var(--accent); color: var(--on-accent); }
/* v195 amendment: per-row actions on Trades entries — compact
   Edit / Remove buttons riding at the row's right edge. */
.dir-row-actions { display: flex; gap: 6px; flex: none; margin-left: auto; align-items: center; }
/* v79: row text column must be able to shrink (long emails) so a
   right-side row button (Remove on a staged person) stays on the row. */
.loc-row > span { flex: 1; min-width: 0; }
.loc-row > button { flex: none; }
.loc-row .meta { overflow-wrap: anywhere; }
.csv-ex { overflow-x: auto; margin-bottom: 10px; }
.csv-ex table { border-collapse: collapse; font-size: 12.5px; }
/* v160: the export preview's header band takes the same treatment as
   .item-band (deep accent tint into the card tone, theme ink) instead
   of the bright primary fill. */
.csv-ex th { background: color-mix(in srgb, var(--accent) 30%, var(--card)); color: var(--ink); font-weight: 700; text-align: left; padding: 6px 8px; border: 1px solid color-mix(in srgb, var(--ink) 25%, var(--card)); white-space: nowrap; }
.csv-ex td { background: var(--card); color: var(--ink); padding: 6px 8px; border: 1px solid color-mix(in srgb, var(--ink) 25%, var(--card)); white-space: nowrap; }
.pick-row { display: flex; gap: 8px; align-items: stretch; margin-bottom: 10px; }
.pick-row input { flex: 1; margin-bottom: 0; }
/* v174 (Rob): "List boxes are larger than adjacent boxes" — in the
   .chain-add add rows (HOO punch/exceptions, 21 DAY concerns) the
   ▼ List buttons stood 46px against their input's 40px, tops aligned
   but bottoms 6px low. Measured cause: .chain-add input carries a
   6px bottom margin (line ~466 — equal specificity to .pick-row
   input's margin-bottom: 0 above, and later in the file, so it
   wins), so the input's MARGIN box sets the .pick-row flex line at
   46px; the input's border box stays 40, but the marginless button,
   stretched by the row's align-items: stretch, takes the full 46.
   (The item editor's pick-rows sit outside .chain-add, so their
   buttons already measured 40 — and the mic button escaped this in
   v169 only because it carries a definite height.) The pick button
   now gets the same anchor as button.mic: exactly one input tall,
   40px, so input, mic, and List button share one height in every
   .pick-row, tops and bottoms aligned. If the input rule's padding
   or font-size ever changes, change this height with it.
   v176 (Rob): "Mic and list should be same size" — this button and
   button.mic now share ONE box: height 40px (the input anchor
   above) and width 80px, the least that encloses the larger
   content ("▼ List", measured natural width ≈75px at the shared
   0 14px padding) with comfortable padding. Because every add-row
   pairs one field with one of these two buttons, the shared width
   also puts every field in the stack at one identical length. If
   the shared width ever changes, change button.mic's with it. */
.pick-btn { flex: none; padding: 0 14px; height: 40px; width: 80px; }
.toolbar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.toolbar button { min-width: 0; }
/* v150 (Rob): report detail header card layout — Edit header gets
   its own right-aligned line at the very top of the card, above the
   title block, so the title always runs the full card width below
   it and never shares the button's line. The bottom action row
   pushes Assign (left) and Delete (right) to the ends. */
.detail-head-edit-row { display: flex; justify-content: flex-end; margin-bottom: 8px; }
/* User 1.5.54 (Rob, 2026-11-21): the lot bar at the top of the
   report view — the lot and the two start-something buttons for
   that home, slim so it never pushes the work down. */
.lot-bar { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 12px; }
.detail-head-actions { flex-wrap: nowrap; justify-content: space-between; }
/* v152 (Rob): the report detail action buttons sit two per row,
   each pair sharing its row evenly — Download PDF | Countertop
   Report on the first row, Email report | View report status on
   the second. */
.detail-actions button { flex: 1 1 0; }
/* v143: the one add-item action for reports and milestone forms.
   A single shared treatment so every surface says — and shows —
   the same thing: full width, accent fill, bold text. v157: the
   fill/text ride the active theme's accent pair (var(--accent) /
   var(--on-accent)), not v143's fixed Meritage hex. */
.add-deficiency-btn { width: 100%; background: var(--accent); color: var(--on-accent);
  font-weight: 800; font-size: 1.05rem; line-height: 1.25;
  padding: 16px 18px; margin: 0 0 12px; border-radius: 10px;
  box-shadow: 0 2px 8px color-mix(in srgb, var(--accent) 35%, transparent); }
/* v160 (Rob): every accent element takes the theme's single accent —
   no fixed blue fills, no fixed light treatments. The shared primary
   button fills with var(--accent) and reads in var(--on-accent)
   (orange with dark text under Nail It dark, cyan with navy text
   under Meritage colors); outline buttons (ghost here, secondary
   below) draw and read in var(--accent) directly instead of the old
   --btnline/--blue fallback chain. */
button { background: var(--accent); color: var(--on-accent); border: 0; border-radius: 8px;
         padding: 10px 16px; font-size: 1rem; cursor: pointer;
         -webkit-tap-highlight-color: transparent; user-select: none; }
button:active { transform: scale(0.97); filter: brightness(0.9); }
button.ghost { background: transparent; color: var(--accent); border: 1px solid var(--accent); }
button.ghost:active { background: color-mix(in srgb, var(--accent) 14%, transparent); }
button.small { padding: 6px 10px; font-size: .85rem; margin-top: 8px; }
button:disabled { opacity: 0.6; cursor: default; transform: none; }
/* v198: an anchor that must read as a button (the Text invite sms:
   link in the invite modals) — same box, padding, and accent rules
   as button / button.ghost / button.small, never a bare text link. */
a.btnlink { display: inline-block; background: var(--accent); color: var(--on-accent); border: 0; border-radius: 8px;
         padding: 10px 16px; font-size: 1rem; cursor: pointer; text-decoration: none;
         -webkit-tap-highlight-color: transparent; user-select: none; }
a.btnlink:active { transform: scale(0.97); filter: brightness(0.9); }
a.btnlink.ghost { background: transparent; color: var(--accent); border: 1px solid var(--accent); }
a.btnlink.ghost:active { background: color-mix(in srgb, var(--accent) 14%, transparent); }
a.btnlink.small { padding: 6px 10px; font-size: .85rem; margin-top: 8px; }
/* v199: the grayed Text invite — same treatment as button:disabled
   above (opacity 0.6, cursor default, no tap transform or active
   wash). The anchor carries no sms: href; its tap only explains. */
a.btnlink.disabled { opacity: 0.6; cursor: default; }
a.btnlink.disabled:active { transform: none; filter: none; background: transparent; }
/* v172: visually hidden but still functional — for native controls
   whose own rendering breaks the theme (the file input's button
   paints white on dark themes). The element stays clickable and
   script-reachable; a styled control drives it instead. */
.visually-hidden { position: absolute; width: 1px; height: 1px; margin: -1px;
  padding: 0; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%);
  border: 0; white-space: nowrap; }
/* v160 (Rob): form-control borders take the theme accent at the same
   strength as the .card border, so inputs, selects, and textareas
   read as one system with the cards instead of a fixed light-gray
   (#ccc) line that rendered white in the dark themes.
   v163 (Rob): the borders are the accent itself — plain var(--accent)
   at full strength, the same color as the chevrons/arrows. The pale
   50%-white mix (v160) and the darker 55%-black mix (v162) are both
   superseded by his call: "Why cant they be the same color as the
   arrows?" Card borders use the same plain accent. */
input { width: 100%; padding: 10px; margin-bottom: 10px; border: 1px solid var(--accent);
        border-radius: 8px; font-size: 1rem; background: var(--card); color: var(--ink); }
/* User 1.5.38 (Rob): a locked field must LOOK locked. The rule
   above paints every box the same, so a read-only standard title
   or the builder name read as editable. Grey them. */
input.is-locked, input:disabled { background: #e9e6df; color: #6f6a5e; }
/* One size for every selector control in the app (Rob, v51): real
   radios and checkboxes render 22px everywhere — Lists, the
   Assign-to-team picker, Standard locations, Settings.
   v166 (Rob): the radio discs are DRAWN, not native — a native
   unchecked radio renders as a plain white circle, the loudest
   thing on a dark screen. Ring when off, filled when selected:
   appearance:none; off = accent ring with the surface showing
   through the center; on = accent fill with the on-accent tone
   as the center dot.
   v170 (Rob): "Radio boxes and circles everywhere should be
   hollow with accent color until selected. No white." — the
   drawn treatment moves from the v166 row contexts into this
   global rule so EVERY radio is covered, including the
   home-merge comparison radios, the last native holdouts. */
input[type="radio"] { -webkit-appearance: none; appearance: none;
  width: 22px; height: 22px; flex: none; margin: 0; padding: 0;
  border: 2px solid var(--accent); border-radius: 50%;
  background: transparent; cursor: pointer; }
input[type="radio"]:checked { background: radial-gradient(circle, var(--on-accent) 0 4px, var(--accent) 4px); }
input[type="radio"]:disabled { opacity: .55; cursor: default; }
input[type="radio"]:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
/* v170: the merge radios ride a smaller disc that fits their
   pick-one rows — same drawn treatment at 20px, dot scaled. */
input[type="radio"].mg-radio { width: 20px; height: 20px; }
input[type="radio"].mg-radio:checked { background: radial-gradient(circle, var(--on-accent) 0 3.5px, var(--accent) 3.5px); }
/* v168 (Rob): the v166 white-disc problem in checkbox form — a
   native UNCHECKED checkbox renders as a bright white square on the
   dark themes (his words on the HOO grid: "white box is too
   white"). Draw the box from the theme tokens like the discs:
   appearance:none, off = an open square outlined in the accent with
   the surface showing through; on = the accent fill Rob approved,
   with the check drawn in var(--on-accent) so every theme keeps its
   pairing (dark check on orange/cyan, white on the deep reds). The
   check is a rotated border pair on ::after — plain CSS borders in
   the variable, no image, so no check color is hard-coded anywhere.
   One global treatment for every square checkbox: the HOO grid and
   21 DAY checklist (.hoo-chk), the standard-locations rows
   (.std-row), the Lists start-over scope rows (.loc-row), the
   coordinator/overview community picks, the report header editor
   boxes, and Settings. */
input[type="checkbox"] { -webkit-appearance: none; appearance: none;
  width: 22px; height: 22px; flex: none; margin: 0; padding: 0;
  border: 2px solid var(--accent); border-radius: 5px;
  background: transparent; cursor: pointer; position: relative; }
input[type="checkbox"]:checked { background: var(--accent); }
input[type="checkbox"]:checked::after { content: ""; position: absolute;
  left: 5px; top: 2px; width: 8px; height: 13px;
  border: solid var(--on-accent); border-width: 0 3px 3px 0;
  transform: rotate(45deg); }
input[type="checkbox"]:disabled { opacity: .55; cursor: default; }
input[type="checkbox"]:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
select { width: 100%; padding: 10px; margin-bottom: 10px; border: 1px solid var(--accent);
        border-radius: 8px; font-size: 1rem; background: var(--card); color: var(--ink); }
.meta { color: #666; font-size: .85rem; display: block; margin-top: 4px; }
/* Instructions (v102): the closing notes inside help topics are body
   text, not small print — left as .meta they shrank and went gray at
   the bottom of every topic (Rob, Oct 23). */
.help-body .meta { color: inherit; font-size: 1rem; }
/* Email usage counter (v103, Rob): a number the admin is responsible
   for — it renders as body text, not small print. */
.usage-line { font-size: 1rem; margin-top: 10px; }
.badge { display: inline-block; color: var(--ink); background: color-mix(in srgb, var(--ink) 10%, var(--card)); border-radius: 20px; padding: 2px 10px;
         font-size: .75rem; margin-top: 6px; }
.badge.done { background: #d4edda; color: #155724; }
/* Classification badges (v46): Damage and Workmanship must read at a
   glance — red for damage, burnt orange for workmanship. */
.badge.cls-damage, .badge.cls-workmanship { color: #fff; font-weight: 700;
  font-size: .85rem; padding: 4px 12px; letter-spacing: .02em; }
.badge.cls-damage { background: #b3261e; }
.badge.cls-workmanship { background: #e65100; }
.err { color: #c00; }
.list { display: flex; flex-direction: column; }
h2 { margin: 4px 0 8px; }
.bottomnav { position: fixed; bottom: 0; left: 0; right: 0; display: flex;
  background: var(--card); border-top: 1px solid color-mix(in srgb, var(--ink) 15%, var(--card)); z-index: 10; }
.bottomnav button { flex: 1; min-width: 0; background: transparent; color: #666; border-radius: 0;
  padding: 12px 4px; font-size: .8rem; }
.bottomnav button.active { color: var(--accent); font-weight: 700; }
#updateBanner { position: fixed; left: 10px; right: 10px; bottom: 76px; z-index: 50;
  background: var(--blue); color: #fff; border-radius: 10px; padding: 10px 12px;
  display: flex; align-items: center; gap: 10px; font-size: .9rem;
  box-shadow: 0 4px 14px rgba(0,0,0,.25); }
#updateBanner span { flex: 1; }
#updateBanner button { background: #fff; color: var(--blue); font-weight: 700;
  border: none; border-radius: 6px; padding: 6px 12px; }
#updateBanner #ubDismiss { background: transparent; color: #fff; font-size: 1.1rem; padding: 2px 6px; }
main { padding-bottom: 70px; }
.card.scripture { border-left: 4px solid var(--blue); background: #f8f6f0; }
.card.scripture .verse { font-style: italic; font-size: 1.05rem; line-height: 1.5; margin: 0 0 8px; }
.card.scripture-invite { border-left: 4px solid var(--accent, #4169E1); background: #f0f4ff; cursor: pointer; }
.modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 100;
  display: flex; align-items: flex-end; justify-content: center; }
.modal { width: 100%; max-width: 720px; max-height: 90vh; overflow-y: auto;
  border-radius: 16px 16px 0 0; margin: 0; }
.modal label { display: block; font-size: .85rem; color: color-mix(in srgb, var(--ink) 62%, var(--card)); margin: 10px 0 4px; }
.modal textarea { width: 100%; padding: 10px; border: 1px solid var(--accent); border-radius: 8px;
  font-size: 1rem; font-family: inherit; resize: vertical; background: var(--card); color: var(--ink); }
.desc-row { display: flex; gap: 8px; align-items: flex-start; }
.desc-row textarea { flex: 1; min-width: 0; }
/* v137: input + dictation mic row (people/contact fields) */
.mic-row { display: flex; gap: 8px; align-items: stretch; }
.mic-row input { flex: 1; min-width: 0; margin-bottom: 0; }
/* User 1.5.16 (Rob): description/notes fields are auto-growing
   textareas — the same face as the text inputs they replace, with
   the height driven by content (autoGrowTextarea in app.js) so the
   whole text stays visible while typing and when a form reopens
   with text already in the box. No resize handle, no scrollbar of
   its own; the rows attribute is the resting (minimum) height. */
textarea.autogrow { width: 100%; padding: 10px; margin-bottom: 10px; border: 1px solid var(--accent);
  border-radius: 8px; font-size: 1rem; font-family: inherit; line-height: 1.35;
  background: var(--card); color: var(--ink); resize: none; overflow-y: hidden; box-sizing: border-box; }
.mic-row textarea.autogrow { flex: 1; min-width: 0; margin-bottom: 0; }
.chain-add textarea.autogrow { margin-bottom: 0; }
/* v169 (Rob): "mic and selected boxes are off sized" — the old mic
   box (1.4rem glyph + 10px of vertical padding) stood ~46px tall
   against the text input's 40px (10px padding + the 1rem line + its
   2x1px border), and a text input does not stretch to a flex row's
   height, so the button set the row's height and towered over the
   field it serves (his HOO screenshot). The button is now exactly
   one input tall — height: 40px, no vertical padding — in the
   forms' .mic-row rows and the item editor's .desc-row alike. If
   the input rule's padding or font-size ever changes, change this
   height with it.
   v176: width 80px — the same box as .pick-btn (see its note):
   Rob's one-size rule for the mic and List buttons, which is also
   what makes the description field the same length as the pick
   fields beside it. */
button.mic { font-size: 1.4rem; padding: 0 14px; flex-shrink: 0; height: 40px; width: 80px; }
/* v140: the mic glyph is an inline SVG (MIC_ICON_SVG, shared from
   itemEditor.js), sized off the button's font-size like the emoji
   it replaced — same tap target, same footprint. */
button.mic .mic-icon { width: 1.15em; height: 1.15em; display: inline-block; vertical-align: middle; }
/* While listening the button goes red and the icon turns white
   (it is drawn in currentColor), with a soft ring around the
   button on top of the pulse — unmissable at a glance. */
button.mic.listening { background: #c00; color: #fff; animation: pulse 1s infinite;
  box-shadow: 0 0 0 3px rgba(204, 0, 0, .35); }
/* v140: home editor error banner — pinned at the top of the editor
   card, impossible to miss. The explicit [hidden] rule matters:
   this class sets display:flex, which would otherwise override
   the browser's [hidden] { display:none } (v84 lesson). */
.hm-banner { display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  border: 1.5px solid #c00; border-radius: 8px; padding: 10px 12px; margin-bottom: 12px;
  background: color-mix(in srgb, #c00 10%, var(--card)); font-weight: 600; }
.hm-banner[hidden] { display: none; }
.hm-banner #hmBannerText { flex: 1; min-width: 0; }
.hm-banner #hmBannerDismiss { flex: none; }
/* v140: Homes list card tap hint (the card opens the home hub). */
.home-chev { float: right; color: var(--accent); font-size: 1.75rem; font-weight: 800; line-height: 1; }
@keyframes pulse { 50% { opacity: .6; } }
.photo-row { display: flex; gap: 8px; margin-top: 8px; flex-wrap: wrap; position: relative; }
/* v131: diagonal completion stamp across a completed item's photo
   strip — bold green, semi-transparent so the deficiency photos (the
   evidence) stay fully readable underneath. Pure presentation from
   item state; pointer-events off so photo taps pass through. */
.done-stamp { position: absolute; top: 50%; left: 50%; z-index: 2;
  transform: translate(-50%, -50%) rotate(-14deg);
  font-size: 1.3rem; font-weight: 800; letter-spacing: .1em; white-space: nowrap;
  color: rgba(29, 122, 61, .82); background: rgba(255, 255, 255, .22);
  border: 3px solid rgba(29, 122, 61, .55); border-radius: 8px;
  padding: 3px 14px 5px; pointer-events: none; }
.photo-row .thumb { width: 80px; height: 80px; object-fit: cover; border-radius: 8px; cursor: pointer; }
.photo-row .thumb.after-thumb { outline: 3px solid #1d7a3d; outline-offset: -3px; }
.modal-overlay.photo-editor { flex-direction: column; align-items: center; justify-content: flex-start;
  background: rgba(0,0,0,.92); padding: 0; }
.photo-canvas-wrap { flex: 1; display: flex; width: 100%; min-height: 0; overflow: auto; }
.photo-canvas-wrap canvas { margin: auto; flex: none; }
.photo-toolbar { display: flex; flex-wrap: wrap; gap: 8px; padding: 10px; width: 100%; max-width: 720px;
  justify-content: center; background: rgba(0,0,0,.8); box-sizing: border-box; }
.photo-toolbar button { flex: 1 1 28%; min-width: 0; font-size: 14px; padding: 8px 2px;
  white-space: nowrap; overflow: hidden; }
.photo-textbar { width: 100%; max-width: 720px; background: var(--card); color: var(--ink); padding: 10px 12px;
  box-sizing: border-box; }
.photo-textbar textarea { width: 100%; box-sizing: border-box; font-size: 16px; padding: 8px;
  border: 1px solid var(--accent); border-radius: 8px; font-family: inherit; }
.photo-textbar-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 8px; }
.photo-textbar-row button { min-width: 0; }
.photo-textbar-row label { display: flex; align-items: center; gap: 6px; }
.photo-textbar-row select { font-size: 16px; padding: 6px; }
.photo-textbar-row button { flex: 1; }
.login-poster { display: block; width: 100%; max-width: 720px; margin: 0 auto 12px;
  border-radius: 12px; }
.spinner { display: inline-block; width: 14px; height: 14px; border: 2px solid #fff;
  border-top-color: transparent; border-radius: 50%; animation: spin .6s linear infinite;
  vertical-align: -2px; margin-right: 6px; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Lists screen: the four list names are the primary navigation there —
   they must read bigger than the Add / Import actions under them. */
.dirtabs { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.dirtabs button { font-size: 18px; font-weight: 700; padding: 13px 12px; width: 100%; }
.dir-actions { display: flex; flex-direction: column; gap: 8px; margin-bottom: 14px; }
.dir-actions button { width: 100%; }

/* Themes (v75): header theme button + picker rows. */
.hdr-right { display: flex; align-items: center; gap: 10px; }
#themeBtn, #soundBtn { background: rgba(255,255,255,.15); border: 1px solid rgba(255,255,255,.45);
  border-radius: 8px; padding: 5px 10px; font-size: 1.05rem; line-height: 1.2; }
button.secondary { background: var(--card); color: var(--accent);
  border: 1.5px solid var(--accent); }
.theme-group { font-weight: 700; margin: 16px 0 4px; color: var(--ink); }
/* v165: Homes list community group heading — a plain list label
   in the .theme-group family, a step smaller and muted. Not the
   .form-sec accent bar; this is a quiet list, not a form. */
.home-group { font-weight: 700; font-size: .9rem; margin: 16px 0 4px; color: var(--ink); opacity: .7; }
.modal label.theme-row { display: flex; align-items: center; gap: 10px;
  padding: 8px 6px; margin: 0; color: var(--ink); font-size: 1rem;
  border-radius: 8px; cursor: pointer; }
.tdots { display: inline-flex; gap: 4px; flex: none; }
.tdots i { width: 18px; height: 18px; border-radius: 50%;
  border: 1px solid rgba(0,0,0,.25); display: block; }

/* The hidden attribute must always win. A class rule that sets
   display (grid/flex/block) silently overrides the browser's
   [hidden] style — that is why the Settings menu never hid and the
   People view opened underneath it, below the fold (Rob, Oct 22). */
[hidden] { display: none !important; }

/* Settings category menu (v81, Rob): Settings opens as a short menu
   of category buttons instead of one long stack of cards. Each
   button opens its section in a pop-up window; People gets its own
   full-screen subview. The section cards themselves are unchanged —
   they live in a hidden store and are moved into the window. */
.settings-menu { display: grid; gap: 10px; }
.settings-category { width: 100%; display: flex; align-items: center;
  justify-content: space-between; gap: 12px; text-align: left;
  background: var(--card); color: var(--ink);
  border: 1.5px solid var(--accent);
  border-radius: 10px; padding: 14px;
  box-shadow: 0 1px 3px rgba(0,0,0,.08); font-size: 1rem; }
.settings-category strong { display: block; font-size: 1rem; }
.settings-category .meta { margin-top: 2px; }
.settings-chevron { color: var(--accent); font-size: 1.75rem; font-weight: 800; line-height: 1; flex: none; }
.settings-signout { width: 100%; }
.settings-window-head { display: flex; justify-content: flex-end; margin-bottom: 4px; }
/* v86: exits must be unmissable — every settings window gets a prominent
   Close pill, and People gets a full-size Back button at top AND bottom
   (Rob, Oct 22 2026: "no clear way to exit" / invisible Close). */
.settings-close { padding: 8px 16px; font-size: .95rem; font-weight: 700;
  border-width: 1.5px; border-radius: 999px; }
.settings-back-btn { padding: 10px 16px; font-size: 1rem; font-weight: 600; }
.settings-people-foot { margin-top: 18px; padding-bottom: 10px; }
.settings-window-body > .card { border: 0; box-shadow: none; margin-bottom: 0; padding: 0; }
.settings-window-body > .card + .card { margin-top: 18px; }
.settings-people-head { margin-bottom: 12px; }

/* v106: photos waiting to upload from this phone */
.pending-thumb { position: relative; display: inline-block; }
.thumb.pending { opacity: .55; }
.pending-badge { position: absolute; left: 0; right: 0; bottom: 0; font-size: .6rem; line-height: 1.3; background: rgba(0,0,0,.65); color: #fff; text-align: center; padding: 1px 2px; border-radius: 0 0 6px 6px; }

/* v115: a waiting photo is a small stack — tile + its own Upload now
   button — so sending it is a deliberate tap, never a hidden refresh. */
.pending-wrap { display: inline-flex; flex-direction: column; gap: 4px; width: 80px; vertical-align: top; }
.pending-wrap .upload-now { width: 100%; margin-top: 0; padding: 4px 0; font-size: .72rem; }

/* User 1.2: the BBR Review Notes list shows a point's anchor photo
   as a small thumb beside its note. */
.bbr-note-thumb { width: 44px; height: 44px; object-fit: cover; border-radius: 6px; vertical-align: middle; margin-right: 4px; }

/* v115: transient toast — the app otherwise answers only with modal
   dialogs or per-view flash cards; an in-place action (Upload now)
   needs an answer that doesn't take over the screen. */
.app-toast { position: fixed; left: 50%; bottom: 84px; transform: translateX(-50%) translateY(8px); background: rgba(20,26,32,.94); color: #fff; padding: 10px 14px; border-radius: 10px; font-size: .9rem; max-width: 88vw; text-align: center; opacity: 0; pointer-events: none; transition: opacity .18s ease, transform .18s ease; z-index: 200; }
.app-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* v134: move-in form (HOO) — the form's own letterhead surfaces are
   uniform #002F55 (masthead + section bars) in every app theme; the
   signature box shade matches the printed form's DocuSign boxes.
   v142 (Rob): the masthead keeps #002F55, but the in-app section
   bars (.form-sec) were "too dark against the other blue" — they
   took Meritage's second accent #00A1FF with navy text. v157
   (Rob): that fixed hex only suited the Meritage colors — the
   bars now ride the ACTIVE THEME's accent pair (var(--accent) /
   var(--on-accent)), so under Nail It (dark) they're the logo
   orange, under Meritage colors still #00A1FF / #002F55. APP UI
   ONLY: the printed PDFs (server/formpdf.js) keep the paper
   #002F55 bars. */
.form-mast { background: #002F55; border-radius: 10px; padding: 8px 12px; display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.form-mast img { height: 46px; width: auto; }
.form-mast .fm-title { color: #fff; font-weight: 700; text-align: right; font-size: .95rem; line-height: 1.3; }
/* v170 (Rob): the bar is a flex row, not text with a floated
   counter. The float let the counter collide with the bar's
   lower edge — half-clipped — whenever the title wrapped to two
   lines (the 21 DAY bar: "Each item marked as demonstrated to /
   discussed with the homeowner"). Now the title wraps inside its
   own flex slot and the counter holds a clear slot at the right
   (dropping to its own line only if the title truly needs the
   whole width) — the two can never overlap, and the one-line
   bars (HOO's "Orientation Review") look exactly as before. */
.form-sec { background: var(--accent); color: var(--on-accent); font-weight: 700; border-radius: 8px; padding: 8px 12px; margin-bottom: 10px; font-size: .95rem;
  display: flex; align-items: flex-start; flex-wrap: wrap; gap: 2px 12px; }
.form-sec .fm-count { margin-left: auto; flex: none; padding-top: .1rem; font-weight: 400; font-size: .85rem; opacity: .85; }
.hdr-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
@media (max-width: 520px) { .hdr-grid { grid-template-columns: 1fr; } }
.hoo-cols { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px 14px; }
@media (max-width: 900px) { .hoo-cols { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .hoo-cols { grid-template-columns: 1fr; } }
.d21-cols { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2px 14px; }
@media (max-width: 700px) { .d21-cols { grid-template-columns: 1fr; } }
.hoo-chk { display: flex; gap: 8px; align-items: flex-start; padding: 3px 0; font-size: .88rem; cursor: pointer; }
.hoo-chk.sub { padding-left: 22px; }
/* v142: the form checklist boxes (HOO review grid + 21 DAY checklist,
   both .hoo-chk) render in the accent too. The BBR's outcome tints
   are buttons, not inputs, and keep their paper meaning untouched.
   v157: the accent is the active theme's var(--accent), not the
   fixed Meritage hex. v168: accent-color no longer applies — the
   global drawn-checkbox rule (appearance:none) styles these boxes
   like every other checkbox in the app. */
/* v136: BBR points — one point per block, three outcome buttons whose
   selected state carries the paper's column tints (pale green /
   yellow / pink), and the inline note under the marks. */
.bbr-point { border-top: 1px solid color-mix(in srgb, var(--ink) 14%, transparent); padding: 9px 0 4px; }
.bbr-point:first-of-type { border-top: 0; }
.bbr-marks { display: flex; gap: 6px; margin: 7px 0; }
.bbr-mark { flex: 1 1 0; background: transparent; color: var(--ink); border: 1px solid #c4d0dd; border-radius: 8px; padding: 8px 4px; font-size: .82rem; cursor: pointer; }
.bbr-mark.acc.on { background: #cfe3c2; border-color: #7fae72; color: #274a1e; font-weight: 700; }
.bbr-mark.maint.on { background: #f7ecc0; border-color: #c2a94e; color: #57450a; font-weight: 700; }
.bbr-mark.svc.on { background: #f3c8c8; border-color: #c07a7a; color: #5f1f1f; font-weight: 700; }
.chain-item { border-top: 1px solid color-mix(in srgb, var(--ink) 14%, transparent); padding: 8px 0 2px; }
/* v155: raw sign-off URLs live in a contained inset box. A bare <a>
   had no wrap (the address bled off the card's edge) and no color
   rule (it fell back to the browser's dark-navy link color —
   unreadable on dark cards). The box wraps the address inside the
   card and reads in the theme's ink on light and dark themes. */
.signoff-url { display: block; word-break: break-all; overflow-wrap: anywhere;
  background: color-mix(in srgb, var(--ink) 7%, var(--card));
  border: 1px solid color-mix(in srgb, var(--ink) 18%, var(--card));
  border-radius: 8px; padding: 8px 10px; margin: 8px 0;
  color: var(--ink); font-size: .82rem; line-height: 1.45; }
/* v176 (Rob): "Vertical spacing is also not uniform" — the add-row
   stack's rhythm now lives HERE, on the container: one 10px gap
   between every pair of rows (description → Location → Assigned →
   Caused by → toggle → Add button), the app's standard row spacing.
   Before, the gaps measured 6 / 16 / 16 / 24 / 0 because each piece
   carried its own margin: the inputs' 6px below (the old rule on
   this line — the same margin box that caused the v174 stretch),
   the pick-rows' 10px, the toggle toolbar's margins plus its small
   buttons' 8px top margin, and the Add button's 12px bottom margin.
   All are neutralized inside the stack only; outside it (report
   item lists, other toolbars) they are untouched. With the input
   margin at 0, the v174 stretch mechanism cannot recur either. */
.chain-add { display: flex; flex-direction: column; gap: 10px; }
.chain-add input { margin-bottom: 0; }
.chain-add .pick-row { margin-bottom: 0; }
.chain-add .toolbar { margin: 0; }
.chain-add .toolbar button { margin-top: 0; }
.chain-add .add-deficiency-btn { margin: 0; }
.sig-row { border-top: 1px solid color-mix(in srgb, var(--ink) 14%, transparent); padding: 10px 0 2px; }
.sig-row:first-of-type { border-top: 0; }
/* v177: the signature pad. The old .sig-box was a light slab with a
   "Mark signed" button; the pad keeps the app's own surfaces — the
   card's color with an accent border — and the signature draws in
   the theme's ink color (--ink contrasts with the card in every
   theme), so nothing white or off-theme appears. The 5/2 aspect
   matches the capture space (1000×400) the client normalizes to;
   at card width that lands ~120–150px tall, sized for a finger.
   touch-action: none keeps a signing stroke from scrolling the
   page. A faint ruled line near the bottom is the writing guide. */
.sig-pad-wrap { margin-bottom: 10px; }
canvas.sig-pad { display: block; width: 100%; aspect-ratio: 5 / 2;
  background:
    linear-gradient(to bottom, transparent calc(100% - 27px), color-mix(in srgb, var(--ink) 22%, transparent) calc(100% - 27px), color-mix(in srgb, var(--ink) 22%, transparent) calc(100% - 26px), transparent calc(100% - 26px)),
    color-mix(in srgb, var(--accent) 5%, var(--card));
  border: 1.5px solid var(--accent); border-radius: 8px; touch-action: none; }
.sig-pad-off { border: 1.5px dashed color-mix(in srgb, var(--ink) 30%, transparent); border-radius: 8px;
  padding: 26px 10px; margin-bottom: 10px; text-align: center; opacity: .6; }
button.toggle-on { background: #1d7a3d; color: #fff; border: 1px solid #1d7a3d; }
