/* GC Check-In — Gamer's Choice brand: black, white, logo blue (#50A2DA).
   Type: Inter (self-hosted). "GC Display" = Inter at heavier weights for caps titles and big numbers.
   Light/dark follow the device setting. Redesign 10/13 (v100). */

@font-face { font-family: 'Inter'; font-weight: 400; font-display: swap; src: url('fonts/inter-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Inter'; font-weight: 500; font-display: swap; src: url('fonts/inter-latin-500-normal.woff2') format('woff2'); }
@font-face { font-family: 'Inter'; font-weight: 600; font-display: swap; src: url('fonts/inter-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'Inter'; font-weight: 700; font-display: swap; src: url('fonts/inter-latin-700-normal.woff2') format('woff2'); }
@font-face { font-family: 'Inter'; font-weight: 800; font-display: swap; src: url('fonts/inter-latin-800-normal.woff2') format('woff2'); }
@font-face { font-family: 'GC Display'; font-weight: 400 500; font-display: swap; src: url('fonts/inter-latin-700-normal.woff2') format('woff2'); }
@font-face { font-family: 'GC Display'; font-weight: 600 900; font-display: swap; src: url('fonts/inter-latin-800-normal.woff2') format('woff2'); }

:root {
  color-scheme: light dark;
  --brand: #50A2DA;          /* logo blue — fills, rings, dots */
  --brand-ink: #1A6FB0;      /* blue that reads as text on white */
  --on-brand: #06121B;       /* text on a blue fill */
  --bg: #F4F5F7;
  --surface: #FFFFFF;
  --surface-2: #F1F2F4;
  --line: #E3E6EB;
  --ink: #0B0C0E;
  --muted: #5B6270;
  --faint: #8A909B;
  --solid: #0B0C0E;          /* black button */
  --on-solid: #FFFFFF;
  --success: #15803D; --success-bg: #E8F5EC; --ip: #6D28D9; --ip-bg: #F1EAFE;
  --warn: #9A5B00;    --warn-bg: #FFF3DD;
  --danger: #B42318;  --danger-bg: #FDECEA;
  --info-bg: #E6F0FA;
  --shadow: 0 1px 2px rgba(11,12,14,.05), 0 2px 10px rgba(11,12,14,.04);
  --shadow-lg: 0 12px 40px rgba(16,24,40,.18);
  --r: 18px; --r-sm: 12px;
  --display: 'GC Display', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}
@media (prefers-color-scheme: dark) {
:root:not([data-theme="light"]) {
    --brand-ink: #7BBDE8;
    --bg: #0A0A0B;
    --surface: #151517;
    --surface-2: #1D1D20;
    --line: #2A2A2F;
    --ink: #F4F4F5;
    --muted: #A1A1AA;
    --faint: #71717A;
    --solid: #F4F4F5;
    --on-solid: #0A0A0B;
    --success: #4ADE80; --success-bg: #12271A; --ip: #B79CFB; --ip-bg: #231A3A;
    --warn: #FBBF24;    --warn-bg: #2A2110;
    --danger: #F87171;  --danger-bg: #2C1414;
    --info-bg: #10222F;
    --shadow: 0 1px 2px rgba(0,0,0,.4);
    --shadow-lg: 0 12px 40px rgba(0,0,0,.6);
  }
}
:root[data-theme="dark"] {
    --brand-ink: #7BBDE8;
    --bg: #0A0A0B;
    --surface: #151517;
    --surface-2: #1D1D20;
    --line: #2A2A2F;
    --ink: #F4F4F5;
    --muted: #A1A1AA;
    --faint: #71717A;
    --solid: #F4F4F5;
    --on-solid: #0A0A0B;
    --success: #4ADE80; --success-bg: #12271A; --ip: #B79CFB; --ip-bg: #231A3A;
    --warn: #FBBF24;    --warn-bg: #2A2110;
    --danger: #F87171;  --danger-bg: #2C1414;
    --info-bg: #10222F;
    --shadow: 0 1px 2px rgba(0,0,0,.4);
    --shadow-lg: 0 12px 40px rgba(0,0,0,.6);
  }

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.45 var(--body); -webkit-font-smoothing: antialiased; }
body { min-height: 100vh; overscroll-behavior: none; }
[hidden]:not(.hdr-btn) { display: none !important; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }

/* ---------- header ---------- */
header { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 10px;
  padding: calc(10px + env(safe-area-inset-top)) 14px 10px; background: #000; color: #fff; }
#logo { width: 38px; height: 38px; border-radius: 50%; flex: 0 0 auto; display: block; box-shadow: 0 0 0 1.5px rgba(255,255,255,.28); }
#title { flex: 1; font-family: var(--display); font-weight: 600; font-size: 19px; letter-spacing: .03em; text-transform: uppercase;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hdr-btn { width: 40px; height: 40px; border: 0; border-radius: 12px; background: rgba(255,255,255,.08); color: #fff; font-size: 19px; cursor: pointer; flex: 0 0 auto; }
.hdr-btn:active { background: rgba(255,255,255,.18); }
.hdr-btn[hidden] { display: none; }
#netbar { background: var(--warn-bg); color: var(--warn); text-align: center; font-size: 13px; font-weight: 600; padding: 7px 12px; }

main { max-width: 720px; margin: 0 auto; padding: 18px 16px 48px; }
h2 { font-family: var(--display); font-weight: 500; font-size: 14px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin: 26px 2px 10px; }
h2:first-child { margin-top: 4px; }
.muted { color: var(--muted); } .small { font-size: 13px; } .center { text-align: center; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; margin-bottom: 12px; box-shadow: var(--shadow); }

/* ---------- sign-in ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.tile { display: flex; align-items: center; gap: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r);
  padding: 12px; font-size: 16px; font-weight: 600; color: var(--ink); text-align: left; cursor: pointer; min-height: 64px; box-shadow: var(--shadow);
  transition: transform .06s ease, border-color .15s ease; }
.tile:hover { border-color: var(--brand); }
.tile:active { transform: scale(.98); }
.avatar { width: 38px; height: 38px; border-radius: 50%; flex: 0 0 auto; display: grid; place-items: center;
  background: var(--info-bg); color: var(--brand-ink); font-family: var(--display); font-weight: 600; font-size: 15px; letter-spacing: .02em; }
.pin-who { display: flex; flex-direction: column; align-items: center; gap: 10px; margin: 8px 0 4px; }
.pin-who .avatar { width: 64px; height: 64px; font-size: 24px; }
.pinpad { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; max-width: 320px; margin: 0 auto; }
.pinpad button { font-family: var(--display); font-size: 28px; font-weight: 500; height: 68px; border-radius: 50%; border: 1px solid var(--line);
  background: var(--surface); color: var(--ink); cursor: pointer; box-shadow: var(--shadow); width: 68px; justify-self: center; }
.pinpad button:active { background: var(--surface-2); transform: scale(.96); }
.pinpad button.small { font-family: var(--body); font-size: 13px; font-weight: 600; color: var(--muted); box-shadow: none; border-color: transparent; background: transparent; }
.dots { display: flex; justify-content: center; gap: 16px; margin: 18px 0 24px; }
.dots i { width: 14px; height: 14px; border-radius: 50%; border: 2px solid var(--faint); display: block; transition: all .12s ease; }
.dots i.on { background: var(--brand); border-color: var(--brand); transform: scale(1.1); }

/* ---------- inputs ---------- */
input, select, textarea { width: 100%; font: inherit; font-size: 17px; padding: 13px 14px; border: 1px solid var(--line);
  border-radius: var(--r-sm); background: var(--surface); color: var(--ink); margin-bottom: 12px; }
input::placeholder, textarea::placeholder { color: var(--faint); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 25%, transparent); }
input[type=search] { background: var(--surface-2); border-color: transparent; }
label.field { display: block; font-size: 13px; font-weight: 600; color: var(--muted); margin: 0 0 6px 2px; }
label.check { display: flex; gap: 12px; align-items: flex-start; cursor: pointer; }
input[type=checkbox] { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--brand); flex: 0 0 auto; }

/* ---------- buttons (one system, 10/12 v97) ----------
   Roles:  .btn (main action, deep blue) · .green (start / complete) · .gray (secondary: white + border)
           .ghost (quiet: text only; .sm.ghost = small secondary) · .danger (delete / remove only)
   Sizes:  .big 60 px (floor actions — headline font, CAPS) · normal 46 px (= text boxes) · .sm 36 px (40 on phones) */
:root { --primary: #1F6FA8; --primary-hover: #185C8C; --on-primary: #fff; --btn-h: 46px; --btn-h-sm: 36px; --btn-h-lg: 60px; }
.btn { display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 2px; width: 100%; min-height: var(--btn-h);
  border: 1px solid transparent; border-radius: 12px; padding: 10px 18px; margin-bottom: 10px; cursor: pointer;
  font-family: var(--body); font-size: 16px; font-weight: 650; line-height: 1.2; letter-spacing: 0; text-transform: none;
  background: var(--primary); color: var(--on-primary); text-align: center; text-decoration: none;
  transition: background-color .15s ease, border-color .15s ease, color .15s ease, transform .06s ease; }
.btn:hover { background: var(--primary-hover); }
.btn:active { transform: scale(.98); } .btn:disabled { opacity: .45; cursor: default; transform: none; }
.btn .sub { display: block; font-family: var(--body); text-transform: none; letter-spacing: 0; font-size: 13px; font-weight: 500; opacity: .85; }
.btn.big { min-height: var(--btn-h-lg); padding: 14px 16px; border-radius: 16px; font-family: var(--display); font-size: 21px; font-weight: 600;
  letter-spacing: .05em; text-transform: uppercase; }
.btn.primary, .btn.blue, .btn.stop { background: var(--primary); color: var(--on-primary); }
.btn.primary:hover, .btn.blue:hover, .btn.stop:hover { background: var(--primary-hover); }
.btn.green { background: var(--success); color: #fff; }
.btn.green:hover { background: color-mix(in srgb, var(--success) 88%, #000); }
@media (prefers-color-scheme: dark) {
:root:not([data-theme="light"]) .btn.green { color: #06200F; }
:root:not([data-theme="light"]) { --primary: #2B7FBF; --primary-hover: #3A8ECD; }
}
:root[data-theme="dark"] .btn.green { color: #06200F; }
:root[data-theme="dark"] { --primary: #2B7FBF; --primary-hover: #3A8ECD; }
.btn.gray { background: var(--surface); color: var(--ink); border-color: var(--line); box-shadow: 0 1px 2px rgba(16,24,40,.05); }
.btn.gray:hover { background: var(--surface-2); }
.btn.ghost { background: transparent; color: var(--muted); border-color: transparent; }
.btn.ghost:hover { background: var(--surface-2); color: var(--ink); }
.btn.sm { display: inline-flex; flex-direction: row; width: auto; min-height: var(--btn-h-sm); padding: 6px 14px; margin: 0 6px 6px 0;
  font-size: 14px; border-radius: 10px; }
.btn.sm.ghost { background: var(--surface); color: var(--ink); border-color: var(--line); }   /* small secondary: Copy, Edit times, Manage… */
.btn.sm.ghost:hover { background: var(--surface-2); }
.row { display: flex; gap: 10px; } .row > * { flex: 1; min-width: 0; }
.link { background: none; border: 0; color: var(--brand-ink); font-weight: 600; padding: 12px; cursor: pointer; display: block; margin: 0 auto; }

/* ---------- associate home ---------- */
.task-line { font-family: var(--display); font-weight: 600; font-size: 20px; letter-spacing: .02em; text-transform: uppercase; color: var(--ink); }
.label { color: var(--muted); font-size: 14px; margin-top: 2px; }
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; letter-spacing: .02em; }
.badge.on { background: var(--success-bg); color: var(--success); }
.badge.on::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: currentColor; animation: pulse 1.6s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .35; } }
.badge.idle { background: var(--surface-2); color: var(--muted); }
.badge.warn { background: var(--warn-bg); color: var(--warn); } .badge.bad { background: var(--danger-bg); color: var(--danger); }
.active-card { border-top: 4px solid var(--brand); }
.timer { font-family: var(--display); font-size: 64px; font-weight: 500; line-height: 1.05; color: var(--ink); text-align: center; font-variant-numeric: tabular-nums; margin: 12px 0 2px; letter-spacing: .01em; }
.scanbox { display: grid; grid-template-columns: 1fr 1fr; background: var(--surface-2); border-radius: var(--r-sm); margin: 16px 0 10px; overflow: hidden; }
.scanbox > div { padding: 12px 8px; text-align: center; }
.scanbox > div + div { border-left: 1px solid var(--line); }
.scanbox b { display: block; font-family: var(--display); font-weight: 600; font-size: 32px; color: var(--ink); line-height: 1.1; }
.scanbox span { display: block; font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--faint); margin-top: 2px; }
.scan-flash { animation: flash .4s ease-out; } @keyframes flash { from { background: color-mix(in srgb, var(--brand) 35%, var(--surface-2)); } }
.scan-dup { animation: dup .6s ease-out; } @keyframes dup { from { background: color-mix(in srgb, var(--danger) 30%, var(--surface-2)); } }
.empty { text-align: center; padding: 34px 16px; }
.empty .ico { width: 56px; height: 56px; border-radius: 50%; margin: 0 auto 12px; display: grid; place-items: center; background: var(--surface-2); color: var(--faint); font-size: 26px; }

/* ---------- count stepper ---------- */
.stepper { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.stepper button { width: 64px; height: 64px; font-size: 28px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; flex: 0 0 auto; }
.stepper button:active { background: var(--surface-2); }
.stepper input { margin: 0; text-align: center; font-family: var(--display); font-size: 36px; font-weight: 600; height: 64px; border-radius: 18px; }

/* ---------- messages ---------- */
.err { background: var(--danger-bg); color: var(--danger); padding: 12px 14px; border-radius: var(--r-sm); font-size: 14px; margin-bottom: 12px; font-weight: 600; }
.ok { background: var(--success-bg); color: var(--success); padding: 12px 14px; border-radius: var(--r-sm); font-size: 14px; margin-bottom: 12px; font-weight: 600; }
.toast { position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 30;
  background: var(--solid); color: var(--on-solid); padding: 12px 18px; border-radius: 999px; font-weight: 600; font-size: 14px; max-width: 92vw;
  box-shadow: var(--shadow-lg); animation: rise .2s ease-out; }
@keyframes rise { from { opacity: 0; transform: translate(-50%, 8px); } }

/* ---------- bottom sheet ---------- */
.sheet { position: fixed; inset: 0; z-index: 20; background: rgba(0,0,0,.5); display: flex; align-items: flex-end; justify-content: center; animation: fade .15s ease-out; }
@keyframes fade { from { opacity: 0; } }
.sheet .panel { background: var(--bg); width: 100%; max-width: 560px; max-height: 92vh; overflow: auto; border-radius: 24px 24px 0 0;
  padding: 10px 18px calc(20px + env(safe-area-inset-bottom)); box-shadow: var(--shadow-lg); animation: up .22s cubic-bezier(.2,.8,.2,1); }
.sheet .panel::before { content: ''; display: block; width: 40px; height: 5px; border-radius: 3px; background: var(--line); margin: 0 auto 14px; }
@keyframes up { from { transform: translateY(30px); opacity: .6; } }
@media (min-width: 700px) { .sheet { align-items: center; } .sheet .panel { border-radius: 24px; } .sheet .panel::before { display: none; } }

/* ---------- supervisor ---------- */
.tabs { display: flex; gap: 4px; overflow-x: auto; margin-bottom: 16px; padding: 4px; background: var(--surface-2); border-radius: 14px; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button { flex: 1 0 auto; border: 0; background: transparent; color: var(--muted); padding: 9px 14px; border-radius: 10px; font-size: 14px; font-weight: 600; cursor: pointer; white-space: nowrap; }
.tabs button.on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.stat-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 6px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 12px; box-shadow: var(--shadow); }
.stat b { display: block; font-family: var(--display); font-size: 28px; font-weight: 600; line-height: 1.1; }
.stat span { font-size: 12px; color: var(--muted); }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; color: var(--faint); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; padding: 6px 8px; border-bottom: 1px solid var(--line); }
td { padding: 11px 8px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
.people { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px; border-radius: 999px; background: var(--surface-2); font-size: 13px; font-weight: 600; color: var(--ink); border: 1px solid var(--line); }
.chip.done { background: var(--info-bg); color: var(--brand-ink); border-color: transparent; }
.chip.work { background: var(--success-bg); color: var(--success); border-color: transparent; }
.chip button { border: 0; background: none; color: var(--faint); font-size: 16px; line-height: 1; padding: 0 0 0 2px; cursor: pointer; }

.spinner { border: 3px solid var(--line); border-top-color: var(--brand); border-radius: 50%; width: 32px; height: 32px; animation: spin .8s linear infinite; margin: 70px auto; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { *, *::before { animation: none !important; transition: none !important; } }

/* ---------- reports ---------- */
:root { --chart: #2E86C8; }
@media (prefers-color-scheme: dark) {
:root:not([data-theme="light"]) { --chart: #4A9BD4; }
}
:root[data-theme="dark"] { --chart: #4A9BD4; }
.seg { display: inline-flex; gap: 4px; padding: 4px; background: var(--surface-2); border-radius: 12px; margin-bottom: 12px; }
.seg button { border: 0; background: transparent; color: var(--muted); padding: 7px 12px; border-radius: 9px; font-size: 13px; font-weight: 600; cursor: pointer; }
.seg button.on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(124px, 1fr)); gap: 10px; margin-bottom: 12px; }
.kpi { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 14px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 4px; min-height: 108px; }
.kpi-l { font-size: 12px; color: var(--muted); font-weight: 600; }
.kpi b { font-size: 26px; font-weight: 700; letter-spacing: -.01em; line-height: 1.15; }
.delta { font-size: 12px; font-weight: 600; color: var(--faint); margin-top: auto; }
.delta.good { color: var(--success); } .delta.bad { color: var(--danger); }
.note { background: var(--info-bg); color: var(--ink); border-radius: var(--r-sm); padding: 12px 14px; font-size: 13px; margin-bottom: 8px; }
.charts { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 12px; }
.chart-card { margin: 0; padding: 14px 14px 8px; }
.chart-t { font-weight: 700; font-size: 15px; } .chart-s { font-size: 12px; color: var(--muted); }
.chart { position: relative; margin-top: 8px; min-height: 168px; }
.chart svg { display: block; overflow: visible; }
.chart .grid { stroke: var(--line); stroke-width: 1; }
.chart .axis { fill: var(--faint); font-size: 11px; }
.chart .val { fill: var(--ink); font-size: 12px; font-weight: 700; }
.chart .ln { fill: none; stroke: var(--chart); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.chart .dot { fill: var(--chart); stroke: var(--surface); stroke-width: 2; transition: r .1s; }
.chart .dot.on { r: 6; }
.chart .hit { fill: transparent; cursor: crosshair; }
.chart-empty { position: absolute; inset: 0; display: grid; place-items: center; color: var(--faint); font-size: 13px; }
#bChan .chart-empty, #bStage .chart-empty, #obCar .chart-empty, #obCh .chart-empty, #obHr .chart-empty { position: static; padding: 20px 0; }
.hb { display: grid; grid-template-columns: 112px 1fr; gap: 10px; align-items: center; padding: 5px 0; cursor: default; }
.hb-l { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hb-t { display: flex; align-items: center; gap: 8px; min-width: 0; }
.hb-b { height: 14px; background: var(--chart); border-radius: 0 4px 4px 0; flex: 0 0 auto; }
.hb-v { font-size: 12px; font-weight: 700; white-space: nowrap; color: var(--ink); }
.hb:hover .hb-b { filter: brightness(1.12); }
th.num, td.num { text-align: right; font-variant-numeric: tabular-nums; }
th[colspan] { text-align: center; }
.tip { position: fixed; z-index: 40; pointer-events: none; background: var(--solid); color: var(--on-solid); font-size: 12px; line-height: 1.45;
  padding: 8px 10px; border-radius: 10px; box-shadow: var(--shadow-lg); max-width: 240px; }

/* ---------- floor: channel chips, batch rows ---------- */
.chips { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 4px; margin-bottom: 8px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chips button { flex: 0 0 auto; border: 1px solid var(--line); background: var(--surface); color: var(--ink); padding: 7px 12px; border-radius: 999px; font-size: 13px; font-weight: 600; cursor: pointer; }
.chips button span { color: var(--faint); font-weight: 700; margin-left: 2px; }
.chips button.on { background: var(--info-bg); color: var(--brand-ink); border-color: var(--primary, #1F6FA8); box-shadow: inset 0 0 0 1px var(--primary, #1F6FA8); }
.chips button.on span { color: inherit; opacity: .8; }
.chips button:not(.on):hover, .chipbtn:not(.on):hover { background: var(--surface-2); }

.batch { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); margin-bottom: 8px; box-shadow: var(--shadow); overflow: hidden; }
.batch.open { border-color: var(--brand); }

.stage-block { padding: 12px 0; } .stage-block + .stage-block { border-top: 1px solid var(--line); }
.stage-h { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.stage-block select, .stage-block input { margin: 0; background: var(--surface); }
.stag { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 11px; font-weight: 700; white-space: nowrap; }
.st-np { background: var(--surface-2); color: var(--muted); border: 1px solid var(--line); }
.st-pr { background: var(--info-bg); color: var(--brand-ink); }
.st-ip { background: var(--ip-bg); color: var(--ip); }
.st-oh { background: var(--warn-bg); color: var(--warn); }
.st-rn { background: var(--danger-bg); color: var(--danger); }
.st-done { background: var(--surface-2); color: var(--faint); }
.pchip { display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); font-size: 13px; font-weight: 600; }
.pchip i { width: 8px; height: 8px; border-radius: 50%; background: var(--faint); flex: 0 0 auto; }
.pchip em { font-style: normal; font-weight: 500; font-size: 12px; color: var(--muted); }
.pchip button { border: 0; background: none; color: var(--faint); font-size: 16px; line-height: 1; padding: 0 0 0 2px; cursor: pointer; }
.ps-working i { background: var(--success); } .ps-paused i { background: var(--warn); } .ps-done i { background: var(--brand); }
.ps-working em { color: var(--success); } .ps-paused em { color: var(--warn); }

/* ---------- people: day bar, board, timelines, feed ---------- */
.daybar { display: flex; gap: 6px; align-items: center; margin-bottom: 12px; }
.daybar input { margin: 0; max-width: 190px; padding: 9px 12px; font-size: 15px; }
.daybar .btn.sm { margin: 0; min-width: 40px; font-size: 18px; padding: 7px 10px; }
.daybar .btn.sm.ghost { font-size: 13px; }
.stat-row.four { grid-template-columns: repeat(4, 1fr); }
.pboard { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 10px; }
.pcard { display: block; width: 100%; text-align: left; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px; box-shadow: var(--shadow); cursor: pointer; }
.pcard:hover { border-color: var(--brand); }
.pcard-h { display: flex; gap: 10px; align-items: center; }
.pcard-n { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.pcard-hrs { font-family: var(--display); font-weight: 600; font-size: 16px; color: var(--muted); }
.pcard-l { font-size: 12px; color: var(--muted); margin: 8px 0 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pstat { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; color: var(--muted); }
.pstat i { width: 8px; height: 8px; border-radius: 50%; background: var(--line); }
.pstat.ps-working { color: var(--success); } .pstat.ps-working i { background: var(--success); animation: pulse 1.6s ease-in-out infinite; }
.pstat.ps-paused { color: var(--warn); } .pstat.ps-paused i { background: var(--warn); }
.pstat.ps-idle i { background: var(--faint); }
.tl { position: relative; height: 10px; background: var(--surface-2); border-radius: 5px; margin-top: 10px; overflow: hidden; }
.tl.big { height: 26px; border-radius: 8px; margin-top: 14px; }
.tl-break { position: absolute; top: 0; bottom: 0; background: repeating-linear-gradient(135deg, transparent 0 3px, var(--line) 3px 5px); }
.tl-b { position: absolute; top: 0; bottom: 0; background: var(--chart); border-radius: 3px; box-shadow: 0 0 0 1px var(--surface-2); }
.tl-b.fl { background: var(--warn); }
.tl-b.live { background: var(--success); }
.tl-ax { position: relative; height: 18px; margin-top: 4px; }
.tl-ax span { position: absolute; transform: translateX(-50%); font-size: 11px; color: var(--faint); }
.tl-key { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--muted); margin: 6px 0 4px; }
.tl-key i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
.k-w { background: var(--chart); } .k-f { background: var(--warn); } .k-b { background: repeating-linear-gradient(135deg, var(--surface-2) 0 3px, var(--line) 3px 5px); border: 1px solid var(--line); }
.feed { padding: 4px 14px; }
.ev { display: grid; grid-template-columns: 74px 96px 1fr; gap: 10px; align-items: start; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.ev:last-child { border-bottom: 0; }
.ev-t { white-space: nowrap; font-variant-numeric: tabular-nums; font-size: 13px; font-weight: 600; color: var(--muted); }
.evtype { justify-self: start; padding: 2px 8px; border-radius: 999px; font-size: 11px; font-weight: 700; background: var(--surface-2); color: var(--muted); white-space: nowrap; }
.ev-started, .ev-resumed { background: var(--success-bg); color: var(--success); }
.ev-paused { background: var(--warn-bg); color: var(--warn); }
.ev-completed { background: var(--info-bg); color: var(--brand-ink); }
.ev-closed { background: var(--danger-bg); color: var(--danger); }
@media (max-width: 420px) { .ev { grid-template-columns: 74px 1fr; } .ev .ev-m { grid-column: 1 / -1; } .stat-row.four .stat b { font-size: 22px; } }
.away { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 12px; font-size: 13px; color: var(--muted); }
.away b { width: 100%; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--faint); margin-bottom: 2px; }
.away span { padding: 4px 10px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--line); }
.panel .stat b { font-size: 22px; }

/* ---------- weekly trends tables ---------- */
.tt { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); margin-bottom: 12px; box-shadow: var(--shadow); }
.tt summary { cursor: pointer; padding: 12px 14px; font-weight: 700; font-size: 15px; list-style: none; display: flex; gap: 8px; align-items: baseline; }
.tt summary::-webkit-details-marker { display: none; }
.tt summary::before { content: '▸'; color: var(--faint); font-size: 12px; transition: transform .15s; }
.tt[open] summary::before { transform: rotate(90deg); }
.tt summary span { font-weight: 500; font-size: 12px; color: var(--muted); }
.tt-wrap { overflow-x: auto; border-top: 1px solid var(--line); max-height: 520px; overflow-y: auto; }
table.trend { font-size: 13px; border-collapse: separate; border-spacing: 0; min-width: 100%; }
table.trend th, table.trend td { padding: 7px 10px; white-space: nowrap; border-bottom: 1px solid var(--line); background: var(--surface); }
table.trend thead th { position: sticky; top: 0; z-index: 2; background: var(--surface-2); }
table.trend thead tr:nth-child(2) th { top: 31px; }
table.trend .stick { position: sticky; left: 0; z-index: 1; border-right: 1px solid var(--line); }
table.trend thead .stick { z-index: 3; }
table.trend td.dl { color: var(--faint); font-size: 12px; }
table.trend td.up { background: var(--success-bg); color: var(--success); font-weight: 600; }
table.trend td.down { background: var(--danger-bg); color: var(--danger); font-weight: 600; }
table.trend sup { color: var(--brand-ink); font-size: 8px; margin-left: 2px; }

/* ---------- floor table + batches ---------- */
.h2row { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin: 26px 2px 8px; }
.h2row h2 { margin: 0; } .h2row .seg { margin: 0; }
.ft-card { padding: 0; overflow: hidden; }

  

.filters .row > div { flex: 1; min-width: 0; }
.filters input, .filters select { padding: 10px 12px; font-size: 15px; }
th.sortable { cursor: pointer; user-select: none; }
th.sortable:hover { color: var(--ink); }
table.btable td.wrap { white-space: normal; min-width: 220px; max-width: 360px; }
body.wide main { max-width: 1240px; }
 

/* ---------- floor compact view ---------- */

 
.compact { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); padding: 4px 8px 8px; }
.crow { display: grid; grid-template-columns: minmax(0, 1.3fr) repeat(var(--n, 3), minmax(0, 1fr)); gap: 4px; align-items: stretch; padding: 2px 0; }
.chead { position: sticky; top: 60px; z-index: 2; background: var(--surface); padding: 6px 0 4px; }
.chead span { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--faint); text-align: center; }
.cdate { display: flex; justify-content: space-between; align-items: baseline; font-family: var(--display); font-weight: 600; font-size: 13px; letter-spacing: .05em;
  text-transform: uppercase; padding: 10px 2px 4px; border-top: 1px solid var(--line); margin-top: 4px; }
.cdate:first-of-type { border-top: 0; }
.cdate span { font-family: var(--body); text-transform: none; letter-spacing: 0; font-size: 11px; color: var(--faint); font-weight: 600; }
.clabel { font-size: 11px; line-height: 1.25; align-self: center; padding-right: 4px; color: var(--muted); min-width: 0; }
.clabel b, .clabel span { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.clabel b { color: var(--ink); font-weight: 700; font-size: 12px; }
.stile { display: flex; flex-direction: column; justify-content: space-between; gap: 2px; min-height: 40px; padding: 4px 6px; border-radius: 7px; border: 0;
  border-left: 3px solid var(--faint); text-align: left; cursor: pointer; color: var(--ink); font: inherit; min-width: 0; }
.stile:hover { filter: brightness(.96); } .stile:active { transform: scale(.97); }
.stile.empty { background: transparent; border: 1px dashed var(--line); cursor: default; }

.t-ppl { display: flex; flex-wrap: wrap; gap: 2px; min-height: 13px; }
.ini { font-size: 9px; font-weight: 700; line-height: 13px; padding: 0 3px; border-radius: 3px; background: color-mix(in srgb, var(--surface) 70%, transparent); }
.ini.w { background: var(--success); color: #fff; } .ini.p { background: var(--warn); color: #fff; } .ini.d { color: var(--success); background: var(--success-bg); }
@media (prefers-color-scheme: dark) {
:root:not([data-theme="light"]) .ini.w, :root:not([data-theme="light"]) .ini.p { color: #0A0A0B; }
}
:root[data-theme="dark"] .ini.w, :root[data-theme="dark"] .ini.p { color: #0A0A0B; }
.t-ppl .none { font-size: 10px; opacity: .5; }
/* status fills: tinted surface + solid left edge, so tiles read in light and dark */
.stile.st-np { background: var(--surface-2); border-left-color: var(--faint); }
.stile.st-pr { background: color-mix(in srgb, var(--brand) 22%, var(--surface)); border-left-color: var(--brand); }
.stile.st-ip { background: color-mix(in srgb, var(--ip) 18%, var(--surface)); border-left-color: var(--ip); }
.stile.st-oh { background: color-mix(in srgb, var(--warn) 26%, var(--surface)); border-left-color: var(--warn); }
.stile.st-rn { background: color-mix(in srgb, var(--danger) 22%, var(--surface)); border-left-color: var(--danger); }
.stile.st-done { background: var(--surface); border-left-color: var(--line); opacity: .6; }

@media (min-width: 900px) { .crow { grid-template-columns: minmax(0, 1.6fr) repeat(var(--n, 3), minmax(0, 1fr)); gap: 6px; } .stile { min-height: 44px; } .clabel { font-size: 13px; } }

/* compact v2: status column, full names, fitted columns */

.cscroll { overflow-x: auto; }
.crow { grid-template-columns: 112px minmax(130px, 190px) repeat(var(--n, 3), minmax(128px, 172px)) !important; justify-content: start; width: max-content; min-width: 100%; }
.chead span { text-align: left; padding-left: 2px; }
.cstat { display: flex; align-items: center; gap: 6px; align-self: stretch; padding: 4px 8px; border-radius: 7px; font-size: 11px; font-weight: 700; line-height: 1.2; }
.cstat i { width: 8px; height: 8px; border-radius: 50%; background: currentColor; flex: 0 0 auto; }
.cstat.st-np { border: 1px solid var(--line); }
.cstat.st-done { background: var(--surface-2); color: var(--muted); }
.cdate { width: 100%; }
.stile { justify-content: flex-start; gap: 3px; padding: 5px 7px; }

.ini { font-size: 11px; line-height: 16px; padding: 0 5px; font-weight: 600; }
.t-ppl { gap: 3px; margin-top: 2px; }
.t-ppl .none { font-size: 10px; opacity: .55; }
.chead { position: static !important; }
.narrow-only { display: none !important; }
@media (max-width: 700px) {
  .wide-only { display: none !important; }
  .narrow-only { display: inline-flex !important; margin-top: 4px; align-self: flex-start; padding: 2px 7px; font-size: 10px; }
  .crow { grid-template-columns: 132px repeat(var(--n, 3), minmax(112px, 140px)) !important; }
  .crow > .clabel { position: sticky; left: 0; z-index: 1; background: var(--surface); align-self: stretch; display: flex; flex-direction: column; justify-content: center; }
  .chead > span:nth-child(2) { position: sticky; left: 0; z-index: 1; background: var(--surface); }
}
@media (max-width: 700px) { .h2row { flex-wrap: wrap; }  }

/* ---------- floor v3: single grid ---------- */
.crow { grid-template-columns: 116px minmax(140px, 210px) 64px repeat(var(--n, 3), minmax(140px, 190px)) !important; }
.chead .num, .corders { text-align: right; padding-right: 6px; }
.corders { align-self: center; font-family: var(--display); font-weight: 600; font-size: 17px; font-variant-numeric: tabular-nums; }
.stile { justify-content: flex-start; gap: 4px; padding: 6px 8px; min-height: 48px; }
.t-st { font-size: 11px; font-weight: 700; }
.t-ppl { display: flex; flex-direction: column; align-items: flex-start; gap: 3px; }
.ini { font-size: 12px; line-height: 17px; padding: 0 6px; border-radius: 4px; font-weight: 600; white-space: nowrap; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.assign { font-size: 12px; font-weight: 700; color: var(--brand-ink); }
.stile.unassigned { box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--brand) 55%, transparent); }
.cdate { display: flex; gap: 10px; align-items: baseline; justify-content: flex-start; }
.cdate b { font-weight: 600; }
.cdate.old1 b { color: var(--warn); } .cdate.old2 b { color: var(--danger); }
.cdate.old1 span, .cdate.old2 span { font-weight: 700; }
.cdate.old1 span { color: var(--warn); } .cdate.old2 span { color: var(--danger); }
.chips.small-chips button { padding: 5px 10px; font-size: 12px; }
.chips button.warnchip:not(.on) { border-color: var(--warn); color: var(--warn); }
.h2row .btn.sm { margin: 0; }
@media (max-width: 700px) {
  .crow { grid-template-columns: 128px 48px repeat(var(--n, 3), minmax(120px, 150px)) !important; }
  .corders { font-size: 15px; }
}
/* add-batches sheet */
.brow { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 10px 12px 4px; margin-bottom: 10px; }
.brow-h { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; font-size: 13px; }
.brow select, .brow input { margin-bottom: 8px; padding: 10px 12px; font-size: 15px; }
.brow-st { display: flex; gap: 14px; flex-wrap: wrap; font-size: 14px; padding: 2px 0 8px; }
.brow-st label { display: inline-flex; gap: 6px; align-items: center; }
.brow-st input { margin: 0; }
/* completed stages stay visible: muted, not faded */
.stile.st-done { opacity: 1; background: var(--surface-2); border-left-color: var(--success); }
.stile.st-done .t-st { color: var(--success); }
.stile.st-done .ini { opacity: .75; }
.cstat.st-done { background: var(--success-bg); color: var(--success); border: 0; }
button.cstat { border: 0; cursor: pointer; font: inherit; font-size: 11px; font-weight: 700; text-align: left; }
button.cstat:hover { filter: brightness(.96); box-shadow: inset 0 0 0 1.5px currentColor; }
.cedit { margin-left: auto; opacity: .6; font-size: 10px; }
.statusgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 12px; }
.stag-btn { border: 0; border-radius: 12px; padding: 14px 10px; font: inherit; font-weight: 700; font-size: 14px; cursor: pointer; text-align: center; }
.stag-btn.st-np { background: var(--surface-2); color: var(--muted); border: 1px solid var(--line); }
.stag-btn.st-done { background: var(--success-bg); color: var(--success); }
.stag-btn.on { box-shadow: inset 0 0 0 2px currentColor; }
.typebc { display: flex; gap: 8px; margin-top: 8px; }
.typebc input { flex: 1; margin: 0; font-variant-numeric: tabular-nums; letter-spacing: .02em; }
.typebc .btn { flex: 0 0 auto; margin: 0; }
.pinpad button.pressed { background: var(--brand); color: #fff; }
.delzone { margin-top: 14px; padding-top: 10px; border-top: 1px solid var(--line); text-align: center; }
.link.danger { color: var(--danger); }
.btn.danger { background: var(--danger); color: #fff; border-color: var(--danger); }
.warnbox { background: var(--danger-bg); border: 1px solid color-mix(in srgb, var(--danger) 35%, transparent); text-align: left; padding: 12px 14px; margin: 0; }
.warnbox .row { margin-top: 10px; } .warnbox .btn { margin: 0; }
table.trend tr.tot td { background: var(--surface-2); border-top: 1px solid var(--line); }
table.trend tr.tot td.stick { background: var(--surface-2); }
.ttimes td { white-space: nowrap; } .ttimes td:nth-child(2) { white-space: normal; min-width: 200px; }
.ttimes .pstat { font-size: 11px; }
.rtop { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; align-items: center; margin-bottom: 4px; }
.rtop .seg { margin-bottom: 8px; }
.tfilter { display: flex; gap: 12px; align-items: center; margin-bottom: 10px; flex-wrap: wrap; }
.tfilter select { flex: 0 1 260px; margin: 0; }
.tfilter .check { display: flex; gap: 6px; align-items: center; margin: 0; }
.langseg { margin: 0 0 8px; } .langseg button { padding: 6px 12px; }
.panel .langseg { display: flex; margin-bottom: 14px; } .panel .langseg button { flex: 1; }

/* ---------- Live tab ---------- */
:root { --s1: #2a78d6; --s2: #eb6834; --s3: #1baf7a; --s4: #eda100;
        --st-good: #0ca30c; --st-warn: #fab219; --st-crit: #d03b3b; }
@media (prefers-color-scheme: dark) {
:root:not([data-theme="light"]) { --s1: #3987e5; --s2: #d95926; --s3: #199e70; --s4: #c98500; }
}
:root[data-theme="dark"] { --s1: #3987e5; --s2: #d95926; --s3: #199e70; --s4: #c98500; }
.lvbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 8px; }
.lvbar .seg, .lvbar .daybar { margin: 0; }
.lvbadge { margin-left: auto; font-size: 12px; font-weight: 600; color: var(--muted); display: inline-flex; align-items: center; gap: 6px; }
.lvbadge::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--faint); }
.lvbadge.on { color: var(--success); }
.lvbadge.on::before { background: var(--st-good); animation: lvpulse 2s infinite; }
@keyframes lvpulse { 0%,100% { box-shadow: 0 0 0 0 rgba(12,163,12,.5); } 50% { box-shadow: 0 0 0 5px rgba(12,163,12,0); } }

.lvlines { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center; margin-bottom: 8px; font-size: 13px; }
.lvchk { display: inline-flex; gap: 6px; align-items: center; cursor: pointer; color: var(--muted); }
.lvchk input { width: 16px; height: 16px; margin: 0; accent-color: var(--brand); }
.lvcard { padding: 10px 8px 6px; transition: opacity .2s; }
.lvcard.loading { opacity: .55; }
.lvchart { width: 100%; touch-action: pan-y; }
.lvsvg { display: block; user-select: none; }
.lvsvg .grid { stroke: var(--line); stroke-width: 1; }
.lvsvg .axis { fill: var(--faint); font-size: 11px; }

.lvsvg .lvlunch { fill: var(--surface-2); }
.lvsvg .lvline { fill: none; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.lvsvg .lvline.ink { stroke: var(--ink); stroke-width: 1.5; }
.lvsvg .lvline.s1 { stroke: var(--s1); }
.lvsvg .lvline.typ { stroke: var(--faint); stroke-dasharray: 4 4; stroke-width: 1.5; }
.lvsvg .lvline.std { stroke: var(--muted); stroke-dasharray: 2 3; stroke-width: 1.5; }
.lvsvg .lvarea { stroke: var(--surface); stroke-width: 1; }
.lvsvg .lvarea.soft { fill-opacity: .16; stroke: none; }
.lvsvg .lvarea.s1, .lvsvg rect.s1 { fill: var(--s1); } .lvsvg .lvarea.s2, .lvsvg rect.s2 { fill: var(--s2); }
.lvsvg .lvarea.s3, .lvsvg rect.s3 { fill: var(--s3); } .lvsvg .lvarea.s4, .lvsvg rect.s4 { fill: var(--s4); }
.lvsvg .lvev circle { fill: var(--surface); stroke: var(--muted); stroke-width: 1.5; }
.lvsvg .lvev text { fill: var(--ink); font-size: 9px; font-weight: 700; pointer-events: none; }
.lvsvg .lvev { cursor: default; }
.lvsvg .lvev.ev-issue circle { stroke: var(--warn); } .lvsvg .lvev.ev-flag circle { stroke: var(--danger); }
.lvsvg .lvnow { stroke: var(--brand); stroke-width: 1.5; stroke-dasharray: 3 3; }
.lvsvg .lvcross { stroke: var(--ink); stroke-width: 1; opacity: .5; pointer-events: none; }
.lvsvg .lvsel { fill: var(--brand); fill-opacity: .15; stroke: var(--brand); pointer-events: none; }
.lvsvg .hit { fill: transparent; cursor: crosshair; }
.lvh.green { fill: var(--st-good); background: var(--st-good); } .lvh.amber { fill: var(--st-warn); background: var(--st-warn); } .lvh.red { fill: var(--st-crit); background: var(--st-crit); }
.lvkey { display: flex; flex-wrap: wrap; gap: 14px; font-size: 12px; color: var(--muted); padding: 2px 6px 4px 46px; }
.lvkey span { display: inline-flex; align-items: center; gap: 5px; } .lvkey i { width: 12px; height: 10px; border-radius: 2px; display: inline-block; }
.lvtt { min-width: 190px; } .lvtt .muted { color: inherit; opacity: .7; }
.lvtr { display: flex; align-items: center; gap: 6px; } .lvtr b { font-variant-numeric: tabular-nums; }
.lk { width: 12px; height: 3px; border-radius: 2px; display: inline-block; background: currentColor; }
.lk.s1 { background: var(--s1); } .lk.s2 { background: var(--s2); } .lk.s3 { background: var(--s3); } .lk.s4 { background: var(--s4); }
.lk.typ { background: none; border-top: 2px dashed currentColor; opacity: .7; height: 0; } .lk.std { background: none; border-top: 2px dotted currentColor; height: 0; }
.lvpanel { position: fixed; top: 64px; right: 12px; bottom: 12px; width: min(380px, calc(100vw - 24px)); z-index: 30; overflow-y: auto;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow-lg); padding: 14px 16px; }
.lvpanel h3 { font-family: var(--display); font-size: 13px; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); margin: 14px 0 6px; }
.lvph { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.lvph .btn { margin: 0; flex: 0 0 auto; }
.lvps { padding: 7px 0; border-bottom: 1px solid var(--line); }
@media (max-width: 700px) { .lvpanel { top: auto; left: 8px; right: 8px; width: auto; max-height: 70vh; } .lvbadge { margin-left: 0; } }
.lvkey .sw { width: 10px; height: 10px; border-radius: 2px; display: inline-block; }
.lvkey .sw.s1 { background: var(--s1); } .lvkey .sw.s2 { background: var(--s2); } .lvkey .sw.s3 { background: var(--s3); } .lvkey .sw.s4 { background: var(--s4); }
.lvkey .lk { color: var(--muted); }
@media (max-width: 700px) { .lvkey { padding-left: 6px; } }
.lvkey i.lk { width: 14px; height: 3px; } .lvkey i.lk.typ, .lvkey i.lk.std { height: 0; background: none; }

:root[data-theme="light"] { color-scheme: light; }
:root[data-theme="dark"] { color-scheme: dark; }
.themerow { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 14px; }
.themerow .seg { margin: 0; }

/* ---------- Live v2: one chart + summary column + top rows ---------- */
.lvchan { flex: 0 1 200px; margin: 0; padding: 7px 10px; font-size: 14px; }
.lvgrid { display: grid; grid-template-columns: 290px minmax(0, 1fr); gap: 14px; align-items: start; }
.lvmain { min-width: 0; }
@media (max-width: 960px) { .lvgrid { grid-template-columns: 1fr; } .lvside { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); } }
.lvside { display: grid; gap: 10px; }
.lvside .card, .lvtop { margin: 0; padding: 12px 14px; }
.lvsh { font-family: var(--display); font-size: 13px; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; display: flex; justify-content: space-between; }
.lvbig3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; text-align: center; }
.lvbig3 b { display: block; font-family: var(--display); font-size: 28px; line-height: 1.1; }
.lvbig3 span { font-size: 11px; color: var(--muted); }
.lvchips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.lvchip { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; background: var(--surface-2); border-radius: 999px; padding: 3px 9px; }
.lvchip .sw, .lvprog .bar i { display: inline-block; }
.lvchip .sw { width: 8px; height: 8px; border-radius: 2px; }
.lvchip .sw.s1, .lvprog i.s1 { background: var(--s1); } .lvchip .sw.s2, .lvprog i.s2 { background: var(--s2); }
.lvchip .sw.s3, .lvprog i.s3 { background: var(--s3); } .lvchip .sw.s4 { background: var(--s4); }
.lvrow { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; padding: 5px 0; font-size: 14px; width: 100%;
  background: none; border: 0; border-top: 1px solid var(--line); text-align: left; color: inherit; font: inherit; }
.lvsh + .lvrow { border-top: 0; }
.lvrow b { font-size: 16px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.lvrow.sub { font-size: 12px; color: var(--muted); border-top: 0; padding-top: 0; }
.lvrow.link { cursor: pointer; } .lvrow.link:hover { color: var(--brand-ink); }
.lvrow em { font-style: normal; font-weight: 700; margin-left: 4px; }
.good { color: var(--success); } .warn { color: var(--warn); } .bad { color: var(--danger); }
.lvcard { padding: 10px 8px 6px; }
.lvhead { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 2px 6px 6px; }
.lvhead .seg { margin: 0 0 0 auto; }
.lvlines { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 13px; }
.lvchk .lk { margin: 0 2px; }
.lvsvg .lvline.s2 { stroke: var(--s2); } .lvsvg .lvline.s3 { stroke: var(--s3); }
.lvsvg .lvline.dash { stroke-dasharray: 5 4; stroke-width: 1.5; opacity: .75; }
.lvsvg .lvline.thin { stroke-width: 1.5; }
.lvsvg .lvdot { stroke: var(--surface); stroke-width: 2; }
.lvsvg .lvdot.s1 { fill: var(--s1); } .lvsvg .lvdot.s2 { fill: var(--s2); } .lvsvg .lvdot.s3 { fill: var(--s3); } .lvsvg .lvdot.ink { fill: var(--ink); } .lvsvg .lvdot.typ { fill: var(--faint); }
.lvsvg .grid.v { opacity: .6; }
.lk.ink { background: var(--ink); } .lk.dash { background: none; border-top: 2px dashed currentColor; height: 0; }
.lvtops { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 14px; }
@media (max-width: 760px) { .lvtops { grid-template-columns: 1fr; } }
.lvtop { max-height: 460px; overflow-y: auto; }
.lvitem { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 10px; align-items: center; width: 100%; padding: 8px 0;
  border: 0; border-top: 1px solid var(--line); background: none; color: inherit; font: inherit; text-align: left; }
button.lvitem { cursor: pointer; } button.lvitem:hover b { color: var(--brand-ink); }
.lvit { display: flex; flex-direction: column; min-width: 0; } .lvit b { font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lvprog { display: flex; flex-direction: column; align-items: flex-end; gap: 3px; min-width: 110px; }
.lvprog .bar { width: 100px; height: 6px; border-radius: 3px; background: var(--surface-2); overflow: hidden; }
.lvprog .bar i { height: 100%; border-radius: 3px; }
.lvage { font-size: 12px; font-weight: 700; color: var(--muted); min-width: 26px; text-align: right; }
.lvage.warn { color: var(--warn); } .lvage.bad { color: var(--danger); }
.lvpst { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; grid-column: 2 / 4; }
.scanfind { margin-bottom: 12px; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px; letter-spacing: .01em; }
.sftable { margin-top: 10px; width: 100%; } .sftable td, .sftable th { text-align: left; }
.scstage { margin-bottom: 12px; }
.sclist { max-height: 260px; overflow-y: auto; border: 1px solid var(--line); border-radius: var(--r-sm); margin-top: 6px; }
.scrow { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; padding: 6px 10px; border-top: 1px solid var(--line); }
.scrow:first-child { border-top: 0; } .scrow.dup { opacity: .7; }

/* ---------- Outbound: associate station + supervisor view (sql/21) */
.segn { background: var(--surface-2); border-radius: 10px; padding: 1px 7px; font-size: 12px; margin-left: 4px; }
/* Outbound: opened from a card on home (10/8) */
.obopen { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; font: inherit; color: var(--ink); cursor: pointer; border-left: 4px solid var(--brand); }
.obopen:hover { border-color: var(--brand); }
.obopen-t { flex: 1; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.obopen-t b { font-size: 18px; }
.obopen-go { flex: 0 0 auto; background: var(--primary); color: var(--on-primary); border-radius: 10px; padding: 8px 14px; font-weight: 650; font-size: 15px; }
.obtask { display: flex; align-items: center; gap: 6px; width: 100%; margin-bottom: 12px; padding: 10px 14px; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--success-bg); color: var(--ink); font: inherit; font-size: 14px; font-weight: 600; text-align: left; cursor: pointer; }
.obtask .obopen-go { margin-left: auto; padding: 4px 10px; font-size: 13px; }
.segdot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--success); margin-left: 6px; vertical-align: middle; }
.obbig { margin: 14px 0 4px; }
.obbig b { display: block; font-family: var(--display); font-weight: 600; font-size: 64px; line-height: 1; color: var(--ink); }
.obbig span { display: block; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--faint); margin-top: 6px; }
.oblast { margin: 14px 0 10px; padding: 14px; border-radius: var(--r-sm); font-size: 17px; font-weight: 600; background: var(--surface-2); color: var(--ink); overflow-wrap: anywhere; }
.oblast.ok { background: var(--success-bg); }
.oblast.warn { background: var(--warn-bg); }
.oblast.bad { background: var(--danger-bg); color: var(--danger); }
.oblast.idle { color: var(--muted); font-weight: 500; }
.obmsg { font-size: 15px; margin-top: 6px; }
.oblist { padding: 4px 14px; }
.obrow { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 14px; min-width: 0; }
.obrow:last-child { border-bottom: 0; }
.obrow .obt { color: var(--muted); flex: 0 0 64px; font-size: 13px; }
.obrow .obmain { flex: 1 1 auto; min-width: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; }
.obrow .obn { flex: 0 1 auto; min-width: 0; overflow-wrap: anywhere; }
.obrow .obtags { display: flex; align-items: center; gap: 8px; margin-left: auto; min-width: 0; }
.obrow .obtags .obch { max-width: 160px; }
.obn .trk-h, .oblast .trk-h { color: var(--muted); }
.obrow .obch { flex: 0 1 auto; max-width: 32%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.obrow.dup { opacity: .7; }
.cartag { display: inline-block; font-size: 11px; font-weight: 700; padding: 2px 7px; border-radius: 6px; letter-spacing: .03em; background: var(--surface-2); color: var(--ink); vertical-align: middle; }
.cartag.c-usps { background: color-mix(in srgb, var(--s1) 18%, var(--surface)); }
.cartag.c-ups { background: color-mix(in srgb, var(--s4) 24%, var(--surface)); }
.cartag.c-fedex { background: color-mix(in srgb, var(--s3) 20%, var(--surface)); }
.obgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 12px; margin-bottom: 12px; }
.obgrid .card { margin: 0; min-width: 0; }
.obgrid .trend { width: 100%; }
#olForm { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-end; }
#olForm label { font-size: 12px; color: var(--muted); font-weight: 600; display: flex; flex-direction: column; gap: 4px; }
#olForm input { margin: 0; padding: 9px 12px; font-size: 15px; }
#olQ { flex: 1 1 200px; min-width: 0; }
.dimrow td { opacity: .6; }
.okc { color: var(--success); }
.kpi b small { font-size: 15px; font-weight: 600; }

/* ---------- Status colors (revamp): one hue + one glyph per status, same everywhere.
   Workflow order: Not Printed (gray, outlined) → Printed (blue) → In Progress (violet)
   → Completed (green); problems: On Hold (amber), Reprint Needed (red). */
:root {
  --st-np: #4B5563; --st-np-bg: #FFFFFF;
  --st-pr: #1D4ED8; --st-pr-bg: #DBEAFE;
  --st-ip: #6D28D9; --st-ip-bg: #EDE9FE;
  --st-oh: #A16207; --st-oh-bg: #FEF3C7;
  --st-rn: #B91C1C; --st-rn-bg: #FEE2E2;
  --st-done: #15803D; --st-done-bg: #DCFCE7;
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) {
  --st-np: #9CA3AF; --st-np-bg: transparent;
  --st-pr: #93C5FD; --st-pr-bg: #172B54;
  --st-ip: #C4B5FD; --st-ip-bg: #2B1B57;
  --st-oh: #FCD34D; --st-oh-bg: #3A2C08;
  --st-rn: #FCA5A5; --st-rn-bg: #461717;
  --st-done: #86EFAC; --st-done-bg: #123220;
} }
:root[data-theme="dark"] {
  --st-np: #9CA3AF; --st-np-bg: transparent;
  --st-pr: #93C5FD; --st-pr-bg: #172B54;
  --st-ip: #C4B5FD; --st-ip-bg: #2B1B57;
  --st-oh: #FCD34D; --st-oh-bg: #3A2C08;
  --st-rn: #FCA5A5; --st-rn-bg: #461717;
  --st-done: #86EFAC; --st-done-bg: #123220;
}
.st-np { --sc: var(--st-np); --sb: var(--st-np-bg); }
.st-pr { --sc: var(--st-pr); --sb: var(--st-pr-bg); }
.st-ip { --sc: var(--st-ip); --sb: var(--st-ip-bg); }
.st-oh { --sc: var(--st-oh); --sb: var(--st-oh-bg); }
.st-rn { --sc: var(--st-rn); --sb: var(--st-rn-bg); }
.st-done { --sc: var(--st-done); --sb: var(--st-done-bg); }
.stag[class*="st-"], .cstat[class*="st-"], .stag-btn[class*="st-"] {
  background: var(--sb); color: var(--sc); border: 1px solid color-mix(in srgb, var(--sc) 35%, transparent); opacity: 1; }
.st-np.stag, .st-np.cstat, .st-np.stag-btn { border: 1.5px dashed color-mix(in srgb, var(--sc) 60%, transparent); }
.stile[class*="st-"] { background: var(--sb); border-left: 4px solid var(--sc); opacity: 1; }
.stile.st-np { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--sc) 30%, transparent); }
.stile[class*="st-"] .t-st { color: var(--sc); }
.stile.st-done .ini { opacity: 1; }

.sico { font-style: normal; display: inline-block; min-width: 1.1em; margin-right: 4px; text-align: center; font-weight: 800; letter-spacing: -.12em; }
.cstat .sico { width: auto; height: auto; border-radius: 0; background: none; flex: 0 0 auto; }
.stag { display: inline-flex; align-items: center; }
.stag-btn.on { box-shadow: inset 0 0 0 2px var(--sc); }
.slegend { display: flex; flex-wrap: wrap; gap: 6px; margin: 2px 0 10px; }
.slegend .stag { font-size: 11px; }

/* Settings → Standards: headers line up with their values */
.stdcard { overflow-x: auto; padding: 6px 14px; }
.stdtable { width: 100%; border-collapse: collapse; table-layout: auto; }
.stdtable th, .stdtable td { padding: 10px 12px; text-align: left; vertical-align: middle; white-space: nowrap; }
.stdtable th.num, .stdtable td.num { text-align: right; font-variant-numeric: tabular-nums; }
.stdtable td.act { text-align: right; width: 1%; }
.stdtable td.act .btn { margin: 0; }
.stdtable th:nth-child(6), .stdtable td:nth-child(6) { width: 1%; }
@media (max-width: 600px) { .stdtable th, .stdtable td { padding: 8px 8px; font-size: 13px; } .stdcard { padding: 4px 6px; } }

/* Verifying is optional: an unused Verifying tile is quiet and never counts as "needs people" */
.stile.optional { opacity: .6; box-shadow: none; }
.stile.optional:not([class*="st-"]) { background: transparent; border: 1px dashed var(--line); border-left-width: 1px; }
.assign.opt { color: var(--muted); font-weight: 600; }

.dangerbox { background: var(--danger-bg); border: 2px solid var(--danger); text-align: left; padding: 12px 14px; margin: 0; }
.dangerbox .row { margin-top: 10px; } .dangerbox .btn { margin: 0; }
.warnbox > .btn { margin-top: 8px; }

/* Settings → History */
.hform { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-end; margin: 0 0 6px; }
.hform label { font-size: 12px; color: var(--muted); font-weight: 600; display: flex; flex-direction: column; gap: 4px; }
.hform input { margin: 0; padding: 9px 12px; font-size: 15px; }
.hform #hQ { flex: 1 1 200px; min-width: 0; }
.hform .btn { flex: 0 0 auto; margin: 0; }
.hday { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; padding: 14px 0 4px; border-bottom: 1px solid var(--line); }
.hrow { display: grid; grid-template-columns: 70px 190px 1fr auto; gap: 10px; align-items: baseline; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.hrow:last-child { border-bottom: 0; }
.ht { color: var(--muted); font-size: 13px; }
.hk { font-weight: 700; font-size: 12px; padding: 2px 8px; border-radius: 6px; background: var(--surface-2); justify-self: start; }
.hk-batches { background: var(--st-pr-bg); color: var(--st-pr); }
.hk-assignments { background: var(--st-ip-bg); color: var(--st-ip); }
.hk-review { background: var(--st-oh-bg); color: var(--st-oh); }
.hk-people, .hk-settings, .hk-data { background: var(--surface-2); color: var(--ink); }
.hm { min-width: 0; overflow-wrap: anywhere; }
@media (max-width: 700px) { .hrow { grid-template-columns: 60px 1fr; } .hrow .hm { grid-column: 1 / -1; } .hrow .hw { grid-column: 1 / -1; } }
.hk.hk-del { background: var(--st-rn-bg); color: var(--st-rn); }

/* one-tap Sign out in the top bar */
.hdr-btn.hdr-out { width: auto; padding: 0 14px; font-size: 14px; font-weight: 650; letter-spacing: 0; background: transparent; border: 1px solid rgba(255,255,255,.3); }
.hdr-btn.hdr-out:hover { background: rgba(255,255,255,.1); }
@media (max-width: 380px) { .hdr-btn.hdr-out { padding: 0 10px; font-size: 13px; } }

/* Reports: a line where each column group starts (Today | This week, each channel / stage) */
table.trend .gs { border-left: 1px solid var(--line); }

/* Outbound station: the scan field is always there */
.obscan { margin: 4px 0 10px; }
.obscan input { font-size: 17px; padding: 12px 14px; }
.obscan input:focus { outline: 2px solid var(--brand); outline-offset: 1px; }

/* PIN boxes: masked like a password, but not a password field (keeps the browser's password manager out) */
.pinbox { -webkit-text-security: disc; text-security: disc; letter-spacing: .3em; font-size: 20px; }

/* Packing-slip scan result line (27) */
.scanmsg { margin: 8px 0 4px; padding: 8px 12px; border-radius: 10px; font-weight: 600; font-size: 15px; line-height: 1.35; }
.scanmsg.ok { background: var(--success-bg); color: var(--success); }
.scanmsg.warn { background: var(--warn-bg); color: var(--warn); }
.scanmsg.bad { background: var(--danger-bg); color: var(--danger); font-size: 16px; }
.wb { color: var(--danger); }

/* "Just scanned" list on the task screen (28) */
.recent { margin-top: 10px; text-align: left; }
.recent-h { font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin: 0 2px 4px; }
.rs { display: grid; grid-template-columns: 18px minmax(0, 1fr) auto; align-items: center; gap: 8px; padding: 5px 8px; border-top: 1px solid var(--line); font-size: 14px; border-radius: 0; }
.recent-h + .rs { border-top: 0; }
.rs i { font-style: normal; font-weight: 700; text-align: center; }
.rs-ok i { color: var(--success); } .rs-repeat i { color: var(--warn); } .rs-wrong i { color: var(--danger); }
.rs .trk { display: flex; min-width: 0; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; white-space: nowrap; }
.rs .trk-h { color: var(--muted); overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.rs .trk b { flex-shrink: 0; }
.rs-wrong .trk b { color: var(--danger); } .rs-repeat .trk b { color: var(--warn); }
.rs .rs-m { font-size: 12px; color: var(--muted); white-space: nowrap; } .rs .rs-m em { font-style: normal; font-weight: 600; }
.rs-wrong .rs-m em { color: var(--danger); } .rs-repeat .rs-m em { color: var(--warn); }
.rs.new { animation: rsIn 1s ease-out; border-radius: 8px; }
@keyframes rsIn { from { background: var(--success-bg); } to { background: transparent; } }
.rs-wrong.new { animation-name: rsBad; } @keyframes rsBad { from { background: var(--danger-bg); } to { background: transparent; } }
.rs-repeat.new { animation-name: rsRep; } @keyframes rsRep { from { background: var(--warn-bg); } to { background: transparent; } }
.cntnote { background: var(--warn-bg); color: var(--warn); font-weight: 600; font-size: 14px; padding: 8px 12px; border-radius: 10px; margin: 0 0 12px; }
.cartag.c-swiftx { background: color-mix(in srgb, var(--s2) 22%, var(--surface)); }
.cartag.c-gofo { background: color-mix(in srgb, #8a5cd6 22%, var(--surface)); }
.cartag.c-veho { background: color-mix(in srgb, #d6458c 20%, var(--surface)); }
.cartag.c-uniuni { background: color-mix(in srgb, #0f9bb5 22%, var(--surface)); }
.cartag.c-ontrac { background: color-mix(in srgb, #7a8b2a 24%, var(--surface)); }

/* Flagged tracking numbers (36) */
.holds { display: grid; gap: 10px; margin: 12px 0 4px; }
.holdcard { background: var(--danger); color: #fff; border-radius: var(--r-sm); padding: 14px 16px; text-align: center; animation: holdIn .6s ease-out; }
.holdcard .hold-h { font-family: var(--display); font-size: 26px; font-weight: 700; letter-spacing: .02em; line-height: 1.1; }
.holdcard .hold-n { margin: 8px 0 4px; font-size: 17px; } .holdcard .hold-n .trk-h { color: rgba(255,255,255,.75); }
.holdcard .cartag { color: var(--ink); }
.holdcard .hold-r { font-weight: 600; font-size: 16px; margin: 2px 0; }
.holdcard .small { color: rgba(255,255,255,.85); }
.holdcard .hold-ok { background: #fff; color: var(--danger); margin: 10px 0 0; }
@keyframes holdIn { 0% { transform: scale(.96); box-shadow: 0 0 0 0 rgba(208,59,59,.6); } 60% { box-shadow: 0 0 0 14px rgba(208,59,59,0); } 100% { transform: none; } }
#flIn { width: 100%; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px; margin-top: 8px; }
.flrow { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 8px; }
.flrow input { flex: 1 1 260px; min-width: 0; }
.flpdf { cursor: pointer; }
.fltable td { vertical-align: top; } .fltable .flacts { white-space: nowrap; }
.flagbtn { font-size: 12px; margin-left: 6px; color: var(--danger); }
.fltable .flck { width: 34px; text-align: center; } .fltable .flck input { width: 18px; height: 18px; cursor: pointer; }
.flbulk { position: sticky; top: 0; z-index: 3; display: flex; align-items: center; gap: 10px; padding: 8px 12px; margin: 6px 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-sm); box-shadow: 0 2px 8px rgba(0,0,0,.06); }

/* My activity (10/8) */
.actbar { justify-content: space-between; }
.actbar b { font-size: 16px; }
.actlist { padding: 4px 16px; }
.ev.act { grid-template-columns: 70px 92px 1fr; }
.ev.act.short { background: linear-gradient(90deg, var(--warn-bg), transparent 70%); margin: 0 -16px; padding-left: 16px; padding-right: 16px; }
.actfoot { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 6px; }
.actfoot .link { margin: 0; padding: 2px 0; font-size: 13px; }
.choices { display: flex; flex-direction: column; gap: 8px; margin-bottom: 12px; }
.choice { text-align: left; padding: 12px 14px; border-radius: var(--r-sm); border: 1px solid var(--line); background: var(--surface); color: var(--ink); font: inherit; font-size: 16px; font-weight: 600; cursor: pointer; }
.choice.on { border-color: var(--brand); background: var(--info-bg); box-shadow: inset 0 0 0 1px var(--brand); }
@media (max-width: 420px) { .ev.act { grid-template-columns: 62px 1fr; } .ev.act .ev-m { grid-column: 1 / -1; } }

/* Jobs on Floor, units in Settings, reports in Review (10/8) */
.jobh { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.jobh .btn { flex: 0 0 auto; width: auto; margin: 0; }
.jobcard.closed { opacity: .75; }
.jobbar { height: 8px; border-radius: 4px; background: var(--surface-2); margin-top: 10px; overflow: hidden; }
.jobbar i { display: block; height: 100%; background: var(--brand); border-radius: 4px; }
.jobbar.over i { background: var(--warn); }
.unitrow { align-items: center; margin-top: 8px; }
.unitrow .unitname { flex: 0 0 38%; font-weight: 600; font-size: 14px; }
.unitrow input { margin: 0; }
.rptnote { margin-top: 8px; padding: 8px 12px; border-radius: 10px; background: var(--info-bg); font-size: 14px; }

/* Other work (10/8) */
.otherbtn { margin-top: 16px; }
.othergrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; margin: 10px 0 12px; }
.othergrid .choice { min-height: 56px; }
.unitrow .selfst { flex: 0 0 auto; margin: 0 6px 0 0; white-space: nowrap; }
@media (max-width: 520px) { .unitrow { flex-wrap: wrap; } .unitrow .unitname { flex: 1 0 100%; } }

/* Floor → Other work (10/8) */

.pcheck { max-height: 42vh; overflow: auto; border: 1px solid var(--line); border-radius: var(--r-sm); margin-bottom: 12px; }
.pcrow { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-bottom: 1px solid var(--line); cursor: pointer; font-size: 15px; }
.pcrow:last-child { border-bottom: 0; }
.pcrow input { width: 20px; height: 20px; margin: 0; flex: 0 0 auto; }

/* Unlogged time (10/8) */
.unl { margin-top: 6px; font-size: 12px; font-weight: 600; color: var(--muted); }
.unl.bad, .unl-bad { color: var(--danger); font-weight: 700; }

/* Add people to a running task (10/9) */

.solorow { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 6px 0; border-top: 1px solid var(--line); font-size: 14px; }
.solorow:first-of-type { border-top: 0; }
.solorow .btn { margin: 0; flex: 0 0 auto; }

/* Inbound Processing tab (10/9): the Other work section as its own tab */

.chhint { align-self: center; margin-left: 4px; }

/* Diagnostics (sql/47) */
.ref { white-space: nowrap; opacity: .85; font-variant-numeric: tabular-nums; }
.tablewrap { overflow-x: auto; padding: 0; }
.dgkpis { display: flex; gap: 24px; flex-wrap: wrap; }
.dgkpis div { display: flex; flex-direction: column; }
.dgkpis b { font-size: 26px; line-height: 1.1; } .dgkpis b.bad { color: var(--danger); }
.dgkpis span { font-size: 12px; color: var(--muted); }
table.dgtable td { white-space: normal; vertical-align: top; }
table.dgtable td:first-child, table.dgtable td.mono { white-space: nowrap; }
.dgrow { cursor: pointer; } .dgrow:hover td { background: var(--surface-2); } .dgrow.done td { opacity: .55; }
table.kv { border-collapse: collapse; width: 100%; } table.kv th { text-align: left; color: var(--muted); font-weight: 500; padding: 3px 10px 3px 0; white-space: nowrap; vertical-align: top; }
table.kv td { padding: 3px 0; word-break: break-word; }
.dgpre { background: var(--surface-2); border-radius: 10px; padding: 10px; font-size: 12px; max-height: 260px; overflow: auto; white-space: pre-wrap; word-break: break-word; margin: 4px 0 10px; }
#netbar { position: sticky; top: 0; z-index: 30; }
#dgForm { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 12px 0 6px; }
#dgForm input[type=search] { flex: 1 1 220px; width: auto; margin: 0; }
#dgForm select { width: auto; flex: 0 0 auto; margin: 0; }
#dgForm .check { margin: 0; display: flex; gap: 6px; align-items: center; }
/* Phase 2: inbound (non-batch) series in Live */
.lvsvg .lvline.s4 { stroke: var(--s4); } .lvsvg .lvdot.s4 { fill: var(--s4); }
.lvsvg .lvline.thin { stroke-width: 1.5; }
.tl-b.ar-in { background: var(--s4); }
.tl-b.live { background-image: repeating-linear-gradient(90deg, transparent 0 5px, rgba(255,255,255,.45) 5px 7px); }
.k-in { background: var(--s4); } .k-live { background: var(--chart); background-image: repeating-linear-gradient(90deg, transparent 0 3px, rgba(255,255,255,.55) 3px 5px); }
i.sq { display: inline-block; width: 10px; height: 10px; border-radius: 3px; vertical-align: -1px; } i.sq.s1 { background: var(--s1); } i.sq.s4 { background: var(--s4); }
/* EOD card + Reports → Inbound (sql/48) */
.eodcard h3 { font-size: 17px; }
.eodkpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin: 10px 0; }
.eodkpis div { display: flex; flex-direction: column; } .eodkpis b { font-size: 24px; line-height: 1.1; } .eodkpis span { font-size: 12px; color: var(--muted); }
@media (max-width: 520px) { .eodkpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.eoddet { border-top: 1px solid var(--line); padding: 6px 0; } .eoddet summary { cursor: pointer; font-size: 14px; }
.eodlist { margin: 6px 0 4px 18px; padding: 0; font-size: 13px; } .eodlist li { margin: 2px 0; }
.eodalso { border-top: 1px solid var(--line); padding-top: 8px; font-size: 14px; display: grid; gap: 4px; }
.inbbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 10px; }
.inbbar label { display: flex; gap: 6px; align-items: center; margin: 0; } .inbbar input[type=date] { width: auto; margin: 0; }
.inbkpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-bottom: 12px; }
@media (max-width: 640px) { .inbkpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.inbchart { width: 100%; height: auto; display: block; }
.inbchart rect.s1 { fill: var(--s1); } .inbchart rect.s4 { fill: var(--s4); } .inbchart rect.hit { fill: transparent; }
table.inbtable td { white-space: normal; }
.tgtin { width: 90px; margin: 0; text-align: right; }
.warnc { color: var(--warn); }
.eodalso i.sq, .lvrow i.sq { margin-right: 4px; }
/* Phase 3 (sql/49) */
.pstat.ps-outbound { color: var(--success); } .pstat.ps-outbound i { background: var(--success); }
.tl-ob { position: absolute; top: 1px; bottom: 1px; border-radius: 3px; background: repeating-linear-gradient(135deg, var(--s3) 0 2px, transparent 2px 4px); opacity: .9; }
.k-ob { background: repeating-linear-gradient(135deg, var(--s3) 0 2px, transparent 2px 4px); border: 1px solid var(--line); }
.tl-b.ex { opacity: .3; background-image: repeating-linear-gradient(135deg, transparent 0 3px, rgba(0,0,0,.35) 3px 4px); }
.lvrow b.bad { color: var(--danger); }
.mopt { display: flex; gap: 12px; align-items: flex-start; padding: 10px 0; border-top: 1px solid var(--line); }
.mopt:first-child { border-top: 0; } .mopt input { margin-top: 3px; flex: 0 0 auto; width: 18px; height: 18px; }
.mopt b { display: block; } .mopt span { font-size: 13px; color: var(--muted); }
/* Reopen a finished stage for someone (sql/50) */
.pchip button.reopen { font-size: 12px; font-weight: 600; color: var(--brand, var(--ink)); background: var(--surface-2); border-radius: 8px; padding: 2px 8px; margin-left: 4px; }
.pchip button.reopen[data-sure="1"] { color: var(--warn); }

/* ===== Inbound Processing redesign (10/12, sql/52) ===== */
.inb { max-width: 1100px; }
.inbhead { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.inbhead h2 { margin: 0 0 2px; }
.inbact { display: flex; gap: 8px; flex-wrap: wrap; }
.inbact .btn { width: auto; margin: 0; }
.inbsec { margin: 22px 2px 8px; font-size: 15px; display: flex; align-items: center; gap: 8px; }
.inbsec.h2row { justify-content: space-between; flex-wrap: wrap; }
.inbempty { color: var(--muted); }
.gcards { display: grid; grid-template-columns: repeat(auto-fit, minmax(380px, 1fr)); gap: 12px; }
.gcard { margin: 0; border-left: 4px solid var(--success); display: flex; flex-direction: column; gap: 10px; }
.gcard.paused { border-left-color: var(--warn); }
.gtop { display: flex; justify-content: space-between; gap: 8px; align-items: flex-start; }
.gtop .btn { width: auto; margin: 0; flex: 0 0 auto; }
.gtitle b { font-size: 16px; } .gnote { color: var(--muted); }
.gmeta { font-size: 13px; color: var(--muted); margin-top: 2px; }
.gcard.running .gstate { color: var(--success); font-weight: 600; } .gcard.paused .gstate { color: var(--warn); font-weight: 600; }
.gpeople { display: flex; flex-wrap: wrap; gap: 6px; }
.gp { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 5px 10px 5px 8px; font: inherit; font-size: 13px; cursor: pointer; color: var(--ink); }
.gp:hover { border-color: var(--brand); }
.gp i { width: 8px; height: 8px; border-radius: 50%; background: var(--success); }
.gp.paused i { background: var(--warn); } .gp span { color: var(--muted); }
.gbtns { display: flex; gap: 8px; flex-wrap: wrap; margin-top: auto; }
.gbtns .btn { width: auto; margin: 0; flex: 1 1 auto; }
.flist { padding: 0 14px; }
.frow { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 12px 0; border-top: 1px solid var(--line); }
.frow:first-child { border-top: 0; }
.fmain { min-width: 0; } .fmain .small { overflow-wrap: anywhere; }
.fbtns { display: flex; gap: 6px; flex: 0 0 auto; } .fbtns .btn { width: auto; margin: 0; }
.when { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.chipbtn { border: 1px solid var(--line); background: var(--surface); color: var(--ink); border-radius: 999px; padding: 7px 12px; font: inherit; font-size: 13px; cursor: pointer; }
.chipbtn.on { background: var(--info-bg); color: var(--brand-ink); border-color: var(--primary); box-shadow: inset 0 0 0 1px var(--primary); }
.whentime { width: auto !important; margin: 0 !important; padding: 6px 10px !important; }
.recentpicks { display: flex; flex-wrap: wrap; gap: 6px; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; align-items: end; }
.row2 .btn { margin: 0; }
@media (max-width: 560px) { .row2 { grid-template-columns: 1fr; } .gcards { grid-template-columns: 1fr; } .frow { flex-direction: column; align-items: stretch; } }
.psbtns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 12px; } .psbtns .btn { margin: 0; }
.skiplist { margin: 4px 0 10px 18px; padding: 0; }
.evlist { display: flex; flex-direction: column; gap: 6px; }
.evrow { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 8px 10px; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface); }
.evrow input[type=time] { width: auto; margin: 0; padding: 5px 8px; }
.evk { font-weight: 700; font-size: 13px; min-width: 76px; }
.ev-started, .ev-resumed, .ev-joined { color: var(--success); } .ev-paused { color: var(--warn); } .ev-completed { color: var(--ink); }
.evn { flex: 1 1 160px; }
.evprev { margin-top: 10px; padding: 10px 12px; border-radius: var(--r-sm); background: var(--surface-2); }
.evprev ul { margin: 4px 0 8px 18px; padding: 0; }
/* Outbound station: who scanned it (sql/53) */
.obwho { font-size: 12px; font-weight: 600; color: var(--ink); background: var(--surface-2); border-radius: 6px; padding: 1px 7px; }
.oblisthead { align-items: center; } .oblisthead .seg { margin: 0; }
.obmore { width: 100%; margin: 10px 0 2px; }
/* 10/12 step 3: hours waiting for review (People) and the numbers glossary (Reports) */
.warn-t { color: var(--warn); font-weight: 600; }
.pcard-hrs .warn-t { display: block; font-size: 11px; text-align: right; }
details.glossary { margin: 4px 2px 14px; font-size: 13px; color: var(--muted); }
details.glossary summary { cursor: pointer; font-weight: 600; color: var(--ink); }
details.glossary ul { margin: 6px 0 0; padding-left: 18px; }
details.glossary li { margin: 3px 0; }
/* 10/12 step 4: 8 sections — views row under the strip; phone bottom bar + More */
.subtabs { margin: -6px 0 14px; }
.bnav { display: none; }
.morelist { display: grid; gap: 8px; margin: 12px 0; }
.morelist .btn { margin: 0; }
@media (max-width: 700px) {
  .tabs { display: none; }
  .bnav { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 15; gap: 2px;   /* under sheets (20) and toasts (30) */
          background: var(--surface); border-top: 1px solid var(--line); box-shadow: 0 -4px 16px rgba(16,24,40,.06);
          padding: 6px 6px calc(6px + env(safe-area-inset-bottom)); }
  .bnav button { flex: 1 1 0; min-width: 0; min-height: 48px; border: 0; background: transparent; color: var(--muted); border-radius: 10px;
                 font-size: 12px; font-weight: 600; line-height: 1.15; padding: 4px 2px; cursor: pointer; overflow: hidden; text-overflow: ellipsis; }
  .bnav button.on { background: var(--surface-2); color: var(--ink); }
  #adminBody { padding-bottom: 76px; }
  .toast { bottom: calc(84px + env(safe-area-inset-bottom)); }
}

/* ---- 10/12 step 5: phone layouts + accessibility ---- */
/* contrast: the light grey used for table headers, counts and axis labels was ~3:1 */
:root { --faint: #6B7280; --danger-solid: #B42318; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --faint: #9CA3AF; } }
:root[data-theme="dark"] { --faint: #9CA3AF; }
/* solid red surfaces keep white text readable in dark mode too (the HOLD card above all) */
.holdcard, .btn.danger { background: var(--danger-solid); border-color: var(--danger-solid); color: #fff; }
.holdcard .hold-ok { color: var(--danger-solid); }
.pinpad button.pressed { color: var(--on-solid); background: var(--solid); }
/* keyboard focus is always visible */
:focus-visible { outline: 3px solid color-mix(in srgb, var(--brand, #2563EB) 70%, transparent); outline-offset: 2px; }

/* Fulfillment board: stage name inside each tile (shown on phones, where the column headers are hidden) */
.stile .t-stage { display: none; }
@media (max-width: 700px) {
  .compact { padding: 0; background: transparent; border: 0; box-shadow: none; }
  .compact .cscroll { overflow: visible; }
  .compact .crow.chead { display: none !important; }
  .compact .crow { display: grid !important; grid-template-columns: minmax(0, 1fr) auto !important; width: auto !important; min-width: 0 !important;
                   gap: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-sm); box-shadow: var(--shadow);
                   padding: 10px 12px; margin: 0 0 8px; }
  .compact .crow > .clabel { position: static !important; background: transparent !important; grid-column: 1; grid-row: 1; }
  .compact .crow > .clabel b, .compact .crow > .clabel span { white-space: normal; }
  .compact .crow > .corders { grid-column: 2; grid-row: 1; font-size: 20px; }
  .compact .crow > .stile { grid-column: 1 / -1; min-height: 46px; flex-direction: row; align-items: center; flex-wrap: wrap; gap: 4px 8px; padding: 8px 10px; }
  .compact .crow > .stile.empty { display: none; }
  .compact .stile .t-stage { display: inline-block; min-width: 74px; font-weight: 700; color: var(--ink); font-size: 13px; }
  .compact .stile .t-ppl { flex: 1 1 auto; }
  .compact .cdate { margin: 12px 2px 6px; }
  /* filter chips wrap instead of running off the screen */
  #showFilter, #chFilter, #catFilter, .chips { flex-wrap: wrap; overflow: visible; }
  /* Holds status picker wraps (it pushed the whole page sideways) */
  #flSeg { display: flex; flex-wrap: wrap; }
  /* Live: the chart before the side cards */
  .lvside { order: 2; }
  /* tap targets: at least ~40 px */
  .btn.sm { min-height: 40px; padding: 10px 14px; }
  .seg button { min-height: 40px; }
  .chips button { min-height: 40px; padding: 9px 13px; }
  .chip button, .pchip button, [data-unassign] { min-width: 40px; min-height: 40px; font-size: 20px; }
  input[type="checkbox"] { width: 22px; height: 22px; }
}
.subtabs { display: flex; width: max-content; max-width: 100%; }
.subtabs + #adminBody > .h2row:first-child, .subtabs + #adminBody > h2:first-child { margin-top: 4px; }
details.ffilters > summary { list-style: none; cursor: pointer; font-size: 13px; font-weight: 600; color: var(--muted); padding: 8px 2px; min-height: 40px; display: flex; align-items: center; }
details.ffilters > summary::-webkit-details-marker { display: none; }
details.ffilters > summary::before { content: '▸'; margin-right: 6px; } details.ffilters[open] > summary::before { content: '▾'; }
@media (min-width: 701px) { details.ffilters > summary { display: none; } }
@media (max-width: 700px) { .slegend { display: none; } }
/* a tap outside a sheet with entered data: a small nudge instead of closing (10/12) */
@keyframes nudge { 0%, 100% { transform: translateY(0); } 40% { transform: translateY(-6px); } 70% { transform: translateY(2px); } }
.sheet .panel.nudge { animation: nudge .25s ease-out; }
/* Live: the usual day as a light band behind today's lines (10/12) */
.lvsvg .lvarea.typband { fill: var(--faint); opacity: .08; }
.lvtop { max-height: none; overflow: visible; }
#lvAllPeople { margin-top: 8px; }
.lvkey i.lk.typ, .lk.typ, .lvline-key .lk.typ { height: 8px !important; border-top: 0 !important; background: var(--faint) !important; opacity: .35; }
/* 10/12 cleanups (v95) */
.wkbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 8px; }
.wkbar .seg { margin-bottom: 0; }
.inbline { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
.inbline .btn { margin-left: auto; }
.pstat.ps-gone i { background: var(--faint); } .pstat.ps-gone { color: var(--muted); }
.floorline { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: center; justify-content: space-between; margin: 0 2px 10px; color: var(--muted); }
.floorline b { color: var(--ink); }
.slegend .sdot { display: inline-flex; align-items: center; gap: 5px; font-size: 11px; color: var(--muted); margin-right: 6px; }
.slegend .sdot i { width: 9px; height: 9px; border-radius: 50%; background: var(--sc); display: inline-block; }
.slegend .sdot.st-np i { background: transparent; border: 1.5px dashed var(--sc); }
.t-st.same { display: none; }
.untoggle { margin: -2px 0 8px; }
.untoggle button { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); border-radius: 999px; padding: 6px 12px; font: inherit; font-size: 13px; cursor: pointer; min-height: 36px; }
.untoggle button i { width: 28px; height: 16px; border-radius: 999px; background: var(--line); position: relative; flex: 0 0 auto; }
.untoggle button i::after { content: ''; position: absolute; top: 2px; left: 2px; width: 12px; height: 12px; border-radius: 50%; background: #fff; transition: left .15s; }
.untoggle button.on { border-color: var(--brand-ink); }
.untoggle button.on i { background: var(--brand-ink); }
.untoggle button.on i::after { left: 14px; }
.untoggle button span { color: var(--muted); font-weight: 700; }
.sfholds { margin: 8px 0; padding: 8px 10px; border-radius: var(--r-sm); background: var(--warn-bg); }
.sfhold { margin-top: 4px; }
.chipf { flex: 1; font-size: 13px; }
/* I-U1: Inbound — one button style (sentence case), one heading style, no repeated tab name */
.inb h3, .inb .inbsec, .inb .inbsec h3 { font-family: var(--body); font-size: 15px; font-weight: 700; text-transform: none; letter-spacing: 0; }
.inbstat { font-size: 14px; color: var(--muted); font-weight: 600; }
.floorline .link { width: auto; display: inline; margin: 0; padding: 0; }
#pad.busy { opacity: .55; pointer-events: none; }
.scan-warn { animation: swarn .6s ease-out; } @keyframes swarn { from { background: color-mix(in srgb, var(--warn) 35%, var(--surface-2)); } }
/* A-U4: toasts sit under the header so they never cover the bottom buttons */
.toast, .toast[hidden] { bottom: auto; top: calc(70px + env(safe-area-inset-top)); }
@media (max-width: 700px) { .toast { bottom: auto; top: calc(64px + env(safe-area-inset-top)); max-width: calc(100vw - 32px); } }
/* O-U2 / O-U3 */
.oblast:empty { display: none; }
.obch { display: inline-block; padding: 1px 8px; border-radius: 999px; font-size: 11px; font-weight: 700; background: var(--surface-2); color: var(--ink); border: 1px solid var(--line); }
@media (min-width: 1100px) {
  .crow { grid-template-columns: 116px minmax(160px, 260px) 64px var(--cols, repeat(var(--n, 3), minmax(140px, 1fr))) !important; width: auto; }
}
.rowmenu { font-size: 18px; line-height: 1; padding: 2px 8px; margin-left: 4px; color: var(--muted); min-width: 32px; min-height: 32px; }
.chiptoggle:hover { color: var(--ink); }
.chiptoggle { font-size: 11px !important; font-weight: 600; color: var(--muted); background: none; border: 0; text-decoration: underline; cursor: pointer; padding: 0 0 0 6px; }
.updchip { position: fixed; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); z-index: 25; border: 0; border-radius: 999px; padding: 10px 16px; font: inherit; font-weight: 700; background: var(--brand); color: var(--on-brand); box-shadow: var(--shadow-lg); cursor: pointer; }
@media (max-width: 700px) { .updchip { bottom: calc(80px + env(safe-area-inset-bottom)); } }
.holdcard .hold-ok:hover { background: #fff; filter: brightness(.95); }
.btn.danger:hover { background: color-mix(in srgb, var(--danger-solid, #B42318) 88%, #000); }
/* inputs and buttons side by side line up (v97) */
.row > input, .row > select, .typebc > input, .hform > input, .flrow > input { margin-bottom: 0; min-height: var(--btn-h); }
.row > .btn, .typebc > .btn, .hform > .btn, .flrow > .btn { margin: 0; align-self: stretch; min-height: var(--btn-h); }
.row { align-items: stretch; }

/* ================================================================
   REDESIGN 10/13 — flush & clean: Inter, black header with the sections
   in it, caps page titles, borderless cards, pill buttons
   ================================================================ */
:root { --hdr-h: 64px; --ink-band: #0B0C0E; --logo-blue: #50A2DA; --r-lg: 20px; }
html, body { letter-spacing: -.005em; }
/* header */
header { background: var(--ink-band); gap: 14px; min-height: var(--hdr-h); padding: env(safe-area-inset-top) 20px 0; }
#logo { width: 34px; height: 34px; box-shadow: none; }
#title { flex: 0 1 auto; font-family: var(--body); font-weight: 800; font-size: 20px; letter-spacing: .06em; }
body:not(.admin) #title, body.admin header:not(:has(.tabs)) #title { flex: 1; }
.hdr-btn { border-radius: 999px; background: #1C1E22; }
.hdr-btn:active { background: #2A2D33; }
.hdr-btn.hdr-out { width: auto; padding: 0 14px; font-size: 14px; font-weight: 600; background: transparent; color: #C9CDD4; }
.hdr-btn.hdr-out:hover { color: #fff; }
#menuBtn.me { background: var(--logo-blue); color: #0B0C0E; font: 800 14px/1 var(--body); letter-spacing: .02em; }
/* sections in the header (computers) */
header .tabs { flex: 1; align-self: stretch; display: flex; gap: 2px; margin: 0 0 0 10px; padding: 0; background: transparent; border-radius: 0; overflow-x: auto; }
header .tabs button { flex: 0 0 auto; padding: 0 12px; border-radius: 0; background: transparent; color: #A7ADB8; font-size: 15px; font-weight: 600; box-shadow: none; }
header .tabs button:hover { color: #fff; }
header .tabs button.on { background: transparent; color: #fff; box-shadow: inset 0 -3px 0 var(--logo-blue); }
@media (max-width: 1100px) { body.admin header .tabs ~ * { flex: 0 0 auto; } header .tabs button { padding: 0 9px; font-size: 14px; } }
@media (max-width: 700px) { header { --hdr-h: 58px; padding: env(safe-area-inset-top) 14px 0; gap: 10px; } header .tabs { display: none; } #title, body.admin #title { flex: 1; font-size: 18px; }
  .hdr-btn.hdr-out { padding: 0 10px; font-size: 13px; } }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) header { box-shadow: 0 1px 0 #1F2227; } }
:root[data-theme="dark"] header { box-shadow: 0 1px 0 #1F2227; }
#showFilter.qviews { flex-wrap: nowrap; overflow-x: auto; margin: 0; }

/* page */
main { padding: 28px 20px 56px; }
body.wide main { max-width: 1360px; }
@media (min-width: 701px) { body.wide main { padding: 32px 32px 56px; } }
.card, .kpi, .stat, .tile, .compact { border: 0; box-shadow: var(--shadow); }
.card { border-radius: var(--r-lg); }
h2 { font-family: var(--body); font-weight: 800; font-size: 13px; letter-spacing: .1em; color: var(--ink); }
.pagehead { display: flex; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin: 0 0 24px; }
.ptext { flex: 1 1 260px; min-width: 0; }
.ptitle { margin: 0; font-family: var(--body); font-weight: 800; font-size: 44px; line-height: 1; letter-spacing: .02em; text-transform: uppercase; color: var(--ink); }
.psub { margin-top: 8px; font-size: 15px; color: var(--muted); min-height: 1px; }
.psub:empty { display: none; }
.phact { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.phact:empty, .phact:has(> #pageAct:empty:only-child) { display: none; }
.pagehead .subtabs { margin: 0; }
@media (max-width: 700px) { .pagehead { margin-bottom: 16px; gap: 12px; } .ptitle { font-size: 32px; } .psub { font-size: 14px; margin-top: 6px; } main { padding: 20px 16px 48px; } }
/* segmented control */
.seg { border-radius: 999px; background: color-mix(in srgb, var(--ink) 7%, transparent); }
.seg button { border-radius: 999px; padding: 8px 16px; font-size: 14px; }
.seg button.on { box-shadow: 0 1px 2px rgba(11,12,14,.14); }
/* pill buttons */
.btn { border-radius: 999px; }
.btn.sm { border-radius: 999px; }
.addbtn { display: inline-flex; align-items: center; gap: 8px; height: 44px; padding: 0 20px; font-size: 15px; }
.linkbtn { border: 0; background: none; color: var(--brand-ink); font-size: 13px; font-weight: 600; padding: 6px 8px; cursor: pointer; }
.linkbtn:hover { text-decoration: underline; }

/* KPI strip */
.rkpis { grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 16px; margin-bottom: 28px; }
.kpi.rk { border-radius: 18px; padding: 18px 20px; min-height: 0; gap: 6px; }
.kpi.rk .kpi-l { font-size: 13px; }
.kpi.rk b { font-weight: 800; font-size: 36px; line-height: 1; letter-spacing: -.01em; }
.kpi-n { font-size: 13px; font-weight: 600; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kpi-n.blue { color: var(--brand-ink); } .kpi-n.good { color: var(--success); } .kpi-n.warn { color: var(--warn); } .kpi-n.bad { color: var(--danger); }
@media (max-width: 700px) {   /* phones: a short row that scrolls sideways, so the board starts on the first screen */
  .rkpis { display: flex; overflow-x: auto; gap: 10px; margin: 0 0 14px; padding: 2px 2px 6px; scroll-snap-type: x proximity; scrollbar-width: none; }
  .rkpis::-webkit-scrollbar { display: none; }
  .kpi.rk { flex: 0 0 148px; padding: 12px 14px; gap: 4px; scroll-snap-align: start; } .kpi.rk b { font-size: 26px; } .kpi.rk .kpi-l, .kpi-n { font-size: 12px; } }

/* quick views + Filters */
.qbar { display: flex; align-items: center; gap: 12px; border-bottom: 1px solid var(--line); margin-bottom: 12px; }
.qviews { display: flex; gap: 2px; flex: 1; min-width: 0; overflow-x: auto; scrollbar-width: none; }
.qviews::-webkit-scrollbar { display: none; }
.qviews button { flex: 0 0 auto; border: 0; background: none; padding: 12px 14px; font-size: 14px; font-weight: 600; color: var(--muted); cursor: pointer; white-space: nowrap; min-height: 44px; }
.qviews button:hover { color: var(--ink); }
.qviews button.on { color: var(--ink); font-weight: 700; box-shadow: inset 0 -2px 0 var(--ink); }
.qn { color: var(--faint); font-weight: 600; margin-left: 2px; }
.qn.blue, .qn.warn { display: inline-block; min-width: 20px; padding: 0 6px; border-radius: 999px; color: #fff; font-size: 12px; line-height: 18px; text-align: center; }
.qn.blue { background: var(--brand-ink); } .qn.warn { background: #B45309; }
.fwrap { position: relative; padding-bottom: 8px; }
.fbtn { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font-size: 14px; font-weight: 600; cursor: pointer; }
.fbtn.has, .fbtn[aria-expanded="true"] { background: var(--solid); color: var(--on-solid); border-color: var(--solid); }
.fcount { background: var(--logo-blue); color: #0B0C0E; border-radius: 999px; padding: 0 7px; font-size: 12px; line-height: 18px; }
.fmenu { position: absolute; right: 0; top: calc(100% + 4px); z-index: 12; width: 340px; max-height: min(70vh, 640px); overflow-y: auto;
  background: var(--surface); border-radius: 20px; box-shadow: 0 12px 32px rgba(11,12,14,.18), 0 0 0 1px var(--line); padding: 16px 18px; display: flex; flex-direction: column; gap: 16px; }
.fmhead { display: flex; align-items: center; justify-content: space-between; }
.fmhead b { font-weight: 800; font-size: 13px; letter-spacing: .1em; text-transform: uppercase; }
.xbtn { width: 32px; height: 32px; border-radius: 50%; border: 0; background: var(--surface-2); color: var(--muted); font-size: 18px; line-height: 1; cursor: pointer; }
.fsec { display: flex; flex-direction: column; gap: 8px; }
.fsl { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.fdates { display: flex; flex-wrap: wrap; gap: 6px; }
.fdates button { border: 0; background: none; box-shadow: inset 0 0 0 1px var(--line); border-radius: 999px; padding: 7px 12px; font-size: 13px; font-weight: 600; cursor: pointer; min-height: 36px; }
.fdates button.on { background: var(--info-bg); color: var(--brand-ink); box-shadow: inset 0 0 0 1.5px var(--brand-ink); }
.frange { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.frange label { display: flex; flex-direction: column; gap: 4px; font-size: 12px; font-weight: 600; color: var(--muted); }
.frange input { height: 40px; border: 1px solid var(--line); border-radius: 12px; padding: 0 10px; font: 500 14px var(--body); background: var(--surface); color: var(--ink); min-width: 0; }
.fchecks { display: flex; flex-direction: column; }
.fchecks button { display: flex; align-items: center; gap: 10px; border: 0; background: none; padding: 8px 4px; min-height: 40px; font-size: 14px; font-weight: 500; color: var(--ink); text-align: left; cursor: pointer; border-radius: 10px; }
.fchecks button:hover { background: var(--surface-2); }
.fchecks button i { width: 18px; height: 18px; flex: 0 0 auto; border-radius: 5px; box-shadow: inset 0 0 0 1.5px #B8BEC8; display: grid; place-items: center; }
.fchecks button.on i { background: var(--brand-ink); box-shadow: none; }
.fchecks button.on i::after { content: ''; width: 9px; height: 5px; border: solid #fff; border-width: 0 0 2px 2px; transform: translateY(-1px) rotate(-45deg); }
.fchecks button span { margin-left: auto; color: var(--faint); font-size: 13px; font-weight: 600; }
.fchecks .chhint { padding: 4px; }
.fmfoot { display: flex; justify-content: space-between; gap: 10px; position: sticky; bottom: -16px; background: var(--surface); padding: 10px 0 0; border-top: 1px solid var(--line); }
@media (max-width: 700px) {
  .qbar { gap: 8px; }
  .qviews button { padding: 12px 10px; }
  .fwrap { position: static; padding-bottom: 6px; }
  .fbtn { padding: 0 12px; }
  .fmenu { position: fixed; left: 0; right: 0; bottom: 0; top: auto; width: auto; max-height: 82vh; border-radius: 24px 24px 0 0; z-index: 25;
    padding: 18px 18px calc(18px + env(safe-area-inset-bottom)); box-shadow: 0 -12px 40px rgba(11,12,14,.25); }
  .fmfoot { bottom: calc(-18px - env(safe-area-inset-bottom)); padding-bottom: 4px; }
}
.fchips { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin: 0 0 14px; }
.fshow { font-weight: 600; margin-right: 2px; }
.fchip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 4px 4px 12px; border-radius: 999px; background: var(--info-bg); color: var(--brand-ink); font-size: 13px; font-weight: 600; max-width: 100%; }
.fchip button { width: 24px; height: 24px; border: 0; border-radius: 50%; background: color-mix(in srgb, var(--brand-ink) 16%, transparent); color: inherit; font-weight: 700; cursor: pointer; flex: 0 0 auto; }

/* the board */
.compact.rboard { border-radius: var(--r-lg); padding: 0; overflow: hidden; }
.rboard .cscroll { padding: 0 0 10px; }
@media (min-width: 701px) { .rboard .crow { grid-template-columns: minmax(220px, 1.5fr) 72px var(--cols, repeat(var(--n, 3), minmax(140px, 1fr))) !important; gap: 10px; padding: 10px 22px; border-top: 1px solid var(--surface-2); align-items: center; } }
.rboard .crow.chead { padding: 14px 22px; border-top: 0; border-bottom: 1px solid var(--line); background: var(--surface); }
.rboard .chead span { font-size: 12px; font-weight: 700; letter-spacing: .1em; color: var(--muted); }
.rboard .cdate { padding: 18px 22px 6px; margin: 0; border: 0; background: transparent; font-family: var(--body); font-weight: 800; font-size: 14px; letter-spacing: .08em; text-transform: uppercase; }
.rboard .cdate span { font-size: 13px; }
.rboard .clabel { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; font-size: 14px; }
.rboard .cname { max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rboard .clabel .cname b { display: inline; font-size: 15px; font-weight: 700; }
.rboard .clabel .cname span { display: inline; font-size: 14px; color: var(--muted); }
.cstat.pill { display: inline-flex !important; align-self: flex-start; align-items: center; gap: 6px; padding: 4px 8px 4px 10px; border-radius: 999px; border: 0;
  font: 600 12px/1.2 var(--body); cursor: pointer; background: var(--sb, var(--surface-2)); color: var(--sc, var(--muted)); }
.cstat.pill i { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.cstat.pill.st-np { background: var(--surface-2); color: var(--muted); border: 0; }
.rboard .corders { font-family: var(--body); font-weight: 800; font-size: 20px; }
.rboard .stile { min-height: 46px; border-radius: 12px; border-left: 0 !important; padding: 8px 12px; gap: 3px; justify-content: center; }
.rboard .stile.unassigned { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brand) 40%, transparent); background: color-mix(in srgb, var(--brand) 5%, var(--surface)); }
.rboard .stile.unassigned:hover { background: var(--info-bg); filter: none; }
.rboard .stile.st-np:not(.unassigned) { box-shadow: none; background: var(--surface-2); }
.rboard .stile.empty { border: 0; background: transparent; }
.rboard .t-ppl { gap: 2px; }
.rboard .ini { font-size: 13px; font-weight: 600; line-height: 18px; padding: 0; background: transparent; border-radius: 0; color: var(--ink); }
.rboard .ini.w, .rboard .ini.p { color: var(--ink); background: transparent; } .rboard .ini.d { color: var(--muted); background: transparent; }
.rboard .ini::before { content: ''; display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 7px; background: var(--faint); vertical-align: 1px; }
.rboard .ini.w::before { background: var(--success); } .rboard .ini.p::before { background: var(--warn); } .rboard .ini.d::before { background: var(--success); opacity: .5; }
.rboard .assign { font-size: 14px; font-weight: 600; }
.rboard .t-st { font-size: 12px; }
@media (max-width: 700px) {
  .compact.rboard { background: transparent; box-shadow: none; overflow: visible; }
  .rboard .cscroll { padding: 0; }
  .rboard .cdate { padding: 14px 4px 8px; }
  .rboard .crow { background: var(--surface); border-radius: 18px; box-shadow: var(--shadow); padding: 14px !important; margin-bottom: 10px; border: 0; gap: 8px !important; }
  .rboard .crow > .clabel { gap: 6px; }
  .rboard .cname { white-space: normal; }
}

/* phone bottom bar with icons */
@media (max-width: 700px) {
  .bnav { padding: 4px 4px calc(4px + env(safe-area-inset-bottom)); box-shadow: none; }
  .bnav button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; min-height: 56px; border-radius: 12px; color: var(--faint); font-size: 11.5px; }
  .bnav button span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .bnav button.on { background: transparent; color: var(--brand-ink); font-weight: 700; }
  #adminBody { padding-bottom: 84px; }
}
.fback { display: none; }
@media (max-width: 700px) { .fback:not([hidden]) { display: block; position: fixed; inset: 0; z-index: 24; background: rgba(11,12,14,.38); } }

/* ---------- Live (redesign 10/13): chart full width, today's numbers, then cards ---------- */
.lvbar { gap: 10px; margin-bottom: 16px; }
.lvbar .lvchan { height: 40px; border-radius: 999px; padding: 0 14px; border: 1px solid var(--line); background: var(--surface); font-weight: 600; }
.lvbar .daybar input { height: 40px; border-radius: 999px; }
.phact .lvbadge { margin: 0 6px 0 0; font-size: 13px; }
.tvbtn { display: inline-flex; align-items: center; gap: 8px; }
.lvcard { padding: 18px 20px 10px; border-radius: var(--r-lg); margin-bottom: 24px; }
.lvhead { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.lvhead .seg { margin: 0 0 0 auto; }
.lvtitle { margin: 0 !important; font-size: 15px; letter-spacing: .1em; }
.lvhint { flex: 1 1 auto; text-align: right; }
.lvlines { margin-bottom: 12px; gap: 8px 16px; font-size: 14px; font-weight: 600; }
.lvchk { color: var(--ink); }
.lvside { display: block; }
.lvsec { margin: 0 2px 12px !important; }
.lvkpis { margin-bottom: 20px; }
.lvk .kpi-l { min-height: 0; }
.lvk .kpi-n { white-space: normal; }
.lvk b.good { color: var(--success); } .lvk b.warn { color: var(--warn); }
.lvcards { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 16px; margin-bottom: 24px; }
.lvside .lvcards .card { margin: 0; padding: 18px 20px; border-radius: 18px; }
.lvsh { font-family: var(--body); font-weight: 800; font-size: 13px; letter-spacing: .1em; color: var(--ink); margin-bottom: 12px; }
.lvbig { font-weight: 800; font-size: 34px; line-height: 1.05; margin-bottom: 10px; }
.lvbig.good { color: var(--success); } .lvbig.warn { color: var(--warn); }
.lvbig3 b { font-family: var(--body); font-weight: 800; font-size: 34px; }
.lvneed { margin-top: 6px; }
.lvtops { display: grid; grid-template-columns: repeat(auto-fit, minmax(380px, 1fr)); gap: 16px; align-items: start; }
.lvtops .lvtop { margin: 0; padding: 18px 20px; border-radius: 18px; }
.lvtops .lvsh .muted { font-weight: 600; letter-spacing: 0; }
@media (max-width: 700px) {
  .lvcard { padding: 14px 12px 8px; } .lvhint { display: none; } .lvtops { grid-template-columns: 1fr; }
  .lvbar { gap: 8px; } .lvbar .lvchan { flex: 1 1 100%; }
}
/* TV mode: a wall screen — no header or controls, big numbers */
body.tv header, body.tv .bnav, body.tv .lvbar, body.tv .lvtops, body.tv #lvNote, body.tv .lvhint, body.tv #lvView { display: none !important; }
body.tv main { max-width: none; padding: 24px 32px; }
body.tv .ptitle { font-size: 56px; }
body.tv .psub { font-size: 20px; }
body.tv .lvk b { font-size: 48px; }
body.tv .lvk .kpi-l { font-size: 16px; }
body.tv .lvcards { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 700px) {
  .phact .tvbtn.btn { display: none; }
  .lvhead { flex-wrap: nowrap; margin-bottom: 8px; } .lvtitle { font-size: 13px; }
  .lvhead .seg button { padding: 6px 12px; font-size: 13px; }
  .lvlines { font-size: 13px; gap: 6px 12px; } .lvchk input { width: 15px; height: 15px; }
  .lvbar .seg button { padding: 7px 12px; }
  .lvbar .daybar { flex: 1 1 auto; display: flex; gap: 6px; } .lvbar .daybar input { flex: 1 1 auto; min-width: 0; }
  .lvbig, .lvbig3 b { font-size: 28px; }
}

/* ---------- associate home (redesign 10/13): black task card, big timer ---------- */
.card.active-card { background: #0B0C0E; color: #fff; border: 0; border-radius: 24px; padding: 22px 22px 24px; text-align: left; }
.active-card .badge.on { background: transparent; color: #8AC4EC; padding: 0; font-size: 13px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.active-card .badge.on::before { background: #4ADE80; width: 8px; height: 8px; }
.active-card .task-line { color: #fff; font-family: var(--body); font-weight: 800; font-size: 32px; line-height: 1.05; letter-spacing: .03em; }
.active-card .small.muted, .active-card .muted { color: #A7ADB8; }
.active-card .label { color: #C9CED6; font-size: 16px; }
.active-card .timer { color: #fff; font-family: var(--body); font-weight: 800; font-size: 68px; letter-spacing: -.01em; text-align: left; margin: 12px 0 2px; }
.scanwrap { text-align: center; margin-bottom: 14px; }
.scanwrap:empty { display: none; }
.scanwrap .scanbox { background: transparent; gap: 12px; margin: 0 0 12px; overflow: visible; }
.scanwrap .scanbox > div { background: var(--surface); border-radius: 18px; padding: 16px 18px; text-align: left; box-shadow: var(--shadow); border: 0 !important; }
.scanwrap .scanbox b { font-family: var(--body); font-weight: 800; font-size: 40px; line-height: 1; }
.scanwrap .scanbox span { font-size: 14px; font-weight: 600; text-transform: none; letter-spacing: 0; color: var(--muted); margin-top: 4px; }
.scanwrap .scanmsg { text-align: left; border-radius: 14px; padding: 12px 14px; }
.scanwrap .recent { background: var(--surface); border-radius: 18px; padding: 12px 14px; box-shadow: var(--shadow); }
.scanwrap .recent:empty { display: none; }
.btn.big { border-radius: 20px; font-family: var(--body); font-weight: 800; letter-spacing: .08em; }
.btn.big .sub { font-family: var(--body); letter-spacing: 0; }
/* Outbound station (redesign 10/13): big count left, yours right, the scan box under them */
.card.obcard { text-align: left; border-radius: 24px; padding: 20px; }
.obcard .badge.on { padding: 0; background: transparent; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; font-size: 12px; }
.obnums { display: flex; align-items: flex-end; gap: 16px; margin: 10px 0 4px; }
.obnums .obbig { flex: 1; margin: 0; }
.obnums .obbig b { font-family: var(--body); font-weight: 800; font-size: 64px; line-height: .95; }
.obnums .obbig span, .obmine span { font-size: 14px; font-weight: 600; color: var(--muted); text-transform: none; letter-spacing: 0; margin-top: 4px; display: block; }
.obmine { text-align: right; }
.obmine b { display: block; font-family: var(--body); font-weight: 800; font-size: 32px; line-height: 1; color: var(--brand-ink); }
.obcard .oblast { border-radius: 14px; }
.obscan { display: flex; gap: 8px; }
.obscan input { flex: 1; min-width: 0; height: 52px; border-radius: 14px; border: 1.5px solid var(--brand-ink); }
.obscan .btn { width: auto; height: 52px; min-height: 52px; border-radius: 14px; padding: 0 18px; }
.oblisthead h2 { font-size: 15px; letter-spacing: .12em; }
.card.oblist { border-radius: 20px; padding: 4px 18px; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .card.active-card { background: #17191D; box-shadow: 0 0 0 1px #2A2D33; } }
:root[data-theme="dark"] .card.active-card { background: #17191D; box-shadow: 0 0 0 1px #2A2D33; }

/* ---------- Inbound Processing (redesign 10/13) ---------- */
.inb { max-width: none; }
.inbgrid { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(300px, 1fr); gap: 24px; align-items: start; }
@media (max-width: 1000px) { .inbgrid { grid-template-columns: 1fr; gap: 8px; } }
.inb h2.inbh { margin: 6px 2px 12px; font-size: 13px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--ink); }
.inb h2.inbh .muted { font-weight: 600; letter-spacing: 0; margin-left: 4px; }
.inbside .card, .inbmain .card { border-radius: 20px; padding: 16px 18px; }
.inbside > h2.inbh ~ h2.inbh { margin-top: 22px; }
.floorline { background: var(--surface); border-radius: 14px; padding: 10px 16px; box-shadow: var(--shadow); margin: 0 0 22px; font-size: 14px; }
.gcards { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 16px; }
.gcard { border-left: 0; border-radius: 22px; padding: 18px 18px 16px; gap: 12px; }
.gtitle b { font-size: 17px; font-weight: 700; }
.gmeta { font-size: 14px; margin-top: 3px; }
.gcard.running .gstate, .gcard.paused .gstate { display: inline-flex; align-items: center; padding: 2px 9px; border-radius: 999px; font-size: 12.5px; }
.gcard.running .gstate { background: var(--success-bg); } .gcard.paused .gstate { background: var(--warn-bg); }
.gp { border: 0; background: var(--surface-2); padding: 6px 12px 6px 10px; font-size: 14px; }
.gp.paused { background: var(--warn-bg); }
.gp:hover { box-shadow: inset 0 0 0 1.5px var(--brand); }
.gbtns { display: grid; grid-template-columns: repeat(auto-fit, minmax(90px, 1fr)); gap: 8px; }
.gbtns .btn { min-height: 44px; }
.gbtns .btn.gray { background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.solorow { padding: 10px 0; }
.inbsec.h2row { margin: 30px 2px 12px; }
.flist { border-radius: 20px; padding: 2px 18px; }
@media (max-width: 700px) { .floorline { margin-bottom: 14px; } .gcards { grid-template-columns: 1fr; } }

/* ---------- every other section (redesign 10/13): one card, number, table and toolbar look ---------- */
/* number cards everywhere (Outbound, Reports, People) */
.kpi { border: 0; border-radius: 18px; padding: 16px 18px; gap: 6px; }
.kpi-l { font-size: 13px; }
.kpi b { font-family: var(--body); font-weight: 800; font-size: 30px; line-height: 1.05; }
.stat { border: 0; border-radius: 18px; padding: 14px 16px; }
.stat b { font-family: var(--body); font-weight: 800; }
.pkpis { margin-bottom: 14px; }
.pkpis b.good { color: var(--success); }
/* cards and lists */
#adminBody .card { border-radius: 20px; }
#adminBody .card.ft-card, #adminBody .compact.rboard { border-radius: 20px; }
.ft-card { overflow: hidden; }
/* tables: quiet caps header, roomier rows */
table.trend thead th, #adminBody table th { font-size: 11.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); background: var(--surface); border-bottom: 1px solid var(--line); }
table.trend th, table.trend td { padding: 10px 12px; }
#adminBody table td { padding-top: 12px; padding-bottom: 12px; }
#adminBody table tbody tr:hover td { background: color-mix(in srgb, var(--surface-2) 60%, var(--surface)); }
.tt-wrap { border-top: 0; }
/* toolbars: date pickers and pills in the page header */
.phact .daybar { margin: 0; display: flex; gap: 6px; align-items: center; }
.phact .daybar input { height: 40px; border-radius: 999px; padding: 0 14px; width: auto; margin: 0; border: 1px solid var(--line); background: var(--surface); }
.phact .daybar .btn.sm { margin: 0; min-height: 40px; min-width: 40px; justify-content: center; }
#adminBody .daybar input[type=date] { border-radius: 999px; }
#adminBody .seg { margin-bottom: 14px; }
#adminBody .h2row .seg { margin-bottom: 0; }
/* People */
.pboard { gap: 14px; }
.pcard { border: 0; border-radius: 18px; padding: 14px 16px; }
.pcard:hover { border: 0; box-shadow: var(--shadow), inset 0 0 0 1.5px var(--brand); }
.pcard-hrs { font-family: var(--body); font-weight: 800; color: var(--ink); }
.away { margin: 18px 2px 6px; }
.away span { border: 0; }
.feed { border-radius: 20px; padding: 4px 18px; }
details.pact > summary { list-style: none; cursor: pointer; margin: 26px 2px 10px; }
details.pact > summary::-webkit-details-marker { display: none; }
details.pact > summary h2 { margin: 0; }
details.pact > summary h2::before { content: '▸ '; color: var(--faint); }
details.pact[open] > summary h2::before { content: '▾ '; }
details.pact > select { max-width: 320px; margin-bottom: 10px; }
/* Review */
.rvlist { padding: 2px 18px; }
.rvrow { display: flex; align-items: center; gap: 14px; padding: 14px 0; border-top: 1px solid var(--line); }
.rvrow:first-child { border-top: 0; }
.rvmain { flex: 1; min-width: 0; }
.rvnote { margin-top: 4px; font-size: 15px; }
.rvrow .btn { flex: 0 0 auto; margin: 0; }
.rvgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(380px, 1fr)); gap: 14px; }
.rvgrid .card { margin: 0; padding: 16px 18px; }
.rvhelp { max-width: 900px; margin: -2px 2px 8px; }
@media (max-width: 700px) { .rvgrid { grid-template-columns: 1fr; } .rvrow { flex-wrap: wrap; } }
/* Holds */
.flrow .link { display: inline; width: auto; margin: 0; padding: 0; }
.flrow .btn.sm { margin: 0; flex: 0 0 auto; }
.flcard-add textarea { border-radius: 14px; }
/* Fulfillment → Table: the filters on one line on computers */
@media (min-width: 900px) {
  #adminBody > .card.filters { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px 14px; padding: 16px 18px; }
  #adminBody > .card.filters > .row { display: contents; }
  #adminBody > .card.filters > .row > div { flex: 1 1 150px; }
  #adminBody > .card.filters .field { margin-top: 0; }
  #adminBody > .card.filters > .row:last-child > span { flex: 1 1 100%; order: 9; }
  #adminBody > .card.filters #bfCsv { order: 8; margin: 0 0 0 auto; height: 42px; }
}
#adminBody > .card.filters input, #adminBody > .card.filters select { border-radius: 12px; height: 42px; padding-top: 0; padding-bottom: 0; }
/* Admin → Settings chips and forms */
#adminBody .chip { border: 0; background: var(--surface-2); padding: 6px 12px; font-size: 13.5px; }
.addrow { display: flex; gap: 10px; align-items: center; padding: 12px 14px; }
.addrow input { flex: 1; margin: 0; height: 46px; border-radius: 12px; }
.addrow .btn { width: auto; margin: 0; padding: 0 22px; flex: 0 0 auto; }
p .link, .small .link, .floorline .link { display: inline; width: auto; padding: 0; margin: 0; }
/* pill rows never wrap into two lines: they scroll sideways on phones */
#adminBody .seg, .phact .seg { max-width: 100%; overflow-x: auto; scrollbar-width: none; flex-wrap: nowrap; }
#adminBody .seg::-webkit-scrollbar { display: none; }
#adminBody .seg button, .phact .seg button { white-space: nowrap; flex: 0 0 auto; }
.flrow .btn.sm, .btn.sm { white-space: nowrap; }
.flrow .btn.sm { flex-direction: row; min-height: 40px; }
.flrow > .btn.sm { align-self: center; }
@media (max-width: 700px) { .flrow > .small.muted { flex: 1 1 100% !important; } }

/* ---------- Inbound by task (10/13) ---------- */
.ikpis { margin-bottom: 14px; }
.ikpis b.good { color: var(--success); }
.gcards.tcards { display: grid; grid-template-columns: repeat(auto-fill, minmax(380px, 1fr)); gap: 18px; align-items: start; }
.card.tcard { margin: 0; padding: 18px; border-radius: 22px; display: flex; flex-direction: column; gap: 12px; }
.tchead { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.inb .tcname, .tcname { margin: 0; font-family: var(--body); font-weight: 800; font-size: 20px; letter-spacing: .04em; text-transform: uppercase; line-height: 1.1; }
.tcmeta { font-size: 14px; color: var(--muted); margin-top: 4px; }
.tcadd { flex: 0 0 auto; width: 40px; height: 40px; border-radius: 50%; border: 0; background: var(--info-bg); color: var(--brand-ink); font-size: 24px; font-weight: 500; line-height: 1; cursor: pointer; }
.tcadd:hover { background: var(--brand-ink); color: #fff; }
.tcard .card.gcard, .tcard .card.jobcard { margin: 0; box-shadow: none; background: var(--surface-2); border-radius: 16px; padding: 14px; border: 0; }
.tcard .gcard .gtitle b { font-size: 15px; }
.tcard .gbtns .btn.gray { background: var(--surface); }
.tcsec { border-top: 1px solid var(--line); padding-top: 10px; }
.tcsl { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.tcard .solorow { border-top: 0; padding: 6px 0; }
@media (max-width: 700px) { .gcards.tcards { grid-template-columns: 1fr; gap: 12px; } .card.tcard { padding: 14px; } }
/* the Assign sheet */
.seg.wmode { display: flex; width: 100%; margin: 0 0 6px; }
.seg.wmode button { flex: 1; padding: 10px 12px; font-size: 15px; }
.seg.wmode button:disabled { opacity: .4; cursor: not-allowed; }
#wModeHint { margin: 0 2px 4px; }
.wnew { background: var(--surface-2); border-radius: 14px; padding: 4px 12px 12px; margin-top: 8px; }

/* ---------- Fulfillment: one Filters bar for Board and Table (v1.2) ---------- */
.fbar { display: flex; align-items: center; gap: 12px; margin: 0 0 12px; padding: 0 2px; }
.fbar .fshow { flex: 1; font-size: 14px; color: var(--muted); margin: 0; }
.fbar .fshow b { color: var(--ink); }
.fbar .fwrap { padding-bottom: 0; }
.fchip.off { background: var(--surface-2); color: var(--muted); }
#stFilter, #ppFilter { display: grid; grid-template-columns: 1fr 1fr; column-gap: 8px; }
@media (max-width: 700px) { .fbar .fwrap { position: static; } #stFilter, #ppFilter { grid-template-columns: 1fr; } }
@media (min-width: 701px) { .fmenu { width: 400px; } #ppFilter { grid-template-columns: 1fr; } }
/* group buttons: long labels ("Resume paused (2)") wrap inside the button instead of spilling out */
.gbtns { grid-template-columns: repeat(auto-fit, minmax(118px, 1fr)); }
.gbtns .btn, .gbtns .btn.sm { white-space: normal; line-height: 1.15; text-align: center; justify-content: center; padding: 8px 12px; min-width: 0; overflow-wrap: anywhere; }

/* ---------- Add batches sheet (10/13): labelled fields, room between them, stages as pills ---------- */
@media (min-width: 700px) { .sheet .panel:has(.addb) { max-width: 640px; padding: 26px 28px 22px; } }
.addb .task-line { margin-bottom: 4px; }
.addb > .label { margin-bottom: 18px; }
.bf { display: flex; flex-direction: column; gap: 6px; margin: 0; }
.bf > span { font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.bf > span em { font-style: normal; font-weight: 500; text-transform: none; letter-spacing: 0; color: var(--faint); }
.bf select, .bf input { margin: 0; height: 46px; padding: 0 14px; font-size: 15px; border-radius: 12px; }
.bdate { margin-bottom: 18px; }
.bdate input { max-width: 240px; }
.addb .brow { border: 0; background: var(--surface); border-radius: 18px; padding: 16px 18px 18px; margin-bottom: 14px; box-shadow: var(--shadow); }
.addb .brow-h { margin-bottom: 14px; font-size: 13px; }
.addb .brow-h b { font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.addb .brow-h .link { margin: 0; padding: 4px 0; font-size: 14px; color: var(--danger); }
.bgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 12px; margin-bottom: 16px; }
.addb .brow-st { gap: 8px; padding: 8px 0 0; }
.addb .brow-st label { position: relative; padding: 8px 14px 8px 36px; border-radius: 999px; background: var(--surface-2); font-size: 14px; font-weight: 600; cursor: pointer; min-height: 38px; }
.addb .brow-st label:has(input:checked) { background: var(--info-bg); color: var(--brand-ink); box-shadow: inset 0 0 0 1.5px var(--brand-ink); }
.addb .brow-st label:has(input:disabled) { cursor: default; }
.addb .brow-st input { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; accent-color: var(--brand-ink); }
.addb .brow-st .small { font-weight: 500; }
.addb .badd { background: transparent; border: 1.5px dashed var(--line); color: var(--brand-ink); margin: 4px 0 18px; }
.addb .badd:hover { background: var(--info-bg); border-color: var(--brand-ink); }
@media (max-width: 699px) { .bgrid { gap: 12px 10px; } .addb .brow { padding: 14px; } .bdate input { max-width: none; } }

/* ---------- Edit times on a batch stage (sql/067) ---------- */
.etimes .etrow { background: var(--surface); border-radius: 16px; padding: 12px 14px 14px; margin-bottom: 10px; box-shadow: var(--shadow); }
.etimes .etrow.off { opacity: .6; }
.etimes .etrow.add { box-shadow: inset 0 0 0 1.5px var(--brand-ink); }
.eth { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; font-size: 15px; }
.eth .etx { margin: 0 0 0 auto; padding: 2px 0; width: auto; color: var(--danger); }
.etgrid { display: grid; grid-template-columns: 1fr 1fr 90px; gap: 10px; }
.etgrid .etwho { grid-column: 1 / -1; }
.etimes input[type=datetime-local] { min-width: 0; }
.etclosed { margin: 6px 0 14px; } .etclosed input { max-width: 260px; }
.etprev { background: var(--surface); border-radius: 16px; padding: 12px 16px; margin: 14px 0 6px; box-shadow: var(--shadow); }
.etprev ul { margin: 4px 0 10px; padding-left: 18px; font-size: 14px; } .etprev li { margin: 3px 0; }
.etprev .fsl.bad, .etprev ul.bad { color: var(--danger); } .etprev .fsl.warn, .etprev ul.warn { color: var(--warn); }
@media (max-width: 699px) { .etgrid { grid-template-columns: 1fr 1fr; } .etgrid .etord { grid-column: 1 / -1; } .etclosed input { max-width: none; } }
.etgrid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 84px; }
@media (max-width: 699px) { .etgrid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
.etgrid input[type=datetime-local] { padding: 0 10px; font-size: 14px; }
@media (max-width: 699px) { .etgrid { grid-template-columns: minmax(0, 1fr); } .etgrid .etord { grid-column: auto; } }

/* ---- Brand: Opsidian (v1.4.0) — shard mark + spaced caps wordmark in the header ---- */
#logo, header #logo { width: 30px; height: 30px; border-radius: 0; box-shadow: none; object-fit: contain; }
#title.brand { font-family: var(--body); font-weight: 600; letter-spacing: .22em; }
@media (max-width: 700px) { #logo, header #logo { width: 26px; height: 26px; } #title.brand { letter-spacing: .18em; } }
