:root {
  color-scheme: light;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #17243b;
  background: #f3f6fa;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  --ink: #17243b;
  --muted: #78869a;
  --blue: #1769e8;
  --blue-dark: #0e56ce;
  --line: #e5eaf0;
  --green: #15803d;
  --red: #c2413b;
  --card-shadow: 0 2px 6px rgb(22 40 70 / 3%), 0 12px 32px rgb(22 40 70 / 2%);
}

* {
  box-sizing: border-box;
}

body {
  min-width: 1200px;
  min-height: 100vh;
  margin: 0;
}

button,
input {
  font: inherit;
}

button {
  color: inherit;
}

button:focus-visible,
a:focus-visible,
input:focus-visible {
  outline: 3px solid rgb(23 105 232 / 35%);
  outline-offset: 2px;
}

.skip-link {
  position: absolute;
  z-index: 20;
  top: 8px;
  left: 8px;
  padding: 10px 14px;
  transform: translateY(-150%);
  border-radius: 8px;
  background: #fff;
  color: var(--blue-dark);
}

.skip-link:focus {
  transform: translateY(0);
}

.topbar {
  height: 66px;
  display: flex;
  align-items: center;
  gap: 30px;
  padding: 0 max(30px, calc((100vw - 1600px) / 2));
  border-bottom: 1px solid #e8edf2;
  background: #fff;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: inherit;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 35px;
  height: 35px;
  place-items: center;
  border-radius: 10px;
  background: #eaf2ff;
  color: var(--blue);
}

.brand-mark svg {
  width: 23px;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.brand-copy {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.brand-copy strong {
  font-family: inherit;
  font-size: 15px;
  letter-spacing: -.3px;
}

.brand-copy span {
  color: #8793a3;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 1.2px;
}

.status-dot,
.record-badge-dot {
  width: 7px;
  height: 7px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: #7d8ca0;
}

.topbar-note {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  color: #67768c;
  font-size: 12px;
  font-weight: 600;
}

.status-dot {
  background: #e4a43c;
  box-shadow: 0 0 0 3px #fff3dc;
}

.page-shell {
  max-width: 1660px;
  margin: 0 auto;
  padding: 24px 28px 40px;
}

.page-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}

.eyebrow {
  margin: 0 0 5px;
  color: #6480a6;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.2px;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 5px;
  font-family: inherit;
  font-size: clamp(22px, 2vw, 27px);
  font-weight: 800;
  letter-spacing: -.8px;
}

.record-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 11px;
  border: 1px solid #dfe6ee;
  border-radius: 9px;
  background: #fff;
  color: #65748b;
  font-size: 11px;
  font-weight: 600;
}

.record-badge-dot {
  background: #54a16b;
  box-shadow: 0 0 0 3px #eaf6ed;
}


.banner-icon {
  display: grid;
  width: 17px;
  height: 17px;
  flex: 0 0 auto;
  place-items: center;
  margin-top: 1px;
  border-radius: 50%;
  background: #f7e8c3;
  color: #8a641c;
  font-size: 11px;
  font-weight: 700;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(245px, .82fr) minmax(420px, 1.42fr) minmax(400px, 1.18fr);
  align-items: start;
  gap: 14px;
}

.left-column,
.middle-column,
.right-column {
  display: grid;
  gap: 14px;
  min-width: 0;
}

.card {
  min-width: 0;
  padding: 17px;
  border: 1px solid #e6ebf0;
  border-radius: 13px;
  background: #fff;
  box-shadow: var(--card-shadow);
}

.card-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 15px;
}

.card-heading > div {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  min-width: 0;
}

.card-heading h2 {
  margin: 0;
  font-family: inherit;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: -.25px;
}

.step-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 27px;
  height: 20px;
  padding: 0 5px;
  border-radius: 6px;
  background: #f0f5fc;
  color: #5074a5;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .35px;
}

.card-subtitle {
  margin: 4px 0 0;
  color: #8793a3;
  font-size: 10px;
  line-height: 1.4;
}

.icon-button {
  display: grid;
  width: 26px;
  height: 26px;
  place-items: center;
  border: 1px solid #e4eaf0;
  border-radius: 7px;
  background: #fff;
  color: #74839a;
  cursor: pointer;
}

.help-button {
  font-size: 12px;
  font-weight: 700;
}

.dropzone {
  display: flex;
  min-height: 188px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 17px 10px 13px;
  border: 1px dashed #c9d6e5;
  border-radius: 10px;
  background: #fbfcfe;
  text-align: center;
  cursor: pointer;
  transition: border-color .15s, background-color .15s;
}

.upload-workspace {
  margin-bottom: 14px;
}

.upload-workspace .card-heading {
  align-items: center;
  margin-bottom: 12px;
}

.upload-limit {
  padding: 6px 9px;
  border: 1px solid #e1e8f0;
  border-radius: 7px;
  background: #f8fafc;
  color: #64748b;
  font-size: 9px;
  font-weight: 700;
  white-space: nowrap;
}

.upload-workspace .dropzone {
  min-height: 145px;
}

.upload-workspace .upload-icon {
  margin-bottom: 5px;
}

.upload-list-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 12px;
}

.upload-list-heading .section-subheading {
  margin: 0;
}

.text-button {
  padding: 5px 8px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #536981;
  font-size: 9px;
  font-weight: 700;
  cursor: pointer;
}

.text-button:hover:not(:disabled) {
  background: #f2f5f8;
  color: #29374d;
}

.text-button:disabled {
  color: #a4afbb;
  cursor: not-allowed;
}

.upload-file-list {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  max-height: 152px;
  overflow: auto;
  margin-top: 8px;
  padding-right: 3px;
}

.upload-file-list .file-item {
  min-width: 0;
  padding: 6px;
  border-color: #edf0f4;
  background: #fcfdff;
}

.upload-file-list .file-icon {
  width: 25px;
  height: 27px;
  font-size: 8px;
  font-weight: 700;
}

.upload-file-list .file-remove {
  width: 20px;
  height: 20px;
}

.upload-empty {
  grid-column: 1 / -1;
  padding: 5px 2px;
  text-align: left;
}

.run-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 14px;
  padding-top: 13px;
  border-top: 1px solid #edf0f4;
}

.run-row p {
  margin: 0;
  color: #77869a;
  font-size: 10px;
}

.run-button {
  min-width: 150px;
  min-height: 39px;
  font-size: 11px;
}

.progress-panel {
  margin-top: 13px;
  padding: 12px 13px;
  border: 1px solid #dfe9f8;
  border-radius: 9px;
  background: #f8fbff;
}

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

.progress-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 9px;
}

.progress-heading > div {
  display: grid;
  gap: 4px;
}

.progress-heading strong {
  color: #34445a;
  font-size: 10px;
}

.progress-heading span {
  color: #78879b;
  font-size: 9px;
}

#progress-percent {
  color: var(--blue);
  font-size: 11px;
  font-weight: 800;
}

.progress-track {
  height: 7px;
  overflow: hidden;
  border-radius: 999px;
  background: #e6edf6;
}

.progress-fill {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #1769e8, #54a0fa);
  transition: width .1s linear;
}

.dropzone:hover,
.dropzone.is-dragging {
  border-color: var(--blue);
  background: #f4f8ff;
}

.upload-icon {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  margin-bottom: 8px;
  color: #72849b;
}

.upload-icon svg {
  width: 37px;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.6;
}

.dropzone > strong {
  color: #33425a;
  font-size: 11px;
}

.dropzone-divider {
  margin: 4px 0 8px;
  color: #9aa5b2;
  font-size: 10px;
}

.button {
  display: inline-flex;
  min-height: 35px;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 12px;
  border: 1px solid transparent;
  border-radius: 8px;
  font-size: 10px;
  font-weight: 700;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color .15s, border-color .15s, transform .15s;
}

.button:not(:disabled):active {
  transform: translateY(1px);
}

.button svg {
  width: 15px;
  height: 15px;
  flex: 0 0 auto;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.button-primary {
  background: var(--blue);
  color: #fff;
}

.button-primary:not(:disabled):hover {
  background: var(--blue-dark);
}

.browse-button {
  min-width: 112px;
  min-height: 34px;
  font-size: 10px;
}

.supported-formats {
  margin-top: 10px;
  color: #8794a5;
  font-size: 9px;
}

.section-subheading {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 19px 0 9px;
}

.section-subheading h3 {
  margin: 0;
  font-size: 11px;
  font-weight: 700;
}

.count-pill,
.muted-count {
  color: #8793a3;
  font-size: 10px;
}

.count-pill {
  display: grid;
  width: 18px;
  height: 18px;
  place-items: center;
  border-radius: 6px;
  background: #f1f4f8;
  font-size: 9px;
  font-weight: 700;
}

.file-list,
.parcel-list,
.validation-list {
  display: grid;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.file-item {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 9px;
  padding: 8px 7px;
  border: 1px solid transparent;
  border-radius: 8px;
  transition: background-color .15s;
}

.file-item:hover {
  background: #f6f8fb;
}

.file-icon {
  display: grid;
  width: 29px;
  height: 32px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 6px;
  background: #edf2f7;
  color: #75859a;
}

.file-icon svg {
  width: 17px;
  height: 17px;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.6;
}

.file-icon.file-shp {
  background: #e7f6ef;
  color: #25885a;
}

.file-icon.file-pdf {
  background: #fff0ef;
  color: #dd5b51;
}

.file-icon.file-image {
  background: #eef4ff;
  color: #527bba;
}

.file-copy {
  min-width: 0;
  flex: 1;
}

.file-name,
.file-meta {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.file-name {
  color: #29374d;
  font-size: 10px;
  font-weight: 600;
}

.file-meta {
  margin-top: 3px;
  color: #8793a3;
  font-size: 9px;
}

.file-remove {
  display: grid;
  width: 24px;
  height: 24px;
  flex: 0 0 auto;
  place-items: center;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: #a0a9b5;
  cursor: pointer;
  font-size: 16px;
}

.file-remove:hover {
  background: #fff0ef;
  color: var(--red);
}

.section-footnote {
  margin: 10px 0 0;
  color: #8a96a5;
  font-size: 9px;
  line-height: 1.45;
}

.parcel-card {
  padding-bottom: 14px;
}

.parcel-card .card-heading {
  align-items: center;
  margin-bottom: 12px;
}

.parcel-card .card-heading > div {
  align-items: center;
}

.search-box {
  display: flex;
  height: 35px;
  align-items: center;
  gap: 7px;
  margin-bottom: 10px;
  padding: 0 9px;
  border: 1px solid #dfe6ee;
  border-radius: 8px;
}

.search-box svg {
  width: 15px;
  height: 15px;
  flex: 0 0 auto;
  stroke: #8794a5;
  stroke-linecap: round;
  stroke-width: 1.7;
}

.search-box input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font-size: 10px;
}

.search-box input::placeholder {
  color: #9aa5b2;
}

.parcel-row {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 10px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.parcel-row:hover {
  background: #f5f8fc;
}

.parcel-row.is-selected {
  border-color: #d7e7ff;
  background: #eef5ff;
  box-shadow: inset 2px 0 #347cf0;
}

.parcel-lot {
  overflow: hidden;
  color: #34425a;
  font-size: 10px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.parcel-area {
  flex: 0 0 auto;
  color: #53647c;
  font-size: 9px;
  font-weight: 600;
}

.parcel-row.is-selected .parcel-area {
  color: var(--blue);
}

.empty-list {
  padding: 12px 6px;
  color: #8793a3;
  font-size: 10px;
  text-align: center;
}

.details-card .card-heading,
.technical-card .card-heading {
  align-items: center;
}

.edit-button {
  min-height: 30px;
  padding: 0 9px;
  font-size: 9px;
}

.button-secondary {
  border-color: #dce4ec;
  background: #fff;
  color: #35445a;
}

.button-secondary:not(:disabled):hover {
  border-color: #b7c8dd;
  background: #f8fafc;
}

.field-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px 15px;
}

.field-column {
  display: grid;
  align-content: start;
  gap: 8px;
  min-width: 0;
}

.data-field {
  display: grid;
  grid-template-columns: minmax(78px, .72fr) minmax(100px, 1.28fr);
  align-items: center;
  gap: 7px;
  min-width: 0;
}

.data-field label {
  color: #617087;
  font-size: 9px;
  font-weight: 600;
}

.data-field input {
  width: 100%;
  min-width: 0;
  height: 29px;
  padding: 0 8px;
  border: 1px solid #e2e8ef;
  border-radius: 6px;
  outline: 0;
  background: #f8fafc;
  color: #26354d;
  font-size: 9px;
  font-weight: 600;
  text-overflow: ellipsis;
}

.data-field input:read-only {
  cursor: default;
}

.data-field.is-editing input,
.survey-summary.is-editing input {
  border-color: #9dbbe6;
  background: #fff;
}

.data-field input::placeholder,
.survey-copy input::placeholder {
  color: #a0aab6;
  font-weight: 400;
}

.survey-inputs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
  margin-bottom: 12px;
}

.survey-summary {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 9px;
  min-height: 59px;
  padding: 9px 10px;
  border: 1px solid #eef1f5;
  border-radius: 8px;
  background: #fafbfd;
}

.survey-icon {
  display: grid;
  width: 25px;
  height: 25px;
  flex: 0 0 auto;
  place-items: center;
  color: #4b5c72;
}

.survey-icon svg {
  width: 22px;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.line-icon {
  color: #60738b;
}

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

.field-label {
  color: #748196;
  font-size: 9px;
  font-weight: 600;
}

.survey-copy input {
  width: 100%;
  min-width: 0;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 4px;
  outline: 0;
  background: transparent;
  color: #29374d;
  font-size: 9px;
  font-weight: 600;
}

.tie-line-inputs {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 4px;
  color: #a0a9b5;
}

.tie-line-inputs input {
  min-width: 0;
}

.tie-line-inputs input:first-child {
  flex: 1.25;
}

.tie-line-inputs input:last-child {
  flex: 1;
}

.coordinate-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 10px;
  margin: -2px 0 12px;
  padding: 10px;
  border: 1px solid #e9edf3;
  border-radius: 8px;
  background: #fbfcfe;
}

.coordinate-heading {
  grid-column: 1 / -1;
  margin: 0;
  color: #63738a;
  font-size: 9px;
  font-weight: 700;
}

.coordinate-fields label {
  display: grid;
  gap: 5px;
  color: #738197;
  font-size: 9px;
  font-weight: 600;
}

.coordinate-fields input {
  width: 100%;
  height: 29px;
  padding: 0 8px;
  border: 1px solid #dfe6ee;
  border-radius: 6px;
  background: #fff;
  color: #29374d;
  font-size: 10px;
}

.coordinate-fields[hidden] {
  display: none;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid #e6ebf0;
  border-radius: 8px;
}

.boundary-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.boundary-table th,
.boundary-table td {
  padding: 7px 9px;
  border-bottom: 1px solid #edf0f4;
  color: #46546a;
  font-size: 9px;
  white-space: nowrap;
}

.boundary-table th {
  background: #f7f9fc;
  color: #607087;
  font-weight: 700;
}

.boundary-table tbody tr:last-child td {
  border-bottom: 0;
}

.boundary-table .align-right {
  text-align: right;
}

.area-summary {
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  align-items: center;
  gap: 9px;
  margin-top: 11px;
  padding: 12px 11px;
  border: 1px solid #d7ecdf;
  border-radius: 9px;
  background: linear-gradient(110deg, #f1fbf4, #eff9f3);
}

.area-cell {
  min-width: 0;
}

.area-cell + .area-cell,
.area-difference {
  padding-left: 10px;
  border-left: 1px solid #d4e5db;
}

.area-label {
  display: block;
  margin-bottom: 4px;
  color: #688271;
  font-size: 8px;
  line-height: 1.35;
}

.area-value {
  color: #1d3440;
  font-family: inherit;
  font-size: clamp(13px, 1.2vw, 17px);
  font-weight: 800;
  white-space: nowrap;
}

.area-difference {
  min-width: 94px;
}

.area-result {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 4px;
  color: var(--green);
  font-size: 8px;
  font-weight: 700;
}

.area-result.is-fail {
  color: var(--red);
}

.area-result-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
}

.map-card {
  padding: 15px;
}

.map-heading {
  align-items: center;
  margin-bottom: 11px;
}

.crs-badge {
  padding: 5px 7px;
  border: 1px solid #e0e8f1;
  border-radius: 6px;
  background: #f7f9fc;
  color: #60738c;
  font-size: 8px;
  font-weight: 700;
  white-space: nowrap;
}

.map-frame {
  overflow: hidden;
  border: 1px solid #dce5df;
  border-radius: 9px;
  background: #eaf0e7;
}

.map-parcel {
  stroke-linejoin: round;
  stroke-width: 2.1;
  transition: fill .15s, stroke-width .15s;
}

.map-parcel.is-selected {
  fill: #f47e6f;
  fill-opacity: .55;
  stroke: #df594c;
  stroke-width: 3;
}

.map-parcel.is-neighbor {
  fill: #4d83d6;
  fill-opacity: .25;
  stroke: #4d83d6;
}

.map-label {
  fill: #26364a;
  font-size: 13px;
  font-weight: 700;
  paint-order: stroke;
  stroke: #fff;
  stroke-linejoin: round;
  stroke-width: 4px;
  text-anchor: middle;
}

.map-corner {
  fill: #f0a343;
  stroke: #fff;
  stroke-width: 2;
}

.map-corner-number {
  fill: #34445a;
  font-size: 9px;
  font-weight: 700;
  text-anchor: middle;
}

.map-control {
  fill: #43536a;
  font-family: sans-serif;
  font-size: 21px;
  font-weight: 600;
  text-anchor: middle;
}

.legend-label {
  fill: #45546a;
  font-size: 9px;
  font-weight: 600;
}

.map-scale-label {
  fill: #536379;
  font-size: 9px;
}

.map-caption {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 9px 10px;
  color: #6f7f91;
  font-size: 9px;
}

.map-caption-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #5e9d72;
}

.validation-card {
  padding: 15px;
}

.validation-heading {
  align-items: center;
  margin-bottom: 12px;
}

.validation-count {
  padding: 5px 8px;
  border: 1px solid #e5eaf0;
  border-radius: 999px;
  background: #f7f9fb;
  color: #63728a;
  font-size: 9px;
  font-weight: 700;
  white-space: nowrap;
}

.validation-count.is-pass {
  border-color: #d4eadb;
  background: #f0faf3;
  color: var(--green);
}

.validation-count.is-attention {
  border-color: #f1dfbc;
  background: #fff9ec;
  color: #986a1e;
}

.validation-list {
  gap: 0;
}

.validation-item {
  display: grid;
  grid-template-columns: 18px 1fr auto;
  align-items: center;
  gap: 8px;
  padding: 9px 0;
  border-bottom: 1px solid #eef1f4;
}

.validation-item:last-child {
  border-bottom: 0;
}

.validation-icon {
  display: grid;
  width: 17px;
  height: 17px;
  place-items: center;
  border-radius: 50%;
  background: #eaf6ed;
  color: #278249;
  font-size: 10px;
  font-weight: 800;
}

.validation-item.is-warning .validation-icon {
  background: #fff3dc;
  color: #a67624;
}

.validation-item.is-fail .validation-icon {
  background: #ffefee;
  color: #bd4d44;
}

.validation-copy {
  min-width: 0;
}

.validation-name {
  display: block;
  color: #39475d;
  font-size: 9px;
  font-weight: 700;
}

.validation-detail {
  display: block;
  margin-top: 3px;
  color: #8793a3;
  font-size: 8px;
  line-height: 1.35;
}

.validation-result {
  color: var(--green);
  font-size: 9px;
  font-weight: 700;
  white-space: nowrap;
}

.validation-item.is-warning .validation-result {
  color: #986a1e;
}

.validation-item.is-fail .validation-result {
  color: var(--red);
}

.export-note {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-top: 10px;
  padding: 9px;
  border: 1px solid #f0e2c6;
  border-radius: 8px;
  background: #fffbf2;
}

.export-note-icon {
  display: grid;
  width: 15px;
  height: 15px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 50%;
  background: #f6e8c8;
  color: #8a6725;
  font-size: 9px;
  font-weight: 800;
}

.export-note p {
  margin: 0;
  color: #77633c;
  font-size: 8px;
  line-height: 1.5;
}

.action-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
  margin-top: 12px;
}

.action-row .button {
  min-width: 0;
  min-height: 36px;
  padding: 0 8px;
  font-size: 9px;
}

.button-approve {
  grid-column: 1 / -1;
  background: var(--blue);
  color: #fff;
}

.button-approve:not(:disabled):hover {
  background: var(--blue-dark);
}

.button:disabled {
  border-color: #e2e7ed;
  background: #f6f8fa;
  color: #a1aab5;
  cursor: not-allowed;
}

.results-card {
  padding: 18px 20px 10px;
}

.results-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
}

.results-heading > div:first-child {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.results-heading h2 {
  margin: 0;
  font-size: 14px;
  font-weight: 800;
}

.results-search {
  width: 270px;
  flex: 0 0 auto;
  margin: 0;
}

.file-zip {
  background: #f0edff;
  color: #7154b5;
}

.results-table-wrap {
  overflow: auto;
  border: 1px solid #e6ebf0;
  border-radius: 9px;
}

.results-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.results-table th {
  padding: 11px 12px;
  background: #f7f9fc;
  color: #748196;
  font-size: 9px;
  font-weight: 700;
  white-space: nowrap;
}

.results-table td {
  padding: 11px 12px;
  border-top: 1px solid #edf0f4;
  color: #47566d;
  font-size: 10px;
  white-space: nowrap;
}

.result-row {
  transition: background-color .12s;
  cursor: pointer;
}

.result-row:hover,
.result-row:focus-within {
  background: #f8fbff;
}

.table-parcel-link {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 0;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.table-file {
  display: inline-flex;
  align-items: center;
  gap: 9px;
}

.table-file > span:last-child {
  display: grid;
  gap: 3px;
}

.table-file strong {
  max-width: 430px;
  overflow: hidden;
  color: #29374d;
  font-size: 10px;
  text-overflow: ellipsis;
}

.table-file small {
  color: #8793a3;
  font-size: 8px;
}

.upload-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #277747;
  font-size: 9px;
  font-weight: 700;
}

.upload-status > span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #43a467;
}

.ocr-status {
  color: #91681f;
  font-size: 9px;
  font-weight: 700;
}

.results-table code {
  padding: 4px 6px;
  border-radius: 5px;
  background: #f2f5f8;
  color: #66768c;
  font-size: 9px;
}

.result-parcel-icon {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border-radius: 8px;
  background: #eef4fd;
  color: #4b76ad;
  font-size: 10px;
  font-weight: 800;
}

.table-parcel-link > span:last-child {
  display: grid;
  gap: 3px;
}

.table-parcel-link strong {
  color: #29374d;
  font-size: 10px;
}

.table-parcel-link small {
  color: #8793a3;
  font-size: 8px;
}

.result-title {
  color: #506078 !important;
  font-size: 9px !important;
}

.source-tag {
  padding: 5px 7px;
  border: 1px solid #e5eaf0;
  border-radius: 6px;
  background: #f8fafc;
  color: #6b7b91;
  font-size: 8px;
  font-weight: 700;
}

.flag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 9px;
  font-weight: 700;
}

.flag > span {
  display: grid;
  width: 17px;
  height: 17px;
  place-items: center;
  border-radius: 50%;
  font-size: 10px;
  font-weight: 800;
}

.flag-review {
  color: #b34239;
}

.flag-review > span {
  background: #ffebe8;
  color: #c64b41;
}

.flag-clear {
  color: #277747;
}

.flag-clear > span {
  background: #e8f5eb;
  color: #278249;
}

.row-open {
  display: grid;
  width: 26px;
  height: 26px;
  place-items: center;
  border: 1px solid #e6ebf0;
  border-radius: 7px;
  background: #fff;
  color: #607087;
  cursor: pointer;
  font-size: 17px;
}

.row-open:hover {
  border-color: #c7d8ed;
  color: var(--blue);
}

.results-empty-row td {
  height: 170px;
  color: #8995a5;
  text-align: center;
  white-space: normal;
}

.results-empty-row td > * {
  display: block;
  margin: 5px auto;
}

.results-empty-row strong {
  color: #44536a;
  font-size: 11px;
}

.results-empty-row span:last-child {
  font-size: 9px;
}

.empty-state-icon {
  display: grid !important;
  width: 32px;
  height: 32px;
  place-items: center;
  border-radius: 9px;
  background: #eef4fd;
  color: #4979b9;
  font-size: 17px;
}

.table-empty {
  padding: 25px !important;
  color: #8793a3 !important;
  text-align: center;
}

.parcel-dialog {
  width: min(1450px, calc(100vw - 80px));
  max-width: none;
  max-height: calc(100vh - 60px);
  overflow: visible;
  padding: 0;
  border: 0;
  border-radius: 15px;
  background: transparent;
  color: var(--ink);
}

.parcel-dialog::backdrop {
  background: rgb(17 29 47 / 52%);
  backdrop-filter: blur(2px);
}

.dialog-shell {
  display: flex;
  max-height: calc(100vh - 60px);
  flex-direction: column;
  overflow: hidden;
  border: 1px solid #e2e8ef;
  border-radius: 15px;
  background: #f3f6fa;
  box-shadow: 0 25px 80px rgb(12 25 43 / 28%);
}

.dialog-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 17px 22px 13px;
  background: #fff;
}

.dialog-header .eyebrow {
  margin-bottom: 4px;
}

.dialog-header h2 {
  margin: 0;
  font-size: 18px;
  letter-spacing: -.3px;
}

.dialog-subtitle {
  margin: 4px 0 0;
  color: #7d8a9b;
  font-size: 10px;
}

.dialog-close {
  width: 31px;
  height: 31px;
  font-size: 21px;
}

.dialog-review-notice {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 9px 22px;
  border-top: 1px solid #f1dfd8;
  border-bottom: 1px solid #f1dfd8;
  background: #fff8f6;
  color: #91483f;
  font-size: 9px;
  line-height: 1.5;
}

.dialog-review-notice[hidden] {
  display: none;
}

.review-notice-icon {
  display: grid;
  width: 17px;
  height: 17px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 50%;
  background: #ffe8e3;
  color: #bd493f;
  font-size: 10px;
  font-weight: 800;
}

.dialog-grid {
  grid-template-columns: minmax(0, 1.12fr) minmax(390px, .88fr);
  align-items: start;
  gap: 12px;
  overflow: auto;
  padding: 13px 18px;
}

.dialog-grid .middle-column,
.dialog-grid .right-column {
  min-width: 0;
}

.dialog-grid .card {
  padding: 15px;
}

.dialog-grid .validation-card {
  padding: 14px;
}

.dialog-grid .validation-item {
  padding: 7px 0;
}

.dialog-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 13px 20px;
  border-top: 1px solid #e7ebf0;
  background: #fff;
}

.dialog-footer > div {
  display: grid;
  gap: 4px;
}

.dialog-footer strong {
  color: #39475d;
  font-size: 10px;
}

.dialog-footer span {
  color: #8793a3;
  font-size: 9px;
}

.confirm-button {
  min-width: 178px;
  min-height: 39px;
  font-size: 10px;
}

.confirm-button[hidden] {
  display: none;
}

.needs-human-validation {
  border-color: #e89991 !important;
  background: #fff7f6 !important;
  box-shadow: 0 0 0 2px rgb(218 86 74 / 8%);
}

.survey-summary.needs-human-validation .field-label,
.coordinate-fields.needs-human-validation .coordinate-heading {
  color: #b4443b;
}

.survey-summary.needs-human-validation input,
.coordinate-fields.needs-human-validation input {
  border-color: #e8a39c;
  background: #fff;
}

.data-field.needs-human-validation input {
  border-color: #dd8179;
  background: #fff6f5;
}

.toast {
  position: fixed;
  z-index: 10;
  right: 20px;
  bottom: 20px;
  max-width: min(390px, calc(100vw - 40px));
  padding: 11px 14px;
  transform: translateY(12px);
  border: 1px solid #dce5ef;
  border-radius: 9px;
  background: #fff;
  box-shadow: 0 10px 30px rgb(20 35 58 / 15%);
  color: #34435a;
  font-size: 11px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .16s, transform .16s;
}

.toast.is-visible {
  transform: translateY(0);
  opacity: 1;
}

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

@media (min-width: 1450px) {
  .dashboard-grid {
    grid-template-columns: minmax(280px, .82fr) minmax(500px, 1.42fr) minmax(440px, 1.18fr);
  }

  .card {
    padding: 19px;
  }

  .map-card,
  .validation-card {
    padding: 17px;
  }
}

.progress-fill-pulse {
  animation: pulse-progress 1.5s ease-in-out infinite;
  background: linear-gradient(90deg, #1769e8, #54a0fa, #1769e8);
  background-size: 200% 100%;
}

@keyframes pulse-progress {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.ocr-done {
  color: #277747;
  font-size: 9px;
  font-weight: 700;
}

.ocr-processing {
  color: #1769e8;
  font-size: 9px;
  font-weight: 700;
}

.ocr-error {
  color: #c2413b;
  font-size: 9px;
  font-weight: 700;
}

/* Tabs */

.tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 18px;
  border-bottom: 1px solid #e2e8ef;
}

.tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: -1px;
  padding: 10px 18px;
  border: 0;
  border-bottom: 2px solid transparent;
  background: none;
  color: #67768c;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: color .15s, border-color .15s;
}

.tab:hover {
  color: var(--ink);
}

.tab.is-active {
  color: var(--blue);
  border-bottom-color: var(--blue);
}

.tab-badge {
  display: inline-grid;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  place-items: center;
  border-radius: 9px;
  background: #fde7c7;
  color: #a2600c;
  font-size: 9px;
  font-weight: 800;
}

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

/* Review tab */

.review-header-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 16px;
  padding: 16px 22px;
}

.review-counts {
  display: flex;
  gap: 24px;
}

.review-count {
  display: grid;
  gap: 2px;
}

.review-count-label {
  color: #617087;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .3px;
  text-transform: uppercase;
}

.review-count strong {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -.5px;
  line-height: 1.1;
}

.review-count-ok {
  color: #1f8a52;
}

.review-count-todo {
  color: #c2413b;
}

.review-count-validation {
  color: #9a6700;
}

.review-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.review-export-hint {
  max-width: 320px;
  color: #67768c;
  font-size: 10px;
  text-align: right;
}

.review-layout {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.review-list-card {
  position: sticky;
  top: 16px;
  display: flex;
  max-height: calc(100vh - 110px);
  flex-direction: column;
  padding: 0;
  overflow: hidden;
}

.review-list-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid #e8edf2;
}

.review-list-heading h3 {
  margin: 0;
  font-size: 12px;
  font-weight: 800;
}

.review-list {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
}

.review-list-empty {
  padding: 24px 16px;
  color: #8793a3;
  font-size: 11px;
  text-align: center;
}

.review-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 11px 14px;
  border: 0;
  border-bottom: 1px solid #edf0f4;
  border-left: 3px solid transparent;
  background: #fff;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: background-color .12s;
}

.review-item:hover {
  background: #f5f9ff;
}

.review-item.is-selected {
  background: #eaf2ff;
  border-left-color: var(--blue);
}

.review-item-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
  flex: 1;
}

.review-item-copy strong {
  font-size: 10px;
  font-weight: 700;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.review-item-copy small {
  color: #8793a3;
  font-size: 8px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.review-item-issues {
  color: #c2413b !important;
}

.review-item-geometry {
  color: #8a5b00 !important;
}

.review-item-detail {
  color: #68778c !important;
}

.review-detail-card {
  min-width: 0;
  padding: 0;
  background: #f3f6fa;
  overflow: hidden;
}

.review-detail-header {
  padding: 17px 22px 13px;
  background: #fff;
  border-bottom: 1px solid #e8edf2;
}

.review-detail-header .eyebrow {
  margin-bottom: 4px;
}

.review-detail-header h2 {
  margin: 0;
  font-size: 18px;
  letter-spacing: -.3px;
}

.review-detail {
  min-width: 0;
}

.review-detail-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 320px;
  padding: 30px;
  color: #8793a3;
  font-size: 11px;
  text-align: center;
}

.review-detail-empty strong {
  color: #47566d;
  font-size: 13px;
}

.ocr-page-result {
  margin-bottom: 16px;
  padding: 14px;
  border: 1px solid #e6ebf0;
  border-radius: 10px;
  background: #fff;
}

.ocr-page-result h3 {
  margin: 0 0 10px;
  color: #34445a;
  font-size: 12px;
  font-weight: 700;
}

.ocr-fields-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 10px;
}

.ocr-fields-table th {
  padding: 7px 9px;
  background: #f7f9fc;
  color: #607087;
  font-size: 9px;
  font-weight: 700;
  text-align: left;
  border-bottom: 1px solid #edf0f4;
}

.ocr-fields-table td {
  padding: 7px 9px;
  border-bottom: 1px solid #edf0f4;
  color: #46546a;
  font-size: 10px;
}

.ocr-field-key {
  color: #617087;
  font-weight: 600;
  white-space: nowrap;
  width: 140px;
}

.ocr-raw {
  margin-top: 8px;
}

.ocr-raw summary {
  color: #617087;
  font-size: 9px;
  font-weight: 600;
  cursor: pointer;
}

.ocr-raw pre {
  margin: 8px 0 0;
  padding: 10px;
  border: 1px solid #e6ebf0;
  border-radius: 7px;
  background: #f8fafc;
  color: #34445a;
  font-size: 9px;
  line-height: 1.55;
  white-space: pre-wrap;
  word-break: break-word;
  max-height: 300px;
  overflow: auto;
}

.ocr-no-fields {
  color: #8793a3;
  font-size: 10px;
  margin: 0;
}

.ocr-view-btn {
  font-size: 14px;
}

/* e-Title row + review dialog */

.etitle-row {
  cursor: pointer;
  transition: background-color .12s;
}

.etitle-row:hover,
.etitle-row:focus-within {
  background: #f5f9ff;
}

.etitle-icon {
  background: #e8f0fe;
  color: #3468b2;
  font-size: 9px;
  font-weight: 800;
}

.td-holder {
  max-width: 200px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.etitle-status {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 8px;
  border-radius: 6px;
  font-size: 9px;
  font-weight: 700;
}

.status-missing {
  background: #fff1ee;
  color: #c2413b;
}

.status-validation {
  background: #fff6df;
  color: #8a5b00;
}

.status-geometry {
  background: #fff6df;
  color: #8a5b00;
}

.status-reviewed {
  background: #e8f0fe;
  color: #1769e8;
}

/* OCR review dialog editable grid */

.ocr-review-banner,
.ocr-reviewed-banner {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 10px 20px;
  margin: 0;
  border-radius: 0;
  font-size: 10px;
  line-height: 1.5;
}

.ocr-review-banner {
  border: 1px solid #f1dfd8;
  background: #fff8f6;
  color: #91483f;
}

.ocr-geometry-banner {
  border-color: #efdfb2;
  background: #fff9e9;
  color: #795300;
}

.ocr-validation-banner {
  border-color: #cfe7d5;
  background: #f1faf3;
  color: #277747;
}

.ocr-review-banner > span:first-child {
  display: grid;
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 50%;
  background: #ffe8e3;
  color: #bd493f;
  font-size: 11px;
  font-weight: 800;
}

.ocr-geometry-banner > span:first-child {
  background: #f7e9be;
  color: #8a5b00;
}

.ocr-validation-banner > span:first-child {
  background: #dcefe1;
  color: #277747;
}

.ocr-reviewed-banner {
  border: 1px solid #cfe1f7;
  background: #f0f7ff;
  color: #2e5fa8;
}

.ocr-reviewed-banner > span:first-child {
  font-size: 14px;
}

/* Page-matched rows: image + fields side by side */

.ocr-page-rows {
  padding: 16px 20px;
}

.ocr-page-row {
  display: grid;
  grid-template-columns: minmax(340px, .45fr) minmax(380px, .55fr);
  gap: 18px;
  align-items: start;
  margin-bottom: 24px;
  padding-bottom: 24px;
  border-bottom: 2px solid #e2e8ef;
}

.ocr-page-row:last-of-type {
  border-bottom: 0;
  margin-bottom: 12px;
  padding-bottom: 0;
}

.ocr-page-image {
  border: 1px solid #dce5ef;
  border-radius: 10px;
  overflow: hidden;
  background: #f0f3f7;
}

.ocr-page-label {
  display: block;
  padding: 6px 12px;
  font-size: 10px;
  font-weight: 700;
  color: #506078;
  text-transform: uppercase;
  letter-spacing: .3px;
  background: rgba(240, 243, 247, .9);
}

.ocr-page-image img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
}

.ocr-doc-unavailable {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 300px;
  gap: 6px;
  color: #8793a3;
  font-size: 11px;
}

.ocr-page-fields {
  min-width: 0;
}

/* Technical description table */

.ocr-td-section {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid #e2e8ef;
}

.ocr-td-section h3 {
  margin: 0 0 8px;
  color: #506078;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .3px;
  text-transform: uppercase;
}

.ocr-td-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 10px;
}

.ocr-td-table th {
  padding: 4px 6px;
  text-align: left;
  color: #617087;
  font-size: 9px;
  font-weight: 600;
  border-bottom: 1px solid #dfe6ee;
}

.ocr-td-table td {
  padding: 3px 4px;
  vertical-align: middle;
}

.ocr-td-table td:nth-child(1) { width: 18%; }
.ocr-td-table td:nth-child(2) { width: 48%; }
.ocr-td-table td:nth-child(3) { width: 26%; }
.ocr-td-table td:nth-child(4) { width: 8%; text-align: right; }

.ocr-td-table input {
  width: 100%;
  height: 28px;
  padding: 0 7px;
  border: 1px solid #dfe6ee;
  border-radius: 6px;
  background: #fff;
  color: #26354d;
  font-size: 10px;
  font-weight: 500;
}

.ocr-td-table input:focus {
  outline: none;
  border-color: #93b5e6;
  box-shadow: 0 0 0 2px rgb(23 105 232 / 12%);
}

.ocr-td-table input.td-input-invalid,
.ocr-td-table input.td-input-invalid:focus {
  border-color: #e08a83;
  background: #fff7f6;
  box-shadow: 0 0 0 2px rgb(218 86 74 / 10%);
}

.ocr-td-table input.td-input-review {
  border-color: #e8c1bd;
  background: #fffafa;
}

.ocr-td-table input.td-input-review:focus {
  border-color: #d45e55;
  box-shadow: 0 0 0 2px rgb(218 86 74 / 14%);
}

.td-empty {
  color: #8793a3;
  font-style: italic;
  text-align: center;
  padding: 10px !important;
}

.td-row-bad .td-empty {
  color: #b4443b;
  background: #fff7f6;
}

.td-remove {
  width: 24px;
  height: 24px;
  border: 1px solid #dfe6ee;
  border-radius: 6px;
  background: #fff;
  color: #8793a3;
  font-size: 13px;
  line-height: 1;
  cursor: pointer;
}

.td-remove:hover {
  border-color: #e3a3a0;
  color: #c2413b;
}

.td-add {
  margin-top: 8px;
  min-height: 28px;
  padding: 0 10px;
  font-size: 9px;
}

/* GIS map */

.ocr-map-pane {
  border: 1px solid #dce5ef;
  border-radius: 10px;
  overflow: hidden;
  background: #f6f8fb;
}

.map-layer-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-top: 1px solid #dce5ef;
  color: #506078;
  font-size: 10px;
  font-weight: 600;
  cursor: pointer;
}

.parcel-map-wrap {
  border-top: 1px solid #dce5ef;
}

.parcel-map {
  height: 340px;
  background: #e9eef3;
}

.parcel-map-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 120px;
  padding: 16px 20px;
  color: #8793a3;
  font-size: 10px;
  text-align: center;
}

.parcel-map-note {
  margin: 0;
  padding: 6px 12px;
  color: #8793a3;
  font-size: 9px;
}

.corner-tip {
  padding: 1px 4px;
  font-size: 10px;
  font-weight: 700;
}

.parcel-stats {
  display: grid;
  gap: 8px;
}

.ocr-stat {
  display: grid;
  gap: 2px;
}

.ocr-stat-label {
  color: #617087;
  font-size: 9px;
  font-weight: 600;
}

.ocr-stat-value {
  color: #26354d;
  font-size: 11px;
  font-weight: 600;
}

.ocr-stat-value small {
  color: #6b7a93;
  font-weight: 500;
}

.ocr-stat-value.ok {
  color: #1f8a52;
}

.ocr-stat-value.bad {
  color: #c2413b;
}

.ocr-corner-table {
  width: 100%;
  margin-top: 4px;
  border-collapse: collapse;
  font-size: 10px;
  font-variant-numeric: tabular-nums;
}

.ocr-corner-table th,
.ocr-corner-table td {
  padding: 4px 6px;
  text-align: right;
  border-bottom: 1px solid #edf0f4;
}

.ocr-corner-table th:first-child,
.ocr-corner-table td:first-child {
  text-align: left;
}

.ocr-corner-table th {
  color: #617087;
  font-size: 9px;
  font-weight: 600;
}

.ocr-stat-note {
  margin: 4px 0 0;
  color: #8793a3;
  font-size: 9px;
}

.ocr-additional-page-note {
  margin: 0;
  color: #78879b;
  font-size: 11px;
  line-height: 1.5;
}

.ocr-field-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.ocr-field-grid-2col {
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.ocr-page-fields-section {
  margin-bottom: 18px;
}

.ocr-page-fields-section:last-of-type {
  margin-bottom: 8px;
}

.ocr-page-fields-header {
  padding: 8px 0;
  margin-bottom: 8px;
  border-bottom: 2px solid #d0d9e4;
  color: #34445a;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: -.1px;
}

.ocr-field-column h3 {
  margin: 0 0 10px;
  color: #506078;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .3px;
  text-transform: uppercase;
}

.ocr-field {
  position: relative;
  margin-bottom: 8px;
}

.ocr-field:focus-within {
  z-index: 20;
}

.ocr-field input,
.ocr-td-table input {
  text-transform: uppercase;
}

.location-autocomplete {
  position: relative;
}

.location-suggestions {
  position: absolute;
  z-index: 50;
  top: calc(100% + 3px);
  right: 0;
  left: 0;
  max-height: 220px;
  overflow-y: auto;
  overscroll-behavior: contain;
  border: 1px solid #cbd6e3;
  border-radius: 7px;
  background: #fff;
  box-shadow: 0 8px 20px rgb(34 49 73 / 16%);
}

.location-suggestions[hidden] {
  display: none;
}

.location-suggestion {
  display: block;
  width: 100%;
  padding: 8px 10px;
  border: 0;
  background: #fff;
  color: #26354d;
  font: inherit;
  font-size: 10px;
  text-align: left;
  text-transform: uppercase;
  cursor: pointer;
}

.location-suggestion + .location-suggestion {
  border-top: 1px solid #edf0f4;
}

.location-suggestion:hover,
.location-suggestion:focus {
  outline: none;
  background: #edf5ff;
}

.location-suggestion-empty {
  padding: 9px 10px;
  color: #78879b;
  font-size: 10px;
}

.ocr-field-review-needed input {
  border-color: #e8c1bd;
  background: #fffafa;
}

.ocr-field-review-needed label {
  color: #9b625c;
}

.ocr-field label {
  display: block;
  margin-bottom: 4px;
  color: #617087;
  font-size: 9px;
  font-weight: 600;
}

.ocr-required {
  color: #c2413b;
}

.ocr-field input {
  width: 100%;
  height: 32px;
  box-sizing: border-box;
  padding: 0 8px;
  border: 1px solid #dfe6ee;
  border-radius: 7px;
  background: #fff;
  color: #26354d;
  font-size: 10px;
  font-weight: 500;
  transition: border-color .15s, box-shadow .15s;
}

.ocr-field input:focus {
  border-color: #93b5e6;
  box-shadow: 0 0 0 2px rgb(23 105 232 / 12%);
  outline: none;
}

.ocr-field input::placeholder {
  color: #b3bcc7;
  font-weight: 400;
  font-style: italic;
}

.ocr-field-missing input {
  border-color: #e08a83 !important;
  background: #fff7f6 !important;
  box-shadow: 0 0 0 2px rgb(218 86 74 / 10%);
}

.ocr-field-missing input:focus,
.ocr-field-location-invalid input:focus {
  border-color: #d45e55 !important;
  box-shadow: 0 0 0 2px rgb(218 86 74 / 18%);
}

.ocr-field-missing label {
  color: #b4443b;
}

.ocr-extraction-error {
  display: block;
  margin-top: 4px;
  color: #b4443b;
  font-size: 9px;
}

.ocr-field-location-invalid input {
  border-color: #e08a83 !important;
  background: #fff7f6 !important;
  box-shadow: 0 0 0 2px rgb(218 86 74 / 10%);
}

.ocr-field-location-invalid label,
.ocr-location-error {
  color: #b4443b;
}

.ocr-location-error {
  display: block;
  margin-top: 4px;
  font-size: 9px;
}

.location-validation-status {
  margin: 0 20px;
  padding: 8px 10px;
  border-radius: 7px;
  background: #f0f5fb;
  color: #506078;
  font-size: 10px;
}

.location-validation-status:empty {
  display: none;
}

.location-validation-status.is-error {
  background: #fff1f0;
  color: #a12e29;
}

.location-validation-retry {
  margin-left: 6px;
  padding: 0;
  border: 0;
  background: none;
  color: #1769e8;
  font: inherit;
  text-decoration: underline;
  cursor: pointer;
}

.ocr-dialog-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 8px;
  padding-top: 14px;
  border-top: 1px solid #e8edf2;
}

.ocr-dialog-actions .button {
  min-height: 38px;
  font-size: 10px;
}

/* Extracted files list */

.extracted-pages-view {
  display: grid;
  gap: 4px;
  border: 1px solid #e6ebf0;
  border-radius: 9px;
  overflow: hidden;
}

.extracted-pages-view[hidden] {
  display: none;
}

.extracted-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: #fff;
  border-bottom: 1px solid #edf0f4;
  cursor: pointer;
  transition: background-color .12s;
  min-width: 0;
}

.extracted-item:last-child {
  border-bottom: 0;
}

.extracted-item:hover {
  background: #f5f9ff;
}

.extracted-item-info {
  display: grid;
  gap: 2px;
  min-width: 0;
  flex: 1;
}

.extracted-item-info strong {
  color: #29374d;
  font-size: 10px;
  font-weight: 700;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.extracted-item-info small {
  color: #8793a3;
  font-size: 8px;
}

.extracted-item-holder {
  flex: 0 1 140px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #47566d;
  font-size: 10px;
}

.extracted-item-area {
  flex: 0 0 auto;
  color: #47566d;
  font-size: 10px;
  text-align: right;
  white-space: nowrap;
}

.extracted-processing-list {
  display: grid;
  gap: 6px;
  padding: 14px 16px;
  border: 1px solid #e0eaf8;
  border-radius: 12px;
  background: #f8fbff;
}

.extracted-processing-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border: 1px solid #e6edf6;
  border-radius: 8px;
  background: #fff;
}

.extracted-processing-name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #34445a;
  font-size: 10px;
  font-weight: 600;
}

.ocr-error-detail {
  max-width: 40%;
  overflow: hidden;
  color: #8e3b36;
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.extracted-empty {
  padding: 30px 20px;
  color: #8793a3;
  font-size: 10px;
  text-align: center;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
  }
}
