/* ============================================================================
   VANGUARD CUSTOMER PORTAL (MVP Prototype 2.0) — STYLES
   Brand tokens + components lifted from outputs/brand-sample.html (the signed-off
   styling foundation). Navy primary · sky-teal secondary · red = LOGO ONLY ·
   Plus Jakarta Sans · comfortable/airy. The feel, above everything: EASY.
   Why plain CSS variables (not the production token architecture): prototype,
   not production (ADR-0002 / docs/ui-ux.md). Koda rebuilds tokens for real.
   ============================================================================ */

/* ── BRAND TOKENS ─────────────────────────────────────────────────────────── */
:root{
  --navy:#004674; --navy-800:#003A60; --navy-50:#EBF3FA;
  --teal:#6FBED9;            /* brand secondary — sky teal */
  --teal-dark:#1F6F8F;       /* darker sky-teal for text/borders on white */
  --teal-50:#EAF6FB;
  --red:#ED2124;             /* LOGO ONLY — never a UI action */
  --error:#DC2626;
  --ink:#0F172A; --muted:#475569; --faint:#94A3B8;
  --line:#E2E8F0; --chrome:#F1F5F9; --canvas:#FFFFFF; --thead:#F8FAFC;
  --asphalt:#c8c8c8;          /* speed-calmer diagram backdrop (matches the reference configurator) */
  --ok-bg:#F0FDF4; --ok-bd:#BBF7D0; --ok-tx:#15803D;
  --warn-bg:#FFFBEB; --warn-bd:#FDE68A; --warn-tx:#B45309;
  --info-bg:#EFF6FF; --info-bd:#BFDBFE; --info-tx:#1D4ED8;
  --neu-bg:#F8FAFC; --neu-bd:#E2E8F0; --neu-tx:#475569;
  --err-bg:#FEF2F2; --err-bd:#FECACA; --err-tx:#B91C1C;
  /* Radius grammar: interactive · structural · overlay. Bumped for the 2.0
     look-&-feel refresh — softly rounded (not square, not pill), matching Oliver's
     CTA reference screenshots. */
  --ri:3px; --rs:5px; --ro:6px;   /* Option B — slight rounding (matches the documented radius grammar) */
  --shadow-sm:0 1px 3px rgba(0,0,0,.04);
  --shadow-pop:0 8px 28px rgba(15,23,42,.16);
  --shadow-lift:0 10px 24px rgba(31,111,143,.18);   /* teal-tinted "lift" on hover for clickable cards */
}
*{box-sizing:border-box;margin:0;padding:0}
html,body{height:100%}
body{font-family:'Plus Jakarta Sans',system-ui,sans-serif;color:var(--ink);background:var(--chrome);font-size:14px;line-height:1.5;-webkit-font-smoothing:antialiased}
a{color:inherit;text-decoration:none}
button{font-family:inherit}
/* Every click target (delegated data-action) shows the hand cursor, so anything
   clickable reads as clickable — links without href, table rows, cards, chips.
   'noop' overlays and the zoom-out lightbox keep their own; disabled = not-allowed. */
[data-action]:not([data-action="noop"]):not(.lightbox){cursor:pointer}
[data-action][disabled],[data-action]:disabled{cursor:not-allowed}
/* Content images open the lightbox on click, so they get the hand too (logo + the
   lightbox's own image excluded). */
#app img:not(.logo-img):not(.lightbox-img){cursor:pointer}
.hidden{display:none !important}
.muted{color:var(--muted)}
.tabnum{font-variant-numeric:tabular-nums}
/* Lucide inline icons (ADR-0006): align to text; flex containers centre them via align-items. */
.li{display:inline-block;vertical-align:-.14em;flex-shrink:0}
button .li,a .li{pointer-events:none}
.dot-online{display:inline-block;width:7px;height:7px;border-radius:50%;background:var(--ok-tx);margin-right:6px;vertical-align:middle}

/* ── GLOBAL ⌘K SEARCH — top-bar box + overlay (ADR-0006 tokens) ────────────── */
.topsearch{position:relative;display:inline-flex;align-items:center;gap:8px;min-width:210px;max-width:320px;flex:0 1 300px;font-size:13px;font-weight:500;color:var(--muted);border:1px solid var(--line);border-radius:var(--ri);padding:8px 12px;background:#fff;cursor:text}
.topsearch:hover{border-color:var(--teal)}
.topsearch .li{color:var(--faint)}
.topsearch .ts-ph{flex:1;text-align:left}
.topsearch .ts-kbd{font-size:10.5px;font-weight:700;color:var(--muted);background:var(--neu-bg);border:1px solid var(--neu-bd);border-radius:4px;padding:2px 6px;letter-spacing:.3px}
.topsearch:focus-visible{outline:2px solid var(--teal);outline-offset:1px}
@media(max-width:900px){.topsearch .ts-ph,.topsearch .ts-kbd{display:none}.topsearch{min-width:0;flex:0 0 auto;padding:8px}}
.search-ov{position:fixed;inset:0;background:rgba(15,23,42,.34);z-index:120;display:flex;justify-content:center;align-items:flex-start;padding:12vh 16px 16px}
.search-box{background:#fff;border:1px solid var(--line);border-radius:var(--ro);box-shadow:var(--shadow-pop);width:100%;max-width:620px;max-height:74vh;display:flex;flex-direction:column;overflow:hidden}
.search-top{display:flex;align-items:center;gap:10px;padding:14px 16px;border-bottom:1px solid var(--line)}
.search-top .li{color:var(--faint);flex-shrink:0}
.search-top input{flex:1;border:none;outline:none;font:inherit;font-size:16px;color:var(--ink);background:none}
.search-top .ts-esc{font-size:11px;font-weight:700;color:var(--muted);background:var(--neu-bg);border:1px solid var(--neu-bd);border-radius:4px;padding:3px 7px;cursor:pointer}
.search-results{overflow:auto;padding:6px}
/* Type-filter row (Batch 3) — HubSpot-style segmented chips above the results. */
.search-types{display:flex;flex-wrap:wrap;gap:6px;padding:8px 8px 4px;border-bottom:1px solid var(--line);margin-bottom:4px}
.stype{font:inherit;font-size:12px;font-weight:600;color:var(--muted);background:var(--neu-bg);border:1px solid var(--neu-bd);border-radius:var(--rs);padding:4px 10px;cursor:pointer;display:inline-flex;align-items:center;gap:6px}
.stype:hover{background:#eef2f7;color:var(--ink)}
.stype.on{background:var(--navy);border-color:var(--navy);color:#fff}
.stype .stn{font-size:11px;font-weight:700;opacity:.75}
.stype.on .stn{opacity:.9}
.search-grp{font-size:11px;font-weight:700;letter-spacing:.4px;text-transform:uppercase;color:var(--faint);padding:12px 12px 6px;display:flex;justify-content:space-between;align-items:baseline}
.search-grp .gn{color:var(--muted);font-weight:600}
.srow{display:flex;align-items:center;gap:12px;padding:9px 12px;border-radius:var(--ri);cursor:pointer}
.srow:hover,.srow.active{background:var(--teal-50)}
.srow .sic{width:34px;height:34px;border-radius:var(--ri);flex-shrink:0;display:flex;align-items:center;justify-content:center;background:var(--neu-bg);color:var(--muted)}
.srow .sbody{flex:1;min-width:0}
.srow .slabel{font-weight:600;color:var(--ink);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.srow .ssub{font-size:12px;color:var(--muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.srow .sacts{display:flex;gap:6px;flex-shrink:0}
.srow .sacts .btn{padding:5px 11px;font-size:12px}
.search-more{font-size:12px;font-weight:600;color:var(--teal-dark);padding:7px 12px;cursor:pointer;border-radius:var(--ri)}
.search-more:hover{background:var(--teal-50)}
.search-empty{padding:40px 24px;text-align:center;color:var(--muted)}
.search-empty .big{color:var(--faint);margin-bottom:10px}
.search-recent .rlab{font-size:11px;font-weight:700;letter-spacing:.4px;text-transform:uppercase;color:var(--faint);padding:12px 12px 4px}
.search-recent .ritem{display:flex;align-items:center;gap:10px;padding:9px 12px;border-radius:var(--ri);cursor:pointer;color:var(--muted);font-size:13px}
.search-recent .ritem:hover{background:var(--teal-50)}

/* ── PER-COLUMN HEADER FILTER (funnel + body-mounted popover) ──────────────── */
.tbl.list th.has-flt .th-lbl{display:inline-flex;align-items:center}
.tbl.list th.has-flt{white-space:nowrap}
.tbl.list th .th-flt{display:inline-flex;align-items:center;justify-content:center;margin-left:6px;padding:2px;border:0;background:transparent;color:var(--faint);border-radius:var(--ri);cursor:pointer;vertical-align:middle;line-height:0}
.tbl.list th .th-flt:hover{color:var(--navy);background:var(--navy-50)}
.tbl.list th .th-flt.on,.tbl.list th.flt-on .th-flt,.tbl.list th .th-flt.active{color:var(--navy);background:var(--navy-50)}
.tbl.list th.num .th-flt{margin-left:4px}
.colflt-pop{position:fixed;z-index:210;min-width:210px;max-width:280px;background:#fff;border:1px solid var(--line);border-radius:var(--rs);box-shadow:var(--shadow-pop);padding:10px;font-weight:400;text-transform:none;letter-spacing:0}
.colflt-pop .cflt-head{font-size:11px;font-weight:700;color:var(--muted);text-transform:uppercase;letter-spacing:.04em;margin-bottom:8px}
.colflt-pop .cflt-input{width:100%;height:34px;padding:0 10px;border:1px solid var(--line);border-radius:var(--ri);font-size:13px;color:var(--ink)}
.colflt-pop .cflt-input:focus{outline:none;border-color:var(--teal);box-shadow:0 0 0 3px var(--navy-50)}
.colflt-pop .cflt-list{max-height:220px;overflow:auto;display:flex;flex-direction:column;gap:2px}
.colflt-pop .cflt-opt{display:flex;align-items:center;gap:8px;padding:6px;font-size:13px;color:var(--ink);border-radius:var(--ri);cursor:pointer;white-space:nowrap}
.colflt-pop .cflt-opt:hover{background:var(--navy-50)}
.colflt-pop .cflt-opt input{width:15px;height:15px;accent-color:var(--navy);flex:0 0 auto}
.colflt-pop .cflt-opt span{overflow:hidden;text-overflow:ellipsis}
.colflt-pop .cflt-date{display:flex;flex-direction:column;gap:8px}
.colflt-pop .cflt-date label{display:flex;flex-direction:column;gap:3px;font-size:11px;font-weight:700;color:var(--muted);text-transform:uppercase;letter-spacing:.04em}
.colflt-pop .cflt-date input{height:34px;padding:0 10px;border:1px solid var(--line);border-radius:var(--ri);font-size:13px;color:var(--ink);font-family:inherit}
.colflt-pop .cflt-date input:focus{outline:none;border-color:var(--teal);box-shadow:0 0 0 3px var(--navy-50)}
.colflt-pop .cflt-foot{display:flex;justify-content:space-between;gap:8px;margin-top:10px;padding-top:8px;border-top:1px solid var(--line)}

/* ── DEMO TOOLBAR (testing device — NOT part of the product) ──────────────────
   The "view as role / switch test user" switcher. Dark strip so it reads as a
   scaffold, not portal chrome. Pairs with "no real auth" (ADR-0002). */
.demobar{background:#fff;color:var(--muted);display:flex;align-items:center;gap:12px;padding:8px 16px;font-size:12px;flex-wrap:wrap;border-top:1px solid var(--line);box-shadow:0 -2px 10px rgba(15,23,42,.06);z-index:40}
.demobar .tag{font-weight:700;letter-spacing:.03em;text-transform:uppercase;font-size:10.5px;color:var(--muted);display:flex;align-items:center;gap:6px}
.demobar .tag .blink{width:7px;height:7px;border-radius:50%;background:var(--teal);box-shadow:0 0 0 3px rgba(111,190,217,.3)}
.demobar label{color:var(--muted);font-size:11px;font-weight:600;margin:0}
.demobar select{font:inherit;font-size:12px;font-weight:600;background:#fff;color:var(--navy);border:1px solid var(--teal);border-radius:var(--ri);padding:5px 9px;cursor:pointer;max-width:320px}
/* persona picker becomes a searchable combo (19 users) — style its input to match */
.demobar .combo{display:inline-block;width:auto;position:relative}
.demobar .combo-input{font:inherit;font-size:12px;font-weight:600;background:#fff;color:var(--navy);border:1px solid var(--teal);border-radius:var(--ri);padding:5px 26px 5px 9px;cursor:text;min-width:260px;max-width:320px;margin:0}
.demobar .combo-caret{color:var(--teal)}
.demobar .spacer{flex:1}
.demobar .demo-meta{color:var(--navy);font-weight:600}
.demobar .demo-link{color:var(--navy);border-bottom:1px solid var(--teal);cursor:pointer;font-weight:700}
.demobar .demo-link:hover{border-color:var(--navy)}
.demo-fb-add{width:22px;height:22px;border-radius:50%;background:var(--navy);color:#fff;border:none;display:inline-flex;align-items:center;justify-content:center;cursor:pointer;vertical-align:middle;margin-right:2px}
.demo-fb-add:hover{background:var(--navy-800)}

/* ── FEEDBACK TOOL — capture/markup modal + index page thumbnails ──────────── */
/* Full-screen capture editor (BugHerd-style) — dark stage + big canvas on the left,
   fixed-width tool/form sidebar on the right. Sits above everything except the
   lightbox/tour (which never overlap it in practice). */
/* Opacity-only fade — NOT the shared .popin (translateY/scale). A transform mid-animation
   shifts what getBoundingClientRect() reports for the canvas underneath it, so if the user
   starts drawing before the animation settles, mouse coordinates get mapped against a
   moving/scaling box and the stroke lands somewhere other than the cursor. */
@keyframes fbFadeIn{from{opacity:0}to{opacity:1}}
.fb-editor{position:fixed;inset:0;z-index:150;background:rgba(15,23,42,.94);display:flex;animation:fbFadeIn .12s ease-out}
.fb-editor-close{position:fixed;top:20px;right:360px;width:40px;height:40px;border-radius:50%;border:none;background:rgba(255,255,255,.12);color:#fff;display:flex;align-items:center;justify-content:center;cursor:pointer;z-index:151}
.fb-editor-close:hover{background:rgba(255,255,255,.24)}
.fb-editor-canvas-area{flex:1;display:flex;align-items:center;justify-content:center;padding:40px;overflow:auto;min-width:0}
.fb-editor-sidebar{width:340px;flex-shrink:0;background:#fff;padding:28px 24px;overflow-y:auto;display:flex;flex-direction:column}
.fb-editor-sidebar h2{font-size:18px;font-weight:700;margin-bottom:4px}
.fb-page-tag{display:flex;align-items:center;flex-wrap:wrap;gap:7px;font-size:13px;color:var(--muted);margin:8px 0 2px}
.fb-page-pill{display:inline-flex;align-items:center;gap:5px;padding:4px 11px;border-radius:999px;background:var(--navy);color:#fff;font-weight:600;font-size:12.5px}
.fb-page-pill svg{width:13px;height:13px}
.fb-editor-actions{display:flex;gap:10px;margin-top:auto;padding-top:18px}
.fb-editor-actions .btn{flex:1}
.fb-toolbar{display:flex;align-items:center;gap:10px;margin:16px 0 10px;flex-wrap:wrap}
.fb-toolbar .segment{margin-bottom:0}   /* the shared .segment bottom-margin offset it in this centered row (Undo looked unaligned) */
/* display:inline-block so the wrapper shrink-wraps to the base canvas's rendered size —
   the annotation canvas (position:absolute, 100%/100%) then lines up with it exactly. */
.fb-canvas-wrap{position:relative;display:inline-block;border-radius:var(--rs);overflow:hidden;box-shadow:var(--shadow-pop);max-width:100%;max-height:100%;line-height:0}
.fb-canvas-wrap .fb-base-canvas{cursor:default;display:block;max-width:100%;max-height:calc(100vh - 80px);width:auto;height:auto}
.fb-canvas-wrap .fb-annotation-canvas{position:absolute;top:0;left:0;width:100%;height:100%;cursor:crosshair}
/* Spotlight, not fill: the selection stays clear and everything around it is dimmed.
   The huge spread box-shadow is clipped by .fb-canvas-wrap's overflow:hidden, so it
   only darkens the screenshot area, not the whole editor. */
#fb-crop-box{position:absolute;border:2px dashed var(--navy);background:transparent;box-shadow:0 0 0 9999px rgba(15,23,42,.5);pointer-events:none}
.fb-thumb{width:56px;height:40px;border-radius:var(--ri);object-fit:cover;background:var(--chrome);border:1px solid var(--line)}
.fb-thumb-empty{width:56px;height:40px;border-radius:var(--ri);background:var(--neu-bg);border:1px dashed var(--line)}
.fb-comment{max-width:340px;white-space:normal;line-height:1.4}
.fb-response{max-width:300px;white-space:normal;line-height:1.4;color:var(--ink);font-weight:500}
.fb-noresponse{color:var(--faint);font-size:12px;font-style:italic}
.fb-rowacts{display:inline-flex;gap:6px;justify-content:flex-end;flex-wrap:wrap}
@media (max-width:900px){
  .fb-editor{flex-direction:column}
  .fb-editor-sidebar{width:100%}
  .fb-editor-close{right:20px}
}

/* ── BUTTONS ──────────────────────────────────────────────────────────────── */
.btn{font:inherit;font-weight:600;border-radius:var(--ri);padding:10px 18px;cursor:pointer;border:1.5px solid transparent;font-size:14px;display:inline-flex;align-items:center;justify-content:center;gap:8px;white-space:nowrap;transition:background .15s ease,border-color .15s ease,box-shadow .15s ease,transform .1s ease}
.btn:disabled{opacity:.5;cursor:not-allowed}
/* Vanguard double-chevron signature — only on the prominent full-width primary
   CTAs (refs: Rounded CTA 1/2.png) so it stays special; not on small card buttons
   or modal confirm buttons. The inline "→" was stripped from these in app.js. */
.btn-primary.btn-block::after{content:"»";font-weight:800;font-size:1.1em;line-height:1}
.btn-primary.btn-block.btn-send::after{content:none}   /* trailing icon replaces the » on this button only */
.btn-primary{background:var(--navy);color:#fff}
.btn-primary:hover:not(:disabled){background:var(--navy-800)}
.btn-secondary{background:#fff;color:var(--teal-dark);border-color:var(--teal)}
.btn-secondary:hover:not(:disabled){background:var(--teal-50)}
.btn-ghost{background:#fff;color:var(--muted);border-color:var(--line)}
.btn-ghost:hover:not(:disabled){background:var(--chrome);color:var(--ink)}
.btn-danger{background:#fff;color:var(--error);border-color:var(--err-bd)}
.btn-danger:hover:not(:disabled){background:var(--err-bg)}
.btn-sm{padding:7px 12px;font-size:13px}
.btn-block{width:100%}

/* ── BADGES ───────────────────────────────────────────────────────────────── */
.badge{display:inline-flex;align-items:center;gap:5px;font-size:11px;font-weight:600;border-radius:100px;padding:3px 10px;border:1px solid;white-space:nowrap}
.badge.ok{background:var(--ok-bg);border-color:var(--ok-bd);color:var(--ok-tx)}
.badge.info{background:var(--info-bg);border-color:var(--info-bd);color:var(--info-tx)}
.badge.neu{background:var(--neu-bg);border-color:var(--neu-bd);color:var(--neu-tx)}
.badge.warn{background:var(--warn-bg);border-color:var(--warn-bd);color:var(--warn-tx)}
.badge.err{background:var(--err-bg);border-color:var(--err-bd);color:var(--err-tx)}

/* ── LOGO WORDMARK (placeholder until the real Vanguard logo asset is embedded) */
.logo{font-weight:800;font-size:22px;color:var(--navy);letter-spacing:-.01em;cursor:pointer;display:flex;align-items:center}
.logo .dot{color:var(--red)}
.logo-img{height:30px;width:auto;display:block}
.auth-card .logo-img{height:42px;margin-bottom:2px}

/* ── AUTH ZONE (centred card; login / sign-up / onboarding) ──────────────────*/
.auth-wrap{min-height:100%;display:flex;align-items:center;justify-content:center;padding:40px}
.auth-card{background:var(--canvas);border:1px solid var(--line);border-radius:var(--rs);box-shadow:var(--shadow-sm);width:100%;max-width:420px;padding:40px 36px}
.auth-card h1{font-size:20px;font-weight:700;margin:26px 0 6px;letter-spacing:-.02em}
.auth-card p.sub{color:var(--muted);font-size:14px;margin-bottom:24px}
.auth-foot{margin-top:18px;text-align:center;font-size:13px;color:var(--muted)}
.tlink{color:var(--teal-dark);font-weight:600;border-bottom:2px solid var(--teal);cursor:pointer}
/* Secondary sign-in action (e.g. "Email me a sign-in link instead") — centred teal link. */
.auth-alt{margin-top:16px;text-align:center;font-size:14px}
.auth-link{color:var(--teal-dark);font-weight:600;cursor:pointer;border-bottom:1px solid var(--teal)}
.auth-link:hover{opacity:.75}
/* Resend cooldown: the button counts down and is unclickable while it does. Supabase enforces a
   minimum interval between auth emails to the same address plus an hourly cap, so an enabled-looking
   button invites the click-spam that burns the hourly budget. Muted, not-allowed, no hover lift. */
.auth-link.is-cooling,.btn.is-cooling{opacity:.55;cursor:not-allowed;pointer-events:none}
.auth-link.is-cooling{color:var(--ink-3,#64748b);border-bottom-color:transparent;font-weight:500}
/* Status line for "code sent" — distinct from .auth-err, which is a failure. */
.auth-note{background:#ecfdf5;border:1px solid #a7f3d0;color:#065f46;font-size:13px;padding:8px 12px;border-radius:8px;margin-bottom:12px}
/* Back link in an auth footer ("← Use a different email") — muted, recedes below the action above. */
.auth-foot .tlink{color:var(--muted);font-weight:500;border-bottom:none}
.auth-foot .tlink:hover{color:var(--teal-dark);text-decoration:underline}
/* TEST-ONLY "sign in as this customer" shortcut (dashed, amber, clearly a dev affordance). */
.test-login{margin-top:14px;text-align:center}
.test-login-link{display:inline-flex;align-items:center;gap:6px;font-size:12.5px;font-weight:600;color:#b45309;background:#fffbeb;border:1px dashed #f59e0b;border-radius:8px;padding:6px 12px;cursor:pointer}
.test-login-link:hover{background:#fef3c7}
/* Account-manager card (path 5 — "you're already a customer, contact your AM"). */
.am-card{margin:18px 0;background:var(--chrome);border:1px solid var(--line);border-radius:12px;padding:14px 16px;text-align:left}
.am-eyebrow{font-size:11px;text-transform:uppercase;letter-spacing:.06em;color:var(--muted);font-weight:700;margin-bottom:5px}
.am-name{font-size:15px;font-weight:700;color:var(--ink);margin-bottom:6px}
.am-line{display:flex;align-items:center;gap:8px;font-size:14px;color:var(--ink);margin-top:3px}
.am-line a{color:var(--teal-dark);text-decoration:none}
.am-line a:hover{text-decoration:underline}

/* ── FORMS ────────────────────────────────────────────────────────────────── */
label{display:block;font-size:12px;font-weight:600;color:var(--muted);margin-bottom:6px}
.field{width:100%;font:inherit;font-size:14px;padding:11px 13px;border:1px solid var(--line);border-radius:var(--ri);margin-bottom:18px;outline:none;background:#fff;color:var(--ink)}
.field:focus{border-color:var(--navy);box-shadow:0 0 0 3px rgba(0,70,116,.12)}

/* ── SEARCHABLE COMBO BOXES (every dropdown is type-to-search; Oliver) ─────────
   The native <select> is hidden (keeps value + onchange); a search input + a
   body-mounted floating popup overlay it. Wrapper inherits the select's class/
   style for layout; the field "look" lives on the input. */
.combo{position:relative;display:block}
.combo > select{display:none !important}
.combo.field{border:0;padding:0;background:none;box-shadow:none}   /* keep .field margin/width; drop its border (it's on the input) */
.combo-input{width:100%;padding-right:30px;cursor:text}
.combo-input.field{margin:0}
/* fixed-height combo (e.g. Account › addresses branch filter) so it lines up with the
   search input + button on the same row (Batch 3). */
.combo.combo-40{height:40px;margin:0}
.combo.combo-40 .combo-input.field{height:40px;padding-top:0;padding-bottom:0}
.combo-caret{position:absolute;right:11px;top:50%;transform:translateY(-50%);font-size:10px;color:var(--faint);cursor:pointer}
.combo-pop{position:fixed;z-index:200;background:#fff;border:1px solid var(--line);border-radius:var(--rs);box-shadow:var(--shadow-pop);max-height:240px;overflow:auto;padding:4px}
.combo-opt{padding:8px 11px;font-size:13px;border-radius:var(--ri);cursor:pointer;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.combo-opt:hover,.combo-opt.active{background:var(--navy-50)}
.combo-opt.sel{font-weight:700;color:var(--navy)}
.combo-grp{padding:8px 11px 4px;font-size:10px;font-weight:700;text-transform:uppercase;letter-spacing:.05em;color:var(--faint)}
.combo-empty{padding:9px 11px;font-size:12px;color:var(--muted)}
.combo-create{color:var(--teal-dark);font-weight:600;border-top:1px solid var(--line);margin-top:4px;padding-top:9px}

/* ── APP SHELL (top bar + left menu + main) ──────────────────────────────────*/
.shell{display:grid;grid-template-columns:248px 1fr;grid-template-rows:60px 1fr;min-height:100%;height:100%}
.topbar{grid-column:1/3;background:var(--canvas);border-bottom:1px solid var(--line);display:flex;align-items:center;padding:0 22px;height:60px;gap:16px}
.topbar .spacer{flex:1}
/* Top-bar layout: Search │ pipe │ Cart │ utility icons │ account card. */
/* Hairline divider — semi-transparent so total ink is conserved whether it renders as
   one crisp device pixel or gets anti-aliased across two at fractional zoom (keeps all
   pipes looking the same weight instead of thick/thin as the viewport scales). */
.topdiv{width:1px;height:24px;background:rgba(71,85,105,.30);flex-shrink:0}
/* HubSpot-style utility cluster: uniform borderless icon buttons (hover fills).
   gap keeps each hover/badge clear of its neighbour. */
.toputils{display:flex;align-items:center;gap:6px}
.topicon{width:36px;height:36px;border-radius:var(--ri);border:1px solid transparent;background:transparent;color:var(--navy);display:inline-flex;align-items:center;justify-content:center;cursor:pointer;text-decoration:none;position:relative}
.topicon:hover{background:var(--teal-50);border-color:var(--teal)}
.toputils .alertbell{display:inline-flex}
.toputils .alertbell .bell{border-color:transparent;background:transparent;width:36px;height:36px}
.toputils .alertbell .bell:hover{background:var(--teal-50);border-color:var(--teal)}

/* basket */
.basket{position:relative;color:var(--navy);font-size:13px;font-weight:600;border:1px solid var(--line);border-radius:var(--ri);padding:8px 14px;background:#fff;cursor:pointer;display:inline-flex;align-items:center;gap:8px}
.basket:hover{border-color:var(--teal);background:var(--teal-50)}
.basket svg{width:19px;height:19px;flex-shrink:0}
.basket .count{position:absolute;top:-8px;right:-8px;background:var(--teal-dark);color:#fff;border-radius:100px;font-size:10px;font-weight:700;padding:1px 6px;min-width:18px;text-align:center}
.basket .count.zero{display:none}
/* Top-bar cart: a distinct bordered button with its own space (clear, like the search).
   Count sits inline (truck · count · "Cart"), not floating above the icon. */
.basket.topcart{height:38px;padding:0 14px 0 12px;gap:7px}
.basket.topcart .cart-n{background:var(--navy);color:#fff;border-radius:100px;font-size:11px;font-weight:700;padding:0 6px;min-width:18px;height:18px;display:inline-flex;align-items:center;justify-content:center;font-variant-numeric:tabular-nums}
.basket.topcart .basket-lbl{font-size:13px;font-weight:600}

/* ── MESSAGES & ALERTS (top-bar bell + dropdown) ──────────────────────────── */
.alertbell{position:relative}
.bell{position:relative;background:#fff;border:1px solid var(--line);border-radius:var(--ri);width:38px;height:38px;display:inline-flex;align-items:center;justify-content:center;color:var(--navy);cursor:pointer}
.bell:hover{border-color:var(--teal);background:var(--teal-50)}
.bell svg{width:19px;height:19px}
.bell-count{position:absolute;top:-7px;right:-7px;background:var(--teal-dark);color:#fff;border-radius:100px;font-size:10px;font-weight:700;padding:1px 5px;min-width:17px;text-align:center;line-height:1.4}
.alerts-menu{position:absolute;right:0;top:calc(100% + 8px);background:#fff;border:1px solid var(--line);border-radius:var(--ro);box-shadow:var(--shadow-pop);width:370px;max-width:calc(100vw - 36px);z-index:60;overflow:hidden}
.alerts-head{display:flex;justify-content:space-between;align-items:center;padding:13px 16px;border-bottom:1px solid var(--line);font-weight:700;font-size:14px}
.alerts-readall{font-size:12px;font-weight:600;color:var(--teal-dark);cursor:pointer}
.alerts-readall:hover{text-decoration:underline}
.alerts-list{max-height:440px;overflow:auto}
.alert-item{display:flex;gap:12px;align-items:flex-start;padding:12px 16px;border-bottom:1px solid var(--line);cursor:pointer}
.alert-item:last-child{border-bottom:none}
.alert-item:hover{background:var(--chrome)}
.alert-item.unread{background:var(--navy-50)}
.alert-ic{width:32px;height:32px;border-radius:50%;flex-shrink:0;display:flex;align-items:center;justify-content:center;background:var(--neu-bg);color:var(--muted)}
.alert-ic svg{width:16px;height:16px}
.alert-ic.order{background:var(--info-bg);color:var(--info-tx)}
.alert-ic.quote{background:var(--teal-50);color:var(--teal-dark)}
.alert-ic.approval{background:var(--warn-bg);color:var(--warn-tx)}
.alert-body{flex:1;min-width:0}
.alert-title{font-size:13px;font-weight:700;line-height:1.3;color:var(--ink)}
.alert-sub{font-size:12px;color:var(--muted);line-height:1.45;margin-top:2px}
.alert-time{font-size:11px;color:var(--faint);margin-top:5px}
.alert-dot{width:8px;height:8px;border-radius:50%;background:var(--teal-dark);flex-shrink:0;margin-top:6px}
.alerts-foot{border-top:1px solid var(--line);padding:10px 16px;text-align:center;background:var(--neu-bg)}
.alerts-seeall{font-size:13px;font-weight:700;color:var(--teal-dark);cursor:pointer}
.alerts-seeall:hover{text-decoration:underline}
.alerts-empty{padding:34px 16px;text-align:center;color:var(--muted);font-size:13px}
.alerts-empty .big{font-size:28px;opacity:.4;margin-bottom:8px}

/* account chip + dropdown */
.acct{position:relative}
.chip{display:flex;align-items:center;gap:9px;background:var(--navy-50);border-radius:8px;padding:4px 14px 4px 5px;font-size:13px;font-weight:600;color:var(--navy);cursor:pointer;border:1px solid transparent}
.chip:hover{border-color:var(--teal)}
.chip .caret{font-size:10px;opacity:.7}
.avatar{width:30px;height:30px;border-radius:50%;background:var(--navy);color:#fff;display:flex;align-items:center;justify-content:center;font-size:12px;font-weight:700;flex-shrink:0}
.menu{position:absolute;right:0;top:calc(100% + 8px);background:#fff;border:1px solid var(--line);border-radius:var(--ro);box-shadow:var(--shadow-pop);min-width:230px;padding:6px;z-index:60}
.menu .mhead{padding:10px 12px 8px;border-bottom:1px solid var(--line);margin-bottom:6px}
.menu .mhead .nm{font-weight:700;color:var(--ink)}
.menu .mhead .sub{font-size:12px;color:var(--muted);margin-top:2px}
.menu .mitem{display:flex;align-items:center;gap:10px;padding:9px 12px;border-radius:var(--ri);font-size:13px;font-weight:500;color:#334155;cursor:pointer}
.menu .mitem:hover{background:var(--chrome)}
.menu .mitem .ic{width:16px;text-align:center;color:var(--muted)}
.menu .mitem.danger{color:var(--error)}
.menu .msep{height:1px;background:var(--line);margin:6px 0}

/* sidebar / left menu */
.sidebar{background:var(--chrome);border-right:1px solid var(--line);padding:18px 14px;display:flex;flex-direction:column;gap:3px;overflow:auto}
.navitem{display:flex;align-items:center;gap:12px;padding:11px 12px;border-radius:var(--ri);color:#334155;font-size:13.5px;font-weight:600;cursor:pointer;transition:background .12s ease}
.navitem:hover{background:#fff}
.navitem.active{color:var(--navy);font-weight:700;background:#fff}
/* bigger, "designed" line icons — reserved for the left nav (Oliver: icons live here only) */
.navitem .ic{width:24px;height:24px;display:inline-flex;align-items:center;justify-content:center;color:var(--teal-dark);flex-shrink:0}
.navitem .ic svg{width:21px;height:21px}
.navitem.active .ic{color:var(--navy)}
.navitem .pill{margin-left:auto;background:var(--navy-50);color:var(--navy);font-size:10px;font-weight:700;border-radius:100px;padding:1px 7px}
/* Expandable Quotes/Orders groups: parent keeps the nav look; the active section
   shows a chevron rotated open + indented sub-items beneath it (Oliver). */
.navparent .navchev{margin-left:auto;color:var(--faint);transition:transform .15s ease;flex-shrink:0}
.navparent.open{color:var(--navy);font-weight:700}
.navparent.open .ic,.navparent.open .navchev{color:var(--navy)}
.navparent.open .navchev{transform:rotate(90deg)}
.navsub{display:flex;flex-direction:column;gap:2px;margin:2px 0 6px}
.navsubitem{position:relative;display:flex;align-items:center;gap:8px;padding:8px 12px 8px 48px;border-radius:var(--ri);color:#475569;font-size:12.5px;font-weight:600;cursor:pointer;transition:background .12s ease}
.navsubitem:hover{background:#fff}
.navsubitem.active{color:var(--navy);background:#fff;font-weight:700}
/* Active CHILD indicator: small navy dot in the left gutter (Batch 3). Parents/top-level
   items stay white-pill only — the dot marks the active leaf without shifting labels. */
.navsubitem.active::before{content:'';position:absolute;left:21px;top:50%;transform:translateY(-50%);width:6px;height:6px;border-radius:50%;background:var(--navy)}
.navsubitem .pill{margin-left:auto;background:var(--navy-50);color:var(--navy);font-size:10px;font-weight:700;border-radius:100px;padding:1px 7px}
.nav-sectn{font-size:10px;font-weight:700;text-transform:uppercase;letter-spacing:.06em;color:var(--faint);padding:14px 12px 6px}
.nav-spacer{flex:1}
/* sidebar profile summary (top of nav) — a Portal 1.0 element, re-skinned navy/teal */
.side-profile{background:var(--navy);color:#fff;border-radius:var(--rs);padding:18px 14px;margin-bottom:14px;text-align:center}
.side-profile .spav{width:50px;height:50px;border-radius:50%;background:var(--teal);color:var(--navy-800);font-weight:800;font-size:18px;display:flex;align-items:center;justify-content:center;margin:0 auto 10px}
.side-profile .spnm{font-weight:700;font-size:14px;line-height:1.3}
.side-profile .spco{font-size:12px;color:rgba(255,255,255,.82);margin-top:3px}
.side-profile .spac{font-size:11px;color:rgba(255,255,255,.6);margin-top:2px}
/* sidebar help card (bottom of nav) — live chat (primary) + account manager (secondary) */
.side-help{background:#fff;border:1px solid var(--line);border-radius:var(--rs);padding:14px;margin-top:8px;box-shadow:var(--shadow-sm)}
.side-help .eyebrow{font-size:10px;font-weight:800;text-transform:uppercase;letter-spacing:.06em;color:var(--teal-dark);margin-bottom:6px}
.side-help p{font-size:12px;color:var(--muted);line-height:1.45;margin-bottom:10px}
.side-help .btn{width:100%;font-size:12.5px;padding:10px;white-space:normal;line-height:1.3;height:auto;text-align:center}
.side-help .am{font-size:11.5px;color:var(--muted);margin-top:11px;line-height:1.55;border-top:1px solid var(--line);padding-top:10px}
.side-help .am b{color:var(--ink)}
.side-help .am a{color:var(--teal-dark);font-weight:700;word-break:break-word}

/* main content */
.main{background:var(--canvas);padding:30px 36px;overflow:auto}
.main h1{font-size:21px;font-weight:700;letter-spacing:-.02em;margin-bottom:4px}
.main .lede{color:var(--muted);font-size:14px;margin-bottom:26px}
.section-h{font-size:15px;font-weight:700;margin:30px 0 14px;display:flex;align-items:center;justify-content:space-between}
.section-h a.more{font-size:13px;font-weight:600;color:var(--teal-dark);cursor:pointer}

/* ── CARDS / METRICS ──────────────────────────────────────────────────────── */
.cards{display:grid;grid-template-columns:repeat(3,1fr);gap:16px}
.card{background:var(--canvas);border:1px solid var(--line);border-radius:var(--rs);box-shadow:var(--shadow-sm);padding:18px 20px}
.card.click{cursor:pointer;transition:transform .12s ease,box-shadow .15s ease,border-color .15s ease}
.card.click:hover{border-color:var(--teal);box-shadow:var(--shadow-lift);transform:translateY(-2px)}
.card .k{font-size:12px;color:var(--muted);font-weight:600;margin-bottom:8px}
.card .v{font-size:26px;font-weight:800;color:var(--navy);font-variant-numeric:tabular-nums}
.card .meta{font-size:12px;color:var(--muted);margin-top:4px}

/* ── DASHBOARD (Pass 2 refresh) — metric cards · order cards · My Products minis ──
   Modelled on Portal 1.0 (Reference files/Portal 1.0 dashboard .png), re-skinned to
   2.0 navy/teal: big count + caps label + a link cue, with a teal left-accent. */
/* Metric cards (Batch 3 refresh, P2-4): icon chip · label over number · chevron —
   same visual language as the attention rows / search results. Whole card is the link. */
.card.metric2{display:flex;align-items:center;gap:14px;padding:16px 18px;cursor:pointer;transition:transform .12s ease,box-shadow .15s ease,border-color .15s ease}
.card.metric2:hover{border-color:var(--teal);box-shadow:var(--shadow-lift);transform:translateY(-2px)}
.card.metric2 .mic{width:38px;height:38px;border-radius:var(--rs);background:var(--navy-50);color:var(--navy);display:flex;align-items:center;justify-content:center;flex-shrink:0}
.card.metric2 .mtxt{min-width:0}
.card.metric2 .m-k{font-size:11px;font-weight:700;text-transform:uppercase;letter-spacing:.05em;color:var(--muted)}
.card.metric2 .m-v{font-size:24px;font-weight:800;color:var(--navy);font-variant-numeric:tabular-nums;line-height:1.15}
.card.metric2 .mchev{margin-left:auto;color:var(--faint);transition:color .12s ease,transform .12s ease}
.card.metric2:hover .mchev{color:var(--teal-dark);transform:translateX(2px)}

/* "Needs your attention" strip (P1-1) — reuses the notification-item language. */
.attn{border:1px solid var(--line);border-radius:var(--rs);background:#fff;box-shadow:var(--shadow-sm);margin-bottom:24px;overflow:hidden}
.attn-h{font-size:11px;font-weight:800;text-transform:uppercase;letter-spacing:.06em;color:var(--muted);padding:12px 18px 10px;border-bottom:1px solid var(--line);display:flex;align-items:center;gap:8px}
.attn-h .n{background:var(--warn-bg);border:1px solid var(--warn-bd);color:var(--warn-tx);border-radius:100px;font-size:10px;padding:0 7px;line-height:1.6}
.attn-list{display:grid;grid-template-columns:1fr 1fr}
.attn-item{display:flex;gap:12px;align-items:flex-start;padding:13px 18px;border-bottom:1px solid var(--line);cursor:pointer}
.attn-item:hover{background:var(--chrome)}
.attn-item:nth-child(odd){border-right:1px solid var(--line)}
.attn-item:last-child:nth-child(odd){border-right:1px solid var(--line)}
/* No header inside the box now (the section-h carries the title) — drop the last row's
   bottom border so it doesn't double up with the box edge. */
.attn-list .attn-item:last-child,
.attn-list .attn-item:nth-last-child(2):nth-child(odd){border-bottom:none}
.attn-ic{width:32px;height:32px;border-radius:50%;flex-shrink:0;display:flex;align-items:center;justify-content:center}
.attn-ic.warn{background:var(--warn-bg);color:var(--warn-tx)}
.attn-ic.teal{background:var(--teal-50);color:var(--teal-dark)}
.attn-ic.info{background:var(--info-bg);color:var(--info-tx)}
.attn-body{min-width:0}
.attn-tt{font-size:13px;font-weight:700;line-height:1.35}
.attn-sub{font-size:12px;color:var(--muted);margin-top:1px}
.attn-go{font-size:12px;font-weight:700;color:var(--teal-dark);margin-top:4px;display:inline-block}
.adm{font-size:9.5px;font-weight:800;text-transform:uppercase;letter-spacing:.06em;color:var(--faint);border:1px solid var(--line);border-radius:3px;padding:1px 5px;margin-left:6px;vertical-align:middle;white-space:nowrap}
@media(max-width:640px){.attn-list{grid-template-columns:1fr}.attn-item:nth-child(odd){border-right:none}}

/* Updates page (full list as a table): type chips (left) + search + Clear all (right).
   Search flexes to fill the middle; the row wraps on narrow screens. */
.upd-tools{display:flex;align-items:center;gap:12px;margin-bottom:16px;flex-wrap:wrap}
.upd-tools .tbl-search{flex:1 1 160px;min-width:0}
.upd-tools .tbl-chips{flex-shrink:0}
.upd-tools .chip .chip-n{margin-left:6px;font-variant-numeric:tabular-nums;opacity:.7}
.upd-when{color:var(--faint);white-space:nowrap}
.upd-ic{display:inline-flex;width:26px;height:26px;border-radius:50%;align-items:center;justify-content:center;vertical-align:middle;margin-right:10px;flex-shrink:0}
.upd-ic.warn{background:var(--warn-bg);color:var(--warn-tx)}
.upd-ic.teal{background:var(--teal-50);color:var(--teal-dark)}
.upd-ic.info{background:var(--info-bg);color:var(--info-tx)}
.tbl.list td.upd-what{white-space:normal}
.upd-tt{font-weight:700;vertical-align:middle}
.tbl.list td.upd-detail{color:var(--muted);white-space:normal}

/* recent-order cards (replaces the dashboard table — Oliver: cards, not listing lines) */
.order-cards{display:flex;flex-direction:column;gap:12px}
.order-card{background:#fff;border:1px solid var(--line);border-radius:var(--rs);box-shadow:var(--shadow-sm);padding:16px 18px;cursor:pointer;transition:transform .12s ease,box-shadow .15s ease,border-color .15s ease}
.order-card:hover{border-color:var(--teal);box-shadow:var(--shadow-lift);transform:translateY(-2px)}
.order-card .oc-top{display:flex;align-items:center;justify-content:space-between;gap:10px}
.order-card .oc-title{font-size:15px;font-weight:700;color:var(--navy);line-height:1.3}
.order-card .oc-meta{font-size:12px;color:var(--muted);margin-top:5px}
.order-card .oc-proj{color:var(--teal-dark);font-weight:700}
.order-card .oc-proj:hover{text-decoration:underline}
.order-card .oc-exp{font-size:12px;font-weight:700;color:var(--muted);white-space:nowrap;flex-shrink:0}
.order-card .oc-exp.amber{color:var(--warn-tx)}
.order-card .oc-bot{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:12px}
.order-card .oc-price{font-size:18px;font-weight:800;color:var(--ink);font-variant-numeric:tabular-nums}
.order-card .oc-price small{font-size:11px;font-weight:600;color:var(--muted)}
.order-card .oc-actions{display:flex;gap:8px;flex-shrink:0}

/* My Products "mini" cards (dashboard preview — click through to the product) */
.myprod-minis{display:grid;grid-template-columns:repeat(2,1fr);gap:12px}
.myprod-mini{display:flex;align-items:center;gap:12px;background:#fff;border:1px solid var(--line);border-radius:var(--rs);box-shadow:var(--shadow-sm);padding:12px 14px;cursor:pointer;transition:transform .12s ease,box-shadow .15s ease,border-color .15s ease}
.myprod-mini:hover{border-color:var(--teal);box-shadow:var(--shadow-lift);transform:translateY(-2px)}
.myprod-mini .fm-thumb{width:48px;height:48px;border-radius:var(--ri);background:var(--chrome);flex-shrink:0;display:flex;align-items:center;justify-content:center;overflow:hidden}
.myprod-mini .fm-thumb img{width:100%;height:100%;object-fit:contain;mix-blend-mode:multiply}
.myprod-mini .fm-thumb .ph{color:var(--faint)}
.myprod-mini .fm-info{flex:1;min-width:0}
.myprod-mini .fm-nm{font-size:13px;font-weight:700;line-height:1.3;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.myprod-mini .fm-code{font-size:11px;color:var(--muted);font-weight:600;margin-top:2px}

/* ── TABLES ───────────────────────────────────────────────────────────────── */
.tbl{width:100%;border-collapse:collapse;border:1px solid var(--line);border-radius:var(--rs);overflow:hidden;font-size:13px;background:#fff}
.tbl th{background:var(--thead);text-align:left;font-size:11px;font-weight:700;color:var(--muted);text-transform:uppercase;letter-spacing:.04em;padding:11px 14px}
.tbl th.num{text-align:right}   /* numeric headers (Qty/Unit/Line) line up over their right-aligned values */
.tbl td{padding:12px 14px;border-top:1px solid var(--line);vertical-align:middle}
.tbl tr.click{cursor:pointer}
.tbl tr.click:hover td{background:var(--navy-50)}
.tbl td.num{text-align:right;font-variant-numeric:tabular-nums;font-weight:600}
.tbl .code{color:var(--muted);font-size:12px}
.tbl td.cimg,.tbl th.cimg{width:46px;padding-right:4px}   /* image column: no header, tight */
.tbl td.iname{font-weight:600;color:var(--ink)}           /* product name = primary column */

/* ── EMPTY STATE ──────────────────────────────────────────────────────────── */
.empty{border:1px dashed var(--line);border-radius:var(--rs);background:var(--neu-bg);padding:42px 28px;text-align:center;color:var(--muted)}
.empty .big{font-size:30px;margin-bottom:10px;opacity:.5}
.empty h3{font-size:15px;font-weight:700;color:var(--ink);margin-bottom:6px}
.empty p{font-size:13px;margin-bottom:16px}

/* ── STUB (placeholder for screens built in later milestones) ─────────────── */
.stub{border:1px dashed var(--teal);background:var(--teal-50);border-radius:var(--rs);padding:34px 28px;color:var(--teal-dark)}
.stub h3{font-size:15px;font-weight:700;color:var(--navy);margin-bottom:8px}
.stub p{font-size:13px;color:var(--muted);max-width:560px}
.stub .ms{display:inline-block;margin-top:14px;font-size:11px;font-weight:700;text-transform:uppercase;letter-spacing:.05em;background:#fff;border:1px solid var(--teal);color:var(--teal-dark);border-radius:100px;padding:4px 11px}

/* ── ASK A QUESTION — navy icon-only chat launcher (HubSpot style) ──────────── */
.chat{position:fixed;right:26px;bottom:54px;width:58px;height:58px;background:var(--navy);color:#fff;border-radius:50%;display:flex;align-items:center;justify-content:center;box-shadow:0 4px 16px rgba(0,0,0,.22);cursor:pointer;z-index:50;border:none}
.chat:hover{background:var(--navy-800)}
.chat svg{width:27px;height:27px}

/* ── "Ask a question" LIVE CHAT widget (HubSpot-style) ────────────────────── */
.chatpanel{position:fixed;right:26px;bottom:124px;width:362px;max-width:calc(100vw - 36px);height:478px;max-height:calc(100vh - 130px);background:#fff;border-radius:14px;box-shadow:0 14px 44px rgba(15,23,42,.30);display:flex;flex-direction:column;overflow:hidden;z-index:56;animation:chatin .18s ease-out}
@keyframes chatin{from{opacity:0;transform:translateY(12px)}to{opacity:1;transform:none}}
.chat-head{background:var(--navy);color:#fff;padding:14px 16px;display:flex;align-items:center;gap:11px}
.chat-avs{display:flex}
.chat-avs .cav{width:30px;height:30px;border-radius:50%;background:var(--teal);color:var(--navy-800);font-weight:800;font-size:12px;display:flex;align-items:center;justify-content:center;border:2px solid var(--navy);margin-left:-9px}
.chat-avs .cav:first-child{margin-left:0}
.chat-meta{flex:1;min-width:0}
.chat-names{font-weight:700;font-size:14px}
.chat-status{font-size:11px;color:rgba(255,255,255,.78)}
.chat-x{background:none;border:none;color:#fff;font-size:17px;cursor:pointer;opacity:.85;line-height:1}
.chat-x:hover{opacity:1}
/* Page context passed to the agent (HubSpot live chat surfaces the visitor's page). */
.chat-context{display:flex;align-items:flex-start;gap:7px;padding:9px 14px;background:var(--navy-50);border-bottom:1px solid var(--line);font-size:11.5px;color:var(--muted);line-height:1.4}
.chat-context .li{color:var(--teal-dark);margin-top:1px;flex-shrink:0}
.chat-context b{color:var(--navy);font-weight:700}
.chat-body{flex:1;overflow:auto;padding:16px;background:var(--chrome);display:flex;flex-direction:column;gap:10px}
.cmsg{display:flex;gap:8px;align-items:flex-end;max-width:86%}
.cmsg.agent{align-self:flex-start}
.cmsg.user{align-self:flex-end;flex-direction:row-reverse}
.cmsg .cav{width:24px;height:24px;border-radius:50%;background:var(--navy);color:#fff;font-size:11px;font-weight:700;display:flex;align-items:center;justify-content:center;flex-shrink:0}
.cbub{padding:9px 13px;border-radius:14px;font-size:13px;line-height:1.45;white-space:pre-line}
.cmsg.agent .cbub{background:#fff;border:1px solid var(--line);color:var(--ink);border-bottom-left-radius:4px}
.cmsg.user .cbub{background:var(--navy);color:#fff;border-bottom-right-radius:4px}
.chat-input{display:flex;align-items:center;gap:8px;padding:12px;border-top:1px solid var(--line);background:#fff}
.chat-input input{flex:1;border:1px solid var(--line);border-radius:100px;padding:10px 16px;font:inherit;font-size:13px;outline:none}
.chat-input input:focus{border-color:var(--navy);box-shadow:0 0 0 3px rgba(0,70,116,.1)}
.chat-send{width:38px;height:38px;border-radius:50%;background:var(--navy);color:#fff;border:none;cursor:pointer;font-size:14px;flex-shrink:0}
.chat-send:hover{background:var(--navy-800)}

/* ── PRODUCT ENQUIRY modal (centred; message + attachments) ───────────────── */
.enq-prod{display:flex;align-items:center;gap:12px;background:var(--neu-bg);border:1px solid var(--line);border-radius:var(--rs);padding:10px 12px;margin-bottom:14px}
.enq-prod .qthumb{width:46px;height:46px;border-radius:var(--ri);background:#fff;flex-shrink:0;display:flex;align-items:center;justify-content:center;overflow:hidden}
.enq-prod .qthumb img{width:100%;height:100%;object-fit:contain;mix-blend-mode:multiply}
.enq-prod .qthumb .ph{color:var(--faint)}
.enq-prod .qnm{font-size:13px;font-weight:700}
.enq-prod .qcode{font-size:11px;color:var(--muted);font-weight:600}
.enq-from{font-size:12px;color:var(--muted);margin-bottom:14px}
.enq-drop{display:flex;align-items:center;justify-content:center;gap:8px;border:1.5px dashed var(--teal);border-radius:var(--rs);padding:16px;color:var(--teal-dark);font-weight:600;font-size:13px;cursor:pointer;background:var(--teal-50)}
.enq-drop:hover{background:#fff}
.enq-drop input{display:none}
.enq-files{display:flex;flex-wrap:wrap;gap:8px;margin-top:10px}
.enq-file{font-size:12px;background:#fff;border:1px solid var(--line);border-radius:100px;padding:4px 10px;color:var(--muted);display:inline-flex;align-items:center;gap:6px}
.enq-file b{cursor:pointer;color:var(--faint);font-weight:700}
.enq-file b:hover{color:var(--error)}

/* ── TOAST + SPINNER (feels-real feedback) ───────────────────────────────────*/
#toast-host{position:fixed;left:50%;bottom:58px;transform:translateX(-50%);display:flex;flex-direction:column;gap:8px;z-index:90;align-items:center}
.toast{background:var(--navy-800);color:#fff;font-size:13px;font-weight:600;padding:11px 18px;border-radius:var(--ro);box-shadow:var(--shadow-pop);display:flex;align-items:center;gap:9px;animation:toastin .18s ease-out}
.toast.err{background:var(--error)}
@keyframes toastin{from{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}
.spinner{width:34px;height:34px;border:3px solid var(--navy-50);border-top-color:var(--navy);border-radius:50%;animation:spin .7s linear infinite}
@keyframes spin{to{transform:rotate(360deg)}}
@media (prefers-reduced-motion:reduce){.spinner{animation-duration:1.6s}.toast{animation:none}}

/* ── APP ROOT LAYOUT ──────────────────────────────────────────────────────── */
#app{height:100%}
.appframe{display:flex;flex-direction:column;height:100vh}
.appframe .demobar{flex-shrink:0}
.appframe .view{flex:1;min-height:0}

/* ============================================================================
   MILESTONE 2 — BUY-FLOW (Browse list · product detail · fixings · Quote panel)
   Browse is a LISTING of rows (not a content page) per Oliver: small thumbnail
   "enough to see what it is", code · name · price · stock · qty · Add. Rich
   content pages are the future unified website, not the MVP.
   ============================================================================ */

/* layout: category rail + results */
.browse{display:grid;grid-template-columns:220px 1fr;gap:28px;align-items:start}
.catnav{font-size:13px;position:sticky;top:0}
.catnav .cat{display:flex;align-items:flex-start;gap:6px;padding:9px 11px;border-radius:var(--ri);cursor:pointer;color:#334155;font-weight:500}
.catnav .cat:hover{background:#fff}
.catnav .cat.active{background:var(--navy-50);color:var(--navy);font-weight:700}
.catnav .cat .n{margin-left:auto;flex-shrink:0;color:var(--faint);font-weight:600}
.catnav .cat.active .n{color:var(--navy)}
.catnav .cat .allflag{font-weight:600;font-size:12px;color:var(--muted)}
.catnav .cat-chev{flex-shrink:0;display:inline-flex;align-items:center;color:var(--faint);margin-top:1px}
.catnav .cat.active .cat-chev{color:var(--navy)}
.catnav .cat-chev-sp{width:15px}
/* child subcategories under the active parent (parent → child) */
.catnav .subnav{margin:1px 0 6px 0;display:flex;flex-direction:column;gap:1px}
.catnav .subcat{display:flex;align-items:flex-start;gap:6px;padding:6px 11px;border-radius:var(--ri);cursor:pointer;color:var(--muted);font-size:12px;font-weight:500}
.catnav .subcat:hover{background:#fff;color:var(--ink)}
.catnav .subcat.active{background:var(--navy-50);color:var(--navy);font-weight:700}
.catnav .subcat .n{margin-left:auto;flex-shrink:0;color:var(--faint);font-weight:600}
/* subcategory group headings in the product list */
.subhead{font-size:12px;font-weight:700;text-transform:uppercase;letter-spacing:.04em;color:var(--muted);margin:20px 0 8px;display:flex;align-items:center;justify-content:space-between}
.subhead:first-child{margin-top:8px}
.subhead span{color:var(--faint);font-weight:600}
.searchwrap{position:relative;margin-bottom:8px}
.search{width:100%;font:inherit;font-size:14px;padding:11px 14px 11px 38px;border:1px solid var(--line);border-radius:var(--ri);outline:none;background:#fff}
.search:focus{border-color:var(--navy);box-shadow:0 0 0 3px rgba(0,70,116,.12)}
.searchwrap .si{position:absolute;left:13px;top:50%;transform:translateY(-50%);color:var(--faint)}
.resmeta{font-size:12px;color:var(--muted);margin:4px 2px 14px}

/* product rows */
.plist{display:flex;flex-direction:column;gap:10px}
.prow{display:flex;align-items:center;gap:16px;background:#fff;border:1px solid var(--line);border-radius:var(--rs);padding:12px 16px;box-shadow:var(--shadow-sm)}
.prow:hover{border-color:var(--teal)}
.prow .thumb{width:60px;height:60px;border-radius:var(--ri);background:var(--chrome);flex-shrink:0;display:flex;align-items:center;justify-content:center;overflow:hidden;cursor:pointer}
.prow .thumb img{width:100%;height:100%;object-fit:contain;mix-blend-mode:multiply}
.prow .thumb .ph{color:var(--faint);font-size:20px}
.prow .pinfo{flex:1;min-width:0;cursor:pointer}
.prow .pinfo .code{font-size:11px;color:var(--muted);font-weight:600}
.prow .pinfo .nm{font-size:14px;font-weight:700;line-height:1.3;margin:1px 0 2px}
.prow .pinfo .nm:hover{color:var(--navy)}
.prow .pinfo .ds{font-size:12px;color:var(--muted);line-height:1.4;display:-webkit-box;-webkit-line-clamp:1;-webkit-box-orient:vertical;overflow:hidden}
.prow .pmid{width:128px;flex-shrink:0;text-align:right}
.prow .price{font-size:15px;font-weight:800;color:var(--navy);font-variant-numeric:tabular-nums;white-space:nowrap}
.prow .price small{font-weight:600;color:var(--muted);font-size:11px}
.prow .price.enq{color:var(--teal-dark);font-size:13px;font-weight:700}
.prow .price.locked{color:var(--faint);font-size:12px;font-weight:600}
.prow .pstock{margin-top:5px}
.prow .pact{width:184px;flex-shrink:0;display:flex;flex-direction:column;align-items:flex-end;gap:8px}

/* My Products star */
.myprod-star{background:none;border:none;cursor:pointer;color:var(--faint);font-size:18px;line-height:1;padding:4px;flex-shrink:0}
.myprod-star:hover{color:var(--teal-dark)}
.myprod-star.on{color:var(--teal-dark)}
.myprod-star.locked{cursor:default;color:var(--teal-dark);opacity:.85}
.myprod-star.locked:hover{color:var(--teal-dark)}
.btn.locked{cursor:default;opacity:.75}

/* quantity stepper */
.qty{display:inline-flex;align-items:center;border:1px solid var(--line);border-radius:var(--ri);overflow:hidden;background:#fff}
.qty button{width:30px;height:34px;border:none;background:#fff;color:var(--navy);font-size:16px;font-weight:700;cursor:pointer}
.qty button:hover{background:var(--navy-50)}
.qty input{width:46px;height:34px;border:none;border-left:1px solid var(--line);border-right:1px solid var(--line);text-align:center;font:inherit;font-weight:700;font-size:13px;color:var(--ink);outline:none;-moz-appearance:textfield}
.qty input::-webkit-outer-spin-button,.qty input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}
.qty.lg input{width:64px;height:42px}
.qty.lg button{height:42px;width:38px}
.unitnote{font-size:11px;color:var(--faint);text-align:right}

/* PRODUCT DETAIL (lightweight, functional — not a content page) */
.crumbs{font-size:12px;color:var(--muted);margin-bottom:14px}
.crumbs a{color:var(--teal-dark);font-weight:600;cursor:pointer}
.pdetail{display:grid;grid-template-columns:340px 1fr;gap:36px;align-items:start}
.pdetail .pimg{background:var(--chrome);border:1px solid var(--line);border-radius:var(--rs);height:300px;display:flex;align-items:center;justify-content:center;overflow:hidden}
.pdetail .pimg img{max-width:100%;max-height:100%;object-fit:contain;mix-blend-mode:multiply}
.pdetail .pimg .ph{color:var(--faint);font-size:40px}
.pdetail h1{font-size:22px;margin-bottom:6px}
.pdetail .dcode{font-size:12px;color:var(--muted);font-weight:600;margin-bottom:14px}
.pdetail .ddesc{font-size:14px;color:var(--muted);line-height:1.6;margin-bottom:20px;max-width:620px}
.pdetail .dprice{font-size:26px;font-weight:800;color:var(--navy);margin-bottom:4px;font-variant-numeric:tabular-nums}
.pdetail .dprice small{font-size:13px;color:var(--muted);font-weight:600}
.pdetail .dbuy{display:flex;align-items:center;gap:14px;margin:22px 0;flex-wrap:wrap}
.specs{border-top:1px solid var(--line);margin-top:8px;padding-top:18px;font-size:13px;max-width:520px}
.specs .srow{display:flex;justify-content:space-between;padding:7px 0;border-bottom:1px solid var(--line)}
.specs .srow .k{color:var(--muted)}
.specs .srow .v{font-weight:600}

/* ── RIGHT SLIDE-OUT QUOTE PANEL (the cart) ───────────────────────────────── */
.qbackdrop{position:fixed;inset:0;background:rgba(15,23,42,.4);z-index:95;opacity:0;visibility:hidden;transition:opacity .2s}
.qbackdrop.open{opacity:1;visibility:visible}
.qpanel{position:fixed;top:0;right:0;bottom:0;width:430px;max-width:92vw;background:#fff;z-index:100;box-shadow:-8px 0 28px rgba(15,23,42,.18);display:flex;flex-direction:column;transform:translateX(100%);transition:transform .22s ease-out}
.qpanel.open{transform:translateX(0)}
@media (prefers-reduced-motion:reduce){.qpanel,.qbackdrop{transition:none}}
.qhead{display:flex;align-items:center;gap:10px;padding:18px 20px;border-bottom:1px solid var(--line)}
.qhead h2{font-size:16px;font-weight:700}
.qhead .qcount{background:var(--navy-50);color:var(--navy);font-size:12px;font-weight:700;border-radius:100px;padding:2px 9px}
.qhead .x{margin-left:auto;background:none;border:none;font-size:22px;color:var(--muted);cursor:pointer;line-height:1}
.qhead .x:hover{color:var(--ink)}
.qlines{flex:1;overflow:auto;padding:8px 20px}
.qline{display:flex;gap:12px;padding:14px 0;border-bottom:1px solid var(--line)}
.qline .qthumb{width:46px;height:46px;border-radius:var(--ri);background:var(--chrome);flex-shrink:0;display:flex;align-items:center;justify-content:center;overflow:hidden}
.qline .qthumb img{width:100%;height:100%;object-fit:contain;mix-blend-mode:multiply}
.qline .qthumb .ph{color:var(--faint);font-size:14px}
.qline .qmid{flex:1;min-width:0}
.qline .qnm{font-size:13px;font-weight:700;line-height:1.3}
.qline .qcode{font-size:11px;color:var(--muted);font-weight:600}
.qline .qctl{display:flex;align-items:center;gap:10px;margin-top:8px}
.qline .qremove{background:none;border:none;color:var(--muted);font-size:12px;font-weight:600;cursor:pointer;text-decoration:underline}
.qline .qremove:hover{color:var(--error)}
.qline .qlt{font-weight:800;color:var(--navy);font-variant-numeric:tabular-nums;white-space:nowrap}
/* configured set in the cart (heading + parts + edit/remove) */
.qgroup{border:1px solid var(--teal);border-radius:var(--rs);background:var(--teal-50);padding:6px 10px 10px;margin:10px 0}
.qgroup-head{padding:6px 4px 4px}
.qg-label{font-size:13px;font-weight:800;color:var(--navy)}
.qg-sub{font-size:11px;color:var(--muted);font-weight:600}
.qg-actions{display:flex;gap:8px;padding:0 4px 6px}
.qg-btn{background:#fff;border:1px solid var(--teal);color:var(--teal-dark);border-radius:var(--ri);font:inherit;font-size:11px;font-weight:700;padding:5px 9px;cursor:pointer}
.qg-btn:hover{background:var(--navy);color:#fff;border-color:var(--navy)}
.qg-btn.rm{border-color:var(--line);color:var(--muted)}
.qg-btn.rm:hover{background:var(--error);border-color:var(--error);color:#fff}
.qline.qgl{background:#fff;border:1px solid var(--line);border-radius:var(--ri);padding:8px 10px;margin:6px 0 0;border-bottom:1px solid var(--line)}
.qline.qgl .qthumb{width:38px;height:38px}
.qline.fix{padding:10px 0 10px 58px;border-bottom:1px dashed var(--line)}
.qline.fix .qnm{font-weight:600;font-size:12px;color:var(--muted)}
.qline.fix .ficon{color:var(--teal-dark);font-weight:700;margin-right:4px}
.qline .qfix-for{font-size:11px;color:var(--faint);margin-top:3px}   /* "↳ Fixings for X" caption on the (now full-line) fixing row */
.qsum{padding:16px 20px;border-top:1px solid var(--line);background:var(--neu-bg)}
.qsum .row{display:flex;justify-content:space-between;font-size:13px;padding:4px 0;color:var(--muted)}
.qsum .row.tot{font-size:16px;font-weight:800;color:var(--ink);border-top:1px solid var(--line);margin-top:8px;padding-top:12px}
.qsum .row .v{font-variant-numeric:tabular-nums;font-weight:600;color:var(--ink)}
.qsum .row.tot .v{color:var(--navy)}
.qsum .frnote{font-size:11px;color:var(--faint);margin-top:6px;text-align:right}
.qfoot{padding:16px 20px;border-top:1px solid var(--line);display:flex;flex-direction:column;gap:10px}
.qempty{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;color:var(--muted);padding:30px}
.qempty .big{font-size:34px;opacity:.4;margin-bottom:12px}
.qempty h3{font-size:15px;color:var(--ink);margin-bottom:6px}
.qempty p{font-size:13px;margin-bottom:18px}

/* ── MODAL (fixings prompt, etc.) ─────────────────────────────────────────── */
.modal-backdrop{position:fixed;inset:0;background:rgba(15,23,42,.45);z-index:110;display:flex;align-items:center;justify-content:center;padding:24px}
.modal{position:relative;background:#fff;border-radius:var(--ro);box-shadow:var(--shadow-pop);width:100%;max-width:480px;overflow:hidden;animation:popin .16s ease-out}
.modal-x{position:absolute;top:10px;right:10px;width:32px;height:32px;display:flex;align-items:center;justify-content:center;border:0;background:transparent;color:var(--muted);cursor:pointer;border-radius:var(--ri);z-index:3}
.modal-x:hover{background:var(--neu-bg);color:var(--ink)}
/* Full-screen image lightbox (Batch 3) — sits above all other overlays. */
.lightbox{position:fixed;inset:0;background:rgba(15,23,42,.86);z-index:220;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:14px;padding:6vh 24px;cursor:zoom-out;animation:popin .14s ease-out}
.lightbox-img{max-width:min(1100px,92vw);max-height:82vh;object-fit:contain;border-radius:var(--rs);box-shadow:0 18px 60px rgba(0,0,0,.5);background:#fff}
.lightbox-cap{color:#e2e8f0;font-size:13px;font-weight:600;text-align:center;max-width:92vw}
.lightbox-x{position:fixed;top:20px;right:24px;width:42px;height:42px;display:flex;align-items:center;justify-content:center;border:0;background:rgba(255,255,255,.12);color:#fff;cursor:pointer;border-radius:var(--rs)}
.lightbox-x:hover{background:rgba(255,255,255,.24)}
/* Call-us modal card (top-bar phone icon) */
.callcard{border:1px solid var(--line);border-radius:var(--rs);padding:16px 18px;background:var(--chrome)}
.callcard-k{font-size:11px;font-weight:700;text-transform:uppercase;letter-spacing:.05em;color:var(--muted);border-bottom:1px solid var(--line);padding-bottom:8px;margin-bottom:10px}
.callcard-num{display:inline-flex;align-items:center;gap:9px;font-size:22px;font-weight:700;color:var(--navy);text-decoration:none}
.callcard-num:hover{color:var(--teal-dark)}
@keyframes popin{from{opacity:0;transform:translateY(10px) scale(.98)}to{opacity:1;transform:none}}
.modal .mtop{padding:22px 24px 6px}
.modal .mtop .meyebrow{font-size:11px;font-weight:700;text-transform:uppercase;letter-spacing:.05em;color:var(--teal-dark);margin-bottom:6px}
.modal h2{font-size:18px;font-weight:700;letter-spacing:-.01em}
.modal .msub{font-size:13px;color:var(--muted);margin-top:6px}
.modal .mbody{padding:14px 24px}
.modal .mfoot{padding:16px 24px;background:var(--neu-bg);border-top:1px solid var(--line);display:flex;gap:10px;justify-content:flex-end}
.fixopt{display:flex;align-items:center;gap:13px;border:1px solid var(--line);border-radius:var(--rs);padding:12px 14px;margin-bottom:10px;cursor:pointer}
.fixopt:hover{border-color:var(--teal);background:var(--teal-50)}
.fixopt.sel{border-color:var(--navy);background:var(--navy-50)}
.fixopt .fcheck{width:20px;height:20px;border-radius:50%;border:2px solid var(--line);flex-shrink:0;display:flex;align-items:center;justify-content:center;font-size:11px;color:#fff}
.fixopt.sel .fcheck{background:var(--navy);border-color:var(--navy)}
.fixopt .fnm{font-size:13px;font-weight:700}
.fixopt .fds{font-size:12px;color:var(--muted)}
.fixopt .fpr{margin-left:auto;font-weight:800;color:var(--navy);font-variant-numeric:tabular-nums;white-space:nowrap}
.readonly-note{display:inline-flex;align-items:center;gap:6px;font-size:12px;font-weight:600;color:var(--muted);background:var(--neu-bg);border:1px solid var(--line);border-radius:var(--ri);padding:6px 10px}

/* ============================================================================
   MILESTONE 3 — CHECKOUT, FREIGHT & ORDERS
   ============================================================================ */
.checkout-grid{display:grid;grid-template-columns:1fr 340px;gap:28px;align-items:start}

/* ── CHECKOUT ACCORDION (Pass 4) — progressive disclosure, one step open at a time ──
   Land with Step 1 open; "Continue →" validates the step, collapses it and opens the
   next; any step re-opens via its header. Same fields & order logic as before. */
.co-step{background:#fff;border:1px solid var(--line);border-radius:var(--rs);box-shadow:var(--shadow-sm);margin-bottom:14px;overflow:hidden}
.co-step.open{border-color:var(--teal)}
.co-step-head{width:100%;display:flex;align-items:center;gap:12px;padding:15px 18px;background:none;border:none;cursor:pointer;font:inherit;text-align:left}
.co-step-head:hover{background:var(--neu-bg)}
.co-num{width:24px;height:24px;border-radius:50%;background:var(--navy);color:#fff;font-size:12px;font-weight:700;display:inline-flex;align-items:center;justify-content:center;flex-shrink:0}
.co-num.done{background:var(--ok-tx)}
.co-step-title{font-size:14px;font-weight:700;color:var(--ink)}
.co-step-sum{font-size:12.5px;color:var(--muted);margin-left:6px;flex:1;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.co-step-chev{margin-left:auto;color:var(--faint);font-size:12px;flex-shrink:0}
.co-step-body{padding:6px 18px 18px}
.co-step-body .chint{font-size:12px;color:var(--muted);margin-bottom:14px}
.co-continue{margin-top:16px}

/* delivery vs pickup — rounded selectable cards (no emoji), per Oliver */
.co-method-cards{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin-bottom:16px}
.co-method-card{display:flex;align-items:flex-start;gap:11px;border:1.5px solid var(--line);border-radius:var(--rs);padding:14px;cursor:pointer;background:#fff;transition:border-color .12s ease,background .12s ease}
.co-method-card:hover{border-color:var(--teal)}
.co-method-card.sel{border-color:var(--navy);background:var(--navy-50)}
.co-method-card .cmc-radio{width:18px;height:18px;border-radius:50%;border:2px solid var(--line);flex-shrink:0;margin-top:1px;position:relative}
.co-method-card.sel .cmc-radio{border-color:var(--navy)}
.co-method-card.sel .cmc-radio:after{content:'';position:absolute;inset:3px;border-radius:50%;background:var(--navy)}
.co-method-card .cmc-t{display:block;font-size:13px;font-weight:700}
.co-method-card .cmc-d{display:block;font-size:12px;color:var(--muted);margin-top:2px;line-height:1.4}

/* inline "add new delivery address" form in checkout Step 1 */
.new-addr{border:1px solid var(--line);border-radius:var(--rs);background:var(--neu-bg);padding:14px 16px;margin-top:10px}
.new-addr .na-h{font-size:13px;font-weight:700;margin-bottom:10px}
.new-addr .na-save{display:flex;align-items:center;gap:8px;font-size:12.5px;font-weight:600;color:var(--ink);margin:6px 0 0;text-transform:none}
.new-addr .na-save input{width:auto;margin:0;accent-color:var(--navy)}
.new-addr .na-actions{display:flex;gap:8px;justify-content:flex-end;margin-top:14px}

.co-card{background:#fff;border:1px solid var(--line);border-radius:var(--rs);box-shadow:var(--shadow-sm);padding:20px 22px;margin-bottom:18px}
.co-card h3{font-size:14px;font-weight:700;margin-bottom:4px;display:flex;align-items:center;gap:9px}
.co-card .chint{font-size:12px;color:var(--muted);margin-bottom:16px}
.co-card .num-badge{width:22px;height:22px;border-radius:50%;background:var(--navy);color:#fff;font-size:11px;font-weight:700;display:inline-flex;align-items:center;justify-content:center}
.formrow{display:grid;grid-template-columns:1fr 1fr;gap:0 16px}
.formrow .full{grid-column:1/3}
textarea.field{resize:vertical;min-height:64px;line-height:1.5}
/* native (non-combo) dropdowns — used for short lists (≤5 options); custom chevron
   so they match the app instead of the OS default. */
select.field{cursor:pointer;background-color:#fff;appearance:none;-webkit-appearance:none;padding-right:34px;
  background-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'><polyline points='6 9 12 15 18 9'/></svg>");
  background-repeat:no-repeat;background-position:right 12px center}
.field.short{margin-bottom:0}
.fiellabel-row{display:flex;justify-content:space-between;align-items:baseline}
.opt-tag{font-size:11px;color:var(--faint);font-weight:600}

/* segmented control (delivery/pickup, card/bank) */
.segment{display:inline-flex;border:1px solid var(--line);border-radius:var(--ri);overflow:hidden;background:#fff;margin-bottom:18px}
.segment button{font:inherit;font-size:13px;font-weight:600;padding:9px 18px;border:none;background:#fff;color:var(--muted);cursor:pointer;display:flex;align-items:center;gap:7px}
.segment button+button{border-left:1px solid var(--line)}
.segment button.on{background:var(--navy);color:#fff}

/* payment method option */
.payopt{display:flex;align-items:center;gap:13px;border:1px solid var(--line);border-radius:var(--rs);padding:13px 15px;margin-bottom:10px;cursor:pointer}
.payopt:hover{border-color:var(--teal)}
.payopt.sel{border-color:var(--navy);background:var(--navy-50)}
.payopt .pradio{width:18px;height:18px;border-radius:50%;border:2px solid var(--line);flex-shrink:0;position:relative}
.payopt.sel .pradio{border-color:var(--navy)}
.payopt.sel .pradio:after{content:'';position:absolute;inset:3px;border-radius:50%;background:var(--navy)}
.payopt .pnm{font-size:13px;font-weight:700}
.payopt .pds{font-size:12px;color:var(--muted)}
.bank-badge{width:32px;height:32px;border-radius:50%;background:var(--navy);color:#fff;display:flex;align-items:center;justify-content:center;font-size:10.5px;font-weight:800;letter-spacing:-.02em;flex-shrink:0}
.bank-logo{width:32px;height:32px;border-radius:var(--rs);border:1px solid var(--line);object-fit:cover;flex-shrink:0}
.bank-hdr-tile{width:56px;height:56px;border-radius:var(--ro);background:#fff;display:flex;align-items:center;justify-content:center;margin:0 auto;box-shadow:var(--shadow-sm)}
.bank-badge-hdr{width:44px;height:44px;font-size:13px;background:none;color:var(--navy)}
.bank-logo-hdr{width:44px;height:44px;border-radius:var(--rs);border:none;object-fit:cover}
.po-note{background:var(--info-bg);border:1px solid var(--info-bd);color:var(--info-tx);border-radius:var(--ri);padding:11px 14px;font-size:12.5px;font-weight:500;margin-top:6px}
.pickup-note{background:var(--neu-bg);border:1px solid var(--line);border-radius:var(--ri);padding:14px 16px;font-size:13px;color:var(--muted)}
.pickup-note b{color:var(--ink)}

/* Direct credit — remittance instructions (checkout step 3, confirmation, order detail) */
.dc-block{margin-bottom:22px}
.dc-block h3{font-size:15px;font-weight:700;margin-bottom:10px;color:var(--ink)}
.dc-panel{color:var(--ink)}
.dc-row{display:flex;justify-content:space-between;gap:12px;padding:5px 0;border-bottom:1px solid var(--line);font-size:13px}
.dc-row:last-of-type{border-bottom:none}
.dc-row .k{color:var(--muted)}
.dc-row .v{font-weight:600;text-align:right}
.dc-foot{margin-top:10px;padding-top:10px;border-top:1px solid var(--line);font-size:12px;color:var(--muted)}
.dc-foot a{color:var(--teal-dark)}

/* Open Banking / PayTo authorisation overlay (mocked) — navy header needs a light close icon */
.bank-auth-modal .modal-x{color:rgba(255,255,255,.85)}
.bank-auth-modal .modal-x:hover{background:rgba(255,255,255,.15);color:#fff}

/* order summary (checkout right rail) — reuses quote summary vibe */
.co-summary{position:sticky;top:0;border:1px solid var(--line);border-radius:var(--rs);background:#fff;box-shadow:var(--shadow-sm);overflow:hidden}
.co-summary .csh{padding:16px 18px;border-bottom:1px solid var(--line);font-weight:700;font-size:14px}
.co-sumlines{padding:8px 18px;max-height:260px;overflow:auto}
.cosl{display:flex;align-items:center;justify-content:space-between;gap:10px;font-size:12.5px;padding:7px 0;border-bottom:1px solid var(--line)}
.cosl:last-child{border-bottom:none}
.cosl .cn{color:var(--ink);flex:1;min-width:0}.cosl .cq{color:var(--muted)}
.cosl .cv{font-variant-numeric:tabular-nums;font-weight:600;white-space:nowrap}
.co-sum{padding:14px 18px;background:var(--neu-bg);border-top:1px solid var(--line)}
.co-sum .row{display:flex;justify-content:space-between;font-size:13px;padding:4px 0;color:var(--muted)}
.co-sum .row .v{font-variant-numeric:tabular-nums;font-weight:600;color:var(--ink)}
.co-sum .row.tot{font-size:17px;font-weight:800;color:var(--ink);border-top:1px solid var(--line);margin-top:8px;padding-top:12px}
.co-sum .row.tot .v{color:var(--navy)}
.co-act{padding:16px 18px;border-top:1px solid var(--line);display:flex;flex-direction:column;gap:10px}

/* ORDER CONFIRMATION */
.conf{max-width:680px;margin:0 auto;text-align:center;padding:24px 0 40px}
.conf .tick{width:74px;height:74px;border-radius:50%;background:var(--ok-bg);border:2px solid var(--ok-bd);color:var(--ok-tx);font-size:38px;display:flex;align-items:center;justify-content:center;margin:8px auto 18px}
.conf h1{font-size:24px;margin-bottom:8px}
.conf .csub{color:var(--muted);font-size:14px;margin-bottom:26px}
.conf .cbox{text-align:left;border:1px solid var(--line);border-radius:var(--rs);background:#fff;box-shadow:var(--shadow-sm);padding:0;overflow:hidden;margin-bottom:22px}
.conf .cbox .cbh{background:var(--navy);color:#fff;padding:14px 20px;display:flex;justify-content:space-between;align-items:center}
.conf .cbox .cbh .so{font-weight:800;font-size:16px}
.conf .cbox .cbh .amt{font-weight:800;font-size:16px;font-variant-numeric:tabular-nums}
.conf .cbox .cbody{padding:16px 20px;font-size:13px}
.conf .cbox .crow{display:flex;justify-content:space-between;padding:6px 0;border-bottom:1px solid var(--line)}
.conf .cbox .crow:last-child{border:none}
.conf .cbox .crow .k{color:var(--muted)}
.conf .cbox .crow .v{font-weight:600;text-align:right}
.conf .next{background:var(--info-bg);border:1px solid var(--info-bd);color:var(--info-tx);border-radius:var(--rs);padding:14px 18px;font-size:13px;text-align:left;margin-bottom:24px;line-height:1.55}
.conf .cbtns{display:flex;gap:12px;justify-content:center;flex-wrap:wrap}

/* PAST ORDER detail */
.od-grid{display:grid;grid-template-columns:1fr 300px;gap:28px;align-items:start}
.od-meta{border:1px solid var(--line);border-radius:var(--rs);background:#fff;box-shadow:var(--shadow-sm);padding:18px 20px}
.od-meta .mr{display:flex;justify-content:space-between;font-size:13px;padding:7px 0;border-bottom:1px solid var(--line)}
.od-meta .mr:last-child{border:none}
.od-meta .mr .k{color:var(--muted)} .od-meta .mr .v{font-weight:600;text-align:right}

/* detail right-rail (quote detail): meta + totals + CTAs grouped in one card, CTAs
   stacked under the totals (Oliver + "Example of CTA under totals area" reference). */
.dr-table .tbl{margin:0}
.detail-rail{border:1px solid var(--line);border-radius:var(--rs);background:#fff;box-shadow:var(--shadow-sm);overflow:hidden;position:sticky;top:0}
.detail-rail .dr-head{padding:14px 18px;border-bottom:1px solid var(--line);font-weight:700;font-size:14px;display:flex;justify-content:space-between;align-items:center;gap:8px}
.detail-rail .dr-meta{padding:6px 18px}
.detail-rail .dr-row{display:flex;justify-content:space-between;gap:10px;font-size:12.5px;padding:7px 0;border-bottom:1px solid var(--line)}
.detail-rail .dr-meta .dr-row:last-child{border-bottom:none}
.detail-rail .dr-row .k{color:var(--muted)} .detail-rail .dr-row .v{font-weight:600;text-align:right;color:var(--ink)}
.detail-rail .dr-tot{padding:10px 18px;background:var(--neu-bg);border-top:1px solid var(--line)}
.detail-rail .dr-tot .dr-row{border-bottom:none;padding:4px 0;color:var(--muted)}
.detail-rail .dr-tot .dr-row.tot{font-size:16px;font-weight:800;color:var(--ink);border-top:1px solid var(--line);margin-top:6px;padding-top:10px}
.detail-rail .dr-tot .dr-row.tot .v{color:var(--navy)}
.detail-rail .dr-act{padding:14px 18px;border-top:1px solid var(--line);display:flex;flex-direction:column;gap:8px}
/* 6-column detail table: tighter columns; stack the rail below the table on narrower
   viewports so the table gets full width and never overflows. */
.dr-table .tbl th,.dr-table .tbl td{padding-left:10px;padding-right:10px}
@media (max-width:1100px){.od-grid{grid-template-columns:1fr}}

/* ── "SYSTEM WORKING" OVERLAY (the feels-real spinner) ────────────────────── */
.processing{position:fixed;inset:0;background:rgba(255,255,255,.82);z-index:130;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:18px;backdrop-filter:blur(1.5px)}
.processing .spinner{width:46px;height:46px;border-width:4px}
.processing .pmsg{font-size:15px;font-weight:700;color:var(--navy)}
.processing .psub{font-size:12.5px;color:var(--muted);margin-top:-8px}

/* Guided tour — spotlight overlay (box-shadow trick darkens everything but the target) */
.tour-backdrop{position:fixed;inset:0;z-index:199;background:transparent}
.tour-spot{position:fixed;z-index:200;border-radius:8px;box-shadow:0 0 0 9999px rgba(15,23,42,.62);pointer-events:none;transition:top .2s ease,left .2s ease,width .2s ease,height .2s ease}
.tour-spot-none{top:50%;left:50%;width:0;height:0;box-shadow:0 0 0 9999px rgba(15,23,42,.62)}
.tour-card{position:fixed;z-index:201;background:#fff;border-radius:var(--ro);box-shadow:var(--shadow-pop);padding:20px;animation:popin .16s ease-out}
.tour-step-n{font-size:11px;font-weight:700;text-transform:uppercase;letter-spacing:.05em;color:var(--teal-dark);margin-bottom:6px}
.tour-card h3{font-size:15px;font-weight:700;margin-bottom:6px}
.tour-card p{font-size:13px;color:var(--muted);line-height:1.5}
.tour-actions{display:flex;justify-content:space-between;align-items:center;margin-top:16px}
.tour-actions-right{display:inline-flex;align-items:center;gap:16px}
.tour-skip{background:none;border:none;font:inherit;font-size:12.5px;color:var(--muted);cursor:pointer;text-decoration:underline}
.tour-skip:hover{color:var(--ink)}

/* ============================================================================
   MILESTONE 4 — ENTRY JOURNEYS (login paths · welcome · onboarding)
   ============================================================================ */
.auth-choice{display:flex;align-items:center;gap:14px;border:1px solid var(--line);border-radius:var(--rs);padding:15px 16px;margin-bottom:12px;cursor:pointer;text-align:left}
.auth-choice:hover{border-color:var(--navy);background:var(--navy-50)}
.auth-choice .ach-ic{font-size:24px;flex-shrink:0;line-height:1}
.auth-choice .ach-t{font-size:14px;font-weight:700}
.auth-choice .ach-d{font-size:12.5px;color:var(--muted);margin-top:2px;line-height:1.4}
.auth-choice .ach-go{margin-left:auto;color:var(--navy);font-weight:800;font-size:18px}
.auth-card .formrow{gap:0 14px}
.auth-card .badge{align-self:flex-start}

/* pending-account explainer banner (shown above every screen for pending users) */
.pending-banner{display:flex;gap:12px;align-items:flex-start;background:var(--warn-bg);border:1px solid var(--warn-bd);color:var(--warn-tx);border-radius:var(--rs);padding:13px 16px;margin-bottom:22px;font-size:13px;line-height:1.5}
.pending-banner .pb-ic{font-size:18px;line-height:1.2;flex-shrink:0}
.pending-banner b{font-weight:700}

/* ============================================================================
   MILESTONE 5 — SAVED QUOTES · SEND COMPOSER · MY PRODUCTS
   ============================================================================ */
.qcards{display:grid;grid-template-columns:repeat(2,1fr);gap:16px}
.qcard{background:#fff;border:1px solid var(--line);border-radius:var(--rs);box-shadow:var(--shadow-sm);padding:18px 20px;cursor:pointer;display:flex;flex-direction:column;transition:transform .12s ease,box-shadow .15s ease,border-color .15s ease}
.qcard:hover{border-color:var(--teal);box-shadow:var(--shadow-lift);transform:translateY(-2px)}
.qcard .qc-top{display:flex;justify-content:space-between;align-items:flex-start;gap:10px}
.qcard .qc-name{font-size:15px;font-weight:700;color:var(--navy);line-height:1.3}
.qcard .qc-meta{font-size:12px;color:var(--muted);margin-top:3px}
.qcard .qc-total{font-size:19px;font-weight:800;color:var(--ink);font-variant-numeric:tabular-nums;margin-top:8px}
.qcard .qc-actions{display:flex;gap:8px;margin-top:14px}

/* branded quote preview inside the Send composer */
.email-preview{border:1px solid var(--line);border-radius:var(--rs);overflow:hidden;margin-top:4px;font-size:13px}
.email-preview .ep-head{background:var(--navy);color:#fff;padding:10px 14px;font-weight:800;font-size:16px}
.email-preview .ep-head .dot{color:var(--red)}
.email-preview .ep-body{padding:14px;color:var(--muted);line-height:1.55}
.email-preview .ep-quote{background:var(--neu-bg);border:1px solid var(--line);border-radius:var(--ri);padding:10px 12px;margin:10px 0;color:var(--ink)}
.email-preview .ep-total{font-weight:800;color:var(--navy)}
.email-preview .ep-link{color:var(--teal-dark);font-weight:700}
.modal .mbody.scroll{max-height:62vh;overflow:auto}
.sent-ok{text-align:center;padding:14px 0 4px}
.sent-ok .tick{width:60px;height:60px;border-radius:50%;background:var(--ok-bg);border:2px solid var(--ok-bd);color:var(--ok-tx);font-size:30px;display:flex;align-items:center;justify-content:center;margin:0 auto 14px}

/* inline "add to My Products" search results (My Products tab) */
.myprodadd-results{border:1px solid var(--line);border-radius:var(--rs);overflow:hidden;margin-bottom:6px;background:#fff}
.myprodadd-row{display:flex;align-items:center;gap:12px;padding:10px 14px;border-bottom:1px solid var(--line)}
.myprodadd-row:last-child{border-bottom:none}
.myprodadd-row .myprodadd-info{flex:1;min-width:0}
.myprodadd-row .code{font-size:11px;color:var(--muted);font-weight:600}
.myprodadd-row .nm{font-size:13px;font-weight:700;line-height:1.3}

/* shared-quote (recipient link view) */
.shared-banner{display:flex;gap:10px;align-items:center;background:var(--info-bg);border:1px solid var(--info-bd);color:var(--info-tx);border-radius:var(--rs);padding:12px 16px;margin-bottom:18px;font-size:13px;font-weight:600}
.share-msg{background:var(--neu-bg);border:1px solid var(--line);border-left:3px solid var(--teal);border-radius:var(--ri);padding:12px 16px;margin-bottom:20px;font-size:14px;color:var(--ink);line-height:1.5}

/* small line-item thumbnail (quote/order/checkout — product visible at every stage) */
.cellitem{display:flex;align-items:center;gap:11px}
.linethumb{width:36px;height:36px;border-radius:4px;background:var(--chrome);flex-shrink:0;display:flex;align-items:center;justify-content:center;overflow:hidden}
.linethumb img{width:100%;height:100%;object-fit:contain;mix-blend-mode:multiply}
.linethumb .ph{color:var(--faint);font-size:13px}

/* ============================================================================
   MILESTONE 6 — ACCOUNT HUB
   ============================================================================ */
.acct-tabs{display:flex;gap:4px;border-bottom:1px solid var(--line);margin-bottom:22px;flex-wrap:wrap}
.acct-tab{background:none;border:none;border-bottom:2px solid transparent;padding:10px 16px;font:inherit;font-size:13px;font-weight:600;color:var(--muted);cursor:pointer;margin-bottom:-1px}
.acct-tab:hover{color:var(--ink)}
.acct-tab.on{color:var(--navy);border-bottom-color:var(--navy)}
/* Account Users tab: one search (left) + Invite user (right), matched heights (Batch 3). */
.acct-usertools{display:flex;align-items:center;gap:12px;margin-bottom:18px}
.li-faint{color:var(--faint);vertical-align:middle}
.ns-note{display:flex;gap:8px;align-items:center;background:var(--info-bg);border:1px solid var(--info-bd);color:var(--info-tx);border-radius:var(--ri);padding:11px 14px;font-size:12.5px;font-weight:500;margin-bottom:16px}
.addr-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:16px}
.addr-card{background:#fff;border:1px solid var(--line);border-radius:var(--rs);box-shadow:var(--shadow-sm);padding:16px 18px}
.addr-top{display:flex;justify-content:space-between;align-items:flex-start;gap:8px;margin-bottom:8px}
.addr-label{font-weight:700;font-size:14px}
.addr-node{font-size:12px;color:var(--muted)}
.addr-lines{font-size:13px;color:var(--muted);line-height:1.5;margin-bottom:14px}
.addr-actions{display:flex;gap:8px;flex-wrap:wrap}
.co-card label{margin-top:6px}
.co-card .field[disabled]{background:var(--neu-bg);color:var(--muted);cursor:not-allowed}
.co-branch{margin-bottom:18px;max-width:460px}
.co-branch label{display:block;font-size:13px;font-weight:600;color:var(--ink);margin-bottom:6px}

/* ============================================================================
   MILESTONE 7 — CONFIGURATORS
   ============================================================================ */
.cfg-grid{display:grid;grid-template-columns:300px 1fr;gap:28px;align-items:start}
.cfg-controls label{display:block;margin:14px 0 6px}
.cfg-controls label:first-child{margin-top:0}
.cfg-controls .qty{width:100%}
.cfg-controls .qty input{flex:1;width:auto}
/* realistic speed-calmer render container — fixed 4:1 box (matches the reference's
   font-scaling assumption); the SVG fills it and centres via preserveAspectRatio. */
.sc-diagram{width:100%;aspect-ratio:4/1;background:var(--asphalt);border:1px solid var(--line);border-radius:var(--rs);overflow:hidden;margin-bottom:20px}
.sc-diagram svg{width:100%;height:100%;display:block}
.sec-h2{font-size:15px;font-weight:700;margin:18px 0 12px}
@media (max-width:900px){.cfg-grid{grid-template-columns:1fr}}

/* ============================================================================
   SHARED DATA TABLE — transaction lists (Projects · Quotes · Orders)
   Sortable headers, filter toolbar (search + chips + branch dropdown), pager.
   ============================================================================ */
.tbl-wrap{display:flex;flex-direction:column;gap:14px}
.tbl-actions{margin-bottom:16px}
.tbl-toolbar{display:flex;align-items:center;gap:12px;flex-wrap:wrap}
.tbl-toolbar .tbl-search{flex:1 1 160px;min-width:150px}   /* fills the right-hand space to the far edge; stays on the filters' row */
.tbl-search{height:32px;min-width:230px;padding:0 14px;border:1px solid var(--line);border-radius:var(--rs);font-size:13px;background:#fff;color:var(--ink)}
.tbl-search:focus{outline:none;border-color:var(--teal);box-shadow:0 0 0 3px var(--navy-50)}
.tbl-filter{display:inline-flex;align-items:center;gap:8px;font-size:12px;color:var(--muted);font-weight:600}
/* compact the branded control for the toolbar — applies to both the native <select>
   (≤5 branches) and the searchable combo (>5 branches) so they look identical. */
.tbl-filter select.field{margin:0;width:auto;min-width:150px;height:32px;padding-top:0;padding-bottom:0;font-size:13px;font-weight:600;color:var(--ink);border-radius:var(--rs)}
.tbl-filter .combo.field{margin:0;width:auto;min-width:160px}
.tbl-filter .combo-input.field{height:32px;padding-top:0;padding-bottom:0;font-size:13px;font-weight:600;border-radius:var(--rs)}
.tbl-chips{display:inline-flex;gap:6px;flex-wrap:wrap}
.tbl-chips .chip{height:32px;padding:0 13px;border:1px solid var(--line);border-radius:6px;background:#fff;color:var(--muted);font-size:12px;font-weight:600;cursor:pointer;transition:all .12s ease}
.tbl-chips .chip:hover{border-color:var(--teal);color:var(--ink)}
.tbl-chips .chip.on{background:var(--navy);border-color:var(--navy);color:#fff}

/* list-table skin (extends .tbl) — sortable headers + clickable rows */
.tbl.list th.srt{cursor:pointer;user-select:none;white-space:nowrap}
.tbl.list th.srt:hover{color:var(--ink)}
.tbl.list th.active{color:var(--navy)}
.tbl.list th .srt-c{font-size:9px;margin-left:4px;vertical-align:middle}
.tbl.list td.iname{color:var(--navy);font-weight:700}
.tbl.list .tbl-link{color:var(--teal-dark);font-weight:600;cursor:pointer}
.tbl.list .tbl-link:hover{text-decoration:underline}
.tbl.list .btn-track{display:inline-flex;align-items:center;padding:4px 10px;border:1px solid var(--line,#d0d5dd);border-radius:6px;color:var(--teal-dark);font-weight:600;font-size:12px;text-decoration:none;cursor:pointer;white-space:nowrap}
.tbl.list .btn-track:hover{background:var(--teal-dark);color:#fff;border-color:var(--teal-dark)}
.tbl.list td.row-acts{text-align:right;white-space:nowrap}
.tbl.list .row-acts-wrap{display:inline-flex;gap:6px;align-items:center;justify-content:flex-end}
.tbl.list .row-act{display:inline-flex;align-items:center;gap:4px;padding:4px 10px;border:1px solid var(--line,#d0d5dd);border-radius:6px;background:#fff;color:var(--teal-dark);font-weight:600;font-size:12px;text-decoration:none;cursor:pointer;white-space:nowrap;line-height:1.4}
.tbl.list .row-act:hover{background:var(--teal-dark);color:#fff;border-color:var(--teal-dark)}
.tbl.list .row-act.primary{background:var(--navy);color:#fff;border-color:var(--navy)}
.tbl.list .row-act.primary:hover{filter:brightness(1.08)}
/* Collapsible kit/group parent rows on record detail (ADR-0014). A kit reads like any other item row — its
   ONLY distinction is the caret (no "X items" pill — Louis 2026-07-22); the whole row is the toggle target. */
.tbl .ln-toggle{margin-right:6px;color:var(--teal-dark);vertical-align:middle;display:inline-flex;align-items:center}
.tbl .ln-child > td{background:#fff}
.tbl .ln-child .iname{color:var(--muted);font-weight:400}
.tbl .ln-indent{display:inline-block;width:18px}
/* Close the detail line-items table with a bottom edge so a trailing note row (e.g. a "Free …" description)
   reads as part of the table rather than floating (Louis 2026-07-22). List tables (.tbl.list) are unaffected. */
.tbl:not(.list) > tbody > tr:last-child > td{border-bottom:1px solid var(--line)}
.tbl.list .muted{color:var(--muted)}
.tbl.list td .neg{color:var(--err-tx,#b42318);font-weight:600}

.tbl-empty{padding:34px 16px;text-align:center;color:var(--muted);font-size:14px;border:1px dashed var(--line);border-top:0;border-radius:0 0 var(--rs) var(--rs)}
.tbl-count{font-size:12px;color:var(--muted)}
.tbl-pager{display:flex;align-items:center;justify-content:space-between;gap:12px}
.tbl-pg-btns{display:flex;gap:8px}
.tbl-pg-btns .btn[disabled]{opacity:.45;pointer-events:none}

.proj-meta{font-size:13px;color:var(--muted);margin:-10px 0 8px}
.proj-meta .code{color:var(--muted)}
.main .muted{color:var(--muted)}
@media (max-width:720px){.tbl-toolbar{gap:8px}.tbl-search{min-width:0;flex:1 1 100%}}
/* backorder split note on an order/quote line (R1-03) */
.bo-note{display:flex;align-items:center;gap:5px;margin-top:3px;font-size:12px;font-weight:600;color:var(--warn-tx)}

/* ============================================================================
   MOBILE / RESPONSIVE  (2026-07-07 — implements docs/mobile-responsive-audit.md)
   Desktop-first overrides. Base state hides the mobile-only chrome; at ≤900px the
   fixed shell collapses and the sidebar becomes an off-canvas drawer; at ≤600px
   we tighten the top bar, stack forms, and size inputs/targets for touch.
   ============================================================================ */
.navtoggle{display:none;width:38px;height:38px;border:1px solid transparent;background:transparent;color:var(--navy);border-radius:var(--ri);align-items:center;justify-content:center;cursor:pointer;flex-shrink:0}
.navtoggle:hover{background:var(--teal-50);border-color:var(--teal)}
.nav-backdrop{display:none}
.catnav-toggle{display:none}   /* Browse category toggle — mobile only (desktop shows the rail inline) */
.combo-pop{max-width:calc(100vw - 16px)}   /* backstop: popup never wider than the screen (JS also clamps its position) */
.tbl-scroll{width:100%}   /* plain wrapper on desktop; becomes a horizontal scroller on mobile */

@media (max-width:900px){
  /* Shell → single column; the sidebar leaves the grid and becomes a drawer. */
  .shell{display:flex;flex-direction:column;height:100%}
  .navtoggle{display:inline-flex}
  .topbar{grid-column:auto;height:56px;padding:0 12px;gap:8px}
  .main{flex:1;min-height:0;padding:22px 16px}

  .sidebar{position:fixed;top:0;left:0;bottom:0;width:272px;max-width:84vw;z-index:106;
    transform:translateX(-100%);transition:transform .22s ease-out;
    box-shadow:6px 0 30px rgba(15,23,42,.24);overflow-y:auto}
  .sidebar.open{transform:translateX(0)}
  .nav-backdrop{display:block;position:fixed;inset:0;background:rgba(15,23,42,.44);z-index:105;
    opacity:0;visibility:hidden;transition:opacity .2s}
  .nav-backdrop.open{opacity:1;visibility:visible}

  /* Top bar: reclaim width. Search collapses to its icon (rule at :62 hides the
     placeholder/hint already); drop the dividers and the "Welcome, Name" text. */
  .topbar .topsearch{flex:0 0 auto}
  .topbar .topdiv{display:none}
  .chip{padding:4px 8px 4px 5px}
  .chip > span:not(.avatar):not(.caret){display:none}   /* keep avatar + caret, drop the name */

  /* Collapse every fixed multi-column grid to a single column. minmax(0,1fr) (not
     1fr) so a track can't be forced wider than the screen by nowrap content inside
     it — e.g. a long product name in a My Products card. */
  .browse,.pdetail,.checkout-grid,.cards,.myprod-minis,.qcards,.addr-grid,.co-method-cards,.od-grid,.cfg-grid{grid-template-columns:minmax(0,1fr)}
  .browse{gap:18px}
  .catnav{position:static}          /* was sticky — pointless once stacked above the list */

  /* Category rail collapses behind a toggle so products are the first thing you see. */
  .catnav-toggle{display:flex;align-items:center;justify-content:space-between;gap:10px;width:100%;
    background:#fff;border:1px solid var(--line);border-radius:var(--rs);padding:11px 14px;
    font:inherit;font-size:14px;font-weight:600;color:var(--navy);cursor:pointer;box-shadow:var(--shadow-sm)}
  .catnav-toggle .ct-l{display:inline-flex;align-items:center;gap:8px;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  .catnav-toggle .ct-chev{color:var(--faint);transition:transform .15s ease;flex-shrink:0}
  .catnav-toggle[aria-expanded="true"] .ct-chev{transform:rotate(180deg)}
  .catnav{display:none}
  .catnav.open{display:block;margin-top:-6px}

  /* Wide data tables scroll inside their own box instead of pushing the page wide. */
  .tbl-scroll{overflow-x:auto;-webkit-overflow-scrolling:touch;border-radius:var(--rs)}
  .tbl-scroll .tbl{min-width:600px}   /* keep columns legible; the box scrolls, not the page */
}

@media (max-width:600px){
  .main{padding:18px 13px}
  .main h1{font-size:19px}

  /* Secondary top-bar icons (call/email/help) fold away; bell + cart + search stay. */
  .toputils .topicon{display:none}
  .basket.topcart .basket-lbl{display:none}   /* icon + count only */
  .topbar{gap:6px}
  .topbar .logo{min-width:0;overflow:hidden}  /* let the wordmark shrink rather than push the bar wide */
  .topbar .logo-img{height:24px}
  .chip .caret{display:none}                   /* avatar only on phones */

  /* Two-up forms stack. */
  .formrow{grid-template-columns:1fr}

  /* Product rows: the price (128px) + action (184px) columns can't sit beside the
     thumb+info on a phone. Wrap so price stays on line 1 (right) and the action
     block (qty + Add/Configure) drops to its own full-width line. */
  .prow{flex-wrap:wrap;gap:12px 14px}
  .prow .pmid{width:auto;min-width:0;margin-left:auto;text-align:right}
  .prow .pact{width:100%;align-items:stretch}
  .prow .pact .qty{align-self:flex-start}   /* keep the stepper compact, don't stretch it */

  /* 16px inputs stop iOS Safari auto-zooming on focus. */
  .field,textarea.field,select.field,.search,.tbl-search,.combo-input,.cflt-input,.colflt-pop .cflt-date input{font-size:16px}

  /* Roomier touch targets. */
  .topicon,.navtoggle{width:42px;height:42px}
  .qty button{width:38px;height:40px}
  .qty input{height:40px}

  /* Overlays never exceed the screen. */
  .tour-card{max-width:calc(100vw - 24px)}
  .demobar{gap:8px}
  .demobar .combo-input{min-width:0;max-width:100%}
}

/* ── Vanguard staff: customer emulation ────────────────────────────────────────────────────────
   Replaces the shared-password "Test: sign in as this customer". Staff sign in as themselves and
   choose whose portal to view; RLS already returns every synced customer to them (migration 0015),
   so this is a choice over data the session can read, not a new grant. */
.emubar{position:sticky;top:0;z-index:60;display:flex;align-items:center;gap:10px;flex-wrap:wrap;
  padding:8px 16px;background:#7c2d12;color:#fff;font-size:13px;box-shadow:0 1px 4px rgba(0,0,0,.2)}
.emubar .spacer{flex:1}
.emubar-tag{background:rgba(255,255,255,.18);border:1px solid rgba(255,255,255,.35);border-radius:999px;
  padding:2px 9px;font-size:11px;font-weight:700;letter-spacing:.03em;text-transform:uppercase;white-space:nowrap}
.emubar-text{opacity:.95}
.emubar-text b{font-weight:700}
.emubar-link{cursor:pointer;font-weight:600;text-decoration:underline;text-underline-offset:2px;white-space:nowrap}
.emubar-link:hover{opacity:.8}

.staff-pick-card{max-width:560px}
.staff-pick-list{margin-top:12px;max-height:46vh;overflow-y:auto;border:1px solid var(--line,#e2e8f0);border-radius:10px}
.staff-pick-row{display:flex;align-items:center;gap:10px;padding:11px 14px;cursor:pointer;border-bottom:1px solid var(--line,#eef2f7)}
.staff-pick-row:last-child{border-bottom:0}
.staff-pick-row:hover{background:var(--wash,#f8fafc)}
.staff-pick-name{flex:1;font-weight:600;color:var(--ink,#0f172a)}
.staff-pick-level{font-size:11px;text-transform:uppercase;letter-spacing:.03em;color:#64748b;
  background:#f1f5f9;border-radius:999px;padding:2px 8px}
.staff-pick-empty,.staff-pick-more{padding:12px 14px;color:#64748b;font-size:13px}
.staff-pick-more{padding-left:0}
