/* FLEETDESK — dark ops theme, phone-first (390px), tuned for iPhone 17 Pro Max */

:root {
  --bg: #0a0d13;
  --bg2: #0d1219;
  --surface: #121821;
  --surface2: #182029;
  --surface3: #1f2937;
  --border: #232c3b;
  --border2: #2e3949;
  --text: #e9eef6;
  --muted: #8b96a9;
  --faint: #5d6779;
  --accent: #ffb547;
  --accent-ink: #221500;
  --blue: #4cc2ff;
  --green: #34d17b;
  --red: #ff5d5d;
  --violet: #a78bfa;
  --cyan: #67e8f9;
  --shadow: 0 10px 30px rgba(0,0,0,.45);
  --r-lg: 18px; --r-md: 14px; --r-sm: 10px;
  --sat: env(safe-area-inset-top, 0px);
  --sab: env(safe-area-inset-bottom, 0px);
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, monospace;
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", system-ui, sans-serif;
  --glass: rgba(10,13,19,.82);
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font-family: var(--sans); font-size: 15px; line-height: 1.45;
  overscroll-behavior-y: none;
}
body::before { /* ambient glow */
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 0;
  background:
    radial-gradient(900px 420px at 85% -10%, rgba(255,181,71,.07), transparent 60%),
    radial-gradient(700px 400px at -10% 20%, rgba(76,194,255,.06), transparent 60%);
}
a { color: inherit; text-decoration: none; }
button { font-family: inherit; color: inherit; }
svg { display: block; }
::selection { background: rgba(255,181,71,.28); }

/* ---------- topbar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 40;
  display: flex; align-items: center; gap: 6px;
  padding: calc(var(--sat) + 8px) 12px 8px;
  background: var(--glass);
  -webkit-backdrop-filter: saturate(180%) blur(18px);
  backdrop-filter: saturate(180%) blur(18px);
  border-bottom: 1px solid var(--border);
}
.iconbtn {
  display: grid; place-items: center; width: 38px; height: 38px;
  border-radius: 12px; border: 1px solid var(--border); background: var(--surface);
  color: var(--muted); cursor: pointer; flex: none;
  transition: transform .12s ease, color .12s ease, border-color .12s ease;
}
.iconbtn:active { transform: scale(.92); color: var(--text); }
.brand {
  display: flex; align-items: center; gap: 8px; flex: 1; min-width: 0;
  font-weight: 800; letter-spacing: .12em; font-size: 14px; color: var(--text);
}
.brand span { text-shadow: 0 0 24px rgba(255,181,71,.25); }
.opchip {
  display: flex; align-items: center; gap: 6px; flex: none;
  border: 1px solid var(--border); background: var(--surface); color: var(--text);
  border-radius: 999px; padding: 6px 10px 6px 8px; font-size: 12.5px; font-weight: 700;
  cursor: pointer; max-width: 168px; transition: border-color .12s ease;
}
.opchip:active { border-color: var(--accent); }
.opchip svg { color: var(--faint); }
.opdot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 8px rgba(52,209,123,.7); flex: none; }
#opName { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-transform: uppercase; letter-spacing: .06em; }

/* ---------- chip nav ---------- */
.chipnav {
  position: sticky; top: calc(var(--sat) + 54px); z-index: 30;
  display: flex; gap: 8px; overflow-x: auto; padding: 10px 12px;
  background: var(--glass);
  -webkit-backdrop-filter: saturate(180%) blur(18px);
  backdrop-filter: saturate(180%) blur(18px);
  border-bottom: 1px solid var(--border);
  scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.chipnav::-webkit-scrollbar { display: none; }
.chipnav a {
  flex: none; padding: 7px 14px; border-radius: 999px; font-size: 13px; font-weight: 650;
  color: var(--muted); border: 1px solid var(--border); background: var(--surface);
  transition: color .12s ease, background .12s ease, border-color .12s ease;
}
.chipnav a.active { color: var(--accent-ink); background: var(--accent); border-color: var(--accent); font-weight: 750; }

/* ---------- layout ---------- */
#view { position: relative; z-index: 1; padding: 0 0 calc(120px + var(--sab)); min-height: 70vh; }
.wrap { padding: 18px 14px 0; max-width: 1100px; margin: 0 auto; }
.pagehead { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.kicker { font-size: 11px; letter-spacing: .18em; font-weight: 750; color: var(--accent); text-transform: uppercase; margin-bottom: 3px; }
h1 { font-size: 26px; font-weight: 800; letter-spacing: -.02em; margin: 0; line-height: 1.15; }
.sub { color: var(--muted); font-size: 13px; margin-top: 4px; }
.section { margin-top: 26px; }
.section > h2 { font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); font-weight: 750; margin: 0 0 10px 2px; }

/* ---------- pills & badges ---------- */
.pill {
  display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px;
  border-radius: 999px; font-size: 11px; font-weight: 750; letter-spacing: .04em;
  border: 1px solid transparent; white-space: nowrap;
}
.pill .dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.st-queued { color: var(--blue); background: rgba(76,194,255,.1); border-color: rgba(76,194,255,.3); }
.st-in_progress { color: var(--accent); background: rgba(255,181,71,.1); border-color: rgba(255,181,71,.3); }
.st-blocked { color: var(--red); background: rgba(255,93,93,.1); border-color: rgba(255,93,93,.3); }
.st-done { color: var(--green); background: rgba(52,209,123,.1); border-color: rgba(52,209,123,.3); }
.st-open { color: var(--violet); background: rgba(167,139,250,.1); border-color: rgba(167,139,250,.3); }
.st-in_review { color: var(--cyan); background: rgba(103,232,249,.1); border-color: rgba(103,232,249,.3); }
.st-converted { color: var(--green); background: rgba(52,209,123,.1); border-color: rgba(52,209,123,.3); }
.st-closed { color: var(--faint); background: rgba(93,103,121,.12); border-color: rgba(93,103,121,.35); }
.st-raw { color: var(--muted); background: rgba(139,150,169,.1); border-color: rgba(139,150,169,.3); }
.st-triaged { color: var(--blue); background: rgba(76,194,255,.1); border-color: rgba(76,194,255,.3); }
.st-promoted { color: var(--accent); background: rgba(255,181,71,.1); border-color: rgba(255,181,71,.3); }
.st-parked { color: var(--red); background: rgba(255,93,93,.1); border-color: rgba(255,93,93,.3); }
.st-built { color: var(--green); background: rgba(52,209,123,.1); border-color: rgba(52,209,123,.3); }
.st-active { color: var(--green); background: rgba(52,209,123,.1); border-color: rgba(52,209,123,.3); }
.st-away { color: var(--accent); background: rgba(255,181,71,.1); border-color: rgba(255,181,71,.3); }
.st-offline { color: var(--faint); background: rgba(93,103,121,.12); border-color: rgba(93,103,121,.35); }
.pr { font-family: var(--mono); font-size: 11px; font-weight: 700; padding: 3px 7px; border-radius: 7px; }
.pr-P1 { color: #ff8080; background: rgba(255,93,93,.14); }
.pr-P2 { color: var(--accent); background: rgba(255,181,71,.12); }
.pr-P3 { color: var(--blue); background: rgba(76,194,255,.12); }
.pr-P4 { color: var(--faint); background: rgba(93,103,121,.16); }

/* ---------- cards ---------- */
.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg);
  padding: 14px; box-shadow: 0 1px 0 rgba(255,255,255,.02) inset;
}
.card + .card { margin-top: 10px; }
.card.tap { transition: transform .12s ease, border-color .12s ease; cursor: pointer; }
.card.tap:active { transform: scale(.985); border-color: var(--border2); }
.jobcard { display: block; }
.jobcard .row1 { display: flex; align-items: center; gap: 8px; }
.jobcard .jid { font-family: var(--mono); font-size: 11px; color: var(--accent); font-weight: 700; letter-spacing: .04em; }
.jobcard .title { font-weight: 700; font-size: 14.5px; margin: 6px 0 8px; line-height: 1.3; }
.jobcard .row3 { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.jobcard .meta { color: var(--faint); font-size: 12px; }
.avatar {
  width: 20px; height: 20px; border-radius: 50%; display: inline-grid; place-items: center;
  font-size: 9.5px; font-weight: 800; color: var(--accent-ink); background: var(--accent); flex: none;
}
.avatar.a0 { background: var(--blue); } .avatar.a1 { background: var(--green); }
.avatar.a2 { background: var(--violet); } .avatar.a3 { background: var(--red); color: #fff; }
.avatar.a4 { background: var(--cyan); } .avatar.a5 { background: var(--accent); }
.avatar.sm { width: 16px; height: 16px; font-size: 8px; }
.unowned { color: var(--faint); font-size: 11.5px; font-style: italic; }
.steps-mini { height: 4px; border-radius: 2px; background: var(--surface3); overflow: hidden; margin-top: 9px; }
.steps-mini i { display: block; height: 100%; background: var(--green); border-radius: 2px; transition: width .3s ease; }
.blockline { color: var(--red); font-size: 12px; margin-top: 7px; font-weight: 600; }

/* ---------- filter / sort bar ---------- */
.filterbar {
  position: sticky; top: calc(var(--sat) + 98px); z-index: 20;
  display: flex; gap: 8px; padding: 10px 0; margin-bottom: 6px;
  background: linear-gradient(var(--bg) 82%, transparent);
  overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.filterbar::-webkit-scrollbar { display: none; }
.filterbar select, .filterbar .fbtn {
  flex: none; appearance: none; -webkit-appearance: none;
  background: var(--surface); color: var(--text); border: 1px solid var(--border);
  border-radius: 12px; padding: 8px 12px; font-size: 13px; font-weight: 650; cursor: pointer;
}
.filterbar select { padding-right: 26px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%238b96a9' stroke-width='2.4'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 8px center; background-size: 13px; }
.filterbar .fbtn.on { border-color: var(--accent); color: var(--accent); }
.filterbar .fbtn:active { border-color: var(--border2); }
.count-chip { flex: none; align-self: center; font-size: 12px; color: var(--faint); font-weight: 650; white-space: nowrap; }

/* ---------- kanban ---------- */
.boardcols {
  display: grid; grid-auto-flow: column; grid-auto-columns: min(84vw, 300px);
  gap: 10px; overflow-x: auto; padding: 2px 14px 18px;
  -webkit-overflow-scrolling: touch; scroll-snap-type: x proximity; scrollbar-width: none;
}
.boardcols::-webkit-scrollbar { display: none; }
.bcol { scroll-snap-align: start; min-width: 0; }
.bcolhead {
  display: flex; align-items: center; gap: 8px; padding: 8px 6px 10px;
  position: sticky; top: 0;
}
.bcolhead .cname { font-size: 12px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.bcolhead .ccount { font-family: var(--mono); font-size: 11px; color: var(--faint); background: var(--surface2); padding: 2px 7px; border-radius: 6px; }
.bcol .card + .card { margin-top: 8px; }
@media (min-width: 900px) {
  .boardcols { grid-auto-flow: row; grid-template-columns: repeat(4, 1fr); overflow: visible; }
  .wrap { padding: 18px 24px 0; }
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  border: 1px solid var(--border2); background: var(--surface2); color: var(--text);
  border-radius: 13px; padding: 10px 16px; font-size: 14px; font-weight: 700; cursor: pointer;
  transition: transform .12s ease, background .12s ease, border-color .12s ease, opacity .12s;
}
.btn:active { transform: scale(.97); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.good { background: rgba(52,209,123,.14); border-color: rgba(52,209,123,.4); color: var(--green); }
.btn.danger { background: rgba(255,93,93,.12); border-color: rgba(255,93,93,.4); color: var(--red); }
.btn.ghost { background: transparent; border-color: var(--border); color: var(--muted); }
.btn.sm { padding: 7px 12px; font-size: 12.5px; border-radius: 11px; }
.btn.block { width: 100%; }
.btn[disabled] { opacity: .45; pointer-events: none; }
.btnrow { display: flex; flex-wrap: wrap; gap: 8px; }

/* ---------- FAB ---------- */
.fab {
  position: fixed; right: 18px; bottom: calc(22px + var(--sab)); z-index: 35;
  width: 56px; height: 56px; border-radius: 18px; display: grid; place-items: center;
  background: var(--accent); color: var(--accent-ink);
  box-shadow: 0 12px 30px rgba(255,181,71,.35), 0 4px 12px rgba(0,0,0,.4);
  transition: transform .15s ease;
}
.fab:active { transform: scale(.92); }

/* ---------- forms ---------- */
label.f { display: block; margin: 14px 0 6px; font-size: 12px; font-weight: 750; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
input[type="text"], input[type="search"], textarea, select {
  width: 100%; background: var(--bg2); border: 1px solid var(--border); color: var(--text);
  border-radius: 13px; padding: 12px 14px; font-size: 16px; font-family: inherit; outline: none;
  transition: border-color .15s ease, box-shadow .15s ease;
}
textarea { resize: vertical; min-height: 90px; line-height: 1.5; }
input:focus, textarea:focus, select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(255,181,71,.15); }
.hint { color: var(--faint); font-size: 12px; margin-top: 5px; }

/* ---------- job detail ---------- */
.jhead { display: flex; align-items: flex-start; gap: 10px; }
.jhead h1 { font-size: 21px; }
.backbar { display: flex; align-items: center; gap: 10px; padding: 12px 14px 0; }
.backlink { color: var(--muted); font-weight: 700; font-size: 13.5px; display: inline-flex; align-items: center; gap: 5px; }
.backlink:active { color: var(--text); }
.metagrid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 14px; }
.metabox { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--r-md); padding: 10px 12px; }
.metabox .k { font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--faint); font-weight: 750; }
.metabox .v { margin-top: 3px; font-size: 13.5px; font-weight: 650; display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.metabox select { padding: 6px 26px 6px 10px; font-size: 13px; border-radius: 9px; width: auto; }

/* steps */
.step { display: flex; align-items: flex-start; gap: 11px; padding: 11px 0; border-bottom: 1px solid var(--border); cursor: pointer; }
.step:last-of-type { border-bottom: none; }
.step .box {
  width: 22px; height: 22px; border-radius: 7px; border: 2px solid var(--border2);
  display: grid; place-items: center; flex: none; margin-top: 1px; transition: all .15s ease;
}
.step.done .box { background: var(--green); border-color: var(--green); color: #06240f; }
.step.done .txt { color: var(--faint); text-decoration: line-through; }
.step .txt { font-size: 14.5px; font-weight: 600; line-height: 1.35; }
.stepadd { display: flex; gap: 8px; margin-top: 12px; }
.stepadd input { flex: 1; padding: 10px 12px; font-size: 15px; }

/* log timeline */
.logline { position: relative; padding: 0 0 16px 26px; }
.logline::before { content: ""; position: absolute; left: 7px; top: 5px; bottom: -2px; width: 2px; background: var(--border); }
.logline:last-child::before { display: none; }
.logline .node {
  position: absolute; left: 0; top: 3px; width: 16px; height: 16px; border-radius: 50%;
  background: var(--surface2); border: 2px solid var(--border2); display: grid; place-items: center;
  font-size: 9px; z-index: 1;
}
.logline .node.created { color: var(--blue); border-color: var(--blue); }
.logline .node.claimed, .logline .node.assigned { color: var(--accent); border-color: var(--accent); }
.logline .node.completed, .logline .node.built { color: var(--green); border-color: var(--green); }
.logline .node.blocked { color: var(--red); border-color: var(--red); }
.logline .node.unblocked, .logline .node.reopened { color: var(--cyan); border-color: var(--cyan); }
.logline .node.note, .logline .node.step-done, .logline .node.step-reopened, .logline .node.step-added { color: var(--muted); }
.logline .node.converted, .logline .node.promoted, .logline .node.parked, .logline .node.triaged { color: var(--violet); border-color: var(--violet); }
.logline .head { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.logline .who { font-weight: 800; font-size: 13px; }
.logline .kind { font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--faint); font-weight: 750; }
.logline .when { font-size: 11px; color: var(--faint); font-family: var(--mono); margin-left: auto; }
.logline .body { font-size: 14px; color: var(--text); margin-top: 2px; line-height: 1.45; }
.logline .body.note { color: var(--muted); }

/* thread */
.thread { display: flex; flex-direction: column; gap: 10px; }
.bubble { max-width: 92%; padding: 10px 13px; border-radius: 16px; background: var(--surface2); border: 1px solid var(--border); }
.bubble .bwho { font-size: 11px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--accent); margin-bottom: 3px; display: flex; gap: 8px; }
.bubble .bwho .when { color: var(--faint); font-family: var(--mono); text-transform: none; letter-spacing: 0; margin-left: auto; font-weight: 500; }
.bubble .btxt { font-size: 14.5px; line-height: 1.45; }
.bubble.sys { background: rgba(52,209,123,.07); border-color: rgba(52,209,123,.25); align-self: center; max-width: 100%; text-align: center; font-size: 13px; color: var(--green); }

/* tracking */
.trackgrid { display: grid; gap: 10px; }
.nowitem { display: flex; align-items: center; gap: 11px; }
.nowitem .who { display: flex; align-items: center; gap: 8px; width: 92px; flex: none; font-weight: 750; font-size: 13px; }
.nowitem .what { flex: 1; min-width: 0; }
.nowitem .what .t { font-weight: 700; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nowitem .what .s { font-size: 11.5px; color: var(--faint); font-family: var(--mono); }
.waititem { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--border); }
.waititem:last-child { border-bottom: none; }
.waititem .age { margin-left: auto; font-family: var(--mono); font-size: 11.5px; color: var(--red); font-weight: 700; white-space: nowrap; }
.statrow { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 16px; }
/* a four-up row of big numbers: two-up on a phone, and never a number wrapped mid-value (S-04) */
.statrow.four { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 560px) { .statrow.four { grid-template-columns: repeat(2, 1fr); } }
.stat { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-md); padding: 11px 10px; text-align: center; min-width: 0; }
.stat .n { font-size: 22px; font-weight: 800; letter-spacing: -.02em; white-space: nowrap; overflow-wrap: normal; }
@media (max-width: 560px) { .stat .n { font-size: 19px; } }
.stat .l { font-size: 10px; letter-spacing: .1em; text-transform: uppercase; color: var(--faint); font-weight: 750; margin-top: 2px; }
.stat .n.blue { color: var(--blue); } .stat .n.amber { color: var(--accent); }
.stat .n.red { color: var(--red); } .stat .n.green { color: var(--green); }

/* search */
.searchbox { position: sticky; top: calc(var(--sat) + 98px); z-index: 20; padding: 10px 0; background: linear-gradient(var(--bg) 82%, transparent); }
.searchbox input { font-size: 17px; border-radius: 15px; }
.sresult { display: block; }
.sresult .where { font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--faint); font-weight: 750; margin-bottom: 5px; }
.sresult mark { background: rgba(255,181,71,.25); color: var(--accent); border-radius: 3px; padding: 0 1px; }
.sresult .snippet { color: var(--muted); font-size: 13px; margin-top: 5px; line-height: 1.4; }

/* operators */
.oprow { display: flex; align-items: center; gap: 12px; }
.oprow .av { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; font-size: 15px; font-weight: 800; color: var(--accent-ink); flex: none; }
.oprow .info { flex: 1; min-width: 0; }
.oprow .info .nm { font-weight: 800; font-size: 15px; }
.oprow .info .rl { color: var(--muted); font-size: 12.5px; margin-top: 1px; }
.oprow .counts { text-align: right; flex: none; }
.oprow .counts .c { font-size: 16px; font-weight: 800; font-family: var(--mono); }
.oprow .counts .k { font-size: 9.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--faint); font-weight: 750; }

/* data */
.datarow { display: flex; align-items: center; gap: 12px; padding: 13px 0; border-bottom: 1px solid var(--border); }
.datarow:last-child { border-bottom: none; }
.datarow .dinfo { flex: 1; min-width: 0; }
.datarow .dt { font-weight: 750; font-size: 14.5px; }
.datarow .dd { color: var(--muted); font-size: 12.5px; margin-top: 2px; }

/* ---------- drawer ---------- */
.scrim { position: fixed; inset: 0; background: rgba(4,6,10,.6); z-index: 60; -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
.drawer {
  position: fixed; top: 0; bottom: 0; left: 0; width: min(84vw, 320px); z-index: 61;
  background: var(--bg2); border-right: 1px solid var(--border);
  padding: calc(var(--sat) + 16px) 14px calc(16px + var(--sab));
  overflow-y: auto; -webkit-overflow-scrolling: touch; animation: slidein .2s ease;
}
@keyframes slidein { from { transform: translateX(-30px); opacity: 0; } to { transform: none; opacity: 1; } }
.drawer .dhead { display: flex; align-items: center; gap: 9px; font-weight: 800; letter-spacing: .12em; font-size: 14px; padding: 4px 6px 14px; border-bottom: 1px solid var(--border); margin-bottom: 10px; }
.drawer a.dlink { display: flex; align-items: center; gap: 11px; padding: 11px 10px; border-radius: 12px; font-weight: 700; font-size: 14.5px; color: var(--muted); }
.drawer a.dlink.active { color: var(--text); background: var(--surface2); }
.drawer a.dlink:active { background: var(--surface3); }
.drawer a.dlink .ic { width: 26px; height: 26px; border-radius: 8px; background: var(--surface2); display: grid; place-items: center; font-size: 13px; flex: none; }
.drawer .dsec { font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--faint); font-weight: 750; padding: 16px 10px 6px; }
.drawer .dfoot { margin-top: 18px; padding: 12px 10px 0; border-top: 1px solid var(--border); color: var(--faint); font-size: 12px; line-height: 1.5; }

/* ---------- modal ---------- */
.mscrim { position: fixed; inset: 0; z-index: 70; background: rgba(4,6,10,.62); display: flex; align-items: flex-end; justify-content: center; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); animation: fadein .15s ease; }
@keyframes fadein { from { opacity: 0; } to { opacity: 1; } }
.mcard {
  width: 100%; max-width: 440px; background: var(--surface); border: 1px solid var(--border2);
  border-radius: 22px 22px 0 0; padding: 20px 18px calc(20px + var(--sab));
  box-shadow: var(--shadow); animation: sheetup .22s cubic-bezier(.2,.9,.3,1);
  max-height: 90vh; max-height: 90dvh; overflow-y: auto; -webkit-overflow-scrolling: touch;
}
/* long forms: the action row stays reachable at the bottom of the sheet */
.mcard .mactions { position: sticky; bottom: calc(-20px - var(--sab)); background: var(--surface); padding: 12px 0 calc(4px + var(--sab)); margin-bottom: calc(-4px - var(--sab)); z-index: 2; }
@keyframes sheetup { from { transform: translateY(40px); opacity: .4; } to { transform: none; opacity: 1; } }
@media (min-width: 700px) {
  .mscrim { align-items: center; }
  .mcard { border-radius: 22px; padding-bottom: 20px; }
}
.mcard h3 { margin: 0 0 4px; font-size: 18px; font-weight: 800; letter-spacing: -.01em; }
.mcard .mbody { color: var(--muted); font-size: 13.5px; margin-bottom: 12px; }
.mactions { display: flex; gap: 10px; margin-top: 16px; }
.mactions .btn { flex: 1; }
.mpick { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.mpick button {
  display: flex; align-items: center; gap: 11px; text-align: left; width: 100%;
  background: var(--surface2); border: 1px solid var(--border); border-radius: 14px;
  padding: 12px 14px; cursor: pointer; color: var(--text); font-size: 15px; font-weight: 700;
  transition: border-color .12s, transform .12s;
}
.mpick button:active { transform: scale(.98); border-color: var(--accent); }
.mpick button .sub { margin: 0; font-weight: 500; font-size: 12px; }
.mpick button .cur { margin-left: auto; color: var(--green); font-size: 12px; font-weight: 800; }

/* ---------- toast ---------- */
#toast {
  position: fixed; left: 50%; bottom: calc(28px + var(--sab)); transform: translateX(-50%);
  z-index: 80; background: #1c2531; color: var(--text); border: 1px solid var(--border2);
  padding: 11px 18px; border-radius: 999px; font-size: 13.5px; font-weight: 700;
  box-shadow: var(--shadow); animation: toastin .2s ease; max-width: 88vw; text-align: center;
}
@keyframes toastin { from { transform: translate(-50%, 14px); opacity: 0; } to { transform: translate(-50%, 0); opacity: 1; } }

/* ---------- misc ---------- */
.empty { text-align: center; color: var(--faint); padding: 42px 20px; }
.empty .big { font-size: 34px; margin-bottom: 8px; opacity: .5; }
.empty .t { font-weight: 750; color: var(--muted); }
.empty .s { font-size: 13px; margin-top: 4px; }
.linkjob { color: var(--accent); font-weight: 700; font-family: var(--mono); font-size: 12.5px; }
.hr { border: none; border-top: 1px solid var(--border); margin: 16px 0; }
.mono { font-family: var(--mono); font-size: 12.5px; }
.muted { color: var(--muted); }
.bignum { font-size: 15px; font-weight: 800; }
.fadein { animation: fadein .18s ease; }
@media (min-width: 900px) {
  h1 { font-size: 32px; }
  .chipnav { display: none; }
  .filterbar { top: calc(var(--sat) + 64px); }
  .searchbox { top: calc(var(--sat) + 64px); }
}


/* ================= v2 polish (bottom nav, light theme, standard fixes) ================= */

/* bottom tab bar on phone — thumb reach; top chip nav takes over on desktop */
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 45;
  display: flex; gap: 2px;
  background: var(--glass);
  -webkit-backdrop-filter: saturate(180%) blur(18px);
  backdrop-filter: saturate(180%) blur(18px);
  border-top: 1px solid var(--border);
  padding: 6px 8px calc(8px + var(--sab));
}
.tabbar a {
  flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px;
  padding: 7px 0 5px; border-radius: 12px;
  font-size: 10.5px; font-weight: 750; letter-spacing: .05em; color: var(--faint);
  transition: color .12s ease;
}
.tabbar a svg { width: 22px; height: 22px; }
.tabbar a.active { color: var(--accent); }
.tabbar a:active { transform: scale(.94); }

@media (max-width: 899px) {
  .chipnav { display: none; }
  .tabbar { display: flex; }
  #view { padding-bottom: calc(150px + var(--sab)); }
  .fab { bottom: calc(86px + var(--sab)); right: 16px; }
  .filterbar { top: calc(var(--sat) + 58px); }
  .searchbox { top: calc(var(--sat) + 58px); }
}
@media (min-width: 900px) {
  .tabbar { display: none; }
  .chipnav { display: flex; }
  .fab { bottom: calc(24px + var(--sab)); }
}
.fab[hidden] { display: none !important; }

/* no horizontal page scroll, ever */
body { overflow-x: hidden; }

/* filter bar: selects size to content, stay on one scrollable row */
.filterbar select, .filterbar .fbtn, .filterbar input { width: auto; flex: none; }

/* card title clamps at 2 lines; last-log line = freshest truth */
.jobcard .title { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.lastlog {
  color: var(--muted); font-size: 12px; line-height: 1.4; margin: 2px 0 8px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.lastlog .lk { color: var(--faint); font-weight: 700; }

/* aging badges (Trello made useful): untouched 48h+ amber edge, 7d+ red */
.jobcard.aged1 { border-left: 3px solid var(--accent); }
.jobcard.aged2 { border-left: 3px solid var(--red); }

/* swimlanes: rows per operator, columns stay status */
.swim { grid-auto-flow: row; grid-template-columns: none; display: grid; gap: 12px; }
.swim .boardcols-inner { display: grid; grid-auto-flow: column; grid-auto-columns: min(78vw, 280px); gap: 10px; overflow-x: auto; padding-bottom: 6px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.swim .boardcols-inner::-webkit-scrollbar { display: none; }
.lanehead { display: flex; align-items: center; gap: 9px; padding: 2px 2px 6px; }
.lanehead .ln { font-weight: 800; font-size: 14px; }
.lanehead .lc { font-family: var(--mono); font-size: 11px; color: var(--faint); }

/* done column: recent window + show-all */
.showall { display: block; width: 100%; margin-top: 8px; text-align: center; color: var(--muted); font-size: 12.5px; font-weight: 700; background: var(--surface2); border: 1px solid var(--border); border-radius: 12px; padding: 9px; cursor: pointer; }

/* log: chronological read-forward; human notes visually distinct from system events */
.logline.is-note .body { background: var(--surface2); border-left: 3px solid var(--accent); border-radius: 0 10px 10px 0; padding: 8px 11px; margin-top: 5px; color: var(--text) !important; }
.logtoggle { cursor: pointer; border: 1px solid var(--border); background: var(--surface); color: var(--muted); border-radius: 9px; padding: 4px 9px; font-size: 11px; font-weight: 700; letter-spacing: .06em; }
.logtoggle.on { color: var(--accent); border-color: var(--accent); }
.jumplatest { cursor: pointer; color: var(--accent); font-size: 12px; font-weight: 800; background: none; border: none; padding: 4px 2px; }

/* tickets: queue grouping + composer reply/note toggle */
.tgroup { margin-top: 18px; }
.tgroup > h3 { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); font-weight: 750; margin: 0 0 8px 2px; }
.composer-toggle { display: flex; gap: 6px; margin-bottom: 8px; }
.composer-toggle button { flex: 1; border: 1px solid var(--border); background: var(--surface); color: var(--muted); border-radius: 10px; padding: 7px; font-size: 12.5px; font-weight: 750; cursor: pointer; }
.composer-toggle button.on { color: var(--accent); border-color: var(--accent); background: rgba(255,181,71,.08); }
.bubble.internal { border-left: 3px solid var(--accent); }
.bubble.internal .bwho { color: var(--accent); }

/* tracking rows: never overflow the card */
.nowitem { min-width: 0; }
.nowitem .what { min-width: 0; flex: 1; }
.nowitem .what a.t { min-width: 0; }
.nowitem .linkjob { white-space: nowrap; flex: none; }
.waititem .linkjob { white-space: nowrap; flex: none; }

/* crew avatars: proper fill + size everywhere */
.oprow .avatar { width: 42px; height: 42px; border-radius: 13px; font-size: 15px; }
.ophead .avatar { width: 58px; height: 58px; border-radius: 18px; font-size: 19px; }

/* ticket card: job chip is not a nested link */
.tjchip { color: var(--accent); font-weight: 700; font-family: var(--mono); font-size: 12.5px; }

/* quiet tickets in tracking */
.quietline { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--border); }
.quietline:last-child { border-bottom: none; }
.quietline .sil { margin-left: auto; font-family: var(--mono); font-size: 11.5px; color: var(--accent); font-weight: 700; white-space: nowrap; }

/* ids copyable on tap */
.copyable { cursor: copy; }

/* ---------- LIGHT THEME ---------- */
body.light {
  --bg: #f2f4f8; --bg2: #eaeef4; --surface: #ffffff; --surface2: #f1f4f9; --surface3: #e4e9f1;
  --border: #dbe1eb; --border2: #c2ccda;
  --text: #1b2330; --muted: #525f73; --faint: #7f8b9e;
  --accent: #a86a08; --accent-ink: #ffffff;
  --blue: #0069b5; --green: #0c7a43; --red: #c03333; --violet: #6d28d9; --cyan: #0e7490;
  --glass: rgba(242,244,248,.85);
  --shadow: 0 10px 30px rgba(30,40,60,.12);
}
body.light::before { opacity: .4; }
body.light .brand span { text-shadow: none; }
body.light .mscrim { background: rgba(25,32,44,.45); }
body.light #toast { background: #ffffff; color: var(--text); border-color: var(--border); box-shadow: var(--shadow); }
body.light .opdot { box-shadow: none; }
body.light .steps-mini { background: var(--surface3); }


/* ================= v3/v4 additions ================= */

/* quick-filter chips row */
.quickchips { display: flex; gap: 7px; overflow-x: auto; padding: 10px 0 4px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.quickchips::-webkit-scrollbar { display: none; }
.quickchips .fbtn { flex: none; border: 1px solid var(--border); background: var(--surface); color: var(--muted); border-radius: 999px; padding: 7px 13px; font-size: 12px; font-weight: 750; cursor: pointer; letter-spacing: .04em; white-space: nowrap; }
.quickchips .fbtn.on { color: var(--accent); border-color: var(--accent); background: rgba(255,181,71,.08); }

/* internal-note marker chip */
.intmark { color: var(--faint); border: 1px solid var(--border); padding: 0 5px; border-radius: 6px; font-size: 9.5px; font-weight: 800; letter-spacing: .08em; }

/* perf chips (Lab budget proof) */
.perfchip { color: var(--faint); }

/* ledger log nodes */
.logline .node.ledger { color: var(--cyan); border-color: var(--cyan); }

/* no stray focus rings on tap; keyboard users keep :focus-visible */
button:focus, a:focus, select:focus, summary:focus { outline: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* count chips are doors */
a.ccount { cursor: pointer; }
a.ccount:active { color: var(--accent); }

/* motion discipline: honour the OS reduced-motion setting */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ---------- light theme contrast fixes ---------- */
body.light { --faint: #64708a; --muted: #46536a; }
body.light .logline::before { background: var(--border2); }
body.light .btn.primary, body.light .fab { background: #b97a10; border-color: #b97a10; color: #fff; }
body.light .tabbar a.active { color: #8a5a00; }
body.light .quickchips .fbtn.on { color: #8a5a00; background: rgba(255,181,71,.15); }


/* synthetic-mode banner: in the flow under the bar, so it reserves its own space
   and never floats over a heading, a verdict or a card (S-05 / G-02) */
.modebanner {
  display: block; margin: 10px 12px 0; text-align: center;
  background: rgba(255,93,93,.16); border: 1px solid rgba(255,93,93,.45); color: var(--red);
  border-radius: 14px; padding: 8px 14px; font-size: 12px; font-weight: 800; letter-spacing: .04em;
}
.modebanner[hidden] { display: none !important; }

/* ids never wrap */
.jid, .linkjob, .tjchip { white-space: nowrap; }


/* ---------- third theme: NIGHTSHIFT (accent variant, pure token swap) ---------- */
body.nightshift {
  --bg: #07120f; --bg2: #0a1714; --surface: #0f1f1b; --surface2: #14291f; --surface3: #1a3527;
  --border: #1e3a2f; --border2: #2a5240;
  --text: #e7fff4; --muted: #8fb8a5; --faint: #5f8a77;
  --accent: #2dd4bf; --accent-ink: #04211c;
  --blue: #67e8f9; --green: #4ade80; --red: #ff6b6b; --violet: #c4b5fd; --cyan: #67e8f9;
  --glass: rgba(7,18,15,.82);
}
body.nightshift .opdot { box-shadow: 0 0 8px rgba(45,212,191,.7); }

/* ---------- density toggle (P3.2) ---------- */
body.compact { font-size: 14px; }
body.compact .card { padding: 10px 12px; }
body.compact .jobcard .title { font-size: 13.5px; margin: 4px 0 6px; }
body.compact h1 { font-size: 22px; }
body.compact .wrap { padding-top: 12px; }
body.compact .btn { padding: 8px 13px; font-size: 13px; }
body.compact .lastlog { margin: 2px 0 6px; font-size: 11.5px; }
body.compact .stat .n { font-size: 19px; }
body.compact #view { padding-bottom: calc(120px + var(--sab)); }


/* ---------- print stylesheet (P4.8): any view prints clean ---------- */
@media print {
  body { background: #fff !important; color: #000 !important; }
  body::before { display: none !important; }
  .topbar, .chipnav, .tabbar, .fab, .modebanner, .drawer, .scrim, .mscrim, #toast,
  .filterbar, .quickchips, .perfchip, .btn, .backbar { display: none !important; }
  .card { border: 1px solid #999 !important; box-shadow: none !important; background: #fff !important; break-inside: avoid; }
  .bcol { break-inside: avoid; }
  .boardcols { display: block !important; }
  .bcolhead { color: #000; }
  .pill { border: 1px solid #666 !important; color: #000 !important; background: #fff !important; }
  .jid, .linkjob, .mono { color: #000 !important; }
  .muted, .meta, .lastlog { color: #333 !important; }
  .wrap { padding: 0 !important; max-width: none; }
  #view { padding: 0 !important; }
}


/* ---------- Home + More grids ---------- */
.homegrid, .moregrid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (min-width: 700px) { .homegrid, .moregrid { grid-template-columns: repeat(3, 1fr); } }
.hcard, .morecard {
  display: block; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--r-lg); padding: 14px; transition: transform .12s ease, border-color .12s ease;
}
.hcard:active, .morecard:active { transform: scale(.97); border-color: var(--accent); }
.hic, .mic {
  width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center;
  background: var(--surface2); color: var(--accent); font-size: 17px; margin-bottom: 9px;
}
.ht, .mt { font-weight: 800; font-size: 14.5px; letter-spacing: -.01em; }
.hs, .ms { color: var(--muted); font-size: 12px; margin-top: 3px; line-height: 1.35; }
.morecard .mtop { display: flex; align-items: flex-start; justify-content: space-between; gap: 6px; }
.morecard .mic { margin-bottom: 8px; }
.homeTab { color: var(--accent); }
.tabbar a.homeTab svg { width: 26px; height: 26px; }
.tabbar a.homeTab.active svg { color: var(--accent); }


/* ---------- J-queue design passes ---------- */
@media (min-width: 900px) { .boardcols { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
@media (max-width: 899px) {
  .brand span { font-size: 12px; letter-spacing: .08em; }
  .topbar { gap: 4px; padding-left: 8px; padding-right: 8px; }
  .iconbtn { width: 34px; height: 34px; }
  .opchip { padding: 5px 8px 5px 7px; max-width: 108px; }
}
:root { --faint: #7a86a0; } /* small-caps labels ≥4.5:1 on --bg (J-019) */
.attachgrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 10px; }
.attthumb { position: relative; border-radius: 12px; overflow: hidden; border: 1px solid var(--border); background: var(--bg2); aspect-ratio: 1; }
.attthumb img { width: 100%; height: 100%; object-fit: cover; }
.attthumb.file { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 6px; text-align: center; }
.attthumb .af { font-size: 20px; color: var(--accent); }
.attthumb .an { font-size: 10.5px; font-weight: 700; margin-top: 4px; overflow: hidden; text-overflow: ellipsis; max-width: 100%; white-space: nowrap; }
.attthumb .as { font-size: 9.5px; color: var(--faint); }
.attdel { position: absolute; top: 4px; right: 4px; width: 22px; height: 22px; border-radius: 7px; border: none; background: rgba(10,13,19,.75); color: #fff; font-size: 11px; cursor: pointer; }
.crewchip { display: inline-flex; align-items: center; gap: 7px; background: var(--surface2); border: 1px solid var(--border); border-radius: 999px; padding: 5px 12px 5px 6px; font-weight: 700; font-size: 13px; }
.crewchip .avatar { width: 26px; height: 26px; }


/* J-026: owner chips inside cards are links to the work card */
.ownerlink { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; border-radius: 8px; padding: 1px 4px 1px 0; }
.ownerlink:hover .meta { color: var(--accent); text-decoration: underline; }
.ownerlink:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* J-019: every interactive thing shows a keyboard focus ring, including span-links and selects */
a:focus-visible, button:focus-visible, select:focus-visible, input:focus-visible, textarea:focus-visible,
summary:focus-visible, [role="link"]:focus-visible, [tabindex]:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
body.light a:focus-visible, body.light button:focus-visible { outline-color: #b45f00; }


/* C-07 / J-002: narrow-phone pass (320–360px) — nothing may force sideways scroll */
html, body { max-width: 100%; overflow-x: hidden; }
.card, .metabox, .jobcard .title, .bubble .btxt, .logline .body { overflow-wrap: anywhere; }
@media (max-width: 360px) {
  .wrap { padding-left: 10px; padding-right: 10px; }
  .pagehead { flex-wrap: wrap; align-items: flex-start; }
  .statrow { grid-template-columns: repeat(2, 1fr); }
  .metagrid { grid-template-columns: 1fr; }
  .oprow { flex-wrap: wrap; }
  .oprow .counts { margin-left: auto; }
  .boardcols { grid-auto-columns: 88vw; padding-left: 10px; padding-right: 10px; }
  .btn { padding: 9px 12px; }
  .filterbar { flex-wrap: wrap; }
  .filterbar select { min-width: 0; flex: 1 1 120px; }
}


/* bulk select (P4.1) */
.bulkbar { position: sticky; bottom: calc(10px + var(--sab)); z-index: 30; margin-top: 12px; padding: 12px 14px; border-radius: 16px; background: var(--surface3); border: 1px solid var(--accent); box-shadow: var(--shadow); }
.bulkbar[hidden] { display: none; }
a.jobcard.selectable { cursor: copy; }
a.jobcard.selected { outline: 2px solid var(--accent); outline-offset: -2px; background: rgba(255,181,71,.08); }


/* Inspector fixes: date inputs were unstyled white pills; rails clipped chips off-screen */
input[type="date"], input[type="number"] {
  background: var(--bg2); border: 1px solid var(--border); color: var(--text);
  border-radius: 13px; padding: 10px 12px; font-size: 15px; font-family: inherit; min-height: 44px;
  color-scheme: dark;
}
body.light input[type="date"], body.light input[type="number"] { color-scheme: light; }
input[type="date"]:not([value=""]) , input[type="date"] { min-width: 150px; }
@media (max-width: 899px) {
  .quickchips { flex-wrap: wrap; overflow-x: visible; }
  .filterbar { flex-wrap: wrap; overflow-x: visible; }
  .filterbar input[type="search"] { flex: 1 1 140px; width: auto; min-width: 0; }
}


/* L-05: last card must clear the tab bar and the FAB */
#view { padding-bottom: calc(110px + var(--sab)); }


/* Skills chips (and any bare .fbtn) were unstyled white native buttons */
.fbtn { border: 1px solid var(--border2); background: var(--surface); color: var(--muted); border-radius: 999px; padding: 7px 13px; font-size: 12.5px; font-weight: 750; cursor: pointer; letter-spacing: .03em; font-family: inherit; }
.fbtn.on { color: var(--accent); border-color: var(--accent); background: rgba(255,181,71,.1); }
#skillChips { display: flex; flex-wrap: wrap; gap: 7px; }
body.light .fbtn.on { color: #8a5a00; }
.lognum { font-family: var(--mono); font-size: 11px; color: var(--accent); font-weight: 750; }
button.pill#editTitle { background: var(--surface2); }

/* save-failed banner */
.savebanner { position: sticky; top: 0; z-index: 60; background: rgba(255,93,93,.14); border-bottom: 1px solid var(--red); color: var(--red); font-weight: 700; font-size: 13px; padding: 10px 14px; }
.savebanner a { color: var(--text); text-decoration: underline; }

/* agents page */
.tokenbox { font-family: var(--mono); font-size: 12px; word-break: break-all; background: var(--bg2); border: 1px dashed var(--border2); border-radius: 12px; padding: 10px 12px; color: var(--accent); }
.codebox { font-family: var(--mono); font-size: 11.5px; line-height: 1.5; white-space: pre-wrap; word-break: break-word; background: var(--bg2); border: 1px solid var(--border); border-radius: 12px; padding: 10px 12px; color: var(--muted); max-height: 260px; overflow: auto; }
.agentpill { font-size: 10px; letter-spacing: .1em; font-weight: 800; color: var(--cyan); border: 1px solid var(--cyan); border-radius: 6px; padding: 1px 6px; }


/* sheets: the page behind never scrolls; the sheet scrolls itself */
body:has(.mscrim) { overflow: hidden; }
.mcard { overscroll-behavior: contain; }
.codebox { max-height: 340px; }



/* Agent access: per-class grant checkboxes + passphrase-free numeric budgets */
.ckrow { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 4px 0 2px; }
.ckl { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 650; color: var(--text); padding: 7px 11px; border: 1px solid var(--border); border-radius: 11px; background: var(--surface); cursor: pointer; }
.ckl input { appearance: none; -webkit-appearance: none; width: 18px; height: 18px; margin: 0; border: 1px solid var(--border2); border-radius: 5px; background: var(--bg2); display: grid; place-items: center; cursor: pointer; }
.ckl input:checked { background: var(--accent); border-color: var(--accent); }
.ckl input:checked::after { content: ""; width: 5px; height: 9px; border: solid var(--accent-ink); border-width: 0 2px 2px 0; transform: rotate(45deg) translate(-1px, -1px); }
.ckl:has(input:checked) { border-color: var(--accent); }
body.light .ckl input:checked { background: #b97a10; border-color: #b97a10; }


/* filters restored from a previous visit: said, not a bare count chip (G-03) */
.restoredhint { display: block; margin: 0 2px 8px; font-size: 12px; font-weight: 700; color: var(--accent); letter-spacing: .01em; }
body.light .restoredhint { color: #8a5a00; }


/* FD-036: one operator status line on the work card — a view, not a diagnostics dump */
.statusline { display: flex; flex-wrap: wrap; gap: 8px 16px; font-size: 12.5px; color: var(--muted); line-height: 1.5; }
.statusline b { color: var(--faint); font-weight: 750; letter-spacing: .08em; text-transform: uppercase; font-size: 10px; margin-right: 5px; }
