:root {
  --bg: #f3f6f3;
  --bg-2: #ffffff;
  --card: #ffffff;
  --card-2: #eef8ee;
  --ink: #121612;
  --muted: #3d4a3d;
  --faint: #667266;
  --line: #c5e8c5;
  --lime: #32CD32;
  --lime-dk: #1b8c1b;
  --lime-ink: #0a2a0a;
  --yellow: #32CD32;
  --yellow-ink: #0a2a0a;
  --ok: #157a15;
  --ok-bg: #e3f8e3;
  --soon: #c47a00;
  --soon-bg: #fff4dc;
  --over: #d61f1a;
  --over-bg: #fde8e6;
  --idle: #5c6b5c;
  --idle-bg: #e8eee8;
  --bus: #0b4a86;
  --skoolie: #6a4b00;
  --truck: #4a2080;
  --van: #0d5c56;
  --danger: #d61f1a;
  --shadow: 0 8px 24px rgba(18, 40, 18, 0.08);
  --radius: 14px;
  --tap: 48px;
  --font: "Segoe UI", "Trebuchet MS", "Helvetica Neue", sans-serif;
  --cond: "Arial Narrow", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; background: var(--bg); color: var(--ink); font-family: var(--font); }
html { -webkit-text-size-adjust: 100%; }
body {
  min-height: 100dvh;
  font-size: 17px;
  line-height: 1.35;
}
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: var(--lime-dk); }
:focus-visible {
  outline: 3px solid var(--lime);
  outline-offset: 2px;
}

.app { min-height: 100dvh; display: flex; flex-direction: column; }

.top {
  position: sticky; top: 0; z-index: 20;
  background: #ffffff;
  border-bottom: 4px solid var(--lime);
  padding: 12px 16px 10px;
}
.top-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.brand { min-width: 0; }
.kicker {
  font-family: var(--cond);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 700;
  color: var(--lime-dk);
  margin: 0 0 2px;
}
h1 {
  margin: 0;
  font-size: 28px;
  letter-spacing: -0.02em;
  line-height: 1.1;
  color: var(--ink);
}
.sub {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 14px;
}
.sub strong { color: var(--ink); font-weight: 650; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.top-tools { display: flex; flex-wrap: nowrap; gap: 8px; align-items: center; flex-shrink: 0; }
.tabs {
  display: flex;
  flex-wrap: nowrap;
  gap: 8px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  margin: 8px -16px 0;
  padding: 0 16px 10px;
}
.tabs::-webkit-scrollbar { display: none; }
.tabs .btn { flex: 0 0 auto; }

@media (max-width: 720px) {
  .top { padding: 8px 12px 0; }
  .top-row { align-items: center; gap: 8px; }
  h1 { font-size: 20px; }
  .kicker, .yard { display: none; }
  .sub { font-size: 12px; margin-top: 2px; }
  .top-tools .btn, .tabs .btn { min-height: 40px; padding: 0 12px; }
  .tabs { margin: 8px -12px 0; padding: 0 12px 8px; }
}

.btn {
  min-height: var(--tap);
  padding: 0 16px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--ink);
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--lime); color: var(--lime-ink); border-color: #22b422; }
.btn-ghost { background: transparent; }
.btn-danger { background: var(--over-bg); border-color: #e4a09c; color: #8a1410; }
.btn-ok { background: var(--ok-bg); border-color: #8fd48f; color: var(--ok); }
.btn-defect { background: var(--over-bg); border-color: #e4a09c; color: #8a1410; }
.btn-wide { width: 100%; }
.btn[disabled] { opacity: 0.5; cursor: not-allowed; }
.btn.picked { outline: 3px solid var(--lime); outline-offset: 1px; }
.nav-bubble {
  display: inline-flex;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: #d61f1a;
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  align-items: center;
  justify-content: center;
  line-height: 1;
}
.btn-primary .nav-bubble { background: #8a1410; color: #fff; }

.counts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 8px;
  padding: 12px 16px 0;
}
.count {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px;
  text-align: left;
  min-height: 64px;
  cursor: pointer;
}
.count:hover { border-color: var(--lime); }
.count .n { font-size: 28px; font-weight: 800; line-height: 1; }
.count .l { margin-top: 4px; font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); font-weight: 700; }
.count.active { outline: 2px solid var(--lime); }
.count.over .n { color: var(--over); }
.count.soon .n { color: var(--soon); }
.count.ok .n { color: var(--ok); }

.toolbar {
  padding: 12px 16px 8px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.search {
  width: 100%;
  min-height: var(--tap);
  padding: 0 14px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--bg-2);
}
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  min-height: 40px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--card);
  font-weight: 700;
  font-size: 14px;
}
.chip.on { background: var(--lime); color: var(--lime-ink); border-color: #22b422; }

.main { padding: 8px 16px 32px; flex: 1; }

.board {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}
@media (min-width: 720px) {
  .board { grid-template-columns: 1fr 1fr; }
}
@media (min-width: 1100px) {
  .board { grid-template-columns: 1fr 1fr 1fr; }
}

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px 14px 12px;
  text-align: left;
  box-shadow: var(--shadow);
  border-left: 7px solid var(--lime);
  min-height: 132px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.card.st-overdue { border-left-color: var(--over); }
.card.st-due_soon { border-left-color: var(--soon); }
.card.st-ok { border-left-color: var(--lime); }
.card.st-not_logged { border-left-color: var(--idle); }
.card-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.badge {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 4px 8px;
  border-radius: 999px;
  background: var(--idle-bg);
  color: var(--idle);
}
.badge.bus { background: #e8f3ff; color: var(--bus); }
.badge.skoolie { background: #fff4d0; color: var(--skoolie); }
.badge.truck { background: #f3e9ff; color: var(--truck); }
.badge.van { background: #e4f8f6; color: var(--van); }
.badge.overdue { background: var(--over-bg); color: var(--over); }
.badge.due_soon { background: var(--soon-bg); color: var(--soon); }
.badge.ok { background: var(--ok-bg); color: var(--ok); }
.badge.not_logged { background: var(--idle-bg); color: var(--idle); }
.badge.defects, .badge.dvir-defects { background: var(--over-bg); color: var(--over); }
.badge.clear, .badge.cleared { background: var(--ok-bg); color: var(--ok); }
.badge.shared { background: var(--ok-bg); color: var(--ok); }
.badge.local-only { background: var(--soon-bg); color: var(--soon); text-transform: none; letter-spacing: 0.02em; }
.inbox-hint {
  margin: 8px 0 0;
  font-size: 13px;
  font-weight: 650;
  color: var(--ok);
}
.inbox-hint.local { color: var(--soon); }
.badge.oil { background: #fff4dc; color: #6a4b00; }
.badge.filters { background: #e8f3ff; color: #0b4a86; }
.badge.brakes { background: var(--over-bg); color: #8a1410; }
.badge.tires { background: #ececec; color: #333; }
.badge.electrical { background: #fff4d0; color: #6a4b00; }
.badge.body { background: #e4f8f6; color: #0d5c56; }
.badge.other { background: var(--idle-bg); color: var(--idle); }
.badge.deaf { background: var(--lime); color: var(--lime-ink); border: 1px solid #22b422; }
.card h2 { margin: 0; font-size: 22px; }
.card .next { color: var(--ink); font-weight: 650; }
.card .meta { color: var(--muted); font-size: 14px; }
.empty {
  padding: 40px 16px;
  text-align: center;
  color: var(--muted);
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.detail-head {
  display: flex; align-items: flex-start; gap: 10px; flex-wrap: wrap;
  margin-bottom: 12px;
}
.detail-head h2 { margin: 0; font-size: 30px; }
.panel {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px;
  margin-bottom: 12px;
}
.panel h3 {
  margin: 0 0 10px;
  font-size: 13px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--lime-dk);
}

.grid-2 { display: grid; grid-template-columns: 1fr; gap: 10px; }
@media (min-width: 720px) { .grid-2 { grid-template-columns: 1fr 1fr; } }

label.field { display: flex; flex-direction: column; gap: 6px; font-weight: 700; font-size: 14px; color: var(--muted); }
.field input, .field select, .field textarea {
  min-height: var(--tap);
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--bg-2);
  width: 100%;
}
.field select, .toolbar-select {
  border: 2px solid var(--lime);
  background: #ffffff;
  font-weight: 700;
  min-height: var(--tap);
}
.toolbar-select {
  width: 100%;
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 17px;
}
.toolbar-field { width: 100%; }
.log-fast {
  align-items: flex-end;
  gap: 10px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 4px;
}
.log-fast .btn { min-height: var(--tap); min-width: 96px; }
.field textarea { min-height: 88px; resize: vertical; }
.row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

.svc {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}
.svc:last-child { border-bottom: 0; }
@media (min-width: 800px) {
  .svc { grid-template-columns: 1.4fr 1fr auto; align-items: center; }
}
.svc.off { opacity: 0.45; }
.svc-name { font-weight: 800; font-size: 18px; }
.svc-int { color: var(--muted); font-size: 14px; margin-top: 2px; }
.svc-due { font-weight: 700; }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.warn { color: var(--over); font-weight: 800; }
.soon-txt { color: var(--soon); font-weight: 800; }
.ok-txt { color: var(--ok); font-weight: 800; }

.hist {
  width: 100%;
  border-collapse: collapse;
}
.hist th, .hist td {
  text-align: left;
  padding: 10px 8px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
.hist th {
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--faint);
}
.table-wrap { overflow-x: auto; }

.modal {
  width: min(560px, calc(100vw - 24px));
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--bg-2);
  color: var(--ink);
  padding: 0;
  box-shadow: var(--shadow);
}
.modal::backdrop { background: rgba(18, 40, 18, 0.45); }
.modal-h { padding: 16px 16px 8px; }
.modal-h h3 { margin: 0; font-size: 22px; }
.modal-b { padding: 8px 16px 16px; display: flex; flex-direction: column; gap: 10px; }
.modal-f { padding: 12px 16px 16px; display: flex; gap: 8px; justify-content: flex-end; flex-wrap: wrap; }

.toast {
  position: fixed;
  left: 50%;
  bottom: 20px;
  transform: translateX(-50%);
  background: var(--lime);
  color: var(--lime-ink);
  font-weight: 800;
  padding: 12px 18px;
  border-radius: 999px;
  z-index: 50;
  box-shadow: var(--shadow);
}

.toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  font-weight: 700;
}
.toggle input { width: 20px; height: 20px; accent-color: var(--lime); }

.help {
  background: var(--card-2);
  border: 1px dashed var(--lime-dk);
  border-radius: 12px;
  padding: 12px;
  color: var(--muted);
  font-size: 14px;
}

.file-btn { position: relative; overflow: hidden; }
.file-btn input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }

.yard {
  margin-top: 4px;
  color: var(--faint);
  font-size: 13px;
}

.check {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px;
  background: #f7fbf7;
  margin-bottom: 8px;
}
.check.ok { border-color: #8fd48f; background: var(--ok-bg); }
.check.defect { border-color: #e4a09c; background: var(--over-bg); }
.check-top {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
}
.check-name { font-weight: 800; font-size: 17px; }
.seg { display: flex; gap: 8px; flex-wrap: wrap; }
.seg .btn { flex: 1; min-width: 120px; }
.sig-input {
  font-family: "Segoe Script", "Bradley Hand", "Comic Sans MS", cursive;
  font-size: 22px;
}
.qty-n { font-size: 26px; font-weight: 800; color: var(--lime-dk); }
.stock-card { min-height: 160px; }

.badge.missing-info { background: var(--soon-bg); color: var(--soon); }
.wo-app .wo-main { max-width: 8.6in; margin: 0 auto; width: 100%; }
.wo-sheet {
  background: #fff;
  border: 2px solid var(--lime-dk);
  color: var(--ink);
  padding: 14px 16px 18px;
  box-shadow: var(--shadow);
}
.wo-head { display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 8px; margin-bottom: 10px; }
.wo-kicker {
  grid-column: 1 / -1;
  margin: 0;
  font-family: var(--cond);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 11px;
  font-weight: 700;
  color: var(--lime-dk);
}
.wo-title {
  margin: 0;
  font-size: 28px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 800;
}
.wo-num { font-weight: 800; font-size: 18px; color: var(--lime-dk); }
.wo-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 16px;
  margin-bottom: 8px;
}
.wo-line {
  display: flex;
  align-items: baseline;
  gap: 8px;
  font-weight: 800;
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink);
}
.wo-line input, .wo-line select {
  flex: 1;
  min-height: 34px;
  border: none;
  border-bottom: 1px solid #121612;
  border-radius: 0;
  background: transparent;
  padding: 2px 4px;
  font-weight: 650;
  text-transform: none;
  letter-spacing: 0;
}
.wo-span { grid-column: 1 / -1; }
.wo-gr { align-items: center; flex-wrap: wrap; }
.wo-check { display: inline-flex; align-items: center; gap: 6px; font-weight: 800; text-transform: none; letter-spacing: 0; font-size: 14px; }
.wo-check input { width: 16px; height: 16px; accent-color: var(--lime); }
.wo-block h3 {
  margin: 12px 0 6px;
  font-size: 13px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border-top: 2px solid #121612;
  padding-top: 8px;
}
.wo-h-note { font-weight: 600; letter-spacing: 0; text-transform: none; color: var(--muted); }
.wo-lined {
  width: 100%;
  border: 1px solid #121612;
  border-radius: 0;
  background-color: #fff;
  background-image: repeating-linear-gradient(to bottom, transparent 0, transparent 27px, #c5e8c5 27px, #c5e8c5 28px);
  line-height: 28px;
  padding: 0 8px;
  resize: vertical;
}
.wo-lined-lg { min-height: 168px; }
.wo-lined-sm { min-height: 84px; }
.wo-parts { width: 100%; border-collapse: collapse; }
.wo-parts th {
  text-align: left;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 4px 6px;
  border-bottom: 2px solid #121612;
}
.wo-parts td { border-bottom: 1px solid #121612; padding: 0 4px; }
.wo-parts input {
  width: 100%;
  border: none;
  background: transparent;
  min-height: 32px;
  padding: 4px;
}
.wo-parts th:last-child, .wo-parts td:last-child { width: 72px; }
.wo-signs {
  display: grid;
  grid-template-columns: 1fr 140px;
  gap: 10px 16px;
  margin-top: 12px;
  padding-top: 8px;
  border-top: 2px solid #121612;
}

@media (max-width: 700px) {
  .wo-meta, .wo-signs { grid-template-columns: 1fr; }
}

@media print {
  @page { size: letter portrait; margin: 0.4in; }
  html, body { background: #fff !important; color: #000 !important; }
  .top, .toast, .screen-only, .modal { display: none !important; }
  .main { padding: 0 !important; }
  .app { min-height: 0; }
  .wo-sheet {
    border: 2px solid #000;
    box-shadow: none;
    padding: 8px 10px;
    color: #000;
  }
  .wo-kicker, .wo-num, .wo-h-note { color: #000 !important; }
  .wo-title { font-size: 22px; }
  .wo-lined {
    background-image: repeating-linear-gradient(to bottom, transparent 0, transparent 21px, #000 21px, #000 22px);
    border-color: #000;
    line-height: 22px;
    color: #000;
  }
  .wo-lined-lg { min-height: 132px; }
  .wo-lined-sm { min-height: 66px; }
  .wo-line input, .wo-line select, .wo-parts input, .wo-lined {
    color: #000 !important;
    border-color: #000 !important;
  }
  .wo-block h3, .wo-parts th, .wo-signs { border-color: #000; }
  .wo-block { break-inside: avoid; }
  .dvir-print-note { display: none !important; }
  .dvir-print-sheet {
    display: block !important;
    page-break-before: always;
    break-before: page;
    border: 2px solid #000;
    box-shadow: none;
    color: #000;
  }
  .dvir-print-grid { width: 100%; border-collapse: collapse; font-size: 12px; }
  .dvir-print-grid th, .dvir-print-grid td { border: 1px solid #000; padding: 4px 6px; }
  .dvir-print-grid .dvir-x { text-align: center; width: 48px; font-weight: 800; }
}
.dvir-print-note { margin: 12px 0 8px; font-weight: 650; }
.dvir-print-sheet { margin-top: 18px; }
.dvir-print-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px 16px;
  margin: 8px 0 12px;
  font-size: 14px;
}
.dvir-print-grid { width: 100%; border-collapse: collapse; }
.dvir-print-grid th, .dvir-print-grid td { border: 1px solid var(--line); padding: 6px 8px; text-align: left; }
.dvir-print-grid .dvir-x { text-align: center; width: 52px; font-weight: 800; }


.sheet-note { margin: 0 0 10px; font-size: 14px; }
.sheet-wrap {
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  max-height: calc(100dvh - 210px);
  box-shadow: var(--shadow);
}
.repair-sheet {
  border-collapse: separate;
  border-spacing: 0;
  width: max(1180px, 100%);
  min-width: 1180px;
  background: #fff;
}
.repair-sheet th, .repair-sheet td {
  border-bottom: 1px solid var(--line);
  border-right: 1px solid var(--line);
  vertical-align: top;
  padding: 10px 8px;
  text-align: left;
}
.repair-sheet thead th {
  position: sticky;
  top: 0;
  z-index: 3;
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 800;
  color: var(--lime-ink);
  background: #eef8ee;
}
.repair-sheet .sticky-col {
  position: sticky;
  background: #fff;
  z-index: 2;
}
.repair-sheet thead .sticky-col {
  z-index: 5;
  background: #eef8ee;
}
.repair-sheet tbody tr:nth-child(even) .sticky-col { background: #f7fbf7; }
.repair-sheet tbody tr:nth-child(even) td.grp-pri { background: #f3fbf3; }
.repair-sheet tbody tr:nth-child(even) td.grp-fut { background: #f7fbf7; }
.col-bus { left: 0; width: 132px; min-width: 132px; max-width: 132px; }
.col-loc { left: 132px; width: 210px; min-width: 210px; max-width: 210px; box-shadow: 6px 0 10px rgba(18, 40, 18, 0.06); }
.bus-cell { display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.bus-no { font-size: 22px; font-weight: 800; line-height: 1.1; }
.bus-name { font-size: 12px; }
.grp-pri { background: #fff; min-width: 560px; }
.grp-fut { background: #f4faf4; min-width: 560px; }
.repair-sheet thead th.grp-pri {
  background: var(--lime);
  color: var(--lime-ink);
  border-bottom: 3px solid var(--lime-dk);
}
.repair-sheet thead th.grp-fut {
  background: #c5e8c5;
  color: var(--lime-ink);
  border-bottom: 3px solid var(--lime-dk);
}
.rgroup { display: flex; flex-direction: column; gap: 6px; min-width: 520px; }
.rline-head, .rline {
  display: grid;
  grid-template-columns: 138px minmax(160px, 1.3fr) minmax(150px, 1fr) auto;
  gap: 6px;
  align-items: center;
}
.rline-head {
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--faint);
  font-weight: 800;
  padding: 0 2px 4px;
}
.rline {
  padding: 6px 0;
  border-top: 1px dashed var(--line);
}
.rline.done { opacity: 0.55; }
.rline-empty { padding: 8px 2px; font-size: 14px; }
.rline-acts { display: flex; flex-wrap: wrap; gap: 6px; }
.rline-acts .btn { min-height: 40px; padding: 0 10px; font-size: 14px; }
.rline-add { margin-top: 4px; }
.sheet-inp {
  min-height: 44px;
  width: 100%;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #fff;
}
.loc-inp { min-height: var(--tap); }
.rline-problem { font-weight: 650; }

@media (max-width: 720px) {
  .sheet-wrap { max-height: none; }
}

.gate-main { max-width: 560px; margin: 0 auto; padding-top: 24px; }
.gate-hero h2 { margin: 4px 0 10px; font-size: 28px; }
.gate-choices {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}
.gate-choice {
  min-height: 88px;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 4px;
  padding: 16px 18px;
  text-align: left;
  white-space: normal;
  width: 100%;
  font-size: 16px;
}
.gate-choice strong { font-size: 22px; }
.gate-choice span { font-weight: 650; color: var(--muted); }
.btn-primary.gate-choice span { color: var(--lime-ink); opacity: 0.8; }

.bus-picker {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 8px;
}
.bus-pick {
  min-height: 84px;
  padding: 10px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #fff;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  text-align: left;
  font-weight: 800;
  font-size: 16px;
}
.bus-pick.picked {
  outline: 3px solid var(--lime);
  outline-offset: 1px;
  background: var(--card-2);
  border-color: #22b422;
}

.confirm-hero { text-align: left; padding: 22px 18px; }
.confirm-hero h2 { margin: 6px 0 10px; font-size: 32px; }

.dvir-friendly .dvir-fields {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.dvir-friendly .check { padding: 14px; }
.dvir-friendly .check-name { font-size: 19px; }
.dvir-friendly .seg .btn { min-height: 52px; font-size: 18px; }
.dvir-friendly #dvir-submit { min-height: 56px; font-size: 20px; }

body.role-driver .top .actions { justify-content: flex-end; }

.dvir-grid-wrap { overflow-x: auto; }
.dvir-grid {
  width: 100%;
  border-collapse: collapse;
  min-width: 520px;
}
.dvir-grid-simple { min-width: 0; }
.dvir-grid th, .dvir-grid td {
  border: 1px solid var(--line);
  padding: 6px 4px;
  text-align: center;
  vertical-align: middle;
}
.dvir-grid thead th {
  background: var(--card-2);
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--lime-dk);
}
.dvir-grid .subhead th { font-size: 11px; letter-spacing: 0.04em; }
.dvir-item-col { text-align: left !important; min-width: 160px; padding: 8px !important; }
.dvir-item-name { font-weight: 800; font-size: 15px; }
.dvir-cell {
  min-height: 44px;
  min-width: 52px;
  width: 100%;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #fff;
  font-weight: 800;
  font-size: 13px;
  padding: 0 6px;
}
.dvir-cell.defect { color: #8a1410; }
.dvir-cell.picked { outline: 3px solid var(--lime); outline-offset: 0; background: var(--ok-bg); }
.dvir-cell.defect.picked { background: var(--over-bg); outline-color: #d61f1a; }
.dvir-other-note {
  margin-top: 6px;
  width: 100%;
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 6px 8px;
  background: #fff;
}
.cert-list { display: flex; flex-direction: column; gap: 8px; }
.cert-opt {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-weight: 700;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}
.cert-opt input { margin-top: 4px; width: 18px; height: 18px; accent-color: var(--lime-dk); }
.card.st-soon { border-left-color: var(--soon); }
.detail-head h2 { font-size: 22px; line-height: 1.2; }

.needed-panel { margin-bottom: 16px; }
.needed-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 10px;
  margin-top: 10px;
}
.needed-card {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px;
  background: #fff;
}
.needed-head {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: flex-start;
}
.needed-list {
  margin: 8px 0 0;
  padding-left: 18px;
}
.needed-list li { margin: 4px 0; }
