/* Node Freight brand tokens - from Brand Book 2026.
   Defined once here and used across the app and PDF consignment notes. */
:root {
  --nf-dark-blue: #174ea1;   /* primary anchor */
  --nf-medium-blue: #6f9bd1;
  --nf-sky-blue: #7ac6ee;     /* accent */
  --nf-black: #000000;
  --nf-ink: #1a1a1a;
  --nf-muted: #5b6b7d;
  --nf-line: #e3e8ee;
  --nf-bg: #f6f8fb;
  --nf-card: #ffffff;
  --nf-radius: 10px;
  --nf-shadow: 0 1px 3px rgba(23, 78, 161, 0.08), 0 1px 2px rgba(0, 0, 0, 0.04);
  --nf-font: 'Inter', 'Segoe UI', system-ui, -apple-system, Arial, sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: var(--nf-font);
  color: var(--nf-ink);
  background: var(--nf-bg);
  line-height: 1.5;
}

/* Header */
.nf-header {
  background: var(--nf-card);
  border-bottom: 1px solid var(--nf-line);
  display: flex;
  align-items: center;
  gap: 28px;
  padding: 14px 28px;
  position: sticky;
  top: 0;
  z-index: 10;
}
.nf-logo { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.nf-logo .word { font-size: 22px; letter-spacing: .5px; color: var(--nf-black); }
.nf-logo .word b { font-weight: 700; }
.nf-logo .word span { font-weight: 700; letter-spacing: 3px; }

.nf-nav { display: flex; gap: 4px; margin-left: 8px; flex-wrap: wrap; }
.nf-nav a {
  text-decoration: none;
  color: var(--nf-muted);
  font-weight: 600;
  font-size: 14px;
  padding: 8px 14px;
  border-radius: 8px;
}
.nf-nav a:hover { background: var(--nf-bg); color: var(--nf-dark-blue); }
.nf-nav a.active { background: var(--nf-dark-blue); color: #fff; }

/* Bottom brand bar device from the brand book */
.nf-barstrip { display: flex; height: 4px; }
.nf-barstrip i { flex: 1; }
.nf-barstrip i:nth-child(1) { background: var(--nf-dark-blue); flex: 3; }
.nf-barstrip i:nth-child(2) { background: var(--nf-medium-blue); }
.nf-barstrip i:nth-child(3) { background: var(--nf-sky-blue); }

/* Layout */
/* Fluid width: use the available window, with a generous cap so it doesn't
   stretch indefinitely on ultra-wide screens. Tables only scroll sideways when
   the window is genuinely too narrow. */
.nf-main { width: 100%; max-width: 1680px; margin: 0 auto; padding: 24px 32px; }
@media (min-width: 1800px) { .nf-main { max-width: 1880px; } }
.nf-pagehead { margin: 4px 0 20px; }
.nf-pagehead h1 { font-size: 26px; margin: 0; font-weight: 700; }
.nf-pagehead .sub { color: var(--nf-muted); font-size: 14px; margin-top: 4px; }

/* Cards */
.nf-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.nf-card {
  background: var(--nf-card);
  border: 1px solid var(--nf-line);
  border-radius: var(--nf-radius);
  box-shadow: var(--nf-shadow);
  padding: 18px 20px;
}
.nf-card .label { color: var(--nf-muted); font-size: 13px; font-weight: 600; text-transform: uppercase; letter-spacing: .4px; }
.nf-card .value { font-size: 30px; font-weight: 700; color: var(--nf-dark-blue); margin-top: 6px; }
.nf-card .hint { color: var(--nf-muted); font-size: 13px; margin-top: 6px; }

.nf-panel {
  background: var(--nf-card);
  border: 1px solid var(--nf-line);
  border-radius: var(--nf-radius);
  box-shadow: var(--nf-shadow);
  padding: 22px 24px;
  margin-top: 20px;
}
.nf-panel h2 { margin: 0 0 8px; font-size: 18px; }
.nf-panel p { color: var(--nf-muted); margin: 6px 0; }

.nf-tag { display: inline-block; background: var(--nf-sky-blue); color: #06324f; font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 999px; }
.nf-foot { text-align: center; color: var(--nf-muted); font-size: 12px; padding: 24px; }

/* --- Shared components (lists, detail pages) --- */
.nf-table { width:100%; border-collapse:collapse; font-size:13px; }
.nf-table thead th { background:var(--nf-bg); text-align:left; padding:11px 12px; color:var(--nf-muted); font-weight:700; border-bottom:1px solid var(--nf-line); white-space:nowrap; }
.nf-table td { padding:10px 12px; border-bottom:1px solid var(--nf-line); }
.nf-table tbody tr:hover { background:#fafcff; }
.nf-table .num { text-align:right; white-space:nowrap; }
.nf-table a { color:var(--nf-dark-blue); text-decoration:none; font-weight:600; }
.nf-table a:hover { text-decoration:underline; }
.mono { font-variant-numeric:tabular-nums; font-weight:600; color:var(--nf-dark-blue); }
.nf-status { font-size:12px; font-weight:600; padding:2px 9px; border-radius:999px; background:var(--nf-bg); color:var(--nf-muted); white-space:nowrap; }
.s-invoiced { background:#e6f0ff; color:#174ea1; }
.s-delivered { background:#e7f6ec; color:#1f7a44; }
.s-cancelled { background:#fde9e9; color:#b3261e; }
.s-booked, .s-intransit, .s-quoted { background:#fff5e6; color:#9a6700; }
.s-onfordelivery { background:#e8f0fe; color:#174ea1; }
.s-delayed { background:#fde9e9; color:#b3261e; }
.s-lostdamaged { background:#fde9e9; color:#b3261e; }
.nf-back { display:inline-block; color:var(--nf-muted); text-decoration:none; font-size:14px; margin-bottom:10px; }
.nf-back:hover { color:var(--nf-dark-blue); }
.nf-kv { display:grid; grid-template-columns:repeat(auto-fit,minmax(220px,1fr)); gap:14px 28px; }
.nf-kv .k { color:var(--nf-muted); font-size:12px; font-weight:600; text-transform:uppercase; letter-spacing:.3px; }
.nf-kv .v { font-size:15px; margin-top:2px; }
.nf-pill { display:inline-block; background:var(--nf-sky-blue); color:#06324f; font-size:12px; font-weight:700; padding:2px 10px; border-radius:999px; }
.nf-pill.warn { background:#fff0d6; color:#8a5a00; }
.nf-pill.muted { background:var(--nf-bg); color:var(--nf-muted); }
h2.nf-sec { font-size:16px; margin:24px 0 10px; }

/* === Header refinements === */
.nf-logo img { display:block; }
.nf-header-tag { margin-left:auto; color:var(--nf-muted); font-size:12px; font-style:italic; letter-spacing:.2px; }
.nf-nav a.cta { background:var(--nf-sky-blue); color:#06324f; }
.nf-nav a.cta:hover { background:#63b9e8; color:#06324f; }
.nf-nav a.cta.active { background:var(--nf-dark-blue); color:#fff; }
/* Main-nav hover menus (2026-07-21, Edward): the button clicks through as
   normal; hovering the item reveals a small dropdown of shortcuts. The
   wrapper is inline-flex + centred (and the nav itself centre-aligns) so
   wrapped buttons sit level with the plain links. */
.nf-nav { align-items:center; }
.nf-navitem { position:relative; display:inline-flex; align-items:center; }
.nf-navitem > a { display:block; }
.nf-navdrop { display:none; position:absolute; top:100%; left:0; background:#fff;
  border:1px solid var(--nf-line); border-radius:10px; box-shadow:0 8px 22px rgba(6,50,79,.16);
  padding:6px; min-width:180px; z-index:80; }
.nf-navitem:hover .nf-navdrop, .nf-navitem:focus-within .nf-navdrop { display:block; }
.nf-navdrop a { display:block; padding:7px 10px; border-radius:7px; font-size:13px;
  color:var(--nf-dark-blue); text-decoration:none; white-space:nowrap; background:none; }
.nf-navdrop a:hover { background:var(--nf-bg); color:var(--nf-dark-blue); }

/* === Buttons === */
.nf-btn { display:inline-block; background:var(--nf-dark-blue); color:#fff; border:none; border-radius:8px;
  padding:9px 16px; font-weight:600; font-size:14px; font-family:var(--nf-font); cursor:pointer; text-decoration:none; }
.nf-btn:hover { background:#123c7d; }
.nf-btn.ghost { background:#fff; color:var(--nf-dark-blue); border:1px solid var(--nf-dark-blue); }
.nf-btn.ghost:hover { background:var(--nf-bg); }
.nf-btn.sm { padding:6px 12px; font-size:13px; }
.nf-btn-lg { padding:12px 26px; font-size:15px; }
.nf-link { color:var(--nf-muted); text-decoration:none; align-self:center; }
.nf-link:hover { color:var(--nf-dark-blue); }
.nf-add { background:#fff; border:1px dashed var(--nf-medium-blue); color:var(--nf-dark-blue); border-radius:8px;
  padding:7px 14px; font-weight:600; font-size:13px; cursor:pointer; margin-top:10px; }
.nf-add:hover { background:var(--nf-bg); }
.nf-x { background:transparent; border:none; color:var(--nf-muted); font-size:18px; cursor:pointer; line-height:1; }
.nf-x:hover { color:#b3261e; }

/* === Forms === */
.nf-field { display:flex; flex-direction:column; gap:4px; margin-bottom:10px; }
.nf-field > span { font-size:12px; font-weight:600; color:var(--nf-muted); }
.nf-field input, .nf-field select, .nf-field textarea, .saved-select {
  width:100%; padding:9px 11px; border:1px solid var(--nf-line); border-radius:8px; font-size:14px;
  font-family:var(--nf-font); background:#fff; color:var(--nf-ink); box-sizing:border-box; }
.nf-field input:focus, .nf-field select:focus, .nf-field textarea:focus, .saved-select:focus {
  outline:none; border-color:var(--nf-medium-blue); box-shadow:0 0 0 3px rgba(111,155,209,.18); }
.saved-select { margin-bottom:12px; }
.nf-grid2 { display:grid; grid-template-columns:1fr 1fr; gap:0 16px; }
.nf-grid3 { display:grid; grid-template-columns:repeat(auto-fit,minmax(200px,1fr)); gap:0 16px; align-items:end; }
.nf-cols2 { display:grid; grid-template-columns:1fr 1fr; gap:18px; }
.nf-check { display:inline-flex; align-items:center; gap:8px; font-size:14px; font-weight:600; color:var(--nf-ink); margin:10px 0; }
.nf-check input { width:16px; height:16px; }
.nf-row { display:flex; justify-content:space-between; align-items:flex-start; gap:16px; }
.nf-hint { color:var(--nf-muted); font-size:13px; margin:4px 2px 14px; }
.nf-muted { color:var(--nf-muted); }

/* === Item / leg tables === */
.nf-itemtable { width:100%; border-collapse:collapse; }
.nf-itemtable th { text-align:left; font-size:12px; color:var(--nf-muted); font-weight:700; padding:6px 8px; border-bottom:1px solid var(--nf-line); }
.nf-itemtable td { padding:5px 8px; vertical-align:middle; }
.nf-itemtable input, .nf-itemtable select { width:100%; padding:8px 10px; border:1px solid var(--nf-line); border-radius:7px; font-size:13px; font-family:var(--nf-font); box-sizing:border-box; }
.nf-itemtable input.num { text-align:right; }

/* === Pricing === */
.nf-price { background:#fff; }
.nf-pricegrid { display:grid; grid-template-columns:repeat(4,1fr); gap:16px; align-items:end; }
.nf-pricegrid .k { font-size:12px; font-weight:600; color:var(--nf-muted); }
.nf-pricegrid .v { font-size:22px; font-weight:800; color:var(--nf-dark-blue); }
.nf-pricegrid .hint { font-size:12px; color:var(--nf-muted); }
.nf-actions { display:flex; gap:14px; align-items:center; margin-top:14px; }

/* === Alerts / context === */
.nf-alert { background:#fdf3f3; border:1px solid #f1c9c9; color:#b3261e; padding:12px 16px; border-radius:8px; margin-bottom:14px; font-weight:600; }
.nf-ok { background:#eaf7ef; border:1px solid #bfe6cd; color:#1f7a44; padding:12px 16px; border-radius:8px; margin-bottom:14px; font-weight:600; }
.nf-ctx { margin-top:10px; background:var(--nf-bg); border:1px solid var(--nf-line); border-radius:8px; padding:9px 13px; font-size:13px; color:var(--nf-ink); }

/* === Record page === */
.nf-addr { line-height:1.5; font-size:14px; }
.nf-instr { margin-top:10px; background:#fff8e6; border:1px solid #f0e2b8; border-radius:8px; padding:8px 12px; font-size:13px; }
.nf-statusform { display:flex; align-items:center; gap:12px; }
.nf-statusform select { padding:8px 11px; border:1px solid var(--nf-line); border-radius:8px; font-family:var(--nf-font); font-size:14px; }

@media (max-width: 820px) {
  .nf-cols2 { grid-template-columns:1fr; }
  .nf-pricegrid { grid-template-columns:1fr 1fr; }
  .nf-header-tag { display:none; }
}

/* Suburb type-ahead */
.nf-ac { position:absolute; left:0; right:0; top:100%; z-index:40; background:#fff;
  border:1px solid var(--nf-medium-blue); border-radius:0 0 8px 8px;
  box-shadow:0 8px 20px rgba(23,78,161,.12); max-height:240px; overflow:auto; }
.nf-ac-item { padding:8px 11px; font-size:13px; cursor:pointer; display:flex; justify-content:space-between; gap:10px; }
.nf-ac-item:hover, .nf-ac-item.active { background:var(--nf-bg); }
.nf-ac-item .pc { color:var(--nf-muted); font-variant-numeric:tabular-nums; }

/* Invoicing */
.inv-tabs { display:flex; flex-wrap:wrap; gap:8px; margin-bottom:16px; }
.inv-tab { text-decoration:none; color:var(--nf-muted); font-weight:600; font-size:14px; padding:8px 14px;
  border:1px solid var(--nf-line); border-radius:999px; background:#fff; }
.inv-tab:hover { background:var(--nf-bg); color:var(--nf-dark-blue); }
.inv-tab.active { background:var(--nf-dark-blue); color:#fff; border-color:var(--nf-dark-blue); }
.inv-tab .inv-n { display:inline-block; min-width:18px; text-align:center; font-size:12px; margin-left:4px;
  background:rgba(0,0,0,.08); border-radius:999px; padding:0 6px; }
.inv-tab.active .inv-n { background:rgba(255,255,255,.25); }
.inv-card { padding:14px 18px; }
.inv-head { display:flex; flex-wrap:wrap; align-items:baseline; gap:8px; margin-bottom:10px; font-size:14px; }
.inv-head .inv-fig { margin-left:auto; color:var(--nf-muted); font-size:13px; }
.inv-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(150px,1fr)); gap:0 14px; }
.inv-read { font-size:15px; padding:9px 0; font-weight:700; color:var(--nf-dark-blue); }
.inv-foot { display:flex; align-items:center; gap:14px; margin-top:6px; }
.inv-foot .nf-btn { margin-left:auto; }

/* Booking: carrier cost breakdown + emphasised cost/sell (item 3) */
.nf-costbox { display:grid; grid-template-columns:1.3fr 1fr; gap:18px; align-items:start; margin-top:6px; }
@media (max-width:760px){ .nf-costbox { grid-template-columns:1fr; } }
.nf-costlines { border:1px solid var(--nf-line); border-radius:10px; padding:10px 14px; background:#fafbfd; }
.nf-costlines .cl { display:flex; align-items:center; justify-content:space-between; gap:10px; padding:5px 0; font-size:13px; color:var(--nf-muted); }
.nf-costlines .cl + .cl { border-top:1px dashed #e7edf4; }
.nf-costlines .cl-k { display:flex; align-items:center; gap:4px; }
.nf-costlines .cl-v { font-weight:600; color:#23303f; white-space:nowrap; }
.inlinenum { width:84px; text-align:right; padding:3px 6px; border:1px solid #cdd8e4; border-radius:6px; font-size:13px; }
.inlinenum.sm { width:54px; }
.nf-bigprices { display:grid; gap:12px; }
.nf-bigprices .bp { border:1px solid var(--nf-line); border-radius:10px; padding:12px 16px; }
.nf-bigprices .bp.sell { border-color:var(--nf-dark-blue); background:#f3f7fc; }
.nf-bigprices .bp-k { font-size:12px; text-transform:uppercase; letter-spacing:.04em; color:var(--nf-muted); }
.nf-bigprices .bp-v { font-size:26px; font-weight:800; color:var(--nf-dark-blue); margin-top:2px; }
.biginput { width:150px; font-size:24px; font-weight:800; border:none; border-bottom:2px solid var(--nf-dark-blue); background:transparent; color:var(--nf-dark-blue); padding:0 2px; }
.biginput:focus { outline:none; }
.nf-disclosure { margin-top:14px; border-top:1px solid #e7edf4; padding-top:10px; }
.nf-disclosure > summary { cursor:pointer; font-weight:600; color:var(--nf-dark-blue); font-size:14px; padding:4px 0; }
.nf-disclosure[open] > summary { margin-bottom:6px; }

/* Pickup/Delivery panels: equal height (grid stretch) with the Save-address
   button pinned bottom-left so the two line up. */
.nf-addrpanel { display:flex; flex-direction:column; }
.nf-addrpanel .nf-savefa { margin-top:auto; align-self:flex-start; }

/* Register: view tabs, date presets, sortable headers, attachment badge */
.nf-filters { display:flex; flex-direction:column; gap:10px; margin-bottom:14px; }
.nf-viewsel { display:flex; align-items:center; gap:8px; }
.nf-viewsel > span { font-size:12px; font-weight:700; text-transform:uppercase; letter-spacing:.04em; color:var(--nf-muted); }
.nf-viewsel select { padding:8px 12px; border:1px solid var(--nf-line); border-radius:8px; font-family:var(--nf-font); font-size:15px; font-weight:600; color:var(--nf-dark-blue); }
.nf-clientbox { padding:8px 12px; border:1px solid var(--nf-line); border-radius:8px; font-family:var(--nf-font); font-size:15px; font-weight:600; color:var(--nf-dark-blue); min-width:300px; }
.nf-clientbox::placeholder { color:var(--nf-muted); font-weight:400; }
.nf-ranges { display:flex; flex-wrap:wrap; gap:6px; }
.nf-chip { background:#fff; border:1px solid var(--nf-line); border-radius:999px; padding:5px 13px; font-size:13px; cursor:pointer; color:#33424f; font-family:var(--nf-font); }
.nf-chip:hover { border-color:var(--nf-medium-blue); }
.nf-chip.on { background:var(--nf-dark-blue); color:#fff; border-color:var(--nf-dark-blue); }
.nf-customrange { display:flex; align-items:center; gap:8px; font-size:13px; }
.nf-customrange input { padding:7px 10px; border:1px solid var(--nf-line); border-radius:8px; font-family:var(--nf-font); font-size:13px; }
.nf-searchrow { display:flex; gap:8px; align-items:center; }
.nf-searchrow input[type=text] { flex:1; max-width:520px; padding:9px 13px; border:1px solid var(--nf-line); border-radius:8px; font-size:14px; font-family:var(--nf-font); }
.nf-clear { color:var(--nf-muted); text-decoration:none; font-size:13px; }
.th-sort { color:var(--nf-muted) !important; text-decoration:none; font-weight:700; white-space:nowrap; }
.th-sort.active { color:var(--nf-dark-blue) !important; }
.th-sort .arrow { font-size:11px; }
.nf-register td { cursor:pointer; }
.nf-register tbody tr:hover { background:#f1f6fc; }
.nf-register td.trunc { max-width:220px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.nf-register td.nowrap { white-space:nowrap; }
.nf-pill.xs { font-size:10px; padding:1px 6px; }
.att-badge { display:inline-flex; width:24px; height:24px; border-radius:50%; align-items:center; justify-content:center; font-size:12px; font-weight:700; background:#fff; color:var(--nf-muted); border:1px solid #cdd8e4; }
.att-badge.has { background:var(--nf-dark-blue); color:#fff; border-color:var(--nf-dark-blue); }

/* Record page: attachments + activity timeline */
.att-list { list-style:none; padding:0; margin:8px 0 0; }
.att-list li { display:flex; align-items:center; gap:10px; padding:8px 0; border-top:1px solid #eef2f7; font-size:14px; }
.att-list li:first-child { border-top:none; }
.att-list .att-kind { font-size:11px; font-weight:700; text-transform:uppercase; color:#fff; background:var(--nf-medium-blue); border-radius:6px; padding:2px 7px; }
.att-list .att-meta { color:var(--nf-muted); font-size:12px; margin-left:auto; }
.nf-timeline { list-style:none; padding:0; margin:6px 0 0; }
.nf-timeline li { padding:8px 0 8px 16px; border-left:2px solid var(--nf-line); position:relative; }
.nf-timeline li::before { content:''; position:absolute; left:-5px; top:13px; width:8px; height:8px; border-radius:50%; background:var(--nf-medium-blue); }
.nf-timeline li.ev-note::before { background:var(--nf-sky-blue); }
.nf-timeline li.ev-created::before { background:#1f7a44; }
.nf-timeline .tl-meta { font-size:12px; color:var(--nf-muted); }
.nf-timeline .tl-note { background:#f3f7fc; border-radius:8px; padding:8px 10px; margin-top:3px; }

/* Invoicing: bulk action bar + stage badges */
.inv-bulkbar { display:flex; flex-wrap:wrap; align-items:center; gap:8px; background:#eef3fa; border:1px solid var(--nf-line); border-radius:10px; padding:10px 12px; margin-bottom:10px; }
.inv-bulkbar .bb-count { font-size:13px; color:var(--nf-muted); margin-right:4px; }
.inv-bulkbar select, .inv-bulkbar input { padding:7px 10px; border:1px solid #cdd8e4; border-radius:8px; font-family:var(--nf-font); font-size:13px; }
.inv-bulkbar .bb-fields { display:inline-flex; gap:6px; align-items:center; }
.inv-bulkbar .nf-btn[disabled] { opacity:.45; cursor:not-allowed; }
.inv-table th, .inv-table td { font-size:12.5px; }
.stage-pill { font-size:11px; font-weight:700; padding:2px 8px; border-radius:999px; white-space:nowrap; background:var(--nf-bg); color:var(--nf-muted); }
.st-carrierbilldue { background:#fff5e6; color:#9a6700; }
.st-carriertopay { background:#fff0e0; color:#9a4a00; }
.st-toinvoice { background:#e8f0fe; color:#174ea1; }
.st-awaitingpayment { background:#fde9e9; color:#b3261e; }
.st-commissiondue { background:#f3eaff; color:#6b3fa0; }
.st-complete { background:#e7f6ec; color:#1f7a44; }
.overdue { color:#b3261e; font-weight:800; font-size:11px; }
.xpill { font-size:9px; font-weight:700; text-transform:uppercase; letter-spacing:.03em; padding:1px 5px; border-radius:999px; background:var(--nf-bg); color:var(--nf-muted); }
.x-draft { background:#eef2f7; color:#5b6b7d; }
.x-submitted { background:#fff5e6; color:#9a6700; }
.x-authorised, .x-authorized { background:#e8f0fe; color:#174ea1; }
.x-paid { background:#e7f6ec; color:#1f7a44; }
.x-voided, .x-deleted { background:#fde9e9; color:#b3261e; }
.inv-bulkbar .bb-lbl { font-size:12px; color:var(--nf-muted); display:inline-flex; align-items:center; gap:4px; }
.inv-tab-alert { color:#b3261e; }
.inv-tab-alert .inv-n { background:#fde9e9; color:#b3261e; }

/* Register row actions menu (3-dot) + quick-edit modal */
.rowmenu { position:relative; display:inline-block; }
.rowmenu > summary { list-style:none; cursor:pointer; padding:2px 8px; border-radius:6px; color:var(--nf-muted); font-size:18px; line-height:1; }
.rowmenu > summary::-webkit-details-marker { display:none; }
.rowmenu > summary:hover { background:var(--nf-bg); color:var(--nf-dark-blue); }
.rowmenu-pop { position:fixed; z-index:9998; background:#fff; border:1px solid var(--nf-line); border-radius:10px; box-shadow:0 10px 24px rgba(0,0,0,.16); min-width:150px; padding:6px; text-align:left; }
.rowmenu-pop a, .rowmenu-pop button { display:block; width:100%; text-align:left; background:none; border:none; padding:8px 10px; font-size:13px; font-family:var(--nf-font); color:var(--nf-ink); cursor:pointer; border-radius:6px; text-decoration:none; }
.rowmenu-pop a:hover, .rowmenu-pop button:hover { background:var(--nf-bg); color:var(--nf-dark-blue); }
.rowmenu-pop form { margin:0; }
.rowmenu-pop button.danger { color:#b3261e; }
.rowmenu-pop button.danger:hover { background:#fde9e9; color:#b3261e; }
.nf-modal { position:fixed; inset:0; background:rgba(15,30,55,.45); display:flex; align-items:flex-start; justify-content:center; z-index:9999; padding:60px 16px; }
.nf-modal-card { background:#fff; border-radius:14px; padding:22px 24px; width:100%; max-width:620px; box-shadow:0 24px 60px rgba(0,0,0,.3); }

/* Merged carrier rate list (rate + pick in one flow) */
.nf-ratelist { margin:6px 0 4px; }
.rate-row { display:flex; flex-wrap:wrap; align-items:center; gap:14px; padding:11px 14px;
  border:1px solid var(--nf-line); border-radius:10px; margin-bottom:8px; background:#fff; transition:border-color .12s, box-shadow .12s; }
.rate-row:hover { border-color:var(--nf-medium-blue); box-shadow:0 2px 10px rgba(23,78,161,.08); }
.rate-row .rr-main { flex:1 1 240px; min-width:200px; display:flex; align-items:center; gap:10px; }
/* Text block sits wholly to the RIGHT of the logo, logo vertically centred
   in the row (2026-07-21, Edward). rr-txt keeps flex children shrinkable. */
.rr-txt { min-width:0; flex:1; }
.rr-name { font-weight:600; font-size:14px; color:var(--nf-dark-blue); }
/* Carrier logo beside the name in the rates list (2026-07-21, Edward):
   a UNIFORM white 80 x 25 px box for every carrier. object-fit:contain
   letterboxes whatever shape arrives - short/wide logos get white above and
   below, tall/narrow ones cap at 25px with white each side - so every logo
   is centred and the text column lines up row after row. */
.rr-logo { width:106px; height:33px; padding:2px; box-sizing:border-box;
  background:#fff; border-radius:4px; object-fit:contain; flex:0 0 auto; }
.rr-sub { font-size:12px; color:var(--nf-muted); margin-top:2px; }
.rr-more { color:var(--nf-dark-blue); cursor:pointer; text-decoration:underline; }
.rr-nums { display:flex; gap:20px; }
.rr-n { display:flex; flex-direction:column; align-items:flex-end; min-width:74px; }
.rr-n span { font-size:10px; text-transform:uppercase; letter-spacing:.04em; color:var(--nf-muted); }
.rr-n b { font-size:14px; font-variant-numeric:tabular-nums; }
.rr-act { display:flex; align-items:center; }
.rr-bd { flex-basis:100%; border-top:1px dashed var(--nf-medium-blue); margin-top:8px; padding-top:8px; }
.bd-l { display:flex; justify-content:space-between; font-size:12px; color:#475569; padding:2px 0; }
/* Breakdown buy/sell columns (2026-07-21, Edward): each money line carries a
   buy AND a sell amount in aligned right-hand columns under a Buy/Sell header. */
.bd-l > span:first-child { flex:1; }
.bd-amt { min-width:84px; text-align:right; font-variant-numeric:tabular-nums; }
.bd-h span { font-size:10px; text-transform:uppercase; letter-spacing:.04em; color:var(--nf-muted); }
.nf-selhead { margin:18px 0 10px; font-weight:700; font-size:12px; text-transform:uppercase; letter-spacing:.4px;
  color:var(--nf-muted); border-top:1px solid var(--nf-line); padding-top:16px; }
.nf-btn.danger { background:#fff; border:1px solid #e6a6a0; color:#b3261e; }
.nf-btn.danger:hover { background:#fde9e9; color:#b3261e; }
/* Compact one-line pricing row (Base / Fuel / Carrier cost / Markup / Margin / Sell) */
.nf-priceline { display:flex; flex-wrap:wrap; gap:16px; align-items:flex-start;
  background:var(--nf-bg); border:1px solid var(--nf-line); border-radius:10px; padding:12px 14px; }
.nf-priceline .nf-field { margin:0; gap:6px; }
.nf-priceline .pl-calc { display:flex; flex-direction:column; gap:6px; }
.nf-priceline .nf-field > span, .nf-priceline .pl-k { font-size:12px; font-weight:600; color:var(--nf-muted); white-space:nowrap; height:15px; line-height:15px; }
.nf-priceline .nf-field input { height:40px; box-sizing:border-box; }
.nf-priceline .pl-v { min-height:40px; display:flex; align-items:center; font-size:23px; line-height:1.1; font-weight:800; color:var(--nf-dark-blue); font-variant-numeric:tabular-nums; white-space:nowrap; }
.nf-priceline .pl-sellrow { position:relative; display:block; }
.nf-priceline .pl-sellrow input { height:40px; box-sizing:border-box; padding-left:18px; }
.nf-priceline .pl-sellrow .pl-dollar { position:absolute; left:8px; top:0; height:40px; display:flex; align-items:center; font-size:15px; font-weight:800; color:var(--nf-dark-blue); pointer-events:none; }
.nf-priceline input.pl-sell { font-size:18px; font-weight:800; color:var(--nf-dark-blue); }

/* Booking/edit pricing card - three columns mirroring the finalised
   consignment view (Carrier cost / Customer sell / Margin). */
.nf-pricecols { display:flex; gap:24px; flex-wrap:wrap; align-items:flex-start; }
/* Wider columns (2026-07-27, Edward): the card has the space, and the fuel
   row now carries an API pill beside the percent on live KwickAz jobs. */
.nf-pricecols .pc-col { flex:1 1 320px; max-width:430px; }
.nf-pricecols .pc-col.pc-side { flex:1 1 260px; max-width:360px; }
.nf-pricecols .pc-table td { padding:5px 12px; height:46px; box-sizing:border-box; vertical-align:middle; }
.nf-pricecols .pc-table tbody tr:hover { background:transparent; }
.nf-pricecols .pc-table input { height:34px; box-sizing:border-box; text-align:right;
  border:1px solid #cdd8e4; border-radius:8px; padding:4px 8px; font-size:14px; }
.nf-pricecols .pc-in { position:relative; display:inline-block; }
.nf-pricecols .pc-in input { width:120px; padding-left:20px; }
.nf-pricecols .pc-in .pc-dollar { position:absolute; left:8px; top:0; height:34px; display:flex;
  align-items:center; font-size:13px; font-weight:700; color:var(--nf-dark-blue); pointer-events:none; }
.nf-pricecols .pc-pct { width:70px; }
.nf-pricecols .pc-inline { display:inline-flex; align-items:center; gap:6px; }
.nf-pricecols .pc-total td { font-weight:800; color:var(--nf-dark-blue); }
.nf-pricecols .pc-total td:first-child { color:#0f1e2e; }
.nf-pricecols input.pc-strong { font-size:15px; font-weight:800; color:var(--nf-dark-blue); }
.nf-pricecols .pc-sellcol thead th { color:#0f1e2e; }
.nf-pricecols .pc-sellcol td:first-child { color:#0f1e2e; font-weight:600; }

/* Required-field accent (Node Freight medium blue bar) */
input.nf-req, select.nf-req, textarea.nf-req { box-shadow: inset 3px 0 0 0 var(--nf-medium-blue); }
input.nf-req:focus, select.nf-req:focus, textarea.nf-req:focus { box-shadow: inset 3px 0 0 0 var(--nf-medium-blue), 0 0 0 3px rgba(111,155,209,.18); }

/* --- Quick Rate (2026-07-21, Edward) ---------------------------------------
   /quick-rate renders the SAME booking form include; these rules strip it to
   Client account + pickup/delivery Suburb & Postcode (postcode auto-fills
   from the suburb type-ahead and the rating engine needs it). Goods and
   Carrier & pricing stay untouched. New booking-form fields added later land
   inside these hidden groups and stay hidden here automatically. */
.quickrate label.nf-field:has(input[name="client_reference_1"]),
.quickrate label.nf-field:has(input[name="client_reference_2"]) { display:none; }
.quickrate .nf-addrpanel > .nf-row { display:none; }              /* saved address + intl toggle */
.quickrate .nf-addrpanel .nf-grid2 label.nf-field { display:none; }
.quickrate .nf-addrpanel .nf-grid2 label.nf-field:has(#pu_suburb),
.quickrate .nf-addrpanel .nf-grid2 label.nf-field:has(#pu_postcode),
.quickrate .nf-addrpanel .nf-grid2 label.nf-field:has(#del_suburb),
.quickrate .nf-addrpanel .nf-grid2 label.nf-field:has(#del_postcode) { display:flex; }
.quickrate .nf-addrpanel > label.nf-field,                        /* special instructions / delivered date */
.quickrate .nf-addrpanel .nf-grid3,                               /* timeslot fields */
.quickrate .nf-addrpanel label.nf-check,                          /* timeslot toggle */
.quickrate .nf-addrpanel .nf-savefa { display:none; }

/* === Signed-in chip (cloud phase 1b, 2026-07-30) ===
   Sits where the tagline sits when auth is enabled; absent when it is not. */
.nf-userchip { margin-left:auto; display:flex; align-items:center; gap:10px;
  font-size:12.5px; color:var(--nf-muted); white-space:nowrap; }
.nf-userchip a, .nf-userchip span { font-weight:700; color:var(--nf-dark-blue); text-decoration:none; }
.nf-userchip a:hover { text-decoration:underline; }
.nf-userchip form { margin:0; }
.nf-userchip button { background:#fff; color:var(--nf-dark-blue); border:1px solid var(--nf-line);
  border-radius:7px; padding:5px 11px; font-family:var(--nf-font); font-size:12.5px;
  font-weight:600; cursor:pointer; }
.nf-userchip button:hover { background:var(--nf-bg); }

/* === Parallel-run banner (cloud phase 2, 2026-07-31) ===
   Only rendered when FMS_MODE=parallel, i.e. on the cloud test copy. Amber
   rather than red: this is a normal state, not an error. */
.nf-parallel { background:#fff6e5; border-top:1px solid #f0d089; border-bottom:1px solid #f0d089;
  color:#8a5a00; padding:9px 24px; font-size:13px; font-weight:700; letter-spacing:.2px; }
