
:root {
  color-scheme: dark;
  --bg: #111315;
  --panel: #191d21;
  --panel-2: #20262b;
  --text: #f2f5f7;
  --muted: #9aa6af;
  --line: #303841;
  --accent: #4fb3ff;
  --good: #47d18c;
  --warn: #f0b84f;
  --bad: #ff6b6b;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
}

body.app-plane-bg::before {
  content: "";
  position: fixed;
  inset: -18vh -18vw;
  z-index: 0;
  pointer-events: none;
  background-image: url("/ui/mavenscene-plane.svg");
  background-repeat: no-repeat;
  background-position: center center;
  background-size: max(132vw, 1500px) auto;
  opacity: 0.032;
  filter: blur(0.4px);
}

body.app-plane-bg main {
  position: relative;
  z-index: 1;
}

main {
  width: min(1080px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0 56px;
}

header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 18px 0 26px;
  border-bottom: 1px solid var(--line);
}

.brand-lockup {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.brand-icon {
  width: 48px;
  height: 48px;
  flex: 0 0 auto;
  border-radius: 11px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.32);
}

.brand-lockup p {
  margin: 4px 0 0;
}

h1 { margin: 0; font-size: 30px; }

.job-title-row {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.job-title-row h1 {
  min-width: 0;
  overflow-wrap: anywhere;
}

.icon-button.job-rename-button {
  width: 34px;
  min-width: 34px;
  height: 34px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
}

.job-rename-button svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.job-rename-form {
  display: grid;
  grid-template-columns: minmax(180px, 420px) auto auto;
  gap: 8px;
  align-items: center;
  margin-top: 8px;
}

.job-rename-form[hidden] { display: none; }

.job-rename-form input {
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-2);
  color: var(--text);
  padding: 9px 11px;
  font: inherit;
}

.rename-job-message {
  grid-column: 1 / -1;
  min-height: 18px;
  color: var(--warn);
  font-size: 13px;
  line-height: 1.35;
}
h2 { margin: 28px 0 14px; font-size: 18px; color: var(--muted); }
p { color: var(--muted); line-height: 1.5; }
a { color: var(--accent); text-decoration: none; }

.actions { display: flex; gap: 10px; flex-wrap: wrap; }

button, .button, input[type="text"], input[type="email"], input[type="password"], input[type="file"] {
  appearance: none;
  border: 1px solid var(--line);
  background: var(--panel-2);
  color: var(--text);
  border-radius: 6px;
  padding: 10px 14px;
  font: inherit;
}

button, .button { cursor: pointer; }

button:hover, .button:hover { border-color: var(--accent); }
button.danger { border-color: rgba(255, 107, 107, 0.45); color: var(--bad); }
button.danger:hover { border-color: var(--bad); }
button:disabled { cursor: not-allowed; opacity: 0.55; }
button[hidden] { display: none; }
.share-password-controls [hidden] { display: none; }
#share-password-fields {
  margin: 14px 0 0;
  display: grid;
  gap: 10px;
  max-width: 420px;
}
#share-password-fields[hidden] {
  display: none;
}
#share-password-save {
  margin-top: 4px;
  justify-self: start;
}
#share-password-save.is-ready {
  border-color: rgba(79, 179, 255, 0.72);
  background: #176aa0;
  color: #f8fbff;
  font-weight: 800;
}
#share-password-save.is-ready:hover {
  border-color: #9ed8ff;
  background: #1e7fbd;
}
.share-password-controls .is-pending,
#share-expiration.is-pending,
#share-custom-expiration.is-pending,
.share-output-row.is-pending {
  border-color: rgba(240, 184, 79, 0.72);
  box-shadow: 0 0 0 1px rgba(240, 184, 79, 0.28);
}
.share-password-controls .is-pending {
  color: var(--warn);
  background: rgba(240, 184, 79, 0.1);
  border: 1px solid rgba(240, 184, 79, 0.42);
  border-radius: 6px;
  padding: 8px 10px;
}
.share-output-row.is-pending {
  border-radius: 6px;
  background: rgba(240, 184, 79, 0.08);
}

.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  margin-top: 18px;
}

.job-overview {
  display: grid;
  gap: 18px;
}

.status-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 6px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel-2);
  color: var(--text);
  font-size: 14px;
  font-weight: 700;
}

.status-badge.status-ok {
  border-color: rgba(71, 209, 140, 0.5);
  color: var(--good);
}

.status-badge.status-warn {
  border-color: rgba(240, 184, 79, 0.5);
  color: var(--warn);
}

.status-badge.status-bad {
  border-color: rgba(255, 107, 107, 0.55);
  color: var(--bad);
}

.status-badge.status-active {
  border-color: rgba(79, 179, 255, 0.55);
  color: var(--accent);
}

.status-badge-compact {
  min-height: 28px;
  padding: 4px 9px;
  font-size: 12px;
}

.job-issue {
  display: grid;
  gap: 16px;
  padding: 16px;
  border: 1px solid rgba(240, 184, 79, 0.48);
  border-radius: 8px;
  background: rgba(240, 184, 79, 0.08);
}

.job-issue[hidden] {
  display: none;
}

.job-issue.is-critical {
  border-color: rgba(255, 107, 107, 0.58);
  background: rgba(255, 107, 107, 0.08);
}

.job-issue.is-warning {
  border-color: rgba(240, 184, 79, 0.52);
}

.job-issue-header {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.issue-badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 9px;
  border: 1px solid rgba(240, 184, 79, 0.5);
  border-radius: 999px;
  color: var(--warn);
  background: rgba(17, 19, 21, 0.45);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.job-issue.is-critical .issue-badge {
  border-color: rgba(255, 107, 107, 0.58);
  color: var(--bad);
}

.job-issue h2,
.job-issue h3,
.job-issue p {
  margin: 0;
}

.job-issue h2 {
  color: var(--text);
  font-size: 18px;
}

.job-issue h3 {
  color: #c6d0d8;
  font-size: 12px;
  text-transform: uppercase;
}

.job-issue-body {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(260px, 1.2fr);
  gap: 16px;
}

.issue-steps {
  display: grid;
  gap: 6px;
  margin: 8px 0 0;
  padding-left: 18px;
  color: var(--muted);
}

.issue-diagnostics summary {
  cursor: pointer;
  color: var(--muted);
  font-weight: 700;
}

.issue-diagnostics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.detail-sections {
  display: grid;
  gap: 18px;
}

.detail-section {
  display: grid;
  gap: 10px;
}

.card > h2:first-child,
.detail-section h2 {
  margin: 0;
}

.job-progress-output {
  display: grid;
  gap: 18px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.compact-grid {
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  margin-top: 12px;
}

.metric-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(160px, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.metric {
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 14px;
}

.metric span { display: block; color: var(--muted); font-size: 13px; margin-bottom: 6px; }
.metric strong { font-size: 18px; word-break: break-word; }
.metric small { display: block; color: var(--muted); margin-top: 8px; word-break: break-word; }

.section-heading {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(48, 56, 65, 0.78);
}

.section-heading h2 {
  margin-top: 0;
  color: var(--text);
}

.section-heading .notice {
  margin-bottom: 0;
}

.status-card {
  display: grid;
  gap: 16px;
}

.status-heading {
  align-items: center;
}

.status-heading h2,
.card-summary h2 {
  margin: 0;
  color: var(--text);
  font-size: 18px;
}


.status-guidance {
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 12px;
  align-items: start;
  padding: 14px;
  border: 1px solid rgba(79, 179, 255, 0.42);
  border-radius: 8px;
  background: rgba(79, 179, 255, 0.08);
}

.status-guidance h3,
.status-guidance p {
  margin: 0;
}

.status-guidance h3 {
  color: var(--text);
  font-size: 17px;
}

.status-guidance p {
  margin-top: 4px;
  color: #c5d0d9;
  line-height: 1.45;
}

.status-guidance-suggestion {
  color: var(--muted) !important;
}

.status-guidance-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(79, 179, 255, 0.48);
  border-radius: 999px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.status-guidance.status-success {
  border-color: rgba(71, 209, 140, 0.45);
  background: rgba(71, 209, 140, 0.08);
}

.status-guidance.status-success .status-guidance-icon {
  border-color: rgba(71, 209, 140, 0.55);
  color: var(--good);
}

.status-guidance.status-warning {
  border-color: rgba(240, 184, 79, 0.5);
  background: rgba(240, 184, 79, 0.09);
}

.status-guidance.status-warning .status-guidance-icon {
  border-color: rgba(240, 184, 79, 0.58);
  color: var(--warn);
}

.status-guidance.status-error {
  border-color: rgba(255, 107, 107, 0.55);
  background: rgba(255, 107, 107, 0.08);
}

.status-guidance.status-error .status-guidance-icon {
  border-color: rgba(255, 107, 107, 0.6);
  color: var(--bad);
}

.support-info {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding: 12px;
  border: 1px solid rgba(240, 184, 79, 0.42);
  border-radius: 8px;
  background: rgba(240, 184, 79, 0.08);
}

.support-info[hidden] {
  display: none;
}

.support-info strong,
.support-info span {
  display: block;
}

.support-info span,
.copy-job-code-message {
  color: var(--muted);
  font-size: 13px;
}

.support-info code {
  padding: 6px 9px;
  border: 1px solid rgba(48, 56, 65, 0.9);
  border-radius: 6px;
  background: rgba(17, 19, 21, 0.55);
  color: var(--text);
  font-size: 13px;
}


.collapsible-card > summary {
  list-style: none;
}

.collapsible-card > summary::-webkit-details-marker {
  display: none;
}

.card-summary {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  cursor: pointer;
}

.collapsible-card[open] > .card-summary {
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(48, 56, 65, 0.78);
}

.card-summary .notice {
  margin: 6px 0 0;
}

.collapsible-card:not([open]) .card-summary .notice {
  display: none;
}

.collapse-indicator {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  min-width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel-2);
}

.collapse-indicator::before {
  content: "";
  width: 10px;
  height: 10px;
  border-right: 2px solid var(--muted);
  border-bottom: 2px solid var(--muted);
  transform: translateY(-2px) rotate(45deg);
}

.collapsible-card[open] .collapse-indicator::before {
  transform: translateY(2px) rotate(225deg);
}

.collapsible-body {
  margin-top: 16px;
}

.upload-card-body {
  margin-top: 22px;
}


.processing-options-card {
  display: block;
}

.processing-options-body {
  display: grid;
  gap: 18px;
}

.processing-options-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(220px, 0.8fr);
  gap: 18px;
  align-items: start;
}

.processing-option-section {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.processing-option-section h3 {
  margin: 0;
  color: var(--text);
  font-size: 14px;
  line-height: 1.25;
}

.choice-grid,
.output-choice-grid {
  display: grid;
  gap: 8px;
}

.processing-profile-grid {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.quality-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.output-choice-grid {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.choice-tile,
.output-choice {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 42px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.42);
  color: var(--text);
  cursor: pointer;
}

.choice-tile:has(input:checked),
.output-choice:has(input:checked) {
  border-color: rgba(59, 130, 246, 0.9);
  background: rgba(37, 99, 235, 0.15);
}

.choice-tile input,
.output-choice input {
  flex: 0 0 auto;
  margin: 0;
}

.choice-tile span,
.output-choice span {
  min-width: 0;
  overflow-wrap: anywhere;
  line-height: 1.25;
}

.choice-tile:has(input:disabled),
.output-choice:has(input:disabled) {
  cursor: not-allowed;
  opacity: 0.72;
}

.processing-config-summary-section {
  grid-column: 2;
  grid-row: 1 / span 3;
}

.processing-config-summary {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(2, 6, 23, 0.28);
}

.summary-row {
  display: grid;
  gap: 4px;
}

.summary-row span {
  color: var(--muted);
  font-size: 12px;
}

.summary-row strong {
  color: var(--text);
  font-size: 15px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.summary-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.summary-chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 8px;
  border: 1px solid rgba(34, 197, 94, 0.4);
  border-radius: 999px;
  background: rgba(34, 197, 94, 0.1);
  color: #bbf7d0;
  font-size: 12px;
  line-height: 1.2;
}

.processing-options-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.processing-options-actions .notice {
  margin: 0;
}

.image-manage-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.pending-photo-workspace {
  display: grid;
  gap: 14px;
}

.pending-workflow-step {
  display: block;
  font-size: 15px;
}

.upload-selected-actions .pending-workflow-step {
  margin-right: auto;
}

.pending-photo-workspace[hidden] {
  display: none !important;
}

.pending-photo-map-panel .image-map {
  min-height: 420px;
}

.pending-selection-panel,
.classic-image-management-body {
  display: grid;
  gap: 12px;
}

.pending-selection-panel {
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.025);
}

.pending-selection-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.pending-selection-heading p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.pending-selection-modes {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.pending-selection-modes button {
  min-height: 46px;
}

.pending-selection-modes button.is-active {
  border-color: rgba(79, 179, 255, 0.8);
  background: rgba(79, 179, 255, 0.18);
  color: var(--text);
}

.pending-polygon-controls,
.pending-mode-details {
  padding: 10px 12px;
  border-left: 3px solid #22c55e;
  background: rgba(34, 197, 94, 0.08);
}

.pending-polygon-controls p,
.pending-mode-details p {
  margin: 0 0 8px;
}

.pending-dataset-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}

.pending-dataset-buttons button.is-active {
  border-color: #22c55e;
  background: rgba(34, 197, 94, 0.16);
}

.classification-vertex-icon {
  border: 2px solid #fff;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.55);
}

.pending-photo-no-gps {
  padding: 10px 12px;
  border-left: 3px solid #f59e0b;
  background: rgba(245, 158, 11, 0.08);
}

.pending-photo-no-gps p {
  margin: 4px 0 0;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.classic-image-management {
  margin-top: 4px;
}

.classic-image-management > summary {
  cursor: pointer;
  color: var(--muted);
  font-weight: 800;
}

.classic-image-management-body {
  margin-top: 14px;
}

.classic-upload-toggle {
  width: fit-content;
}

@media (max-width: 760px) {
  .pending-selection-heading {
    flex-direction: column;
  }
  .pending-selection-modes {
    grid-template-columns: 1fr 1fr;
  }
  .pending-photo-map-panel .image-map {
    min-height: 300px;
  }
}

@media (max-width: 480px) {
  .pending-selection-modes {
    grid-template-columns: 1fr;
  }
}

.image-manage-placeholders {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.image-manage-placeholders span {
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--muted);
  font-size: 13px;
  padding: 7px 10px;
}

.image-manage-toolbar,
.image-browser-controls,
.image-browser-pager {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: space-between;
}

.image-manage-toolbar {
  justify-content: flex-start;
}

.image-manage-toolbar button[disabled] {
  cursor: not-allowed;
  opacity: 0.58;
}

.mission-summary[hidden],
.map-focus-controls[hidden] {
  display: none !important;
}

.map-focus-controls {
  align-items: center;
  background: var(--surface-muted);
  border-bottom: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-start;
  padding: 10px 12px;
}

.image-browser-control-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.image-workspace {
  display: grid;
  gap: 14px;
  grid-template-columns: 1fr;
}

.image-table-panel,
.image-map-panel {
  border: 1px solid var(--border);
  border-radius: 8px;
  min-width: 0;
  overflow: hidden;
}

.image-panel-head {
  align-items: center;
  background: rgba(255, 255, 255, 0.035);
  border-bottom: 1px solid var(--border);
  display: flex;
  gap: 10px;
  justify-content: space-between;
  padding: 10px 12px;
}

.image-panel-head span {
  color: var(--muted);
  font-size: 12px;
}

.image-table-wrap {
  max-height: 520px;
  overflow: auto;
}

.image-table {
  border-collapse: collapse;
  min-width: 1040px;
  width: 100%;
}

.image-table th,
.image-table td {
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 12px;
  padding: 8px;
  text-align: left;
  vertical-align: middle;
}

.image-table th {
  color: var(--muted);
  font-weight: 800;
}

.image-table-row {
  cursor: pointer;
}

.image-table-row:hover,
.image-table-row:focus,
.image-table-row.is-selected {
  background: rgba(79, 179, 255, 0.14);
  outline: none;
}

.image-table td small {
  color: var(--muted);
  display: block;
  margin-top: 2px;
}

.image-table-empty {
  color: var(--muted);
  padding: 18px !important;
}

.image-map {
  align-items: center;
  background:
    linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.05) 1px, transparent 1px),
    rgba(0, 0, 0, 0.2);
  background-size: 32px 32px;
  color: var(--muted);
  display: flex;
  justify-content: center;
  min-height: 420px;
  overflow: hidden;
  position: relative;
}

.image-map.has-leaflet-map {
  display: block;
  min-height: 460px;
}

.image-map .leaflet-container,
.image-map.has-leaflet-map {
  background: #05070a;
}

.image-map .leaflet-control-attribution,
.image-map .leaflet-control-zoom a {
  background: rgba(12, 18, 24, 0.9);
  color: var(--text);
}

.image-map .leaflet-control-attribution a {
  color: var(--accent);
}

.image-map-marker {
  align-items: center;
  background: var(--panel-2);
  border: 2px solid #ffffff;
  border-radius: 999px;
  color: var(--text);
  display: flex;
  font-size: 11px;
  font-weight: 800;
  height: 28px;
  justify-content: center;
  min-width: 28px;
  padding: 0;
}

.image-map-marker.is-selected {
  background: var(--accent);
  color: #06111d;
  z-index: 2;
}

.image-map-marker.image-status-uploaded {
  background: #2563eb;
  color: #ffffff;
}

.image-map-marker.image-status-new {
  background: #16a34a;
  color: #ffffff;
}

.image-map-marker.image-status-already-uploaded {
  background: #64748b;
  color: #ffffff;
}

.image-map-marker.image-status-invalid {
  background: #7f1d1d;
  color: #ffffff;
}

.image-map-marker.image-validation-valid {
  background: #16a34a;
  color: #ffffff;
}

.image-map-marker.image-validation-suspicious {
  background: #f59e0b;
  color: #111827;
}

.image-map-marker.image-validation-outside-mission {
  background: #dc2626;
  color: #ffffff;
}

.image-map-marker.image-validation-not-validated {
  background: #475569;
  color: #ffffff;
}

.image-table-row.image-validation-valid td:nth-child(3) {
  color: #86efac;
}

.image-table-row.image-validation-suspicious td:nth-child(3) {
  color: #fbbf24;
}

.image-table-row.image-validation-outside-mission td:nth-child(3) {
  color: #fca5a5;
}

.image-table-row.image-validation-no-gps td:nth-child(3),
.image-table-row.image-validation-not-validated td:nth-child(3) {
  color: #cbd5e1;
}

.validation-warning {
  grid-column: 1 / -1;
  margin: 0;
}

.image-table-row.image-status-new td:nth-child(2) {
  color: #86efac;
}

.image-table-row.image-status-uploaded td:nth-child(2) {
  color: #93c5fd;
}

.image-table-row.image-status-already-uploaded td:nth-child(2) {
  color: #cbd5e1;
}

.image-table-row.image-status-invalid td:nth-child(2) {
  color: #fca5a5;
}

.image-map-marker-icon {
  background: transparent;
  border: 0;
}


.summary-main {
  min-width: 0;
  display: grid;
  gap: 10px;
  flex: 1;
}

.summary-progress {
  width: min(420px, 100%);
}

.collapsible-card[open] .summary-progress {
  display: none;
}

.summary-progress-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  margin-bottom: 6px;
}

.summary-progress-head strong {
  color: var(--text);
}

.summary-progress-track {
  position: relative;
  width: 100%;
  height: 8px;
  overflow: hidden;
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 999px;
}

.summary-progress-bar {
  width: 0%;
  height: 100%;
  background: var(--accent);
  transition: width 180ms ease;
}

.dataset-extra-details {
  margin-top: 12px;
}

.processing-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.results-section {
  padding: 20px;
  background: #121820;
  border-color: rgba(64, 76, 88, 0.9);
}

.results-section.is-ready {
  border-color: rgba(71, 209, 140, 0.42);
}

.results-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.result-card {
  --result-accent: var(--accent);
  --result-accent-rgb: 79, 179, 255;
  position: relative;
  display: grid;
  grid-template-rows: auto auto auto minmax(132px, auto) auto auto;
  min-height: 390px;
  gap: 12px;
  padding: 16px;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(32, 42, 52, 0.96), rgba(24, 31, 38, 0.96));
  border: 1px solid rgba(64, 76, 88, 0.86);
  border-radius: 8px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.result-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--result-accent);
  opacity: 0.9;
}

.result-card.is-disabled {
  background: rgba(28, 36, 44, 0.72);
}

.result-card-report { --result-accent: #ff6b6b; --result-accent-rgb: 255, 107, 107; }
.result-card-model { --result-accent: #4fb3ff; --result-accent-rgb: 79, 179, 255; }
.result-card-pointcloud { --result-accent: #7c8cff; --result-accent-rgb: 124, 140, 255; }
.result-card-ortho { --result-accent: #f0b84f; --result-accent-rgb: 240, 184, 79; }
.result-card-dsm { --result-accent: #47d18c; --result-accent-rgb: 71, 209, 140; }
.result-card-dtm { --result-accent: #b5a267; --result-accent-rgb: 181, 162, 103; }

.result-card-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
}

.result-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  min-width: 42px;
  height: 42px;
  border: 1px solid rgba(var(--result-accent-rgb), 0.62);
  border-radius: 8px;
  background: rgba(var(--result-accent-rgb), 0.16);
  color: var(--text);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
}

.result-icon svg {
  width: 28px;
  height: 28px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.result-card h3 {
  margin: 0;
  color: var(--text);
  font-size: 17px;
  line-height: 1.25;
}

.result-card p {
  margin: 0;
  font-size: 14px;
}

.result-card .result-note {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.result-preview-frame {
  min-height: 132px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(64, 76, 88, 0.86);
  border-radius: 8px;
  background: #0b1015;
}

.result-preview-frame img {
  width: 100%;
  height: 100%;
  max-height: 180px;
  display: block;
  object-fit: cover;
}

.result-preview-placeholder span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 54px;
  border-radius: 8px;
  border: 1px solid rgba(var(--result-accent-rgb), 0.52);
  background: rgba(var(--result-accent-rgb), 0.14);
  color: var(--text);
  font-size: 13px;
  font-weight: 800;
}

.result-card-meta {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.result-card-meta span { overflow-wrap: anywhere; }

.availability-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 26px;
  padding: 4px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(15, 19, 24, 0.72);
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.availability-badge.status-ok {
  border-color: rgba(71, 209, 140, 0.5);
  background: rgba(71, 209, 140, 0.1);
}
.availability-badge.status-warn {
  border-color: rgba(240, 184, 79, 0.5);
  background: rgba(240, 184, 79, 0.1);
}
.availability-badge.status-bad {
  border-color: rgba(255, 107, 107, 0.45);
  background: rgba(255, 107, 107, 0.08);
}
.availability-badge.status-muted {
  border-color: rgba(154, 166, 175, 0.42);
  background: rgba(154, 166, 175, 0.08);
  color: var(--muted);
}

.result-actions {
  display: grid;
  grid-template-columns: 1fr;
  align-self: end;
  gap: 12px;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.result-action {
  width: 100%;
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 12px;
  line-height: 1.2;
  text-align: center;
  border-color: rgba(var(--result-accent-rgb), 0.5);
  background: rgba(15, 19, 24, 0.64);
}

.result-action-primary {
  background: rgba(var(--result-accent-rgb), 0.18);
}

.result-action-secondary {
  background: rgba(15, 19, 24, 0.78);
}

.result-action:not(:disabled):hover {
  border-color: var(--result-accent);
}

.full-zip-action {
  margin-top: 18px;
}

.full-zip-row {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(32, 38, 43, 0.64);
}

.full-zip-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(71, 209, 140, 0.58);
  border-radius: 8px;
  background: rgba(71, 209, 140, 0.14);
  color: var(--text);
  font-size: 12px;
  font-weight: 800;
}

.full-zip-copy {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.full-zip-copy strong {
  color: var(--text);
  font-size: 14px;
}

.full-zip-copy span {
  color: var(--muted);
  font-size: 13px;
}

.full-zip-row.is-disabled {
  opacity: 0.68;
}

.full-zip-download {
  width: auto;
  min-width: 180px;
  border-color: rgba(71, 209, 140, 0.55);
  background: rgba(71, 209, 140, 0.12);
}


.elevation-products-section {
  padding: 20px;
  background: #121820;
  border-color: rgba(64, 76, 88, 0.9);
}

.elevation-products-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.elevation-product-card {
  --result-accent: #47d18c;
  --result-accent-rgb: 71, 209, 140;
  display: grid;
  gap: 12px;
  padding: 16px;
  background: linear-gradient(180deg, rgba(32, 42, 52, 0.96), rgba(24, 31, 38, 0.96));
  border: 1px solid rgba(64, 76, 88, 0.86);
  border-radius: 8px;
}

.elevation-product-card.is-disabled {
  opacity: 0.72;
}

.elevation-product-head {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
}

.elevation-product-head h3,
.elevation-product-head p,
.elevation-product-card p {
  margin: 0;
}

.elevation-product-head h3 {
  color: var(--text);
  font-size: 17px;
  line-height: 1.25;
}

.elevation-product-head p,
.elevation-product-card p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}

.elevation-preview-frame {
  min-height: 220px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(64, 76, 88, 0.86);
  border-radius: 8px;
  background: #0b1015;
}

.elevation-preview-frame img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 420px;
  object-fit: contain;
}

.elevation-metadata-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.elevation-metadata-grid div {
  min-width: 0;
  padding: 9px;
  border: 1px solid rgba(64, 76, 88, 0.72);
  border-radius: 8px;
  background: rgba(15, 19, 24, 0.62);
}

.elevation-metadata-grid span,
.elevation-metadata-grid strong {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.elevation-metadata-grid span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
}

.elevation-metadata-grid strong {
  margin-top: 4px;
  color: var(--text);
  font-size: 13px;
  line-height: 1.35;
}

.muted { color: var(--muted); }

.status-ok { color: var(--good); }
.status-warn { color: var(--warn); }
.status-bad { color: var(--bad); }

.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 8px; }
table { width: 100%; border-collapse: collapse; min-width: 720px; }
th, td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); }
th { color: var(--muted); font-weight: 600; font-size: 13px; }
tr:last-child td { border-bottom: 0; }

tr.row-failed td {
  background: rgba(255, 107, 107, 0.045);
}

.table-issue-hint {
  display: inline-block;
  max-width: 260px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  vertical-align: middle;
}

.table-issue-hint.has-issue {
  color: var(--bad);
}

.notice {
  min-height: 22px;
  margin-top: 12px;
  color: var(--muted);
}

.create-gate-message {
  order: -1;
  width: min(230px, 42vw);
  min-height: 0;
  margin: 0;
  color: var(--warn);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.25;
  overflow-wrap: break-word;
}

.progress-wrap {
  margin-top: 16px;
}

.progress-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 8px;
}

.progress-head strong { color: var(--text); }

.progress-track {
  position: relative;
  width: 100%;
  height: 12px;
  overflow: hidden;
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 999px;
}

.progress-track.is-processing::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  z-index: 2;
  width: 42%;
  background: linear-gradient(100deg, transparent 0%, rgba(255, 255, 255, 0.07) 32%, rgba(255, 255, 255, 0.22) 50%, rgba(255, 255, 255, 0.07) 68%, transparent 100%);
  transform: translateX(-160%);
  animation: progress-shimmer 3.6s linear infinite;
  pointer-events: none;
}

.progress-bar {
  position: relative;
  z-index: 1;
  width: 0%;
  height: 100%;
  background: var(--accent);
  transition: width 180ms ease;
}

@keyframes progress-shimmer {
  from { transform: translateX(-160%); }
  to { transform: translateX(340%); }
}

.form-row,
.upload-panel {
  display: grid;
  gap: 10px;
}

.form-row {
  grid-template-columns: minmax(140px, 180px) minmax(220px, 1fr) auto;
  align-items: center;
}

label {
  color: var(--muted);
  font-size: 14px;
}

input[type="file"] { width: 100%; }


.advanced-panel summary {
  cursor: pointer;
  color: var(--muted);
  font-weight: 700;
}

.advanced-actions {
  margin-top: 14px;
}

.advanced-panel .result {
  margin-top: 14px;
}

.result {
  min-height: 120px;
  max-height: 360px;
  overflow: auto;
  white-space: pre-wrap;
  word-break: break-word;
  margin: 0;
  padding: 14px;
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--text);
}

@media (max-width: 640px) {
  main { width: min(100% - 20px, 1080px); padding-top: 18px; }
  header { align-items: flex-start; flex-direction: column; }
  h1 { font-size: 24px; }
  .form-row { grid-template-columns: 1fr; }
  .status-row { align-items: flex-start; flex-direction: column; }
  .job-issue-header { flex-direction: column; }
  .job-issue-body { grid-template-columns: 1fr; }
  .metric-row { grid-template-columns: 1fr; }
  .results-section { padding: 16px; }
  .section-heading { padding-bottom: 14px; }
  .results-grid { grid-template-columns: 1fr; }
  .job-rename-form { grid-template-columns: 1fr; }
  .elevation-products-grid { grid-template-columns: 1fr; }
  .elevation-product-head { grid-template-columns: 42px minmax(0, 1fr); }
  .elevation-product-head .availability-badge { grid-column: 1 / -1; }
  .elevation-metadata-grid { grid-template-columns: 1fr; }
  .result-card { min-height: 0; }
  .result-actions { grid-template-columns: 1fr; }
  .full-zip-row { grid-template-columns: 42px 1fr; align-items: start; }
  .full-zip-download { grid-column: 1 / -1; width: 100%; }
}

.account-shell {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.account-button {
  max-width: 240px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 40;
  width: min(560px, calc(100vw - 32px));
  padding: 18px 54px 18px 18px;
  border: 1px solid rgba(79, 179, 255, 0.24);
  border-radius: 8px;
  background: #15191d;
  box-shadow: 0 22px 55px rgba(0, 0, 0, 0.46);
}

.account-menu[hidden],
.account-profile[hidden],
.account-auth-panel[hidden],
.account-method-panel[hidden],
.account-choice-panel[hidden],
.account-signed-in-actions[hidden],
.account-form label[hidden],
.account-form input[hidden],
.account-actions button[hidden],
.account-secondary-actions button[hidden] {
  display: none !important;
}

.account-menu-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 14px;
}

.account-menu-head strong {
  display: block;
  color: var(--text);
  font-size: 18px;
}

.account-menu-controls {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.account-close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid rgba(203, 213, 225, 0.55);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.94);
  color: #f8fafc;
  font-size: 24px;
  line-height: 1;
}

.account-close:hover {
  border-color: rgba(248, 250, 252, 0.86);
  background: rgba(30, 41, 59, 0.98);
}

.account-state {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.account-beta {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 7px;
  border: 1px solid rgba(255, 107, 107, 0.58);
  border-radius: 999px;
  background: rgba(255, 107, 107, 0.12);
  color: #fecaca;
  font-size: 11px;
  font-weight: 900;
}

.account-profile {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 10px;
  align-items: center;
  margin-bottom: 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(32, 38, 43, 0.7);
}

.account-profile img,
.account-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  background: rgba(79, 179, 255, 0.16);
  color: var(--text);
  font-size: 12px;
  font-weight: 900;
}

.account-profile span {
  display: block;
  color: var(--text);
  font-weight: 800;
  overflow-wrap: anywhere;
}

.account-profile small {
  color: var(--muted);
}

.account-access {
  display: inline-flex;
  width: fit-content;
  margin-top: 8px;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 900;
}

.account-access.is-active {
  border: 1px solid rgba(60, 214, 133, 0.48);
  background: rgba(60, 214, 133, 0.12);
  color: #bbf7d0;
}

.account-access.is-blocked {
  border: 1px solid rgba(255, 107, 107, 0.58);
  background: rgba(255, 107, 107, 0.12);
  color: #fecaca;
}

.account-access.is-unknown {
  border: 1px solid rgba(245, 193, 108, 0.55);
  background: rgba(245, 193, 108, 0.12);
  color: #fde68a;
}

.account-access-warning {
  display: block;
  margin-top: 6px;
}

.account-auth-panel {
  display: grid;
  gap: 12px;
}

.account-choice-panel {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.account-choice-card {
  display: grid;
  gap: 6px;
  min-height: 132px;
  padding: 14px;
  text-align: center;
  border-color: rgba(64, 76, 88, 0.86);
  background: rgba(32, 38, 43, 0.72);
}

.account-choice-card span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.account-choice-card strong {
  color: var(--text);
  font-size: 15px;
}

.account-choice-card small {
  color: var(--muted);
  line-height: 1.35;
}

.account-method-panel {
  display: grid;
  gap: 12px;
}

.account-method-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.account-method-head strong {
  color: var(--text);
  font-size: 15px;
}

.account-method-head button {
  padding: 7px 10px;
}

.account-form {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(32, 38, 43, 0.58);
}

.account-form label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.account-form input[type="email"],
.account-form input[type="password"],
.account-form input[type="text"] {
  width: 100%;
}

.account-actions {
  margin-top: 8px;
}

.account-actions button {
  flex: 1 1 auto;
}

.account-secondary-actions {
  display: flex;
  justify-content: center;
}

.account-secondary-actions button {
  border-color: transparent;
  background: transparent;
  color: var(--accent);
  padding: 6px 8px;
}

.account-terms {
  margin: 0;
  text-align: center;
  color: var(--muted);
  font-size: 12px;
}

.account-message {
  min-height: 20px;
  margin: 12px 0 0;
  font-size: 13px;
}

.account-message.is-error {
  color: var(--bad);
}

.account-message.is-info {
  color: var(--good);
}

@media (max-width: 640px) {
  .account-shell { width: 100%; }
  .account-button { max-width: 100%; }
  .account-menu {
    position: fixed;
    top: 76px;
    left: 10px;
    right: 10px;
    width: auto;
    max-height: calc(100vh - 96px);
    overflow: auto;
  }
  .account-choice-panel { grid-template-columns: 1fr; }
}

.primary-action {
  border-color: rgba(79, 179, 255, 0.72);
  background: #176aa0;
  color: #f8fbff;
  font-weight: 800;
}

.primary-action:hover {
  border-color: #9ed8ff;
  background: #1e7fbd;
}

.eyebrow {
  display: inline-flex;
  margin-bottom: 8px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.workspace-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: center;
  padding: 28px 0;
  border-bottom: 1px solid var(--line);
}

.workspace-hero h2 {
  max-width: 760px;
  margin: 0;
  color: var(--text);
  font-size: 34px;
  line-height: 1.12;
}

.workspace-hero p {
  max-width: 720px;
  margin: 12px 0 0;
}

.compact-hero {
  grid-template-columns: minmax(260px, 0.9fr) minmax(320px, 1fr);
}

.compact-hero h2 {
  font-size: 26px;
}

.hero-actions {
  width: min(260px, 100%);
  justify-items: stretch;
}

.hero-actions .primary-action {
  width: 100%;
}

.create-job-form,
.create-job-row {
  display: grid;
  gap: 10px;
}

.create-job-form {
  padding: 16px;
  border: 1px solid rgba(64, 76, 88, 0.86);
  border-radius: 8px;
  background: rgba(25, 29, 33, 0.82);
}

.create-job-row {
  grid-template-columns: minmax(0, 1fr) auto;
}

.workspace-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.summary-tile {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #171c21;
}

.summary-tile span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 8px;
}

.summary-tile strong {
  color: var(--text);
  font-size: 30px;
}

.workspace-section .section-heading,
.compact-heading {
  align-items: center;
}

.compact-heading h2,
.compact-heading .notice {
  margin: 0;
}

.job-card-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.compact-job-list {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.all-jobs-list {
  grid-template-columns: 1fr;
}

.all-jobs-list .job-card {
  grid-template-columns: minmax(240px, 1.2fr) minmax(180px, 0.9fr) minmax(260px, 1.4fr);
  align-items: center;
  gap: 18px;
  min-height: 96px;
}

.all-jobs-list .job-card-main {
  align-items: center;
}

.all-jobs-list .job-card-progress {
  margin: 0;
}

.all-jobs-list .job-card-meta {
  justify-content: flex-end;
}

.job-card-status-text {
  min-width: min(260px, 100%);
}

.job-card {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid rgba(64, 76, 88, 0.86);
  border-radius: 8px;
  background: rgba(28, 34, 40, 0.9);
}

.job-card {
  color: inherit;
  text-decoration: none;
}

.job-card:hover {
  border-color: rgba(79, 179, 255, 0.58);
  background: rgba(31, 39, 47, 0.96);
}

.job-card.is-failed {
  border-color: rgba(255, 107, 107, 0.48);
  background: rgba(45, 28, 31, 0.78);
}

.job-card-main {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
}

.job-card h3 {
  margin: 0;
  color: var(--text);
  font-size: 18px;
}

.job-card p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.job-card-meta,
.job-card-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 13px;
}

.job-card-meta span {
  overflow-wrap: anywhere;
}

.job-card-actions {
  justify-content: flex-end;
}

.job-next-action {
  text-align: center;
}

.job-card-progress {
  position: relative;
  height: 8px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #101418;
}

.job-card-progress.is-processing::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  z-index: 2;
  width: 42%;
  background: linear-gradient(100deg, transparent 0%, rgba(255, 255, 255, 0.07) 32%, rgba(255, 255, 255, 0.22) 50%, rgba(255, 255, 255, 0.07) 68%, transparent 100%);
  transform: translateX(-160%);
  animation: progress-shimmer 3.6s linear infinite;
  pointer-events: none;
}

.job-card-progress.is-queued::after {
  animation-duration: 14.4s;
}

.job-card-progress div {
  position: relative;
  z-index: 1;
  height: 100%;
  background: var(--accent);
}


@media (max-width: 900px) {
  .job-card-list,
  .compact-job-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .all-jobs-list .job-card {
    grid-template-columns: 1fr;
  }

  .all-jobs-list {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .job-card-list,
  .compact-job-list {
    grid-template-columns: 1fr;
  }
}

.empty-state {
  display: grid;
  justify-items: start;
  gap: 10px;
  padding: 20px;
  border: 1px dashed rgba(154, 166, 175, 0.48);
  border-radius: 8px;
  background: rgba(32, 38, 43, 0.42);
}

.empty-state h3 {
  margin: 0;
  color: var(--text);
}

.empty-state p {
  margin: 0;
}

.job-timeline {
  padding: 2px 0 0;
}

.timeline-steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.timeline-step {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 44px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(32, 38, 43, 0.44);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.timeline-flag {
  display: inline-flex;
  width: 16px;
  min-width: 16px;
  height: 16px;
  border: 1px solid rgba(154, 166, 175, 0.42);
  border-radius: 4px;
  background: rgba(17, 19, 21, 0.58);
}

.timeline-step.is-complete,
.timeline-step.is-current {
  border-color: rgba(71, 209, 140, 0.45);
  background: rgba(71, 209, 140, 0.08);
}

.timeline-step.is-complete .timeline-flag,
.timeline-step.is-current .timeline-flag {
  border-color: rgba(71, 209, 140, 0.72);
  background: var(--good);
  box-shadow: 0 0 0 3px rgba(71, 209, 140, 0.10);
}

.timeline-step.is-current strong {
  color: var(--text);
}

.timeline-step.is-failed {
  border-color: rgba(255, 107, 107, 0.50);
  background: rgba(255, 107, 107, 0.08);
}

.timeline-step.is-failed .timeline-flag {
  border-color: rgba(255, 107, 107, 0.72);
  background: var(--bad);
}


.technical-details {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}

.technical-details h2 {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
}

@media (max-width: 820px) {
  .workspace-hero,
  .compact-hero {
    grid-template-columns: 1fr;
  }
  .workspace-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .workspace-hero h2 {
    font-size: 28px;
  }
  .create-job-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .workspace-summary,
  .timeline-steps {
    grid-template-columns: 1fr;
  }
  .job-card-main,
  .job-card-actions {
    align-items: stretch;
    flex-direction: column;
  }
  .job-next-action {
    width: 100%;
  }
  .account-menu {
    padding-right: 54px;
  }
}

.create-section[hidden] {
  display: none !important;
}

.file-input-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  clip-path: inset(50%);
}

.upload-file-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  width: 100%;
  text-align: center;
  font-weight: 800;
}

.upload-file-button.is-disabled,
.button.is-disabled {
  opacity: 0.55;
  pointer-events: none;
}

.upload-selected-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.upload-selected-actions button {
  min-height: 46px;
}

.upload-selected-actions button:first-child {
  border-color: rgba(79, 179, 255, 0.72);
  background: #176aa0;
  color: #f8fbff;
  font-weight: 800;
}

.progress-section-heading {
  padding-bottom: 0;
  border-bottom: 0;
}

.progress-section-heading h2 {
  margin: 0;
}

.progress-section-heading button {
  min-width: 180px;
}

@media (max-width: 640px) {
  .upload-selected-actions,
  .progress-section-heading {
    grid-template-columns: 1fr;
  }
  .progress-section-heading button {
    width: 100%;
  }
}

.file-input-hidden {
  display: none !important;
}

.upload-picker-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.upload-picker-row .upload-file-button {
  width: auto;
  min-width: 170px;
  max-width: 240px;
  padding-inline: 14px;
}

.upload-file-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  margin-right: 8px;
  border: 1px solid rgba(79, 179, 255, 0.45);
  border-radius: 6px;
  background: rgba(79, 179, 255, 0.13);
  color: var(--text);
  font-size: 10px;
  font-weight: 900;
}

.upload-file-summary {
  color: var(--muted);
  font-size: 14px;
  overflow-wrap: anywhere;
}

@media (max-width: 640px) {
  .upload-picker-row {
    align-items: stretch;
    flex-direction: column;
  }
  .upload-picker-row .upload-file-button {
    max-width: none;
    width: 100%;
  }
}

.upload-selected-actions[hidden] {
  display: none !important;
}

.upload-selected-actions {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 10px;
}

.upload-selected-actions button {
  flex: 0 0 auto;
  width: auto;
  min-width: 140px;
}

.upload-selected-actions button:first-child {
  min-width: 160px;
}

#upload.primary-action {
  min-width: 190px;
  border-color: rgba(79, 179, 255, 0.9);
  background: #176aa0;
  color: #f8fbff;
  font-weight: 900;
}

#upload.primary-action:hover:not(:disabled) {
  background: #1e7fbd;
}

.upload-selection-required {
  color: var(--text);
  font-weight: 800;
}

.upload-selection-required.is-error {
  color: var(--bad);
}

.confirmation-dialog {
  width: min(520px, calc(100vw - 32px));
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--panel);
  color: var(--text);
}

.confirmation-dialog::backdrop {
  background: rgba(0, 0, 0, 0.7);
}

.confirmation-dialog h2 {
  margin-top: 0;
}

@media (max-width: 640px) {
  .upload-selected-actions {
    width: 100%;
  }
  .upload-selected-actions button {
    flex: 1 1 0;
    min-width: 0;
  }
}

.stop-processing-button {
  border-color: rgba(248, 113, 113, 0.72);
  background: #9f1f2f;
  color: #fff5f5;
  font-weight: 900;
}

.stop-processing-button:hover {
  border-color: rgba(254, 202, 202, 0.94);
  background: #be2639;
}

.progress-track.is-queued::after {
  animation-duration: 14.4s;
}


.admin-config-shell h2 {
  margin-top: 0;
  color: var(--text);
}

.admin-config-panel {
  display: grid;
  gap: 14px;
  margin-top: 14px;
}

.admin-warning {
  padding: 10px 12px;
  border: 1px solid rgba(240, 184, 79, 0.45);
  border-radius: 6px;
  color: var(--warn);
  background: rgba(240, 184, 79, 0.08);
  font-size: 13px;
}

.admin-worker-list {
  display: grid;
  gap: 12px;
}

.admin-worker-card {
  display: grid;
  gap: 14px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(32, 38, 43, 0.58);
}

.admin-worker-head,
.admin-capacity-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.admin-worker-head h3,
.admin-worker-head p {
  margin: 0;
}

.admin-worker-head h3 {
  font-size: 16px;
}

.admin-worker-head p {
  margin-top: 3px;
  font-size: 13px;
}

.admin-worker-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
}

.admin-capacity-form {
  display: grid;
  gap: 8px;
}

.admin-capacity-form label {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.admin-capacity-row input {
  width: 120px;
}


.admin-panel-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.admin-diagnostics-details {
  border: 1px solid rgba(64, 76, 88, 0.72);
  border-radius: 8px;
  padding: 10px 12px;
  background: rgba(18, 24, 30, 0.42);
}

.admin-diagnostics-details summary {
  cursor: pointer;
  font-weight: 800;
  color: var(--text);
}

.admin-job-table-wrap {
  width: 100%;
  overflow-x: auto;
  margin-top: 10px;
}

.admin-job-table {
  width: 100%;
  min-width: 920px;
  border-collapse: collapse;
  font-size: 12px;
}

.admin-job-table th,
.admin-job-table td {
  padding: 8px 9px;
  border-bottom: 1px solid rgba(64, 76, 88, 0.72);
  text-align: left;
  vertical-align: top;
}

.admin-job-table th {
  color: var(--muted);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0;
}

.admin-job-table td span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
}

.admin-limitations {
  margin: 12px 0 0;
  padding-left: 18px;
  color: var(--muted);
  font-size: 12px;
}

.admin-limitations li + li {
  margin-top: 4px;
}

.upload-debug-controls[hidden] {
  display: none !important;
}

.upload-debug-controls {
  display: grid;
  grid-template-columns: auto minmax(72px, 96px) 1fr;
  gap: 8px 12px;
  align-items: center;
  padding: 10px 12px;
  border: 1px dashed rgba(133, 146, 166, 0.7);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  color: #475569;
  font-size: 0.88rem;
}

.upload-debug-controls strong {
  grid-column: 1 / -1;
  color: #92400e;
  font-size: 0.82rem;
  text-transform: uppercase;
}

.upload-debug-controls input[type="number"] {
  width: 100%;
}

.upload-debug-controls .checkbox-row {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 8px;
}

@media (max-width: 720px) {
  .image-map,
  .image-map.has-leaflet-map {
    min-height: 300px;
  }
}


.sharing-body {
  display: grid;
  gap: 14px;
}

.sharing-controls,
.sharing-locked {
  display: grid;
  gap: 12px;
  max-width: 720px;
}

.sharing-controls label {
  color: var(--muted);
  font-weight: 700;
}

.share-link-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.share-link-row input {
  width: 100%;
}

.sharing-controls select,
.sharing-controls input[type="date"] {
  appearance: none;
  border: 1px solid var(--line);
  background: var(--panel-2);
  color: var(--text);
  border-radius: 6px;
  padding: 10px 14px;
  font: inherit;
}

@media (max-width: 720px) {
  .share-link-row {
    grid-template-columns: 1fr;
  }
}


.account-summary-card .compact-grid,
.account-limits-grid {
  align-items: stretch;
}

.account-plan-hero h2 {
  font-size: clamp(2rem, 5vw, 4rem);
  text-transform: capitalize;
}

.account-dashboard-summary .summary-tile strong {
  font-size: clamp(1.4rem, 3vw, 2.2rem);
}

.account-limits-grid .metric {
  min-height: 92px;
}


.plan-badge {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 9px;
  background: var(--panel-2);
  color: var(--accent);
  font-size: 0.8rem;
  font-weight: 800;
  vertical-align: middle;
}

.plan-feature-grid,
.plans-compare-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.plan-feature,
.plan-compare-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-2);
  padding: 14px;
}

.plan-feature span {
  display: block;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 700;
  margin-bottom: 5px;
}

.plan-feature.is-enabled strong {
  color: var(--good);
}

.plan-feature.is-disabled strong {
  color: var(--muted);
}

.plan-compare-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.plan-compare-head h3 {
  margin: 0;
}

.plan-compare-card p {
  color: var(--muted);
  min-height: 54px;
}

.share-output-permissions {
  display: grid;
  gap: 8px;
  margin-top: 8px;
}

.share-output-permissions h3 {
  margin: 0;
  font-size: 14px;
}

.share-output-permissions-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

#share-save.is-dirty {
  background: #2563eb;
  border-color: #60a5fa;
  color: #ffffff;
}

#share-save.is-dirty:hover {
  background: #1d4ed8;
}

.share-output-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 8px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.admin-search-form,
.admin-subscription-form {
  display: grid;
  gap: 14px;
}

.admin-search-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.admin-table-wrap {
  margin-top: 16px;
  overflow-x: auto;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
}

.admin-table th,
.admin-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.admin-table th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}

.admin-table tr[data-user-id] {
  cursor: pointer;
}

.admin-table tr[data-user-id]:hover,
.admin-table tr[data-user-id]:focus {
  background: rgba(79, 179, 255, 0.08);
  outline: none;
}

.admin-table small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.form-grid label,
.admin-notes-field {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
}

select,
input[type="datetime-local"],
textarea {
  appearance: none;
  border: 1px solid var(--line);
  background: var(--panel-2);
  color: var(--text);
  border-radius: 6px;
  padding: 10px 14px;
  font: inherit;
}

textarea {
  resize: vertical;
  min-height: 96px;
}

.admin-form-actions {
  margin-top: 4px;
}

.account-admin-panel[hidden] {
  display: none;
}

@media (max-width: 760px) {
  .admin-search-row,
  .form-grid {
    grid-template-columns: 1fr;
  }
}


.admin-logs-main {
  width: min(1500px, calc(100% - 32px));
}

.admin-log-controls h2 {
  margin-top: 0;
  color: var(--text);
}

.admin-log-control-grid {
  display: grid;
  grid-template-columns: 120px 150px minmax(220px, 1fr);
  gap: 12px;
  align-items: end;
}

.admin-log-control-grid label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.admin-log-control-grid select,
.admin-log-control-grid input[type="number"] {
  appearance: none;
  border: 1px solid var(--line);
  background: var(--panel-2);
  color: var(--text);
  border-radius: 6px;
  padding: 10px 14px;
  font: inherit;
  width: 100%;
}

.admin-log-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 14px;
}

.admin-log-tab.is-active,
#logs-live.is-active {
  border-color: rgba(79, 179, 255, 0.72);
  background: rgba(79, 179, 255, 0.16);
}

.admin-log-grid {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.admin-log-grid.columns-1 { grid-template-columns: 1fr; }
.admin-log-grid.columns-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.admin-log-grid.columns-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.admin-log-card {
  min-width: 0;
  display: grid;
  grid-template-rows: auto auto minmax(420px, 70vh);
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(25, 29, 33, 0.92);
}

.admin-log-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.admin-log-card-head h3,
.admin-log-card-head p {
  margin: 0;
}

.admin-log-card-head h3 {
  font-size: 16px;
  color: var(--text);
}

.admin-log-card-head p,
.admin-log-meta {
  color: var(--muted);
  font-size: 12px;
}

.admin-log-meta {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.admin-log-output {
  margin: 0;
  min-width: 0;
  overflow: auto;
  padding: 12px;
  border: 1px solid rgba(64, 76, 88, 0.74);
  border-radius: 6px;
  background: #0b0e11;
  color: #d8e1e8;
  font: 12px/1.45 ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  white-space: pre;
}

.admin-log-line {
  min-height: 17px;
}

.admin-log-empty {
  color: var(--muted);
  white-space: normal;
}

@media (max-width: 1180px) {
  .admin-log-grid.columns-3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 820px) {
  .admin-logs-main { width: min(100% - 20px, 1080px); }
  .admin-log-control-grid,
  .admin-log-grid.columns-2,
  .admin-log-grid.columns-3 {
    grid-template-columns: 1fr;
  }
  .admin-log-card {
    grid-template-rows: auto auto minmax(320px, 62vh);
  }
}

@media (max-width: 900px) {
  .processing-options-layout {
    grid-template-columns: 1fr;
  }

  .processing-config-summary-section {
    grid-column: auto;
    grid-row: auto;
  }
}

@media (max-width: 560px) {
  .processing-profile-grid,
  .quality-grid,
  .output-choice-grid {
    grid-template-columns: 1fr;
  }

  .processing-options-actions {
    align-items: stretch;
  }

  .processing-options-actions button {
    width: 100%;
  }
}

.validation-debug-body {
  display: grid;
  gap: 14px;
}

.validation-debug-actions {
  justify-content: flex-start;
}

.validation-debug-content {
  display: grid;
  gap: 14px;
}

.debug-block {
  display: grid;
  gap: 10px;
  min-width: 0;
  padding-top: 4px;
}

.debug-block h3 {
  margin: 0;
  font-size: 14px;
}

.debug-split {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
}

.debug-pill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.debug-pill {
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--muted);
  font-size: 12px;
  padding: 5px 9px;
}

.debug-pill.is-on {
  border-color: rgba(34, 197, 94, 0.46);
  color: var(--text);
}

.debug-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.debug-table th,
.debug-table td {
  border-bottom: 1px solid var(--border);
  padding: 8px 6px;
  text-align: left;
  vertical-align: top;
}

.debug-artifact-list {
  display: grid;
  gap: 7px;
}

.debug-artifact-row {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) minmax(140px, 1.2fr) minmax(110px, 0.8fr) minmax(70px, 0.5fr);
  gap: 8px;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px;
  font-size: 12px;
}

.debug-artifact-row span {
  color: var(--muted);
}

.debug-block pre,
.debug-log-preview pre {
  max-height: 360px;
  overflow: auto;
  margin: 0;
  padding: 12px;
  border: 1px solid rgba(64, 76, 88, 0.74);
  border-radius: 6px;
  background: #0b0e11;
  color: #d8e1e8;
  font: 12px/1.45 ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  white-space: pre;
}

.debug-finding-list {
  display: grid;
  gap: 7px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.debug-finding-list li {
  display: grid;
  gap: 4px;
  border: 1px solid rgba(245, 158, 11, 0.32);
  border-radius: 6px;
  padding: 8px;
}

.debug-finding-list span {
  color: var(--muted);
  font-size: 12px;
}

.debug-finding-list code {
  white-space: pre-wrap;
  word-break: break-word;
}

@media (max-width: 820px) {
  .debug-split,
  .debug-artifact-row {
    grid-template-columns: 1fr;
  }

  .debug-table {
    display: block;
    overflow-x: auto;
  }
}
