/* Precision-Ops — one stylesheet. Navy #042C53, blue #1a7abf, warm greys. */
:root {
  --navy: #042c53; --blue: #1a7abf; --blue-soft: #e7f1fa; --ink: #16202b; --ink-2: #4a5867; --ink-3: #7b8794;
  --line: #e3e8ee; --line-2: #cfd7e0; --bg: #f5f7fa; --panel: #ffffff;
  --green: #1f8a4c; --green-soft: #e6f4ec; --amber: #b7791f; --amber-soft: #fbf1dc; --red: #c0392b; --red-soft: #fbe9e7; --grey-soft: #eef1f4;
  --radius: 10px; --shadow: 0 1px 2px rgba(16, 32, 51, .06), 0 4px 16px rgba(16, 32, 51, .05);
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--bg); color: var(--ink); font-size: 14px; line-height: 1.45; -webkit-font-smoothing: antialiased; }
a { color: var(--blue); text-decoration: none; } a:hover { text-decoration: underline; }
h1, h2, h3, h4 { margin: 0; font-weight: 600; letter-spacing: -.01em; }
h1 { font-size: 22px; } h2 { font-size: 17px; } h3 { font-size: 14px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-3); font-weight: 600; }
.muted { color: var(--ink-3); } .small { font-size: 12.5px; } .num { text-align: right; font-variant-numeric: tabular-nums; } .mono { font-variant-numeric: tabular-nums; }
.right { text-align: right; } .nowrap { white-space: nowrap; } .hidden { display: none !important; }

/* layout */
.shell { display: grid; grid-template-columns: 232px 1fr; min-height: 100vh; }
.side { background: var(--navy); color: #d7e3f0; padding: 18px 14px; display: flex; flex-direction: column; gap: 4px; position: sticky; top: 0; height: 100vh; }
.brand { display: flex; align-items: center; gap: 10px; padding: 4px 8px 18px; color: #fff; }
.brand .mark { width: 30px; height: 30px; border-radius: 8px; background: linear-gradient(135deg, #1a7abf, #5fb1e8); display: grid; place-items: center; font-weight: 700; color: #fff; font-size: 13px; }
.brand b { font-size: 15px; letter-spacing: -.01em; display: block; } .brand span { font-size: 11px; color: #9fb6cc; }
.nav a { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 8px; color: #d7e3f0; font-weight: 500; font-size: 13.5px; }
.nav a:hover { background: rgba(255, 255, 255, .06); text-decoration: none; } .nav a.on { background: rgba(255, 255, 255, .12); color: #fff; }
.nav .sec { font-size: 10.5px; text-transform: uppercase; letter-spacing: .1em; color: #7f98b3; padding: 14px 10px 4px; }
.nav .badge { margin-left: auto; background: var(--blue); color: #fff; font-size: 11px; padding: 1px 7px; border-radius: 999px; }
.side .foot { margin-top: auto; padding: 10px 8px 0; font-size: 12px; color: #9fb6cc; border-top: 1px solid rgba(255, 255, 255, .1); }
.side .foot b { color: #fff; display: block; font-weight: 600; }
.main { min-width: 0; }
.topbar { display: flex; align-items: center; gap: 14px; padding: 12px 28px; background: var(--panel); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.topbar .search { flex: 1; max-width: 520px; position: relative; }
.topbar .search input { width: 100%; padding: 9px 12px 9px 36px; border: 1px solid var(--line-2); border-radius: 8px; background: var(--bg); font: inherit; }
.topbar .search::before { content: "⌕"; position: absolute; left: 12px; top: 7px; font-size: 16px; color: var(--ink-3); }
.region { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line-2); border-radius: 8px; padding: 6px 10px; font-weight: 600; font-size: 13px; background: #fff; }
.region .flag { width: 10px; height: 10px; border-radius: 50%; background: var(--blue); } .region.ie .flag { background: var(--green); }
.region select { border: 0; font: inherit; font-weight: 600; background: transparent; }
.content { padding: 24px 28px 60px; max-width: none; min-width: 0; }
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 18px; }
.page-head .sub { color: var(--ink-3); margin-top: 3px; }
.crumbs { font-size: 12.5px; color: var(--ink-3); margin-bottom: 6px; } .crumbs a { color: var(--ink-3); }

/* panels, grids */
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.panel .ph { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.panel .pb { padding: 16px; }
.grid { display: grid; gap: 16px; } .g2 { grid-template-columns: 1fr 1fr; } .g3 { grid-template-columns: repeat(3, 1fr); } .g4 { grid-template-columns: repeat(4, 1fr); }
.g-main { grid-template-columns: minmax(0, 2fr) minmax(300px, 1fr); }
.stack { display: flex; flex-direction: column; gap: 16px; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; margin-bottom: 18px; }
.kpi { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
.kpi .l { font-size: 12px; color: var(--ink-3); text-transform: uppercase; letter-spacing: .05em; } .kpi .v { font-size: 24px; font-weight: 600; margin-top: 4px; letter-spacing: -.02em; } .kpi .s { font-size: 12px; color: var(--ink-3); margin-top: 2px; }
.kpi.accent { background: var(--navy); color: #fff; border-color: var(--navy); } .kpi.accent .l, .kpi.accent .s { color: #a9c0d8; }

/* tables */
table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
th { text-align: left; font-size: 11.5px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-3); font-weight: 600; padding: 10px 12px; border-bottom: 1px solid var(--line); background: #fafbfc; }
td { padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
tr:last-child td { border-bottom: 0; } tbody tr.row:hover { background: #f8fafc; cursor: pointer; }
td.empty { color: var(--ink-3); text-align: center; padding: 28px; }
th.num, td.num { text-align: right; }
.dl { display: grid; grid-template-columns: 150px 1fr; gap: 8px 14px; font-size: 13.5px; } .dl dt { color: var(--ink-3); } .dl dd { margin: 0; }

/* pills & badges */
.pill { display: inline-block; padding: 2px 9px; border-radius: 999px; font-size: 12px; font-weight: 600; background: var(--grey-soft); color: var(--ink-2); white-space: nowrap; }
.pill.blue { background: var(--blue-soft); color: var(--blue); } .pill.green { background: var(--green-soft); color: var(--green); } .pill.amber { background: var(--amber-soft); color: var(--amber); } .pill.red { background: var(--red-soft); color: var(--red); } .pill.navy { background: var(--navy); color: #fff; }
.tag { font-size: 11px; padding: 1px 6px; border-radius: 5px; background: var(--grey-soft); color: var(--ink-2); margin-left: 6px; }

/* buttons & forms */
.btn { display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 8px; border: 1px solid var(--line-2); background: #fff; color: var(--ink); font: inherit; font-weight: 600; font-size: 13px; cursor: pointer; white-space: nowrap; }
.btn:hover { background: #f3f6f9; text-decoration: none; } .btn:disabled { opacity: .5; cursor: default; }
.btn.primary { background: var(--blue); border-color: var(--blue); color: #fff; } .btn.primary:hover { background: #166aa6; }
.btn.navy { background: var(--navy); border-color: var(--navy); color: #fff; } .btn.danger { color: var(--red); border-color: #efc3bd; } .btn.ghost { border-color: transparent; background: transparent; }
.btn.sm { padding: 5px 10px; font-size: 12.5px; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.form { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px 14px; }
.f { display: flex; flex-direction: column; gap: 5px; } .f > span { font-size: 12px; color: var(--ink-2); font-weight: 600; } .f.wide { grid-column: 1 / -1; }
.f input, .f select, .f textarea { padding: 8px 10px; border: 1px solid var(--line-2); border-radius: 8px; font: inherit; background: #fff; color: var(--ink); }
.f input:focus, .f select:focus, .f textarea:focus { outline: 2px solid rgba(26, 122, 191, .25); border-color: var(--blue); }
.f textarea { min-height: 84px; resize: vertical; }
.check { display: flex; align-items: center; gap: 8px; font-size: 13px; } .check input { width: 16px; height: 16px; }
.hint { font-size: 12.5px; color: var(--ink-3); }
.notice { padding: 10px 14px; border-radius: 8px; background: var(--blue-soft); color: #0f4c7a; font-size: 13px; border: 1px solid #cfe3f5; }
.notice.warn { background: var(--amber-soft); color: #6b4a0e; border-color: #f0dfb9; } .notice.bad { background: var(--red-soft); color: #7a2418; border-color: #f0c7c0; } .notice.good { background: var(--green-soft); color: #14532d; border-color: #bfe5cc; }
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); margin-bottom: 16px; }
.tabs button { background: none; border: 0; border-bottom: 2px solid transparent; padding: 10px 14px; font: inherit; font-weight: 600; color: var(--ink-3); cursor: pointer; }
.tabs button.on { color: var(--navy); border-bottom-color: var(--blue); }
.toolbar { display: flex; gap: 10px; align-items: center; margin-bottom: 14px; flex-wrap: wrap; }
.toolbar input, .toolbar select { padding: 8px 10px; border: 1px solid var(--line-2); border-radius: 8px; font: inherit; background: #fff; }

/* timeline */
.timeline { list-style: none; margin: 0; padding: 0; } .timeline li { display: grid; grid-template-columns: 110px 1fr; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.timeline li:last-child { border-bottom: 0; } .timeline .when { color: var(--ink-3); font-size: 12px; } .timeline .who { color: var(--ink-2); }
.timeline .chg { color: var(--ink-3); } .timeline .chg b { color: var(--ink); font-weight: 500; }

/* stage pipeline */
.stages { display: flex; gap: 6px; flex-wrap: wrap; }
table.plan td { vertical-align: top; }
table.plan select.sassign { max-width: 170px; padding: 3px 6px; font-size: 12.5px; }
table.plan tr.done td:first-child, table.plan tr.done td:nth-child(2) { opacity: .6; }
table.plan tr.prov td { background: repeating-linear-gradient(45deg, transparent, transparent 7px, rgba(240,160,32,.05) 7px, rgba(240,160,32,.05) 14px); }
table.plan .stage-date { white-space: nowrap; }
.stage { padding: 8px 12px; border-radius: 8px; border: 1px solid var(--line-2); background: #fff; font-size: 12.5px; min-width: 120px; }
.stage .n { font-weight: 600; } .stage .s { color: var(--ink-3); font-size: 11.5px; margin-top: 2px; }
.stage.done { background: var(--green-soft); border-color: #bfe5cc; } .stage.booked { background: var(--blue-soft); border-color: #cfe3f5; } .stage.held { border-style: dashed; } .stage.prov { border-style: dashed; border-color: var(--amber, #c98a00); background: var(--amber-soft, #fff8ec); } .stage[data-estage]:hover { border-color: var(--blue); }
.checklist { list-style: none; margin: 0; padding: 0; } .checklist li { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 13.5px; } .checklist li:last-child { border-bottom: 0; }
.checklist .tick { width: 20px; height: 20px; border-radius: 50%; border: 1.5px solid var(--line-2); display: grid; place-items: center; font-size: 12px; color: #fff; cursor: pointer; }
.checklist li.done .tick { background: var(--green); border-color: var(--green); } .checklist li.done span.t { color: var(--ink-3); text-decoration: line-through; }

/* modal */
.modal-bg { position: fixed; inset: 0; background: rgba(4, 44, 83, .45); display: grid; place-items: center; z-index: 1500; padding: 20px; } /* above Leaflet (panes 400-700, controls 800, zoom/attribution containers 1000) so a map on the page behind can't paint over the modal */
.modal { background: #fff; border-radius: 14px; width: min(760px, 100%); max-height: 92vh; overflow: auto; box-shadow: 0 30px 80px rgba(0, 0, 0, .3); }
.modal .mh { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid var(--line); } .modal .mb { padding: 20px; } .modal .mf { display: flex; justify-content: flex-end; gap: 8px; padding: 14px 20px; border-top: 1px solid var(--line); background: #fafbfc; border-radius: 0 0 14px 14px; }
.modal.wide { width: min(1100px, 100%); }
.toast { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); background: var(--navy); color: #fff; padding: 10px 16px; border-radius: 10px; font-size: 13px; z-index: 1600; box-shadow: var(--shadow); }
.toast.bad { background: var(--red); }

/* quote builder */
.lines td input { width: 100%; padding: 5px 7px; border: 1px solid transparent; border-radius: 6px; font: inherit; background: transparent; } .lines td input:hover, .lines td input:focus { border-color: var(--line-2); background: #fff; }
.lines td input.num { text-align: right; } .lines tr.oh td { color: var(--ink-3); background: #fbfcfd; } .lines .auto { font-size: 10.5px; color: var(--blue); margin-left: 6px; font-weight: 600; }
.totals { display: grid; grid-template-columns: 1fr auto; gap: 6px 24px; font-size: 13.5px; justify-content: end; } .totals b { font-size: 15px; }
.margin { font-weight: 700; } .margin.low { color: var(--red); } .margin.ok { color: var(--green); }
.clauses label { display: flex; gap: 10px; align-items: flex-start; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 13px; } .clauses label:last-child { border-bottom: 0; }
.clauses .cb { margin-top: 3px; } .clauses .g { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-3); }
#map { height: 380px; border-radius: 10px; border: 1px solid var(--line); }
.sim td { font-size: 12.5px; }

/* login */
.login { min-height: 100vh; display: grid; place-items: center; background: linear-gradient(160deg, var(--navy), #0b3d6e 60%, #1a7abf); }
.login .card { background: #fff; border-radius: 16px; padding: 34px 36px; width: min(420px, 92vw); box-shadow: 0 30px 80px rgba(0, 0, 0, .35); }
.login .card img { width: 240px; display: block; margin: 0 auto 18px; }
.login h1 { font-size: 18px; text-align: center; margin-bottom: 4px; } .login p { text-align: center; color: var(--ink-3); margin: 0 0 20px; }
.login .f { margin-bottom: 12px; } .login .btn { width: 100%; justify-content: center; padding: 11px; }

/* public acceptance */
.pub { max-width: 820px; margin: 0 auto; padding: 32px 20px 80px; }
.pub .card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 28px 32px; box-shadow: var(--shadow); }
.pub img.logo { width: 260px; display: block; margin: 0 auto 20px; }
@media (max-width: 900px) { .shell { grid-template-columns: 1fr; } .side { position: static; height: auto; } .g2, .g3, .g4, .g-main { grid-template-columns: 1fr; } .content { padding: 16px; } .dl { grid-template-columns: 120px 1fr; } }
@media print { .side, .topbar, .actions, .btn { display: none !important; } .shell { display: block; } .content { padding: 0; } }
/* key/value mini tables (holiday preview etc.) */
table.kv { width: auto; min-width: 320px; margin-top: 6px; } table.kv td { padding: 3px 10px 3px 0; border: 0; } table.kv td.num { text-align: right; }
/* catalogue tick panels on quotes */
.cat .cat-group { margin-bottom: 10px; } .cat .cat-g { font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin: 6px 0 4px; }
.cat.cols { columns: 2; column-gap: 24px; } .cat.cols .cat-group { break-inside: avoid; }
.cat-item { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; padding: 6px 8px; border: 1px solid var(--line); border-radius: 8px; margin: 4px 0; background: #fff; }
.cat-item.on { border-color: var(--blue); background: var(--blue-soft); } .cat-item.slim { padding: 3px 8px; border-color: transparent; background: transparent; flex-wrap: nowrap; } .cat-item.slim label { flex: 1; min-width: 0; } .cat-item.slim.on { background: var(--blue-soft); }
.cat-item .ref { margin-left: auto; } .cat-item .cat-opts { flex-basis: 100%; display: flex; gap: 10px; align-items: center; padding-left: 24px; } .cat-item .cat-opts:empty { display: none; }
.cat-item .cat-opts select { max-width: 520px; } .cat-item .qty span { font-size: 12px; color: var(--muted); margin-right: 6px; } .cat-item .qty input { width: 90px; }
.cat-item .help { width: 18px; height: 18px; border-radius: 50%; border: 1px solid var(--line); background: #fff; color: var(--muted); font-size: 11px; cursor: pointer; line-height: 1; }
.cat-item .rq-opt { margin-left: 24px; }
.tabs.sub { margin-top: -6px; } .tabs.sub button { padding: 6px 10px; font-size: 13px; }
/* RAMS editor */
.rams textarea, .rams input[type=text], .rams input:not([type]) { width: 100%; padding: 8px 10px; border: 1px solid var(--line-2); border-radius: 8px; font: inherit; background: #fff; color: var(--ink); box-sizing: border-box; }
.rams textarea { resize: vertical; line-height: 1.4; } .rams .pb textarea + textarea { margin-top: 6px; }
.rams table.risk { table-layout: fixed; width: 100%; } .rams table.risk td { vertical-align: top; padding: 8px 6px; } .rams table.risk textarea { min-height: 96px; font-size: 12.5px; }
.rams table.risk th:nth-child(2), .rams table.risk th:nth-child(3), .rams table.risk th:nth-child(6), .rams table.risk th:nth-child(7) { width: 46px; } .rams table.risk th:nth-child(4), .rams table.risk th:nth-child(8) { width: 84px; } .rams table.risk th:nth-child(1) { width: 190px; } .rams table.risk th:nth-child(9) { width: 30px; }
.rams table.risk input.small { font-size: 12px; color: var(--muted); margin-top: 4px; } .rams table.risk select { padding: 4px; }
.rams .grid.g-main { grid-template-columns: 1fr; } @media (min-width: 1500px) { .rams .grid.g-main { grid-template-columns: 2.2fr 1fr; } }
/* project chat + files */
.chat-log { max-height: 420px; overflow-y: auto; } .msg { padding: 8px 10px; border-radius: 8px; margin-bottom: 6px; background: #f6f8fa; } .msg.pinned { background: var(--amber-soft); } .msg .body { white-space: pre-wrap; margin-top: 2px; } .msg .msg-act { float: right; opacity: 0; } .msg:hover .msg-act { opacity: 1; } .mention { color: var(--blue); }
.chat-box textarea { width: 100%; box-sizing: border-box; padding: 8px 10px; border: 1px solid var(--line-2); border-radius: 8px; font: inherit; resize: vertical; } .chat-box .actions { display: flex; align-items: center; gap: 10px; margin-top: 6px; } .chat-box .actions .btn:last-child { margin-left: auto; }
.dropzone { min-height: 60px; border: 2px dashed transparent; border-radius: 8px; } .dropzone.over { border-color: var(--blue); background: var(--blue-soft); }
.file-row { display: flex; align-items: center; gap: 10px; padding: 6px 0; border-bottom: 1px solid var(--line); } .file-row > a { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .file-row .file-act { display: flex; gap: 4px; align-items: center; } .file-row select { font-size: 12px; padding: 3px; }
.msg-row { padding: 6px 0; border-bottom: 1px solid var(--line); } .msg-row.mention { border-left: 3px solid var(--blue); padding-left: 8px; }
table.roles th { text-align: center; } table.roles td.c { text-align: center; } table.roles tr.grp td { background: #f3f6f9; font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); padding: 6px 10px; }
/* boards */
.kboard { overflow-x: auto; } .kcols { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(210px, 1fr); gap: 10px; align-items: start; min-width: 1500px; } .kcols.wrap { grid-auto-flow: row; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); min-width: 0; }
.klane { padding: 10px 4px 4px; border-top: 2px solid var(--line); margin-top: 8px; }
.kcol { background: #eef2f6; border-radius: 10px; padding: 6px; min-height: 120px; } .kcol.over .kcolh { background: var(--red-soft); color: var(--red); } .kcol.drop { outline: 2px dashed var(--blue); }
.kcolh { display: flex; justify-content: space-between; align-items: center; font-weight: 600; font-size: 13px; padding: 6px 8px; border-radius: 8px; background: #fff; } .kdod { padding: 4px 8px 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kcards { display: flex; flex-direction: column; gap: 6px; margin-top: 6px; } .kcard { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; cursor: grab; } .kcard[draggable=false] { cursor: default; } .kcard .kh { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; } .kflags { margin-top: 4px; display: flex; flex-wrap: wrap; gap: 4px; }
.age { font-size: 11px; color: var(--muted); white-space: nowrap; } .age.warm { color: var(--amber); font-weight: 600; } .age.hot { color: var(--red); font-weight: 700; }
.gridwrap { overflow-x: auto; } table.dgrid th { writing-mode: vertical-rl; transform: rotate(180deg); font-size: 11px; padding: 6px 2px; white-space: nowrap; max-height: 140px; } table.dgrid th:first-child, table.dgrid th:nth-child(2), table.dgrid th:nth-child(3) { writing-mode: horizontal-tb; transform: none; } table.dgrid td.c { text-align: center; }
.dot { display: inline-block; width: 14px; height: 14px; border-radius: 50%; background: #d5dde5; } .dot.in-progress { background: var(--blue); } .dot.qc { background: var(--amber); } .dot.issued { background: var(--green); } .dot.not-required { background: #fff; border: 1px dashed #bbb; } .dot.gating { box-shadow: 0 0 0 2px #fff, 0 0 0 3px var(--navy); }
.tl { border: 1px solid var(--line); border-radius: 10px; background: #fff; overflow: hidden; } .tlhead, .tlrow { display: flex; border-bottom: 1px solid var(--line); } .tlabel { width: 240px; flex: none; padding: 8px 10px; border-right: 1px solid var(--line); } .ttrack { flex: 1; position: relative; min-height: 36px; background: repeating-linear-gradient(90deg, transparent 0, transparent calc(100%/6 - 1px), var(--line) calc(100%/6 - 1px), var(--line) calc(100%/6)); }
.tlhead .ttrack { min-height: 26px; } .th { position: absolute; top: 4px; font-size: 11px; color: var(--muted); padding-left: 4px; border-left: 1px solid var(--line-2); } .tlgroup { padding: 6px 10px; font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); background: #f6f8fa; }
.tbar { position: absolute; top: 7px; height: 22px; border-radius: 5px; font-size: 11px; line-height: 22px; padding: 0 6px; color: #fff; background: #6b7a8a; overflow: hidden; white-space: nowrap; } .tbar.site_day, .tbar.travel { background: var(--blue); } .tbar.travel { opacity: .6; } .tbar.done, .tbar.signed-off { background: var(--green); }
.mrow { padding: 6px 0; border-bottom: 1px solid var(--line); } .prow { display: grid; grid-template-columns: 150px 1fr 70px; gap: 8px; align-items: center; padding: 3px 0; } .pbar { height: 10px; background: #eef2f6; border-radius: 5px; } .pbar div { height: 100%; background: var(--blue); border-radius: 5px; }
svg.chart { width: 100%; height: auto; display: block; } svg.chart .t { font-size: 10px; fill: var(--muted); } .legend { display: flex; flex-wrap: wrap; gap: 10px; font-size: 11px; margin-top: 6px; } .legend i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 4px; vertical-align: middle; }
/* schedule */
.g-sched { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 14px; align-items: start; }
table.sched { border-collapse: separate; border-spacing: 2px; table-layout: fixed; } table.sched th, table.sched td { padding: 2px; } table.sched th { font-size: 11px; text-align: center; } table.sched th:not(.rh), table.sched td:not(.rh) { width: 112px; } table.sched th.today, table.sched td.today { background: var(--blue-soft); }
table.sched td.rh, table.sched th.rh { width: 160px; } table.sched td.rh { white-space: nowrap; padding: 4px 8px; } table.sched tr.grp td { background: #f3f6f9; font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); padding: 5px 8px; } table.sched tr.veh td.rh { color: var(--muted); }
.gcell { height: 52px; vertical-align: top; border-radius: 4px; background: #fbfcfd; border: 1px solid #eef2f6; } .gcell.nw { background: #eef0f2; } .gcell.drop { outline: 2px dashed var(--blue); }
table#docmx th.docrot { height: 110px; width: 34px; vertical-align: bottom; padding: 4px 0; } table#docmx th.docrot span { display: inline-block; white-space: nowrap; writing-mode: vertical-rl; transform: rotate(180deg); font-size: 11px; color: var(--muted); } table#docmx td, table#docmx th { border-bottom: 1px solid var(--line); }
body.anno-open { overflow: hidden; }
.annov { position: fixed; inset: 0; z-index: 2000; background: #0b1b2b; display: flex; flex-direction: column; }
.annobar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 8px 12px; background: #0f2135; color: #fff; border-bottom: 1px solid #1d3650; }
.annobar .annottl { font-size: 14px; margin-right: 4px; } .annobar .annospacer { flex: 1; } .annobar .annow { color: #cdd8e4; font-size: 12px; display: flex; align-items: center; gap: 6px; }
.annopens { display: flex; gap: 6px; } .annopen { width: 24px; height: 24px; border-radius: 50%; border: 2px solid rgba(255,255,255,.35); cursor: pointer; padding: 0; } .annopen.on { outline: 2px solid #fff; outline-offset: 1px; }
.annostage { flex: 1; display: flex; align-items: center; justify-content: center; overflow: auto; padding: 8px; }
.annocanvas { background: #fff; box-shadow: 0 2px 18px rgba(0,0,0,.5); touch-action: none; cursor: crosshair; max-width: 100%; }
.sq-card { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; margin-bottom: 10px; } .sq-card.closed { opacity: .66; }
.sq-reply { border-left: 2px solid var(--line-2); padding: 4px 0 4px 10px; margin: 6px 0; } .sq-img { max-width: 220px; max-height: 160px; border: 1px solid var(--line); border-radius: 6px; cursor: zoom-in; display: block; margin-top: 4px; }
/* Chip colour follows open site issues: green = none, amber = raised, red = urgent. Held (pencilled) shows as a dashed border, not a hue. */
.gbk { font-size: 11px; line-height: 1.25; padding: 3px 5px; border-radius: 4px; background: #1a7f37; color: #fff; cursor: pointer; overflow: hidden; margin-bottom: 2px; display: flex; flex-direction: column; gap: 1px; min-height: 48px; }
.gbk.iss-low, .gbk.iss-medium { background: #c77700; } .gbk.iss-high { background: #b42318; }
.gbk.held { border: 1px dashed rgba(255, 255, 255, .75); filter: saturate(.7); }
.gbk-top { display: flex; align-items: center; gap: 3px; min-width: 0; } .gbk-num { font-size: 12px; } .gbk-fl { font-size: 10px; } .gbk-time { margin-left: auto; font-size: 10px; opacity: .85; font-variant-numeric: tabular-nums; }
.gbk-site { font-weight: 600; display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.gbk-crew { font-size: 10px; opacity: .92; letter-spacing: .03em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: auto; } .gbk-van { opacity: .9; }
.gbk.cont { min-height: 0; flex-direction: row; align-items: center; opacity: .82; } .gbk-cont { font-size: 10px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gabs { font-size: 10px; padding: 2px 4px; border-radius: 3px; background: var(--amber-soft); color: var(--amber); } .gabs.req { border: 1px dashed var(--amber); background: transparent; }
.ub { padding: 8px; border: 1px solid var(--line); border-radius: 8px; margin-bottom: 6px; cursor: grab; background: #fff; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; } .chip { display: inline-flex; align-items: center; gap: 4px; padding: 4px 8px; border: 1px solid var(--line-2); border-radius: 999px; font-size: 12px; cursor: pointer; background: #fff; } .chip.on { background: var(--blue-soft); border-color: var(--blue); } .chip input { margin: 0; }
.conf .notice { margin-top: 4px; padding: 6px 10px; } .slot { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.ubar { height: 8px; background: #eef2f6; border-radius: 4px; width: 120px; display: inline-block; vertical-align: middle; margin-right: 6px; } .ubar div { height: 100%; background: var(--blue); border-radius: 4px; } .ubar div.hot { background: var(--red); } .ubar div.cold { background: var(--amber); }
.sheets .sheet { margin-bottom: 14px; } @media print { .side, .topbar, .tabs, .toolbar { display: none !important; } .content { padding: 0; } .sheet { break-inside: avoid; } }
table.imp td, table.imp th { padding: 4px 6px; } table.imp select { font-size: 12px; padding: 3px; } .modal.wide { width: min(1300px, 96vw); }
/* scheduling: readiness, locks, kit, clearances, CAD half-days, processing legend */
.rdot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 4px; vertical-align: middle; background: #c4ccd4; } .rdot.green { background: var(--green); } .rdot.amber { background: #f0a020; } .rdot.red { background: #d33; box-shadow: 0 0 0 2px #fdd; }
.gbk .rdot { width: 7px; height: 7px; border: 1px solid #fff; }
.gbk.locked { outline: 2px solid var(--navy); outline-offset: -2px; }
.cbadge { display: inline-block; font-size: 9px; font-weight: 700; line-height: 13px; padding: 0 4px; border-radius: 3px; background: var(--navy); color: #fff; margin-left: 2px; vertical-align: 1px; } .cbadge.exp { background: #d33; text-decoration: line-through; }
.chip.spec { border-color: #f0a020; background: #fff8ea; } .chip.spec.on { background: #f0a020; color: #fff; }
.lockbox { border: 1px dashed var(--line); border-radius: 8px; padding: 8px; } .lockbox .row2 { display: grid; grid-template-columns: 220px 1fr; gap: 6px; margin-top: 6px; }
.legend { display: flex; flex-wrap: wrap; gap: 4px 12px; margin: -4px 0 8px; color: var(--muted); } .legend .lg i { display: inline-block; width: 12px; height: 12px; border: 1px solid #b8c2cc; border-radius: 2px; margin-right: 4px; vertical-align: -2px; }
.legend .lgchip { display: inline-block; width: 13px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; } .legend .lgchip.ok { background: #1a7f37; } .legend .lgchip.amber { background: #c77700; } .legend .lgchip.red { background: #b42318; }
td.gcell.cad { cursor: pointer; padding: 0; height: 36px; } .cadhalf { height: 17px; box-sizing: border-box; display: flex; align-items: stretch; } .cadhalf.am { border-bottom: 1px dotted var(--line); } .cadhalf .gcad, .cadhalf .gabs { width: 100%; }
.gcad { font-size: 11px; line-height: 14px; padding: 1px 4px; border-radius: 3px; background: #dfe7ef; color: var(--navy); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.gabs.mark { background: #e8eef4; color: var(--navy); }
.takekit { font-size: 14px; margin-bottom: 8px; }
@media (max-width: 640px) { .lockbox .row2 { grid-template-columns: 1fr; } }
.chip.spec.on .muted { color: #fff8ea; }
.ctlpick { max-height: 340px; overflow: auto; border: 1px solid var(--line); border-radius: 8px; padding: 4px 10px; } .ctlpick label.check { display: block; margin: 3px 0; }
.ctl-items { margin: 0; padding: 0; list-style: none; } .ctl-items li { display: flex; gap: 6px; align-items: flex-start; margin-bottom: 4px; } .ctl-items li textarea { min-height: 38px; flex: 1; } .ctl-items .pill { flex: none; margin-top: 4px; }
.riskfull table.risk td:first-child { width: 230px; } .riskfull table.risk td:nth-child(5) { width: 52%; } .riskfull .ctl-items textarea { width: 100%; }
/* my calendar */
table.mycal { border-collapse: separate; border-spacing: 3px; width: 100%; table-layout: fixed; } td.mcal { vertical-align: top; background: #fff; border: 1px solid var(--line); border-radius: 6px; padding: 4px; height: 74px; min-width: 96px; }
td.mcal.off { background: #f1f4f7; } td.mcal.today { outline: 2px solid var(--blue); } td.mcal .dn { font-size: 11px; color: var(--muted); margin-bottom: 3px; }
.mtag { display: block; font-size: 11px; line-height: 14px; padding: 2px 4px; border-radius: 3px; margin-bottom: 2px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; text-decoration: none; }
.mtag.job { background: var(--blue); color: #fff; } .mtag.job.held { background: #c9d6e2; color: var(--navy); } .mtag.job.confirmed { background: var(--green); } .mtag.job .t { opacity: .8; }
.mtag.cad { background: #dfe7ef; color: var(--navy); } .mtag.abs { background: var(--amber-soft); color: var(--amber); } .mtag.abs.req { background: transparent; border: 1px dashed var(--amber); } .mtag.hol { background: #e8eef4; color: var(--muted); }
@media (max-width: 760px) { table.mycal, table.mycal tbody, table.mycal tr { display: block; } td.mcal { display: block; height: auto; margin-bottom: 4px; } td.mcal.off:not(.today) { display: none; } }
input.autofilled { background: #f2f8ee; }
.jobbar .pb { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; } .jobbar .jobstate { font-size: 15px; } .jobbar #clock { font-size: 22px; margin: 0 6px; }
.jobbtns { display: flex; gap: 8px; flex-wrap: wrap; } .btn.big { padding: 12px 22px; font-size: 16px; } .btn.danger { background: #c62828; color: #fff; border-color: #c62828; }
.jobbar .notice { flex-basis: 100%; }
.gstage { font-size: 11px; line-height: 1.25; padding: 3px 5px; border-radius: 4px; border: 1px dashed var(--blue); color: var(--navy); cursor: pointer; margin-bottom: 2px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 3; line-clamp: 3; -webkit-box-orient: vertical; overflow-wrap: anywhere; } .gstage b { display: block; }
.toplan { margin-top: 5px; display: flex; flex-wrap: wrap; gap: 3px; } .toplan::before { content: "to schedule"; font-size: 9px; letter-spacing: .04em; text-transform: uppercase; color: #9a6a00; width: 100%; }
.gstage.unplanned { display: inline-block; background: #fff4d6; border: 1px dashed #d8a200; color: #7a4b00; -webkit-line-clamp: 2; line-clamp: 2; margin-bottom: 0; }
@media (max-width: 640px) { .jobbtns .btn.big { flex: 1; } }
.live { margin-right: 3px; }
.rate.blur { filter: blur(5px); user-select: none; }
/* phone: sidebar becomes a top bar with a menu button, so the job page is the first thing a surveyor sees */
.menu-btn { display: none; margin-left: auto; background: none; border: 0; color: #fff; font-size: 22px; cursor: pointer; }
@media (max-width: 760px) { .side { padding: 10px 14px; } .side .brand { display: flex; align-items: center; margin-bottom: 0; } .menu-btn { display: block; } .side .nav, .side .foot { display: none; } .side.open .nav, .side.open .foot { display: flex; flex-direction: column; } .side.open .foot { display: block; } .topbar .btn.primary { display: none; } }
td.rh.asst { padding-left: 18px; background: #fafbfc; }
.offq { position: fixed; left: 50%; transform: translateX(-50%); bottom: 14px; background: #7a4b00; color: #fff; padding: 8px 14px; border-radius: 20px; font-size: 13px; z-index: 50; cursor: pointer; display: none; box-shadow: 0 4px 14px rgba(0,0,0,.2); }
/* field app */
.field { max-width: 640px; } .fh { margin: 16px 0 8px; font-size: 13px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.fjob { display: block; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; margin-bottom: 8px; color: inherit; text-decoration: none; } .fjob.today { border-left: 5px solid var(--blue); } .fj-top { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; margin-bottom: 2px; }
.fday { margin: 10px 0 4px; } .fvan.due { border-left: 5px solid #f0a020; }
.vchk .vrow { display: flex; gap: 10px; align-items: center; padding: 6px 0; border-bottom: 1px solid var(--line); } .vchk .vrow span { flex: 1; font-size: 14px; }
.sigwrap { position: relative; margin-top: 10px; } .sigwrap canvas { width: 100%; height: 160px; border: 1px dashed var(--line-2, #b8c2cc); border-radius: 8px; background: #fff; touch-action: none; } .sigwrap .btn { position: absolute; right: 6px; top: 6px; }
@media (max-width: 760px) { .shell { grid-template-rows: auto 1fr; align-content: start; } table.tsx { display: block; overflow-x: auto; white-space: nowrap; } }
/* phase 3b: site records, day confirmation */
.prow{display:flex;flex-wrap:wrap;gap:4px;margin-bottom:6px;align-items:center}
.prow input,.prow select{width:auto;min-width:0;flex:0 1 auto}
.rrow{padding:5px 0;border-bottom:1px solid #e5e9ef}
.rrow:last-child{border-bottom:0}
.fconf{border-left:4px solid #f59e0b}
.tsx-wrap{overflow-x:auto}
.form h4{margin:12px 0 0;font-size:13px;color:#042C53;grid-column:1/-1}
.form .f.wide > span + .check{margin-right:12px}
.sigwrap canvas { height: auto; }
.grid > *, .stack > .panel { min-width: 0; } .gridwrap { max-width: 100%; overflow-x: auto; }

/* use the width: quote lines give the description the room, numbers stay compact */
table.lines { width: 100%; table-layout: fixed; } table.lines th:nth-child(1) { width: auto; } table.lines th:nth-child(2) { width: 80px; } table.lines th:nth-child(3) { width: 80px; } table.lines th:nth-child(4), table.lines th:nth-child(5) { width: 110px; } table.lines th:nth-child(6) { width: 120px; } table.lines th:nth-child(7) { width: 40px; }
table.lines td:first-child input { text-overflow: ellipsis; }
@media (min-width: 1700px) { .g-main { grid-template-columns: minmax(0, 3fr) minmax(340px, 1fr); } }
table.sched { min-width: 100%; } table.sched td.rh, table.sched th.rh { position: sticky; left: 0; background: var(--panel, #fff); z-index: 2; }
/* Business-specific panels: survey-only items hide in a traffic-management region, and TM-only items hide everywhere else. */
body[data-biz="tm"] .survey-only { display: none !important; }
body:not([data-biz="tm"]) .tm-only { display: none !important; }
/* one shell for everything: IMS framed edge to edge; timesheet tables */
.tstable { width: 100%; } .tstable tr.today td { background: var(--blue-soft); } .tstable td { vertical-align: top; }
table.rv tr.click { cursor: pointer; } table.rv tr.click:hover td { background: #f8fafc; } table.rv tr.sub > td { background: #fafbfc; padding: 12px 16px 16px; }
table.tsday { width: 100%; margin-bottom: 4px; } table.tsday tr.ex td { border-top: 0; padding-top: 0; } .jobev { color: #3730a3; } .gaps { margin-top: 8px; } .gaps .gap { display: inline-flex; gap: 6px; align-items: center; margin: 4px 12px 0 0; }
.tsep { width: 1px; align-self: stretch; background: var(--line); margin: 0 4px; }
.tsprev { display: flex; gap: 16px; flex-wrap: wrap; border: 1px solid var(--line); background: var(--bg); border-radius: 8px; padding: 9px 12px; margin-top: 10px; font-size: 13px; } .tsprev .bad { color: var(--red); }
.form.g3f { grid-template-columns: repeat(3, minmax(0, 1fr)); } @media (max-width: 640px) { .form.g3f { grid-template-columns: 1fr 1fr; } }
.pill.blue { background: var(--blue-soft); color: var(--blue); }
@media (max-width: 640px) { table.tstable thead { display: none; } table.tstable tbody tr { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; padding: 10px 12px; border-bottom: 1px solid var(--line); } table.tstable tbody td { border: 0; padding: 0; } table.tstable tbody td:first-child { width: 100%; } table.tstable tbody tr.today { background: var(--blue-soft); } table.tstable tbody tr.today td { background: none; } table.tstable td.num:empty { display: none; } table.tstable td.num::before { content: attr(data-l); color: var(--ink-3); font-size: 11px; margin-right: 4px; } table.tstable td.right { margin-left: auto; } }

/* ---------- pricing insights ---------- */
.itbl { width: 100%; } .itbl td, .itbl th { padding: 7px 10px; } .itbl tr.flag td { background: var(--amber-soft); }
.itbl td.over { color: var(--red); font-weight: 600; }
.ibarw { display: flex; align-items: center; gap: 8px; min-width: 120px; } .ibarw > span { font-variant-numeric: tabular-nums; min-width: 34px; text-align: right; font-size: 12.5px; }
.ibar { flex: 1; height: 8px; border-radius: 4px; background: var(--grey-soft); overflow: hidden; } .ibar > span { display: block; height: 100%; border-radius: 4px; }
.irange { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 14px; font-size: 13px; } .irange input { padding: 5px 8px; border: 1px solid var(--line); border-radius: 6px; font: inherit; }
.ls-out { margin-top: 12px; font-size: 14px; line-height: 1.55; max-width: 820px; }
.pguide .pg-sug { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 6px; }
.pguide .pg-sug .l { font-size: 11.5px; color: var(--ink-3); text-transform: uppercase; letter-spacing: .04em; } .pguide .pg-sug .v { font-size: 22px; font-weight: 700; } .pguide .pg-sug .s { font-size: 12px; color: var(--ink-3); }
.pguide .pg-row { font-size: 12.5px; padding: 7px 0; border-top: 1px solid var(--line); } .pguide .pg-row.warn { color: #6b4a0e; }
.pg-sim { width: 100%; font-size: 12.5px; } .pg-sim td, .pg-sim th { padding: 5px 4px; vertical-align: top; }
.pcurve { width: 100%; height: auto; margin: 4px 0; } .pcurve .ln { fill: none; stroke: var(--blue); stroke-width: 2; } .pcurve .ax { stroke: var(--line); }
.pcurve .lb { font-size: 9px; fill: var(--ink-3); } .pcurve line.cur { stroke: var(--ink-3); stroke-dasharray: 3 3; } .pcurve text.cur { font-size: 9px; fill: var(--ink-3); }
.pcurve line.sug { stroke: var(--green); stroke-width: 1.5; } .pcurve text.sug { font-size: 9px; fill: var(--green); font-weight: 600; }
@media (max-width: 900px) { .grid.g2 { grid-template-columns: minmax(0, 1fr); } .itbl { display: block; overflow-x: auto; } }
.itbl td:first-child { white-space: nowrap; }
@media (max-width: 700px) { .tabs { overflow-x: auto; flex-wrap: nowrap; } .tabs button { white-space: nowrap; flex: 0 0 auto; } }

/* ---------- HR ---------- */
.hrtable td, .hrtable th { padding: 8px 10px; } .org .org-n { padding: 5px 0; border-left: 2px solid var(--line); padding-left: 10px; }

/* ---------- Management (directors only: financials, KPIs, ops meeting, CEO command centre, job financials) ---------- */
.mg .up { color: var(--green); } .mg .down { color: var(--red); } .mg .amb { color: var(--amber); }
.mg .kpi.warn { border-color: #f0dfb9; background: var(--amber-soft); } .mg .kpi.bad { border-color: #f0c7c0; background: var(--red-soft); }
.mg .kpi .s { font-size: 12px; color: var(--ink-3); margin-top: 2px; }
.mg-meta { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; font-size: 13px; color: var(--ink-2); margin-bottom: 14px; }
.mg-sec { display: flex; align-items: baseline; gap: 10px; margin: 26px 0 10px; } .mg-sec h2 { font-size: 15px; margin: 0; color: var(--navy); } .mg-sec .muted { font-size: 12.5px; }
.mg-hc { width: 90px; font: inherit; font-size: 22px; font-weight: 600; border: 1px solid var(--line); border-radius: 8px; padding: 0 6px; }
.mg-val { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.mg-big { font-size: 34px; font-weight: 700; color: var(--navy); letter-spacing: -.02em; } .mg-big small { font-size: 14px; color: var(--ink-3); font-weight: 500; }
.mg-slider { display: flex; align-items: center; gap: 10px; margin-top: 12px; } .mg-slider input { flex: 1; }
table.mg-range, table.mg-score, table.mg-pnl, table.mg-inv, table.mg-kpi, table.mg-act, table.mg-tt, table.mg-jobs, table.mg-lines { width: 100%; border-collapse: collapse; }
.mg-range td, .mg-range th, .mg-score td, .mg-pnl td, .mg-pnl th, .mg-inv td, .mg-inv th { padding: 8px 12px; border-bottom: 1px solid var(--line); font-size: 13px; }
.mg-range tr.hl td { background: var(--blue-soft); font-weight: 600; }
.mg-pnl tr.tot td { font-weight: 600; } .mg-pnl tr.sub td:first-child { padding-left: 24px; color: var(--ink-2); } .mg-pnl tr.mgn td { font-size: 12px; color: var(--ink-3); } .mg-pnl tr.mgn td:first-child { padding-left: 24px; }
.mg-chart { height: 280px; position: relative; }
.mg-bar { display: grid; grid-template-columns: minmax(120px, 2fr) 3fr 56px 90px; gap: 10px; align-items: center; padding: 5px 0; font-size: 13px; }
.mg-bar .bar { height: 10px; background: var(--grey-soft); border-radius: 5px; overflow: hidden; } .mg-bar .bar i { display: block; height: 100%; border-radius: 5px; } .mg-bar .pc, .mg-bar .amt { text-align: right; font-variant-numeric: tabular-nums; } .mg-bar .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mg-dd { display: flex; flex-direction: column; gap: 10px; } .mg-ddrow { display: grid; grid-template-columns: minmax(0, 1fr) 130px minmax(0, 1fr); gap: 10px; align-items: start; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.mg-ddrow select, .mg-ddrow input { padding: 6px 8px; border: 1px solid var(--line-2); border-radius: 8px; font: inherit; font-size: 13px; } .mg-live { color: var(--blue); margin-top: 3px; }
.mg-kpi th, .mg-kpi td { padding: 7px 9px; border-bottom: 1px solid var(--line); font-size: 13px; white-space: nowrap; } .mg-kpi th { font-size: 11.5px; color: var(--ink-3); text-transform: uppercase; letter-spacing: .04em; text-align: left; } .mg-kpi th.yr { color: var(--ink); text-transform: none; }
.mg-kpi .st { position: sticky; left: 0; background: var(--panel); z-index: 1; min-width: 220px; white-space: normal; } .mg-kpi td.cell.pos { color: var(--green); } .mg-kpi td.cell.neg { color: var(--red); } .mg-kpi td.cell.ed { background: #fbfdff; cursor: text; outline-offset: -2px; } .mg-kpi td.cell.ed:focus { outline: 2px solid var(--blue); color: var(--ink); }
.mg-ra { margin-left: 4px; white-space: nowrap; } .mg-ra .btn { padding: 0 5px; }
.mg-src { display: inline-block; font-size: 10.5px; font-weight: 600; padding: 1px 6px; border-radius: 999px; margin-left: 4px; background: var(--grey-soft); color: var(--ink-2); } .mg-src.xero { background: var(--blue-soft); color: var(--blue); } .mg-src.ops { background: var(--green-soft); color: var(--green); } .mg-src.bigchange { background: var(--amber-soft); color: var(--amber); }
.mg-agenda { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 12px; } .mg-agenda textarea, .mg-act input, .mg-tt select { width: 100%; font: inherit; font-size: 13px; padding: 7px 9px; border: 1px solid var(--line-2); border-radius: 8px; }
.mg-act td, .mg-act th { padding: 6px 10px; border-bottom: 1px solid var(--line); font-size: 13px; vertical-align: middle; } .mg-act tr.done input { text-decoration: line-through; color: var(--ink-3); } .mg-act .actions { white-space: nowrap; text-align: right; }
.mg-carry { display: flex; justify-content: space-between; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.mg-kgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; } .mg-kgrid .kpi { padding: 10px 12px; } .mg-kgrid .kpi .v { font-size: 18px; } .mg-kgrid .kpi .l { font-size: 11px; }
.mg-now { display: flex; align-items: center; gap: 16px; } .mg-now .el { font-size: 30px; font-weight: 700; font-variant-numeric: tabular-nums; color: var(--navy); } .mg-now i, .mg-chip i, .mg-ent i { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 6px; }
.mg-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; } .mg-chip { border: 1px solid var(--line-2); background: #fff; border-radius: 999px; padding: 5px 11px; font: inherit; font-size: 12.5px; cursor: pointer; } .mg-chip.on { border-color: var(--blue); background: var(--blue-soft); }
.mg-sub { font-size: 11.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-3); margin: 14px 0 6px; font-weight: 600; }
.mg-prio { display: flex; align-items: center; gap: 8px; padding: 4px 0; } .mg-prio .n { font-size: 11px; color: var(--ink-3); width: 18px; } .mg-prio input[type=text] { flex: 1; font: inherit; padding: 6px 9px; border: 1px solid var(--line-2); border-radius: 8px; } .mg-prio.done input[type=text] { text-decoration: line-through; color: var(--ink-3); }
.mg-rit { display: flex; gap: 8px; align-items: center; padding: 3px 0; font-size: 13px; } .mg-rit.done { color: var(--ink-3); }
.mg-energy { display: flex; gap: 6px; } .mg-energy button { width: 34px; height: 30px; border: 1px solid var(--line-2); background: #fff; border-radius: 8px; font: inherit; cursor: pointer; } .mg-energy button.on { background: var(--blue); color: #fff; border-color: var(--blue); }
.mg-tt th, .mg-tt td { padding: 6px 8px; border-bottom: 1px solid var(--line); font-size: 12.5px; white-space: nowrap; } .mg-tt tr.tot td { font-weight: 600; } .mg-tt select { padding: 2px 4px; font-size: 12px; }
.mg-ent { display: flex; align-items: center; gap: 6px; padding: 4px 0; border-bottom: 1px solid var(--line); } .mg-ent .lb { flex: 1; }
.mg-chat { max-height: 320px; overflow-y: auto; display: flex; flex-direction: column; gap: 6px; } .mg-chat .msg { padding: 8px 10px; border-radius: 10px; font-size: 13px; white-space: pre-wrap; } .mg-chat .user { background: var(--blue-soft); align-self: flex-end; max-width: 85%; } .mg-chat .ai { background: var(--grey-soft); } .mg-chat .err { background: var(--red-soft); color: #7a2418; }
.mg-hist { margin-top: 8px; max-height: 420px; overflow-y: auto; } .mg-hc { padding: 7px 0; border-bottom: 1px solid var(--line); cursor: pointer; } .mg-hc:hover { background: var(--grey-soft); } .mg-ex { white-space: pre-wrap; color: var(--ink-2); }
.mg-jobs td, .mg-jobs th, .mg-lines td, .mg-lines th { padding: 7px 10px; border-bottom: 1px solid var(--line); font-size: 13px; } .mg-lines tr.tot td { font-weight: 600; } .mg-jobs .chev { color: var(--ink-3); }
@media (max-width: 900px) { .mg-val, .mg-agenda, .mg-ddrow { grid-template-columns: minmax(0, 1fr); } .mg-bar { grid-template-columns: minmax(0, 1fr) 60px 80px; } .mg-bar .bar { display: none; } .mg-kpi .st { min-width: 160px; } }
/* the menu is now taller than a laptop screen once Management is in it: let the sidebar scroll rather than spill */
@media (min-width: 901px) { .side { overflow-y: auto; } .side .nav { flex-shrink: 0; } }

/* ---------- Tender radar & opportunities ---------- */
.radar-runs { display: flex; flex-wrap: wrap; gap: 6px; margin: -4px 0 12px; }
.conn { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; padding: 10px 0; border-top: 1px solid var(--line); } .conn:first-child { border-top: 0; padding-top: 0; }
.task { display: flex; gap: 8px; align-items: baseline; padding: 5px 0; } .task > span:nth-of-type(1) { flex: 1; } .task.done > span:nth-of-type(1) { text-decoration: line-through; color: var(--ink-3); }
.corr { padding: 8px 0; border-top: 1px solid var(--line); } .corr:first-child { border-top: 0; padding-top: 0; }

mark { background: #fdf0b5; color: inherit; border-radius: 3px; padding: 0 2px; }
@media (prefers-color-scheme: dark) { mark { background: #5c4d12; } }

th.sortable { cursor: pointer; user-select: none; white-space: nowrap; }
th.sortable::after { content: " ↕"; opacity: .35; font-size: 11px; }
th.sortable[data-dir="asc"]::after { content: " ▲"; opacity: .8; }
th.sortable[data-dir="desc"]::after { content: " ▼"; opacity: .8; }
.toolbar.tt .tt-q { min-width: 240px; flex: 1 1 240px; max-width: 420px; }
.toolbar.tt select { max-width: 200px; width: auto; }
/* manhole card: duct formation (tap each way) */
.drow{border:1px solid var(--line);border-radius:8px;padding:6px;background:#fbfcfd}
.waywrap{flex-basis:100%;display:flex;gap:10px;align-items:center;margin-top:4px}
.ways{display:grid;gap:3px}
.way{width:28px;height:28px;border-radius:50%;border:1.5px solid var(--ink-3,#8796a5);background:#fff;font-size:14px;line-height:1;padding:0;cursor:pointer;color:var(--ink)}
.way.occupied{background:#042C53;color:#fff;border-color:#042C53}.way.spare{border-color:#1a7f37;color:#1a7f37}.way.blocked{border-color:#b42318;color:#b42318;background:#fdecea}
.form [hidden]{display:none!important}
/* drawing QC workspace */
.qcstages{display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:8px;margin-bottom:12px}
.qcst{display:flex;flex-direction:column;align-items:flex-start;gap:3px;padding:10px 12px;border:1px solid var(--line);border-radius:10px;background:var(--panel);font:inherit;text-align:left;cursor:pointer;color:var(--ink)}
.qcst b{font-size:13px;font-weight:600}.qcst span{font-size:12px}.qcst:hover{border-color:var(--line-2)}
.qcst.on{border-color:var(--blue);box-shadow:inset 0 0 0 1px var(--blue);background:var(--blue-soft)}
.qcst i{font-style:normal;font-weight:600}.qcst .qn{color:var(--amber)}.qcst .qd{color:var(--green)}
.seg{display:inline-flex;flex-wrap:wrap;border:1px solid var(--line-2);border-radius:8px;overflow:hidden;background:#fff}
.seg label{display:flex;cursor:pointer}.seg input{position:absolute;opacity:0;pointer-events:none}
.seg span{padding:8px 14px;font-size:13px;font-weight:600;color:var(--ink-2);border-right:1px solid var(--line)}.seg label:last-child span{border-right:0}
.seg input:checked+span{background:var(--navy);color:#fff}.seg input:focus-visible+span{outline:2px solid var(--blue)}
.seg.sm span{padding:5px 10px;font-size:12.5px}
.qcgrid{display:grid;grid-template-columns:260px minmax(0,1fr);gap:16px;align-items:start}
.qcrail{position:sticky;top:12px;max-height:calc(100vh - 40px);display:flex;flex-direction:column}
.qclist{overflow:auto;padding:4px}
.qclist a{display:grid;grid-template-columns:12px auto 1fr auto;gap:8px;align-items:center;padding:7px 10px;border-radius:7px;color:var(--ink);font-size:13px}
.qclist a:hover{background:var(--grey-soft);text-decoration:none}.qclist a.on{background:var(--blue-soft)}
.qclist .small{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.qc-n{min-width:20px;text-align:center;font-size:11.5px;font-weight:700;color:#fff;background:var(--amber);border-radius:999px;padding:0 6px}.qc-n:empty{display:none}
.qdot{width:10px;height:10px;border-radius:50%;background:#c5ced8}.qdot.red{background:var(--red)}.qdot.amber{background:var(--amber)}.qdot.green{background:var(--green)}.qdot.blue{background:var(--blue)}
.qccompare{display:grid;grid-template-columns:1fr 1fr;gap:0;border-bottom:1px solid var(--line)}
.qccompare>div{padding:14px 16px;min-width:0}.qccompare>div+div{border-left:1px solid var(--line)}
.qccompare h4{font-size:12px;text-transform:uppercase;letter-spacing:.06em;color:var(--ink-3);margin:0 0 8px}
.qccompare table{font-size:12.5px}.qccompare td,.qccompare th{padding:5px 8px}
table.kv td:first-child{color:var(--ink-3);white-space:nowrap;width:1%}
.qcf{border:1px solid var(--line);border-left:4px solid var(--line-2);border-radius:8px;padding:10px 12px;margin-bottom:8px;background:#fff}
.qcf.FAIL{border-left-color:var(--red)}.qcf.WARN{border-left-color:var(--amber)}.qcf.INFO{border-left-color:var(--blue)}.qcf.PASS{border-left-color:var(--green)}
.qcf.decided{background:#fafbfc}.qcf.decided .qcf-m{color:var(--ink-2)}
.qcf-h{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.qcf-m{margin:6px 0 2px;font-weight:500}
.qcf-d{margin-top:6px;font-size:12.5px;color:var(--green)}.qcf-a{margin-top:8px;align-items:center}
label.btn.busy{opacity:.6;pointer-events:none}
/* site diary */
.diaryauto{margin-bottom:4px}.diaryform .urow .row{display:flex;flex-wrap:wrap;gap:8px;align-items:center}.diaryform .urow input[type=text],.diaryform .urow input:not([type]){flex:1 1 200px}
.diaryform .chips .chip{padding:7px 12px;font-size:13px}.diaryform h4{margin-top:16px}
@media (max-width:900px){.qcgrid{grid-template-columns:1fr}.qcrail{position:static;max-height:280px}.qccompare{grid-template-columns:1fr}.qccompare>div+div{border-left:0;border-top:1px solid var(--line)}}

/* Book a job: a question still open, marked where it sits once Book has been pressed */
.bkneed{outline:2px solid #c0392b;outline-offset:3px;border-radius:6px;background:#fdecea}
.bkneed>span:first-child,.bkneed>legend{color:#9e2430;font-weight:600}

/* SSWP control tiles: off, required (amber), in place (green) */
.ctls{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:6px}
.ctl{display:flex;align-items:center;gap:8px;min-height:46px;padding:6px 10px;border:1.5px solid var(--line,#d9dee5);border-radius:10px;background:#fff;font:inherit;font-size:13px;text-align:left;cursor:pointer;line-height:1.2}
.ctl b{flex:none;width:22px;height:22px;border-radius:50%;border:2px solid #b7c0cc;display:grid;place-items:center;font-size:13px}
.ctl[data-s="required"]{border-color:#c77d00;background:#fff4dc}.ctl[data-s="required"] b{border-color:#c77d00;background:#c77d00}.ctl[data-s="required"] b::after{content:"!";color:#fff}
.ctl[data-s="in_place"]{border-color:#1b7f43;background:#e3f6ea}.ctl[data-s="in_place"] b{border-color:#1b7f43;background:#1b7f43}.ctl[data-s="in_place"] b::after{content:"✓";color:#fff}
.ctl.na{border-style:dashed;color:#566}.ctl[data-s="na"]{border-style:solid;border-color:#566;background:#eef1f5}.ctl[data-s="na"] b{background:#566;border-color:#566}.ctl[data-s="na"] b::after{content:"–";color:#fff}
.ctlgrp.waiting>span:first-child .ctlsum{color:#8a4500;font-weight:600}

/* Notifications: the bell and its list */
.nbell{position:relative;flex:none;padding:8px 11px;font-size:16px;line-height:1}
.nbadge{position:absolute;top:-6px;right:-6px;min-width:18px;height:18px;padding:0 5px;border-radius:9px;background:#c0392b;color:#fff;font-size:11px;font-weight:700;line-height:18px;text-align:center}
.npanel{position:fixed;z-index:60;width:min(380px,calc(100vw - 16px));max-height:min(560px,calc(100vh - 90px));display:flex;flex-direction:column;background:var(--panel,#fff);border:1px solid var(--line,#d9dee5);border-radius:12px;box-shadow:0 12px 32px rgba(10,30,60,.18);overflow:hidden}
.nhead{display:flex;justify-content:space-between;align-items:center;gap:8px;padding:10px 14px;border-bottom:1px solid var(--line,#d9dee5)}
.nbody{overflow-y:auto}
.nitem{display:flex;gap:10px;padding:10px 14px;border-bottom:1px solid var(--line,#eef1f5);color:inherit;text-decoration:none}
.nitem:hover{background:var(--bg,#f6f8fb)}.nitem.new{background:#eef5ff}.nitem.new b::after{content:"";display:inline-block;width:7px;height:7px;border-radius:50%;background:#1a73c8;margin-left:6px;vertical-align:middle}
.nico{flex:none;font-size:17px;line-height:1.3}.ntxt{display:flex;flex-direction:column;gap:2px;min-width:0;font-size:13px}.ntxt span{color:var(--ink-2,#44536a)}.ntxt i{font-style:normal;font-size:11px;color:var(--ink-3,#7a8799)}
