/* NFG Sourcing: one stylesheet (house rules 2.2 and 4). Seeded from NFG Fleet 0.59, which has NFG Core's look: Inter, warm greys,
   Core's tables, the black rail with fold-out menus. Fleet-only parts (plates, maps, tracking, register) are left out.
   NFG Sourcing palette: black #000000, Sourcing blue #3289B4, dark grey #A7A9AC, light grey #D9D9D9.
   As THIRSTI Flow uses its red and Tekwani Grow its green, Sourcing uses its blue for the brand mark, primary actions, the
   accent line under the top bar (the Home tile's look: black band, blue line) and what is selected. Status colours stay semantic.
   Modules use these variables; never type a hex code into a module. */
:root{--accent:#3289B4; --accent-dk:#276E91; --accent-bg:#E6F1F7; --ink:#000; --grey-dk:#a7a9ac; --grey-lt:#e3e3e0;
  --muted:#5b5f66; --line:#e3e3e0; --ground:#f5f5f3; --surface:#fff; --soft:#fafaf8; --row:#efefec; --edge:#d0d0cc; --tot:#f0f0ec; --font:Inter,system-ui,-apple-system,"Segoe UI",Arial,sans-serif;
  --ok-bg:#e1f0e5; --ok:#1d5a30; --warn-bg:#fbedd5; --warn:#714200; --info-bg:#e2eaf2; --info:#1f4469; --err-bg:#fbe4e2; --err:#8f1d18;
  --rail:84px; --subw:248px;}
*{box-sizing:border-box}
html,body{height:100%}
body{margin:0;background:var(--ground);color:#111;font-family:var(--font);font-size:14px;line-height:1.45;font-variant-numeric:tabular-nums;-webkit-font-smoothing:antialiased}
button{font:inherit}
.mono{font-family:var(--font);font-variant-numeric:tabular-nums;font-size:13px;font-weight:500;letter-spacing:.01em}
h1{margin:0;font-size:26px;line-height:1.2;font-weight:700;letter-spacing:-.01em}
h2{margin:0;font-size:17px;font-weight:700;letter-spacing:-.005em}
h3{margin:0;font-size:11px;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);font-weight:700}
p{margin:0;max-width:85ch}
.sub-t{color:var(--muted)}
.row{display:flex;flex-wrap:wrap;gap:10px;align-items:center}
[hidden]{display:none!important}

/* sign-in */
.login{min-height:100%;display:flex;align-items:center;justify-content:center;padding:24px 16px;background:var(--ground)}
.login-card{background:var(--surface);border:1px solid var(--grey-lt);border-radius:12px;padding:32px 28px;width:100%;max-width:380px;display:flex;flex-direction:column;gap:14px}
.login-logo{width:190px;height:auto;margin-bottom:6px}
.btn.wide{width:100%;justify-content:center}
.linkbtn{all:unset;cursor:pointer;color:var(--muted);font-size:13px;text-decoration:underline;align-self:center}

/* frame */
.app{position:relative;display:flex;min-height:100vh;width:100%}
.rail{flex:0 0 var(--rail);background:#000;color:#fff;display:flex;flex-direction:column;padding:14px 6px 12px;gap:4px;z-index:5;position:sticky;top:0;height:100vh;overflow-y:auto}
.brand{display:flex;flex-direction:column;align-items:center;gap:6px;padding:4px 0 14px;border-bottom:1px solid #2a2a2a;margin-bottom:8px}
.brand img{width:34px;height:auto}
.brand .word{font-weight:700;font-size:11px;letter-spacing:.16em;color:var(--accent)}
.mods{display:flex;flex-direction:column;gap:2px;flex:1 1 auto}
.mod{all:unset;box-sizing:border-box;cursor:pointer;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;padding:9px 2px 8px;border-radius:8px;color:var(--grey-dk);font-size:10.5px;font-weight:600;text-align:center;line-height:1.15;min-height:56px}
.mod svg{width:22px;height:22px;stroke:currentColor;fill:none;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.mod:hover{color:#fff;background:#1a1a1a}
.mod:focus-visible{outline:2px solid #fff;outline-offset:-2px}
.mod.on{color:#000;background:#fff}
.mod.later{opacity:.55}
.railsep{height:1px;background:#2a2a2a;margin:6px 8px}
.me{all:unset;box-sizing:border-box;cursor:pointer;display:flex;flex-direction:column;align-items:center;gap:4px;padding:8px 2px;border-radius:8px;color:var(--grey-lt);font-size:10px;text-align:center}
.me:hover{background:#1a1a1a}
.av{width:32px;height:32px;border-radius:50%;background:#fff;color:#000;font-weight:700;font-size:12px;display:flex;align-items:center;justify-content:center}

.sub{background:var(--surface);border-right:1px solid var(--line);width:var(--subw);display:flex;flex-direction:column;z-index:4}
.sub.pinned{flex:0 0 var(--subw);position:sticky;top:0;height:100vh}
.sub.over{position:fixed;left:var(--rail);top:0;bottom:0;box-shadow:12px 0 32px rgba(0,0,0,.18)}
.subhd{display:flex;align-items:center;gap:6px;padding:14px 12px 12px 18px;border-bottom:1px solid var(--line);min-height:60px}
.subhd h2{flex:1 1 auto}
.subbd{padding:10px 8px 20px;display:flex;flex-direction:column;gap:2px;overflow-y:auto}
.sec{display:flex;flex-direction:column;gap:1px}
.sec.open:not(:last-child){margin-bottom:8px}
.secit{display:flex;flex-direction:column;gap:1px}
.sec:not(.open) .secit{display:none}
.sech{all:unset;box-sizing:border-box;cursor:pointer;display:flex;align-items:center;justify-content:space-between;gap:8px;min-height:32px;padding:6px 10px;border-radius:6px;font-size:11px;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:var(--muted)}
.sech:hover{background:var(--ground);color:#000}
.sech:focus-visible{outline:2px solid #000}
.sech svg{flex:none;width:14px;height:14px;stroke:currentColor;fill:none;stroke-width:2.2;stroke-linecap:round;stroke-linejoin:round;transition:transform .15s}
.sec.open .sech svg{transform:rotate(180deg)}
.item{all:unset;box-sizing:border-box;cursor:pointer;display:flex;align-items:center;gap:8px;padding:8px 10px;border-radius:8px;font-size:13.5px;font-weight:500;min-height:36px;color:#111}
.item:hover{background:var(--ground)}
.item:focus-visible{outline:2px solid #000}
.item.on{background:#000;color:#fff;font-weight:600}
.item .lk{margin-left:auto;display:inline-flex;color:#8a8c90}
.item .lk svg{width:14px;height:14px;stroke:currentColor;fill:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.scrim{all:unset;position:fixed;inset:0 0 0 var(--rail);background:rgba(0,0,0,.28);z-index:3;cursor:pointer}

.col{flex:1 1 auto;min-width:0;display:flex;flex-direction:column;min-height:100vh}
.topbar{display:flex;align-items:center;gap:8px;padding:10px 18px;min-height:60px;background:var(--surface);border-bottom:1px solid var(--line);flex-wrap:wrap;position:sticky;top:0;z-index:2}
.ib{all:unset;box-sizing:border-box;cursor:pointer;width:36px;height:36px;border-radius:8px;display:inline-flex;align-items:center;justify-content:center;color:var(--muted)}
.ib:hover{background:var(--ground);color:#000}
.ib:focus-visible{outline:2px solid #000}
.ib svg{width:18px;height:18px;stroke:currentColor;fill:none;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.ib.on{background:#000;color:#fff}
.crumbs{display:flex;align-items:center;gap:8px;font-size:14px;flex-wrap:wrap;min-width:0}
.crumbs .c1{all:unset;cursor:pointer;font-weight:500;color:var(--muted)}
.crumbs .c1:hover{text-decoration:underline}
.crumbs .sep{color:var(--grey-dk)}
.crumbs .cur{font-weight:700}
.tools{margin-left:auto;display:flex;align-items:center;gap:6px;flex-wrap:wrap}
.ctx{display:inline-flex;align-items:center;gap:8px;border:1px solid var(--edge);border-radius:8px;padding:4px 10px;font-size:13px;color:var(--muted);min-height:38px;background:#fff}
.va{font:inherit;font-size:13px;font-weight:600;border:0;background:transparent;color:#000;cursor:pointer;max-width:240px}
.main{flex:1 1 auto;padding:22px 26px 40px;display:flex;flex-direction:column;gap:16px;min-width:0}
.status{display:flex;flex-wrap:wrap;gap:6px 16px;justify-content:space-between;padding:8px 18px;border-top:1px solid var(--line);background:var(--surface);font-size:12px;color:var(--muted)}
.loading{color:var(--muted);padding:20px 0}

/* content */
.grid3{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:16px}
.card{background:var(--surface);border:1px solid var(--line);border-radius:12px;padding:16px 20px;display:flex;flex-direction:column;gap:8px;min-width:0}
.kpi{font-size:28px;font-weight:800;letter-spacing:-.02em;font-variant-numeric:tabular-nums;line-height:1.15}
.kv{display:grid;grid-template-columns:minmax(120px,40%) 1fr;gap:4px 12px;font-size:13px;margin:0}
.kv dt{color:var(--muted)} .kv dd{margin:0;min-width:0;overflow-wrap:anywhere}
.tbl{overflow-x:auto;background:var(--surface);border:1px solid var(--line);border-radius:12px}
.t{min-width:var(--min,640px);font-size:13px}
.tr{display:grid;grid-template-columns:var(--cols);border-bottom:1px solid var(--row);align-items:start}
.tr:last-child{border-bottom:0}
.c{padding:9px 10px;min-width:0;overflow-wrap:anywhere}
.n{text-align:right;font-variant-numeric:tabular-nums;white-space:nowrap}
.ctr{text-align:center}
.th{background:#fff;border-bottom:1px solid var(--line)}
.th .c{font-size:11px;letter-spacing:.05em;text-transform:uppercase;color:var(--muted);font-weight:700;padding-top:10px;padding-bottom:8px}
.tot{font-weight:800;border-top:2px solid #000;background:var(--tot)}
.segr{background:#000;color:#fff;font-weight:700}
.opr{background:var(--soft);font-weight:700}
.full{grid-column:1/-1}
.btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;font-family:inherit;font-size:13px;font-weight:600;border:1px solid #cfcfcb;background:#fff;color:#000;border-radius:8px;padding:0 14px;cursor:pointer;min-height:38px;white-space:nowrap;text-decoration:none}
.btn:hover{border-color:#000}
.btn.pri{background:#000;border-color:#000;color:#fff}
.btn.danger{background:var(--err);border-color:var(--err);color:#fff}
.btn.ghost{border-style:dashed;color:var(--muted)}
.btn.sm{min-height:32px;padding:0 10px;font-size:12.5px}
.btn:disabled{opacity:.45;cursor:not-allowed;border-style:dashed}
.btn .bi{width:13px;height:13px;stroke:currentColor;fill:none;stroke-width:2}
.btn:focus-visible,.chip:focus-visible,.link:focus-visible{outline:2px solid #000;outline-offset:2px}
.link{all:unset;cursor:pointer;font-weight:600;text-decoration:underline;text-decoration-color:var(--accent);text-underline-offset:3px}
.chip{font:inherit;font-size:13px;font-weight:600;border:1px solid var(--edge);background:#fff;border-radius:999px;padding:0 14px;cursor:pointer;color:#333;min-height:34px;display:inline-flex;align-items:center;gap:8px}
.chip.on{background:#000;color:#fff;border-color:#000}
.tag{display:inline-block;border-radius:999px;padding:2px 9px;font-size:11.5px;font-weight:700;white-space:nowrap}
.t-ok{background:var(--ok-bg);color:var(--ok)} .t-warn{background:var(--warn-bg);color:var(--warn)}
.t-info{background:var(--info-bg);color:var(--info)} .t-mute{background:#ececec;color:#3c3e41}
.t-err{background:var(--err-bg);color:var(--err)}
.t-reg{background:#ececec;color:#000;letter-spacing:.02em}
.banner{border:1px solid #e3c68c;background:#fdf6e8;border-radius:10px;padding:10px 14px;font-size:13px;color:#573a00}
.banner.err{border-color:#e6aaa5;background:var(--err-bg);color:var(--err)}
.note{border:1px dashed #cfcfcb;border-radius:10px;padding:10px 14px;font-size:13px;color:#3c3e41;background:var(--soft)}
.yes{font-weight:700;text-align:center} .nope{color:var(--grey-dk);text-align:center}
.lock{max-width:560px;margin:40px auto;display:flex;flex-direction:column;align-items:center;gap:14px;text-align:center}
.ring{width:64px;height:64px;border-radius:50%;border:2px solid #000;display:flex;align-items:center;justify-content:center}
.ring svg{width:26px;height:26px;stroke:#000;fill:none;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}

/* files */
.gal{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:10px}
.gal-i{all:unset;box-sizing:border-box;cursor:pointer;display:flex;flex-direction:column;background:var(--surface);border:1px solid var(--line);border-radius:10px;overflow:hidden}
.gal-i:hover,.gal-i:focus-visible{border-color:#000;outline:none}
.gal-i img,.gal-x{width:100%;aspect-ratio:4/3;object-fit:cover;background:var(--soft);display:flex;align-items:center;justify-content:center;font-weight:700;color:var(--muted)}
.gal-c{font-size:12px;padding:6px 8px;color:var(--muted)}
.gal-i.old{opacity:.55}
.ph-big{max-width:100%;max-height:60vh;object-fit:contain;border-radius:6px;background:var(--soft);align-self:center}
.drop input[type=file]{border-style:dashed;padding:18px 10px;cursor:pointer}
.drop.on input[type=file]{border-color:#000;background:var(--soft)}
.flist{display:flex;flex-direction:column;gap:6px;font-size:13px;border:1px solid var(--grey-lt);border-radius:6px;padding:8px 10px;max-height:180px;overflow:auto}

/* forms and dialogs */
.fld{display:flex;flex-direction:column;gap:5px;font-size:11px;font-weight:600;letter-spacing:.06em;text-transform:uppercase;color:var(--muted)}
.fld input,.fld select,.fld textarea{font:inherit;font-size:14px;font-weight:400;letter-spacing:normal;text-transform:none;color:#111;background:#fff;border:1px solid var(--edge);border-radius:8px;padding:8px 10px;min-height:40px;width:100%;min-width:0}
.fld input:focus,.fld select:focus,.fld textarea:focus{outline:0;border-color:#000;box-shadow:0 0 0 1px #000}
.chk{display:flex;gap:8px;align-items:center;font-size:13.5px}
.dlg-wrap{position:fixed;inset:0;background:rgba(0,0,0,.35);display:flex;align-items:flex-start;justify-content:center;padding:40px 16px;z-index:50;overflow-y:auto}
.dlg{background:#fff;border-radius:12px;padding:22px;width:100%;max-width:520px;display:flex;flex-direction:column;gap:14px;box-shadow:0 20px 50px rgba(0,0,0,.25);max-height:calc(100vh - 80px);max-height:calc(100dvh - 80px);overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:var(--grey-dk) transparent}
.dlg-fields{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:12px}
.dlg-btns{justify-content:flex-end;position:sticky;bottom:-22px;z-index:2;background:#fff;margin:0 -22px -22px;padding:12px 22px 22px;border-top:1px solid var(--line)}
.dlg-err{color:var(--err);font-size:13px;font-weight:700}
#toast{position:fixed;bottom:22px;left:50%;transform:translateX(-50%) translateY(20px);background:#000;color:#fff;padding:10px 16px;border-radius:8px;font-size:13.5px;opacity:0;pointer-events:none;transition:opacity .2s,transform .2s;z-index:60}
#toast.show{opacity:1;transform:translateX(-50%) translateY(0)}
#toast.err{background:var(--err)}
@media (max-width:700px){
  .main{padding:16px}
  .sub.pinned{position:fixed;left:var(--rail);top:0;bottom:0}
}
@media (prefers-reduced-motion:reduce){*{transition:none!important}}

/* ---------- Hive additions ---------- */
.filters{display:flex;flex-wrap:wrap;gap:10px;align-items:flex-end}
.filters .fld{flex:0 1 180px}
.filters .fld.grow{flex:1 1 260px}
.tr.click{cursor:pointer}
.tr.click:hover{background:#fafafa}
.apps{display:flex;flex-wrap:wrap;gap:4px}
.temp{font-family:var(--font);font-variant-numeric:tabular-nums;font-size:22px;letter-spacing:.08em;padding:12px;background:var(--soft);border:1px dashed var(--grey-dk);border-radius:8px;text-align:center}
.applist{display:flex;flex-direction:column;border:1px solid var(--grey-lt);border-radius:8px;overflow:hidden;flex-shrink:0}
.dlg-scroll>*{flex-shrink:0}   /* the dialog body scrolls; its parts keep their full height (the app list was being squashed and cut off) */
.apphd{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:2px 0 -6px}
.apphd .lnk{all:unset;cursor:pointer;font-size:13px;font-weight:700;text-decoration:underline}
.applist .chk{padding:9px 12px;border-bottom:1px solid #ededed;margin:0}
.applist .chk:last-child{border-bottom:0}
.dlg h3{margin-top:4px}
.dlg-scroll{max-height:62vh;overflow-y:auto;display:flex;flex-direction:column;gap:14px;padding-right:2px}
.kpis{display:grid;grid-template-columns:repeat(auto-fit,minmax(170px,1fr));gap:12px}
.kpi-l{font-size:11px;letter-spacing:.1em;text-transform:uppercase;color:var(--muted);font-weight:700}
.bar{height:6px;background:var(--grey-lt);border-radius:3px;overflow:hidden}
.bar i{display:block;height:100%;background:#000}
.home-link{all:unset;box-sizing:border-box;cursor:pointer;display:flex;flex-direction:column;align-items:center;gap:4px;padding:8px 2px;border-radius:8px;color:var(--grey-lt);font-size:10px;font-weight:700;text-align:center}
.home-link:hover{background:#1a1a1a;color:#fff}
.app-sw{color:var(--grey-dk)}
.home-link svg{width:20px;height:20px;stroke:currentColor;fill:none;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}

/* Phones: the rail becomes a bar along the bottom so the content keeps the full width. */
@media (max-width:700px){
  .app{flex-direction:column}
  .rail{position:fixed;left:0;right:0;bottom:0;top:auto;height:auto;flex-direction:row;padding:4px 6px calc(4px + env(safe-area-inset-bottom));z-index:6;overflow-x:auto;overflow-y:hidden}
  .rail .brand,.rail .railsep,.rail .me .nm{display:none}
  .mods{flex-direction:row;gap:2px}
  .mod{min-height:50px;min-width:62px;padding:6px 4px}
  .me,.home-link,.app-sw{min-width:56px}
  .col{padding-bottom:70px}
  .sub.over,.sub.pinned{position:fixed;left:0;right:0;top:auto;bottom:62px;width:auto;max-height:70vh;border-right:0;border-top:1px solid var(--grey-lt);box-shadow:0 -12px 32px rgba(0,0,0,.18)}
  .scrim{inset:0}
  .topbar{padding:8px 10px}
  .tools .ib.hide-sm{display:none}
  .status{padding:8px 12px}
  .filters .fld{flex:1 1 140px}
}
.item .lk{font-size:10px;font-weight:700;text-transform:uppercase;letter-spacing:.08em}


/* ---------- tables, padlock, home cards, tabs ---------- */
/* sortable headings and the table search box (H.table) */
.th .sortc{all:unset;box-sizing:border-box;cursor:pointer;user-select:none;padding:10px 10px 8px;min-width:0;font-size:11px;letter-spacing:.05em;text-transform:uppercase;color:var(--muted);font-weight:700}
.th .sortc:hover{color:#000}
.th .sortc:focus-visible{outline:2px solid #000;outline-offset:-2px}
.th .sortc.n{text-align:right}
.tsearch{display:flex;align-items:center;gap:10px;margin-bottom:-8px}
.tsearch input{font:inherit;font-size:14px;border:1px solid var(--grey-dk);border-radius:6px;padding:8px 10px;min-height:36px;flex:0 1 380px;min-width:0}
.tsearch input:focus{outline:2px solid #000;outline-offset:0}
.item .lk svg{width:14px;height:14px}
.lock .ring svg{width:26px;height:26px}
/* home tiles that open a screen */
.kcard{all:unset;box-sizing:border-box;cursor:pointer;background:var(--surface);border:1px solid var(--grey-lt);border-radius:8px;padding:14px 16px;display:flex;flex-direction:column;gap:8px}
.kcard:hover,.kcard:focus-visible{border-color:#000;outline:none}
.tabs{display:flex;gap:2px;border-bottom:1px solid var(--grey-lt);overflow-x:auto;scrollbar-width:thin}
.tab{all:unset;cursor:pointer;padding:9px 14px;font-size:13.5px;font-weight:700;color:var(--muted);border-bottom:3px solid transparent;white-space:nowrap}
.tab:hover{color:#000}
.tab:focus-visible{outline:2px solid #000;outline-offset:-2px}
.tab.on{color:#000;border-bottom-color:#000}
@media (max-width:700px){.fc-no{font-size:21px}.fc-tags{margin-left:0}}

/* header, as Thirsti Flow: Tasks due (n), refresh, bell, Sudo login, Sign out. The SDK's floating SUDO button is replaced by
   the header's (it still opens the shared picker). */
.nfg-sudo-btn{display:none!important}
.tdue{all:unset;box-sizing:border-box;cursor:pointer;background:#c62828;color:#fff;font-weight:700;font-size:13px;border-radius:6px;padding:8px 12px;white-space:nowrap}
.tdue:hover{background:#a51f1f}.tdue:focus-visible{outline:2px solid #000;outline-offset:2px}
.tb-b{border:1px solid var(--grey-lt)}
.bell{position:relative}
.bell i{position:absolute;top:-6px;right:-6px;min-width:17px;height:17px;padding:0 4px;box-sizing:border-box;border-radius:9px;background:#c62828;color:#fff;font:700 10.5px/17px var(--font);font-style:normal;text-align:center}
.tb-sudo{all:unset;box-sizing:border-box;cursor:pointer;border:1px solid #e0a800;background:#fff8e0;color:#5a4300;font-weight:700;font-size:13px;border-radius:6px;padding:7px 12px;white-space:nowrap}
.tb-sudo:hover{background:#ffefb3}.tb-sudo:focus-visible{outline:2px solid #000;outline-offset:2px}
.tb-out{all:unset;box-sizing:border-box;cursor:pointer;display:inline-flex;align-items:center;gap:6px;border:1px solid var(--grey-lt);border-radius:6px;padding:7px 12px;font-size:13px;font-weight:700;color:var(--muted);white-space:nowrap}
.tb-out:hover{background:#f0f0f0;color:#000}.tb-out:focus-visible{outline:2px solid #000}
.tb-out svg{width:16px;height:16px;stroke:currentColor;fill:none;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.notes{display:flex;flex-direction:column;gap:6px;max-height:60vh;overflow:auto}
.note-i{all:unset;box-sizing:border-box;cursor:pointer;display:flex;flex-direction:column;gap:2px;padding:9px 11px;border:1px solid var(--grey-lt);border-radius:8px}
.note-i:hover{background:#f6f6f6}.note-i[disabled]{cursor:default}.note-i.new{border-left:4px solid var(--accent)}
.note-k{font-size:11.5px;color:var(--muted)}
@media (max-width:700px){ .tb-out span{display:none} }


/* ---------- Core's table standard ---------- */
.th .sortc.asc::after{content:" \25B2";font-size:8px} .th .sortc.desc::after{content:" \25BC";font-size:8px}
.th .sortc.n{white-space:normal;text-wrap:balance}
.tr.tf{background:#fff;border-bottom:1px solid var(--line)} .tf .c{padding:2px 8px 8px}
.tf input{width:100%;box-sizing:border-box;font-size:12px;font-weight:400;padding:3px 6px;min-height:30px;border:1px solid var(--edge);border-radius:6px;background:#fff;font-family:inherit}
.tf input:focus{outline:0;border-color:#000}
.tf .c.n input{text-align:right}
.tr.tot.ttop{border-top:0;border-bottom:2px solid #000} .ttop .c{white-space:nowrap;overflow:visible}
[data-thead] .tr.th{border-bottom:0}
[data-tbody] .tr:last-child{border-bottom:0}
.rp .tr{align-items:center}
.rp .c{padding:7px 10px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;overflow-wrap:normal}
.rp .th .sortc,.rp .th .sortc.n{white-space:nowrap}
.rp .tf .c{padding:2px 8px 8px}
.rp .tr:not(.th):not(.tf):not(.tot):hover{background:var(--soft)}
.rp .tag{padding:1px 6px;font-size:10.5px;vertical-align:1px}
.tr.click.sel,.rp .tr.click.sel:hover{background:#f0f0ec;box-shadow:inset 3px 0 0 #000}
.tsearch{margin-bottom:0}

.tbl .tr.tot.ttop .c{overflow:visible;text-overflow:clip}


/* ---------- NFG Sourcing accent (as Flow's red and Grow's green) ---------- */
.topbar{box-shadow:inset 0 3px 0 var(--accent)}
/* the rail in Sourcing blue (as Grow's is Tekwani green). White text and icons on the blue; the logo keeps its own colours
   on a black tile (never recolour the logo: its blue trunk would vanish on the blue rail). */
.rail{background:var(--accent);color:#fff}
.rail .brand{border-bottom:1px solid rgba(255,255,255,.35);padding-bottom:12px}
.rail .brand img{width:40px;height:40px;border-radius:9px;box-shadow:0 1px 3px rgba(0,0,0,.25)}
.rail .brand .word{color:#fff;font-weight:800}
.rail .mod{color:#fff;opacity:.88}
.rail .mod:hover{opacity:1;background:rgba(0,0,0,.16)}
.rail .mod:focus-visible{outline:2px solid #fff;outline-offset:-2px}
.rail .mod.on{opacity:1;background:#fff;color:var(--accent-dk);box-shadow:0 1px 3px rgba(0,0,0,.2)}
.rail .railsep{background:rgba(255,255,255,.35)}
.rail .me,.rail .home-link,.rail .app-sw{color:#fff}
.rail .me:hover,.rail .home-link:hover{background:rgba(0,0,0,.16)}
.rail .av{background:#fff;color:var(--accent-dk)}
.rail .nfg-sw-home:hover,.rail .nfg-sw-arrow:hover,.rail .nfg-sw.open .nfg-sw-arrow{background:rgba(0,0,0,.16)}
.btn.pri{background:var(--accent);border-color:var(--accent);color:#fff}
.btn.pri:hover{background:var(--accent-dk);border-color:var(--accent-dk)}
.btn.pri:disabled{background:#fff;color:#000;border-color:#cfcfcb}
.item.on{background:#000;color:#fff;box-shadow:inset 3px 0 0 var(--accent)}
.chip.on{background:var(--accent);border-color:var(--accent)}
.tab.on{border-bottom-color:var(--accent)}
.tr.click.sel,.rp .tr.click.sel:hover{box-shadow:inset 3px 0 0 var(--accent)}
.fld input:focus,.fld select:focus,.fld textarea:focus{border-color:var(--accent);box-shadow:0 0 0 1px var(--accent)}
.kcard:hover,.kcard:focus-visible{border-color:var(--accent)}
.t-acc{background:var(--accent-bg);color:var(--accent-dk)}

/* Ask Lawrence button in the top bar */
.tb-ask{all:unset;box-sizing:border-box;cursor:pointer;display:inline-flex;align-items:center;gap:6px;border:1px solid var(--accent);background:var(--accent-bg);color:var(--accent-dk);font-weight:700;font-size:13px;border-radius:6px;padding:7px 12px;white-space:nowrap}
.tb-ask:hover{background:var(--accent);color:#fff}.tb-ask:focus-visible{outline:2px solid #000;outline-offset:2px}
.tb-ask svg{width:16px;height:16px;stroke:currentColor;fill:none;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
@media (max-width:700px){ .tb-ask span{display:none} }

/* Home: from supplier to customer */
.flow{display:grid;grid-template-columns:repeat(auto-fit,minmax(130px,1fr));gap:10px;counter-reset:f}
.flow-s{all:unset;box-sizing:border-box;cursor:pointer;position:relative;display:flex;flex-direction:column;gap:4px;padding:12px 12px 12px;border:1px solid var(--line);border-top:3px solid var(--accent);border-radius:8px;background:var(--surface);font-size:13px}
.flow-s:hover,.flow-s:focus-visible{border-color:var(--accent);outline:none}
.flow-s.later{border-top-color:var(--grey-dk)}
.flow-s.later .flow-i{color:var(--grey-dk)}
.flow-n{position:absolute;top:8px;right:10px;font-size:11px;font-weight:700;color:var(--muted)}
.flow-i{color:var(--accent)}
.flow-i svg{width:22px;height:22px;stroke:currentColor;fill:none;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.flow-s .sub-t{font-size:12px;line-height:1.3}
.ask-card .ask-i{width:20px;height:20px;stroke:var(--accent);fill:none;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;vertical-align:-3px}

/* Ask Lawrence */
.ask{display:flex;flex-direction:column;gap:12px;max-width:900px;width:100%}
.thread{display:flex;flex-direction:column;gap:10px;min-height:240px}
.threadtop{display:flex;justify-content:flex-end}
.bub{max-width:80%;padding:10px 14px;border-radius:12px;font-size:14px;white-space:pre-wrap;overflow-wrap:anywhere}
.bub.him{align-self:flex-start;background:var(--surface);border:1px solid var(--line);border-bottom-left-radius:4px}
.bub.me{align-self:flex-end;background:var(--accent);color:#fff;border-bottom-right-radius:4px}
.bub.thinking{color:var(--muted);font-style:italic}
.figs{background:var(--surface);border:1px solid var(--line);border-radius:10px;padding:8px 10px}
.figs summary{cursor:pointer;font-size:12.5px;font-weight:700;color:var(--muted)}
.figs .tbl{margin-top:8px;border:0}
.askbar{position:sticky;bottom:12px;display:flex;gap:8px;align-items:flex-end;background:var(--surface);border:1px solid var(--edge);border-radius:12px;padding:8px;box-shadow:0 6px 20px rgba(0,0,0,.06)}
.askbar textarea{flex:1 1 auto;font:inherit;font-size:14px;border:0;resize:none;outline:0;padding:6px 8px;min-height:24px;max-height:140px;background:transparent}
.asksend{all:unset;cursor:pointer;width:38px;height:38px;border-radius:10px;background:var(--accent);color:#fff;display:flex;align-items:center;justify-content:center}
.asksend:hover{background:var(--accent-dk)}.asksend:focus-visible{outline:2px solid #000;outline-offset:2px}
.asksend svg{width:18px;height:18px;stroke:currentColor;fill:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
