@font-face {
  font-family: Manrope;
  src: url("/static/vendor/manrope-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: Manrope;
  src: url("/static/vendor/manrope-latin-500-normal.woff2") format("woff2");
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: Manrope;
  src: url("/static/vendor/manrope-latin-600-normal.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
}
@font-face {
  font-family: Manrope;
  src: url("/static/vendor/manrope-latin-700-normal.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
}
@font-face {
  font-family: Manrope;
  src: url("/static/vendor/manrope-latin-800-normal.woff2") format("woff2");
  font-weight: 800;
  font-display: swap;
}
:root {
  color-scheme: dark;
  --bg: #10171c;
  --sidebar: #0c1217;
  --surface: #151f26;
  --raised: #1c2932;
  --line: #2a3943;
  --subtle-line: #202e37;
  --text: #edf4f6;
  --muted: #a0b1bd;
  --accent: #6adbc6;
  --accent-bg: #18382f;
  --danger: #ff9995;
  --danger-bg: #3c2528;
  --amber: #eed090;
  --amber-bg: #393324;
  --radius: 12px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

.live-demo {
  margin-top: 20px;
  padding: 20px;
  border: 1px solid var(--accent);
  border-radius: 14px;
  background: var(--surface);
  min-width: 0;
}
.live-demo > p { color: var(--muted); margin: 10px 0 16px; }
.live-demo .run-controls { flex-wrap: wrap; }
.live-demo textarea { width: 100%; margin: 8px 0; }
.live-demo pre { white-space: pre-wrap; overflow-wrap: anywhere; }
.live-demo .order { margin: 16px 0; display: block; }
.live-orders { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 700px) { .live-orders { grid-template-columns: 1fr; } }
.live-demo .timeline { padding-left: 0; }
* {
  box-sizing: border-box;
}
html {
  min-width: 320px;
  scroll-behavior: auto;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font:
    13px/1.55 Manrope,
    system-ui,
    sans-serif;
  -webkit-font-smoothing: antialiased;
}
button,
input,
textarea,
select {
  font: inherit;
  color: inherit;
}
button,
a,
input,
textarea,
select {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}
button {
  transition:
    background 0.16s,
    border-color 0.16s,
    color 0.16s;
}
button:hover:not(:disabled) {
  filter: brightness(1.13);
}
a {
  color: var(--accent);
  text-underline-offset: 4px;
}
svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}
.leaflet-container svg,
.leaflet-container svg * {
  width: auto;
  height: auto;
  fill: revert-layer;
  stroke: revert-layer;
  stroke-width: revert-layer;
  stroke-linecap: revert-layer;
  stroke-linejoin: revert-layer;
}
img {
  display: block;
  max-width: 100%;
}
::selection {
  background: #6adbc6;
  color: #10251f;
}
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}
input,
textarea {
  caret-color: var(--accent);
}
input::placeholder,
textarea::placeholder {
  color: #96a8b5;
}
* {
  scrollbar-width: thin;
  scrollbar-color: #3c515f var(--bg);
}
[hidden] {
  display: none !important;
}
.svg-symbols {
  display: none;
}
h1,
h2,
h3,
h4,
p {
  margin: 0;
}
h1,
h2,
h3 {
  text-wrap: balance;
}
h1 {
  font-size: 28px;
  line-height: 1.25;
  letter-spacing: -0.025em;
  font-weight: 700;
}
h2 {
  font-size: 19px;
  letter-spacing: -0.02em;
  font-weight: 700;
}
h3 {
  font-size: 14px;
  font-weight: 700;
}
h4 {
  font-size: 12px;
  font-weight: 600;
}
.muted,
.small {
  color: var(--muted);
}
.small {
  font-size: 12px;
}
.skip-link {
  position: fixed;
  left: 12px;
  top: -100px;
  z-index: 5000;
  padding: 12px;
  background: var(--accent);
  color: #10251f;
}
.skip-link:focus {
  top: 12px;
}
.shell {
  display: grid;
  grid-template-columns: 224px minmax(0, 1fr);
  min-height: 100vh;
}
.sidebar {
  background: var(--sidebar);
  border-right: 1px solid var(--subtle-line);
  display: flex;
  flex-direction: column;
  padding: 28px 16px 18px;
  position: sticky;
  top: 0;
  height: 100vh;
  z-index: 40;
}
.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
  color: var(--text);
  margin: 0 10px 38px;
  font-size: 23px;
  line-height: 1.1;
  font-weight: 800;
  letter-spacing: -0.025em;
}
.brand-ai {
  color: var(--accent);
}
.brand small {
  display: block;
  color: var(--muted);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.01em;
  margin-top: 6px;
}
.primary-nav {
  display: grid;
  gap: 6px;
}
.nav-item {
  display: flex;
  align-items: center;
  gap: 11px;
  border: 0;
  background: none;
  color: var(--muted);
  padding: 11px 12px;
  text-align: left;
  border-radius: 7px;
  font-weight: 600;
}
.nav-item.active {
  background: var(--accent-bg);
  color: #91e8d8;
}
.nav-count {
  margin-left: auto;
  background: #29463e;
  font-size: 11px;
  min-width: 20px;
  text-align: center;
  border-radius: 4px;
}
.survey-list-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 38px 10px 9px;
}
.survey-list-heading h2 {
  font-size: 12px;
  color: var(--muted);
  font-weight: 600;
  letter-spacing: 0;
}
.icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  padding: 7px;
}
.icon-button:hover {
  background: var(--raised);
  color: var(--text);
}
.survey-list {
  display: grid;
  align-content: start;
  gap: 4px;
  overflow: auto;
  padding: 2px;
  flex: 1;
}
.survey-option {
  display: flex;
  gap: 10px;
  align-items: center;
  min-width: 0;
  padding: 11px 9px;
  border: 1px solid transparent;
  background: transparent;
  border-radius: 7px;
  text-align: left;
  color: var(--muted);
}
.survey-option.active {
  border-color: var(--line);
  background: var(--surface);
  color: var(--text);
}
.survey-option svg {
  width: 16px;
}
.survey-option span {
  min-width: 0;
  display: block;
  overflow-wrap: anywhere;
}
.survey-option strong {
  font-size: 12px;
  font-weight: 600;
  display: block;
}
.survey-option small {
  font-size: 11px;
  display: block;
  color: var(--muted);
  margin-top: 3px;
}
.sidebar-footer {
  border-top: 1px solid var(--subtle-line);
  padding: 15px 3px 0;
  display: flex;
  gap: 7px;
  align-items: center;
  color: var(--muted);
  font-size: 11px;
}
.sidebar-footer .icon-button {
  margin-left: auto;
}
.connection-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}
.workspace {
  min-width: 0;
}
.topbar {
  height: 68px;
  border-bottom: 1px solid var(--subtle-line);
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
}
.breadcrumb {
  display: flex;
  gap: 12px;
  font-size: 12px;
  color: var(--muted);
}
.breadcrumb span {
  color: #5d717f;
}
.breadcrumb b {
  color: #d5e0e6;
  font-weight: 500;
}
.topbar-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}
.mode-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-size: 11px;
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 5px 8px;
}
.mode-badge span {
  width: 5px;
  height: 5px;
  background: var(--amber);
  border-radius: 50%;
}
.text-button {
  border: 0;
  background: none;
  color: var(--accent);
  font-size: 12px;
}
.menu-button {
  display: none;
}
main {
  padding: 30px 32px 20px;
  max-width: 1700px;
  margin: auto;
}
.page-heading {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  margin-bottom: 27px;
}
.page-heading p {
  color: var(--muted);
  font-size: 12px;
  margin-top: 8px;
}
.button {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 9px 14px;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 7px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}
.button.primary {
  background: var(--accent);
  border-color: var(--accent);
  color: #102a23;
}
.button.quiet {
  background: transparent;
  color: #c6d3dc;
}
.button.danger {
  background: var(--danger-bg);
  border-color: #89504f;
  color: #ffc1be;
}
.button svg {
  width: 15px;
  height: 15px;
}
.notice {
  margin-bottom: 20px;
  padding: 12px 15px;
  background: var(--amber-bg);
  color: var(--amber);
  border: 1px solid #665736;
  border-radius: 8px;
  font-size: 12px;
}
.notice button {
  color: inherit;
  background: transparent;
  border: 0;
  text-decoration: underline;
  margin-left: 8px;
}
.notice.error {
  background: var(--danger-bg);
  border-color: #704344;
  color: #ffc1be;
}
.job-panel {
  display: flex;
  gap: 12px;
  align-items: center;
  border: 1px solid #3e665c;
  background: #173029;
  padding: 13px 16px;
  border-radius: 8px;
  margin-bottom: 20px;
}
.job-panel strong {
  font-size: 12px;
}
.job-panel p {
  color: #b2d5cb;
  font-size: 12px;
  margin-top: 3px;
}
.job-panel .icon-button {
  margin-left: auto;
}
.job-panel.failed {
  background: var(--danger-bg);
  border-color: #704344;
}
.job-panel.failed p {
  color: #f0bbbb;
}
.job-indicator {
  width: 14px;
  height: 14px;
  border: 2px solid #416b60;
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
.job-panel.finished .job-indicator {
  animation: none;
  border: 0;
  width: 7px;
  height: 7px;
  background: var(--accent);
}
.job-panel.failed .job-indicator {
  background: var(--danger);
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.survey-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
}
.survey-name-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.survey-heading p {
  margin-top: 5px;
}
.status-badge {
  font-size: 10px;
  line-height: 1.4;
  color: #98e4cc;
  background: var(--accent-bg);
  padding: 4px 7px;
  border-radius: 4px;
  font-weight: 600;
}
.metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--subtle-line);
  border-bottom: 1px solid var(--subtle-line);
  padding: 20px 0;
  margin: 21px 0 25px;
}
.metrics > div {
  padding: 0 22px;
  border-left: 1px solid var(--line);
  display: grid;
  gap: 3px;
}
.metrics > div:first-child {
  padding-left: 0;
  border: 0;
}
.metrics span {
  color: var(--muted);
  font-size: 11px;
}
.metrics strong {
  font-size: 27px;
  line-height: 1.4;
  font-weight: 600;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}
.metrics small {
  font-size: 10px;
  color: var(--muted);
}
.inspection-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.32fr) minmax(310px, 1fr);
  gap: 24px;
}
.panel-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 13px;
  min-height: 32px;
}
.panel-toolbar h3 {
  font-size: 12px;
}
.segmented {
  display: flex;
  background: var(--sidebar);
  padding: 3px;
  border: 1px solid var(--subtle-line);
  border-radius: 6px;
  gap: 2px;
}
.segmented button {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 5px 8px;
  border: 0;
  background: none;
  border-radius: 4px;
  font-size: 11px;
  color: var(--muted);
}
.segmented button.active {
  background: var(--raised);
  color: var(--text);
}
.segmented svg {
  width: 12px;
  height: 12px;
}
.evidence-stage {
  background: #090d10;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
  aspect-ratio: 16/10;
  display: flex;
  align-items: center;
  justify-content: center;
}
.evidence-stage > img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.image-empty {
  padding: 36px;
  color: var(--muted);
  max-width: 350px;
  text-align: center;
  line-height: 1.8;
}
.image-badge {
  position: absolute;
  top: 14px;
  left: 14px;
  padding: 5px 8px;
  background: #0c1217ef;
  border-radius: 4px;
  font-size: 10px;
  color: #e3ecef;
}
.image-expand {
  position: absolute;
  bottom: 12px;
  right: 12px;
  width: 32px;
  height: 32px;
  background: #0c1217ef;
  border: 1px solid #56616a;
  border-radius: 5px;
  display: grid;
  place-items: center;
}
.image-expand svg {
  width: 15px;
}
.evidence-caption {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
  color: var(--muted);
  font-size: 10px;
}
.geo-warning {
  color: var(--amber);
  white-space: nowrap;
}
.selected-details {
  padding: 14px 0;
  border-top: 1px solid var(--subtle-line);
  border-bottom: 1px solid var(--subtle-line);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}
.selected-details span {
  font-size: 10px;
  color: var(--muted);
  display: block;
}
.selected-details strong {
  font-size: 14px;
  font-weight: 600;
  display: block;
  margin-top: 3px;
  font-variant-numeric: tabular-nums;
}
.selected-details small {
  font-size: 10px;
  color: var(--muted);
}
.frame-strip-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 19px 0 10px;
}
.frame-strip {
  display: flex;
  gap: 7px;
  overflow: auto;
  padding: 2px 2px 8px;
}
.frame-thumb {
  flex: 0 0 83px;
  position: relative;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 5px;
  overflow: hidden;
  background: var(--surface);
  height: 55px;
}
.frame-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.frame-thumb.active {
  border-color: var(--accent);
}
.frame-thumb span {
  position: absolute;
  bottom: 0;
  left: 0;
  background: #0c1217ef;
  color: var(--text);
  padding: 1px 4px;
  font-size: 9px;
  font-variant-numeric: tabular-nums;
}
.defects-panel {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.count {
  color: var(--muted);
  font-size: 11px;
  margin-left: 5px;
  font-weight: 500;
}
.panel-toolbar select {
  font-size: 10px;
  background: transparent;
  border: 0;
  color: var(--muted);
  max-width: 140px;
  padding: 7px 1px;
}
select {
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 9px;
  border-radius: 6px;
}
.filter-row {
  display: flex;
  gap: 7px;
  margin-bottom: 12px;
}
.search-field {
  display: flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 9px;
  min-width: 0;
  flex: 1;
}
.search-field svg {
  width: 14px;
  color: var(--muted);
}
.search-field input {
  width: 100%;
  min-width: 0;
  background: transparent;
  border: 0;
  padding: 9px 0;
  font-size: 11px;
  outline-offset: 2px;
}
.filter-button {
  background: transparent;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: 6px;
  font-size: 10px;
  padding: 8px;
  white-space: nowrap;
}
.filter-button[aria-pressed="true"] {
  color: var(--accent);
  border-color: #487b70;
  background: var(--accent-bg);
}
.defect-list {
  flex: 1;
  max-height: 425px;
  min-height: 160px;
  overflow: auto;
}
.defect-row {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 11px;
  padding: 13px 10px;
  border: 1px solid transparent;
  border-bottom-color: var(--subtle-line);
  text-align: left;
  background: transparent;
  border-radius: 5px;
}
.defect-row.active {
  background: var(--raised);
  border-color: #49616d;
}
.defect-thumb {
  width: 61px;
  height: 49px;
  border-radius: 4px;
  background: #23313a;
  object-fit: cover;
  flex-shrink: 0;
}
.defect-info {
  min-width: 0;
  flex: 1;
}
.defect-info strong {
  display: block;
  font-size: 12px;
  font-weight: 600;
}
.defect-info small {
  display: block;
  color: var(--muted);
  font-size: 10px;
  margin-top: 4px;
}
.defect-info .uncertain {
  color: var(--amber);
}
.defect-meta {
  text-align: right;
}
.severity {
  font-size: 10px;
  padding: 4px 6px;
  border-radius: 4px;
  color: #c7dfd7;
  background: #263f37;
  white-space: nowrap;
}
.severity.high {
  color: #ffc0bc;
  background: #462d2f;
}
.severity.medium {
  color: #f7d898;
  background: #3b3425;
}
.defect-meta small {
  display: block;
  color: var(--muted);
  font-size: 10px;
  margin-top: 8px;
  font-variant-numeric: tabular-nums;
}
.review-action {
  border-top: 1px solid var(--line);
  margin-top: 19px;
  padding-top: 18px;
}
.review-action strong {
  font-size: 12px;
}
.review-action p {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.8;
  margin-top: 6px;
  max-width: 44ch;
}
.run-controls {
  display: flex;
  gap: 8px;
  margin-top: 13px;
}
.run-controls select {
  flex: 1;
  min-width: 0;
  font-size: 11px;
}
.run-controls .button {
  font-size: 11px;
}
.workspace-footer {
  margin-top: 25px;
  padding-top: 15px;
  border-top: 1px solid var(--subtle-line);
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 10px;
}
.map-stage {
  aspect-ratio: 16/10;
  position: relative;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
#map {
  height: 100%;
  width: 100%;
  background: #243039;
}
.map-error {
  position: absolute;
  bottom: 24px;
  left: 10px;
  right: 10px;
  z-index: 1000;
  background: #162127;
  padding: 9px;
  color: var(--amber);
  font-size: 11px;
}
.leaflet-container {
  font-family: Manrope, sans-serif;
}
.leaflet-popup-content-wrapper {
  background: var(--surface);
  color: var(--text);
  border-radius: 8px;
}
.leaflet-popup-tip {
  background: var(--surface);
}
.leaflet-popup-content {
  font-size: 12px;
  line-height: 1.7;
}
.leaflet-control-attribution {
  font-size: 10px;
}
.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 20px;
  margin-bottom: 21px;
}
.section-heading h3 {
  font-size: 16px;
}
.section-heading p {
  font-size: 12px;
  color: var(--muted);
  margin-top: 6px;
  max-width: 70ch;
}
.section-heading select {
  font-size: 11px;
}
.order-list {
  display: grid;
  gap: 15px;
}
.order {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: var(--radius);
  padding: 22px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 25px;
}
.order-meta {
  display: flex;
  gap: 9px;
  align-items: center;
  margin-bottom: 9px;
  font-size: 11px;
  color: var(--muted);
}
.order h4 {
  font-size: 14px;
  font-weight: 700;
}
.order p {
  font-size: 12px;
  color: var(--muted);
  margin-top: 8px;
  line-height: 1.9;
  max-width: 75ch;
}
.order-evidence {
  display: flex;
  gap: 8px;
  margin-top: 14px;
  flex-wrap: wrap;
}
.order-evidence button {
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--bg);
  overflow: hidden;
  text-align: left;
  color: var(--muted);
  font-size: 10px;
  width: 100px;
}
.order-evidence img {
  height: 62px;
  width: 100%;
  object-fit: cover;
}
.order-evidence span {
  padding: 5px 7px;
  display: block;
}
.order-decision {
  border-left: 1px solid var(--line);
  padding-left: 22px;
  display: flex;
  flex-direction: column;
  align-items: start;
  justify-content: center;
}
.order-decision strong {
  font-size: 12px;
}
.order-decision p {
  font-size: 11px;
}
.decision-actions {
  display: flex;
  gap: 8px;
  margin-top: 13px;
  flex-wrap: wrap;
}
.decision-actions .button {
  font-size: 11px;
}
.decision-note {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.status-approved {
  color: var(--accent);
}
.status-rejected {
  color: var(--danger);
}
.status-pending {
  color: var(--amber);
}
.agent-summary {
  padding: 15px 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  margin-bottom: 24px;
  font-size: 12px;
}
.agent-summary p {
  color: var(--muted);
  font-size: 12px;
  margin-top: 6px;
}
.timeline {
  margin: 0;
  padding: 0;
  list-style: none;
  max-width: 1000px;
}
.timeline li {
  display: grid;
  grid-template-columns: 35px 1fr;
  position: relative;
  padding-bottom: 22px;
}
.timeline li:not(:last-child):before {
  content: "";
  position: absolute;
  width: 1px;
  background: var(--line);
  left: 11px;
  top: 27px;
  bottom: 0;
}
.timeline-number {
  border: 1px solid var(--line);
  background: var(--surface);
  height: 23px;
  width: 23px;
  border-radius: 50%;
  font-size: 10px;
  display: grid;
  place-items: center;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.timeline-content strong {
  font-size: 12px;
}
.timeline-content .latency {
  font-size: 10px;
  color: var(--muted);
  margin-left: 10px;
}
.timeline-content p {
  font-size: 12px;
  color: var(--muted);
  margin: 5px 0;
  line-height: 1.8;
}
.timeline-content details {
  font-size: 11px;
  color: var(--muted);
  margin-top: 7px;
}
.timeline-content summary {
  cursor: pointer;
}
.timeline-content pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  padding: 12px;
  background: var(--sidebar);
  border-radius: 5px;
  max-height: 260px;
  overflow: auto;
}
.timeline-crop {
  width: 180px;
  max-height: 130px;
  object-fit: contain;
  border-radius: 6px;
  margin-top: 10px;
}
.empty-state {
  padding: 35px 20px;
  color: var(--muted);
  text-align: center;
}
.empty-state h4 {
  color: var(--text);
  font-size: 13px;
  margin-bottom: 8px;
}
.empty-state p {
  font-size: 12px;
  max-width: 52ch;
  margin: auto;
  line-height: 1.8;
}
.empty-state button {
  margin-top: 14px;
}
.empty-workspace {
  border: 1px dashed var(--line);
  padding: 65px 25px;
  text-align: center;
  border-radius: var(--radius);
}
.empty-workspace > svg {
  width: 48px;
  height: 48px;
  color: var(--accent);
  margin: 0 auto 22px;
}
.empty-workspace p {
  max-width: 48ch;
  margin: 12px auto 22px;
  color: var(--muted);
  line-height: 1.9;
}
.dialog {
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 26px;
  width: min(520px, calc(100vw - 32px));
  max-height: calc(100dvh - 36px);
  box-shadow: 0 25px 90px #0008;
  overflow: auto;
}
.dialog::backdrop {
  background: #04090cc9;
}
.dialog-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
  margin-bottom: 16px;
}
.dialog-heading h2 {
  font-size: 20px;
}
.dialog-heading .icon-button {
  margin-right: -7px;
}
.dialog > .muted,
.dialog form > .muted {
  font-size: 12px;
  line-height: 1.8;
}
.field {
  display: block;
  font-size: 12px;
  font-weight: 600;
  margin-top: 20px;
}
.optional {
  font-weight: 400;
  color: var(--muted);
  font-size: 11px;
  margin-left: 5px;
}
.field input,
.field textarea {
  display: block;
  width: 100%;
  margin-top: 8px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 11px 12px;
  font-size: 12px;
}
.field textarea {
  resize: vertical;
}
.field input[type="file"] {
  font-size: 11px;
  padding: 9px;
}
.field input::file-selector-button {
  background: var(--raised);
  color: var(--text);
  border: 1px solid var(--line);
  padding: 6px 9px;
  border-radius: 4px;
  margin-right: 10px;
  font: inherit;
}
.file-drop {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
  justify-content: center;
  position: relative;
  border: 1px dashed #58736f;
  border-radius: 9px;
  padding: 26px 18px;
  margin-top: 23px;
  cursor: pointer;
  background: #142925;
  text-align: center;
}
.file-drop > svg {
  color: var(--accent);
  height: 26px;
  width: 26px;
  margin-bottom: 5px;
}
.file-drop strong {
  font-size: 12px;
  overflow-wrap: anywhere;
}
.file-drop span {
  font-size: 11px;
  color: #b1c9c2;
}
.file-drop input {
  position: absolute;
  inset: 0;
  opacity: 0;
  width: 100%;
  cursor: pointer;
}
.file-drop:focus-within {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}
.file-drop.dragging {
  background: #244d42;
}
.form-note {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.8;
  margin-top: 15px;
}
.form-error {
  background: var(--danger-bg);
  color: #ffc1be;
  padding: 11px 12px;
  font-size: 12px;
  border-radius: 6px;
  margin-top: 16px;
  overflow-wrap: anywhere;
}
.dialog-footer {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  margin-top: 26px;
}
.image-dialog {
  width: min(1100px, calc(100vw - 32px));
  padding: 20px;
}
.image-dialog > img {
  max-height: calc(100dvh - 175px);
  width: 100%;
  object-fit: contain;
  background: #080e11;
}
.image-dialog > p {
  margin-top: 10px;
}
.help-content h3 {
  margin-top: 24px;
}
.help-content p {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.9;
  margin-top: 7px;
}
.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  max-width: calc(100vw - 35px);
  padding: 12px 20px;
  border: 1px solid #51776d;
  border-radius: 8px;
  background: #1b3930;
  color: #daf3eb;
  font-size: 12px;
  box-shadow: 0 8px 30px #0005;
  z-index: 5000;
}
@media (min-width: 1600px) {
  main {
    padding: 36px 45px;
  }
  .inspection-grid {
    gap: 32px;
  }
  .evidence-stage,
  .map-stage {
    aspect-ratio: 16/9;
  }
  .defect-list {
    max-height: 520px;
  }
  .defect-row {
    padding: 17px 12px;
  }
  .defect-thumb {
    width: 75px;
    height: 57px;
  }
  .defect-info strong {
    font-size: 12px;
  }
}
@media (max-width: 1180px) {
  .shell {
    grid-template-columns: 195px 1fr;
  }
  .sidebar {
    padding-left: 11px;
    padding-right: 11px;
  }
  .brand {
    margin-left: 7px;
  }
  .topbar {
    padding: 0 22px;
  }
  main {
    padding: 26px 22px;
  }
  .inspection-grid {
    grid-template-columns: minmax(0, 1.1fr) minmax(280px, 1fr);
    gap: 18px;
  }
  .metrics > div {
    padding: 0 14px;
  }
  .metrics small {
    font-size: 9px;
  }
  .evidence-caption {
    flex-direction: column;
    gap: 4px;
  }
  .panel-toolbar {
    flex-wrap: wrap;
  }
  .defect-thumb {
    width: 49px;
    height: 44px;
  }
  .defect-row {
    gap: 8px;
    padding: 12px 7px;
  }
  .defect-meta {
    font-size: 9px;
  }
  .severity {
    font-size: 9px;
  }
  .frame-thumb {
    flex-basis: 70px;
    height: 49px;
  }
  .run-controls {
    flex-wrap: wrap;
  }
  .run-controls .button {
    flex: 1;
  }
  .order {
    grid-template-columns: minmax(0, 1fr) 190px;
  }
  .order-decision {
    padding-left: 16px;
  }
  .workspace-footer {
    font-size: 9px;
  }
}
@media (max-width: 960px) {
  .inspection-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .evidence-stage,
  .map-stage {
    aspect-ratio: 16/9;
  }
  .defects-panel {
    margin-top: 10px;
  }
  .defect-list {
    max-height: 370px;
  }
  .defect-thumb {
    width: 75px;
    height: 51px;
  }
  .defect-info strong {
    font-size: 12px;
  }
  .defect-info small,
  .severity {
    font-size: 11px;
  }
  .evidence-caption {
    flex-direction: row;
  }
  .run-controls {
    flex-wrap: nowrap;
  }
  .run-controls .button {
    flex: initial;
  }
  .review-action {
    display: flex;
    gap: 25px;
    align-items: center;
    justify-content: space-between;
  }
  .run-controls {
    flex-wrap: wrap;
    max-width: 215px;
    margin-top: 0;
  }
  .run-controls .button {
    width: 100%;
  }
  .metrics {
    gap: 0;
  }
  .metrics > div {
    padding: 0 10px;
  }
  .metrics span {
    font-size: 10px;
  }
  .metrics strong {
    font-size: 24px;
  }
  .metrics small {
    font-size: 9px;
  }
  .order {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .order-decision {
    padding-left: 0;
    padding-top: 15px;
    border-left: 0;
    border-top: 1px solid var(--line);
  }
  .workspace-footer {
    flex-direction: column;
    gap: 5px;
  }
  .page-heading {
    align-items: start;
  }
  .page-heading p {
    max-width: 30ch;
  }
  .page-heading h1 {
    font-size: 25px;
  }
}
@media (max-width: 700px) {
  .shell {
    display: block;
  }
  .sidebar {
    position: fixed;
    left: 0;
    width: 244px;
    transform: translateX(-100%);
    transition: transform 0.3s var(--ease);
    box-shadow: none;
  }
  .sidebar.open {
    transform: translateX(0);
    box-shadow: 20px 0 60px #0008;
  }
  .menu-button {
    display: flex;
  }
  .topbar {
    height: 58px;
    padding: 0 15px;
    gap: 8px;
  }
  .breadcrumb {
    font-size: 11px;
    margin-right: auto;
    gap: 8px;
  }
  .breadcrumb > b {
    display: none;
  }
  .mode-badge {
    font-size: 10px;
    padding: 4px 6px;
  }
  .topbar-actions {
    gap: 6px;
  }
  .text-button {
    font-size: 10px;
  }
  main {
    padding: 24px 16px 20px;
  }
  .page-heading {
    margin-bottom: 25px;
    gap: 12px;
  }
  .page-heading h1 {
    font-size: 24px;
  }
  .page-heading p {
    font-size: 11px;
    max-width: 26ch;
    margin-top: 7px;
  }
  .page-heading > .button {
    padding: 9px 10px;
    font-size: 11px;
    margin-top: 3px;
    min-height: 38px;
  }
  .survey-heading {
    align-items: start;
    gap: 10px;
  }
  .survey-name-row {
    gap: 7px;
  }
  .survey-heading h2 {
    font-size: 16px;
  }
  .survey-heading > .button {
    font-size: 0;
    padding: 9px;
  }
  .survey-heading > .button svg {
    width: 16px;
  }
  .survey-heading p {
    font-size: 10px;
    max-width: 32ch;
  }
  .status-badge {
    font-size: 9px;
  }
  .metrics {
    grid-template-columns: 1fr 1fr;
    row-gap: 18px;
    padding: 18px 0;
    margin: 19px 0 22px;
  }
  .metrics > div {
    padding-left: 20px;
  }
  .metrics > div:nth-child(odd) {
    padding-left: 0;
    border-left: 0;
  }
  .metrics span {
    font-size: 11px;
  }
  .metrics small {
    font-size: 10px;
  }
  .metrics strong {
    font-size: 25px;
  }
  .inspection-grid {
    gap: 25px;
  }
  .evidence-stage,
  .map-stage {
    aspect-ratio: 4/3;
  }
  .evidence-caption {
    font-size: 9px;
  }
  .selected-details {
    gap: 7px;
  }
  .selected-details strong {
    font-size: 13px;
  }
  .selected-details span,
  .selected-details small {
    font-size: 10px;
  }
  .defect-list {
    max-height: none;
  }
  .filter-row {
    gap: 8px;
  }
  .search-field input {
    font-size: 12px;
    padding: 11px 0;
  }
  .filter-button {
    font-size: 11px;
  }
  .defect-row {
    padding: 14px 8px;
    gap: 12px;
  }
  .defect-thumb {
    width: 65px;
    height: 50px;
  }
  .review-action {
    display: block;
  }
  .review-action p {
    font-size: 12px;
    max-width: 50ch;
  }
  .run-controls {
    margin-top: 15px;
    max-width: none;
    flex-wrap: nowrap;
  }
  .run-controls .button {
    width: auto;
  }
  .run-controls select {
    font-size: 12px;
  }
  .section-heading {
    gap: 12px;
    flex-wrap: wrap;
  }
  .section-heading p {
    font-size: 12px;
  }
  .order {
    padding: 17px;
  }
  .order h4 {
    font-size: 13px;
  }
  .order p {
    font-size: 12px;
  }
  .dialog {
    padding: 22px;
  }
  .dialog-heading h2 {
    font-size: 19px;
  }
  .workspace-footer {
    font-size: 10px;
    line-height: 1.8;
  }
  .job-panel {
    padding: 12px;
  }
  .job-panel p {
    font-size: 11px;
  }
  .timeline-content .latency {
    font-size: 9px;
  }
  .empty-workspace {
    padding: 45px 18px;
  }
  .empty-workspace h2 {
    font-size: 18px;
  }
  .empty-workspace p {
    font-size: 12px;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *:before,
  *:after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
  }
}

.evidence-panel,
.inspection-grid,
.view-panel {
  min-width: 0;
}
.evidence-stage,
.map-stage,
.frame-strip {
  max-width: 100%;
}
@media (max-width: 700px) {
  .evidence-caption {
    flex-direction: column;
    gap: 4px;
  }
  .review-action {
    padding-bottom: 8px;
  }
}

.nav-backdrop {
  position: fixed;
  inset: 0;
  z-index: 35;
  background: #04090c88;
  border: 0;
}

.selected-details.overview {
  display: block;
}

/* Evidence-to-decision guidance, within the existing slate and teal system. */
.review-brief { display:flex; align-items:center; justify-content:space-between; gap:24px; padding:20px 22px; margin:18px 0; border:1px solid #335249; border-left:3px solid var(--accent); border-radius:var(--radius); background:linear-gradient(110deg,#172b27,var(--surface)); }
.review-brief-copy { max-width:760px; }
.eyebrow { color:var(--accent); text-transform:uppercase; letter-spacing:.13em; font-size:10px; font-weight:800; margin-bottom:4px; }
.review-brief h3 { font-size:17px; }
#nextStepDetail { color:var(--muted); font-size:12px; margin-top:5px; }
.review-brief > button { flex-shrink:0; }
.review-steps { display:flex; flex-wrap:wrap; gap:8px 18px; padding:0; margin:12px 0 0; list-style:none; color:var(--muted); font-size:11px; }
.review-steps .complete { color:var(--accent); }
.review-steps .current { color:var(--amber); }
.outcome-filter-row { display:flex; align-items:center; justify-content:space-between; gap:10px; color:var(--muted); font-size:11px; padding:0 0 12px; }
.outcome-filter-row select { max-width:65%; }
.outcome-label { display:inline-block; color:var(--accent); }
.outcome-label.dismissed { color:var(--muted); }
.outcome-label.resurvey,.outcome-label.uncertain,.outcome-label.unreviewed { color:var(--amber); }
.defect-row.dismissed .defect-thumb { opacity:.55; }
.evidence-outcome { grid-column:1 / -1; border-top:1px solid var(--subtle-line); padding-top:12px; }
.evidence-outcome p { color:var(--muted); font-size:11px; margin-top:4px; }
.export-choices { display:grid; gap:12px; margin:24px 0; }
.export-choice { width:100%; text-align:left; background:var(--surface); border:1px solid var(--line); border-radius:10px; padding:18px; }
.export-choice strong { display:block; font-size:15px; margin-bottom:8px; }
.export-choice strong span { float:right; color:var(--accent); font-size:11px; letter-spacing:.1em; }
.export-choice small { display:block; color:var(--muted); line-height:1.7; }
@media(max-width:700px) {
  .review-brief { align-items:stretch; flex-direction:column; padding:16px; gap:15px; }
  .review-brief h3 { font-size:16px; }
  .review-steps { gap:6px 12px; font-size:10px; }
  .review-brief > button { width:100%; }
}
