:root {
  font-family: Arial, Helvetica, sans-serif;
  color: #202a26;
  background: #f4f6f5;
  font-size: 15px;
  line-height: 1.5;
  --green: #246148;
  --line: #d7dfda;
  --muted: #627069;
  --amber: #996415;
  --red: #a13434;
  --control-size: 44px;
  letter-spacing: 0;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input,
select {
  font: inherit;
}
button,
a,
input,
select {
  touch-action: manipulation;
}
button,
a {
  color: inherit;
}
a {
  text-decoration: none;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: wait;
  opacity: 0.55;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid #cc9f30;
  outline-offset: 3px;
}
button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border: 1px solid var(--line);
  background: white;
  border-radius: 5px;
  padding: 10px 15px;
  font-weight: 600;
  min-height: 42px;
}
button:hover {
  background: #edf2ef;
}
button.primary,
.primary {
  background: var(--green);
  color: #fff;
  border-color: var(--green);
}
button.primary:hover,
.primary:hover {
  background: #194a36;
}
.lucide {
  width: 19px;
  height: 19px;
  flex-shrink: 0;
  stroke-width: 1.8;
}
.icon-button {
  width: 42px;
  height: 42px;
  padding: 0;
  flex: 0 0 42px;
}
.subtle {
  color: var(--muted);
}
.small {
  font-size: 12px;
}
.topbar {
  min-height: 83px;
  padding: 16px 32px;
  background: #fff;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 21px;
  font-weight: 700;
  line-height: 1.2;
}
.brand small {
  display: block;
  font-size: 11px;
  font-weight: 400;
  color: var(--muted);
  margin-top: 5px;
}
.brand-symbol {
  width: 43px;
  height: 43px;
  background: #e8f0eb;
  display: grid;
  place-items: center;
  color: var(--green);
  border-radius: 5px;
}
.brand-symbol .lucide {
  width: 26px;
  height: 26px;
}
nav {
  display: flex;
  align-items: center;
  gap: 8px;
}
nav > a {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 13px;
  font-size: 13px;
  border-bottom: 2px solid transparent;
}
nav > a[aria-current] {
  color: var(--green);
  border-color: var(--green);
}
nav form {
  margin-left: 8px;
}
h1,
h2,
h3,
p {
  margin-top: 0;
}
h1 {
  font-size: 26px;
  line-height: 1.2;
  margin-bottom: 0;
}
h2 {
  font-size: 17px;
  line-height: 1.35;
  margin-bottom: 18px;
}
h3 {
  font-size: 18px;
  line-height: 1.3;
  margin-bottom: 18px;
}
.workspace {
  max-width: 1500px;
  margin: auto;
  padding: 28px 32px 24px;
}
.page-heading,
.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
}
.page-heading > .subtle {
  font-size: 12px;
}
.eyebrow {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 6px;
}
.mode-switch {
  display: flex;
  gap: 0;
  border-bottom: 1px solid var(--line);
  margin-bottom: 24px;
}
.mode-switch button {
  border: 0;
  border-bottom: 3px solid transparent;
  border-radius: 0;
  padding: 13px 20px;
  background: transparent;
  font-size: 14px;
}
.mode-switch button[aria-pressed="true"] {
  border-color: var(--green);
  color: var(--green);
  background: #e8f0eb;
}
.work-grid {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 28px;
}
.input-column {
  min-width: 0;
}
.address-form {
  padding-bottom: 18px;
  margin-bottom: 22px;
  border-bottom: 1px solid var(--line);
}
label,
legend {
  display: block;
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 7px;
}
input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),
select {
  width: 100%;
  min-width: 0;
  min-height: 43px;
  background: #fff;
  color: #202a26;
  border: 1px solid #bcc9c0;
  border-radius: 5px;
  padding: 10px 11px;
  font-size: 14px;
}
select {
  padding-right: 28px;
  text-overflow: ellipsis;
}
.search-field {
  display: flex;
  align-items: center;
  position: relative;
}
.search-field input {
  padding-right: 47px !important;
}
.search-field button {
  position: absolute;
  right: 2px;
  border: 0;
  background: transparent;
  width: 39px;
  height: 39px;
  min-height: 39px;
}
.field-status {
  margin: 6px 0 0;
  font-size: 12px;
  color: var(--muted);
}
.field-status:empty {
  display: none;
}
.search-results {
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
  border: 1px solid var(--line);
  max-height: 230px;
  overflow: auto;
  background: #fff;
  border-radius: 5px;
}
.search-results li + li {
  border-top: 1px solid var(--line);
}
.search-results button {
  font-size: 13px;
  font-weight: 400;
  line-height: 1.5;
  text-align: left;
  width: 100%;
  border: 0;
  justify-content: flex-start;
  border-radius: 0;
}
.target-label {
  font-size: 12px;
  color: var(--green);
  border-left: 3px solid var(--green);
  padding-left: 9px;
  margin-top: 12px;
  overflow-wrap: anywhere;
}
.size-field {
  border: 0;
  padding: 0;
  margin: 18px 0;
}
.segmented {
  display: grid;
  grid-template-columns: 1fr 1fr;
}
.segmented label {
  margin: 0;
  position: relative;
}
.segmented input {
  position: absolute;
  opacity: 0;
  inset: 0;
}
.segmented span {
  display: block;
  text-align: center;
  border: 1px solid #bcc9c0;
  padding: 9px;
  background: #fff;
  cursor: pointer;
  font-size: 14px;
}
.segmented label:first-child span {
  border-radius: 5px 0 0 5px;
}
.segmented label:last-child span {
  border-radius: 0 5px 5px 0;
  border-left: 0;
}
.segmented input:checked + span {
  background: #e4eee7;
  color: #184e35;
  box-shadow: inset 0 0 0 1px var(--green);
}
.segmented input:focus-visible + span {
  outline: 3px solid #cc9f30;
  outline-offset: 2px;
}
.unit-input {
  position: relative;
}
.unit-input input {
  padding-right: 38px !important;
}
.unit-input > span {
  position: absolute;
  right: 14px;
  top: 9px;
  color: var(--muted);
}
#quantity-field > p {
  margin: 6px 0 0;
}
.quantity-stepper {
  display: grid;
  grid-template-columns: var(--control-size) minmax(0, 1fr) var(--control-size);
}
.quantity-stepper button,
.quantity-stepper #quantity {
  border: 1px solid #bcc9c0;
  border-radius: 0;
  min-height: var(--control-size);
}
.quantity-stepper button {
  background: #e4eee7;
  color: #184e35;
  font-size: 20px;
  padding: 0;
}
.quantity-stepper button:first-child {
  border-radius: 5px 0 0 5px;
}
.quantity-stepper button:last-child {
  border-radius: 0 5px 5px 0;
}
.quantity-stepper input {
  border-left: 0;
  border-right: 0;
  text-align: center;
  font-weight: 600;
}
.quantity-stepper .unit-input > span {
  font-weight: 600;
  color: #184e35;
}
.quantity-stepper button:disabled {
  cursor: not-allowed;
}
.actions {
  display: flex;
  gap: 8px;
  margin-top: 22px;
}
.actions > .primary {
  flex: 1;
}
.map-column {
  min-width: 0;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 5px;
  overflow: hidden;
  align-self: start;
}
.map-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  gap: 10px;
  flex-wrap: wrap;
}
.map-toolbar h2 {
  margin: 0;
  font-size: 14px;
}
.map-tools {
  display: flex;
  align-items: center;
  gap: 7px;
}
.map-tools .icon-button {
  width: var(--control-size);
  height: var(--control-size);
  min-height: var(--control-size);
  flex-basis: var(--control-size);
}
.map-tools .lucide {
  width: 22px;
  height: 22px;
}
.icon-button[aria-pressed="true"] {
  background: #faeccb;
  border-color: #ba862b;
  color: #714d0c;
}
.check-label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  min-height: var(--control-size);
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: white;
  cursor: pointer;
}
.check-label input {
  accent-color: var(--green);
  width: 18px;
  height: 18px;
  margin: 0;
}
#map {
  height: 385px;
  width: 100%;
  background: #e3e9e4;
  z-index: 0;
}
#map.placing {
  cursor: crosshair;
}
.map-legend {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 10px 15px;
  font-size: 11px;
  color: var(--muted);
  flex-wrap: wrap;
}
.map-legend span {
  display: flex;
  align-items: center;
  gap: 6px;
}
.map-legend span:last-child {
  margin-left: auto;
}
.dot {
  height: 8px;
  width: 8px;
  border-radius: 50%;
  display: inline-block;
}
.location-dot {
  background: var(--green);
}
.target-dot {
  background: #d79220;
}
.map-status {
  margin: 0;
  padding: 8px 14px;
  background: #fff5dd;
  color: #734c09;
  font-size: 12px;
}
.location-pin {
  width: 30px !important;
  height: 30px !important;
  border-radius: 50%;
  background: var(--green);
  color: white;
  border: 3px solid white;
  box-shadow: 0 1px 5px #202a2650;
  display: grid;
  place-items: center;
  font-size: 10px;
  font-weight: 700;
}
.target-pin {
  background: #d79220;
  color: #302711;
}
.results-section {
  margin-top: 30px;
  border-top: 1px solid var(--line);
  padding-top: 24px;
}
.results-section .location-card {
  min-height: 285px;
}
.results-section[data-calculation-mode="bulk"] .location-card {
  min-height: 385px;
}
#results-context {
  overflow-wrap: anywhere;
  display: block;
}
.results-section .section-heading {
  display: block;
}
.results-section .section-heading h2 {
  margin-bottom: 8px;
}
.section-heading {
  margin-bottom: 17px;
}
.section-heading h2 {
  margin: 0;
}
.section-heading > span {
  font-size: 12px;
}
.location-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}
.location-card {
  border: 1px solid var(--line);
  background: white;
  border-radius: 5px;
  padding: 17px;
  min-width: 0;
}
.location-card.recommended {
  border-top: 3px solid var(--green);
  padding-top: 15px;
}
.location-card h3 {
  font-size: 16px;
  margin: 12px 0 16px;
}
.site-tag {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 11px;
  min-height: 20px;
}
.site-tag.good {
  color: var(--green);
}
.site-tag.warning {
  color: var(--amber);
}
.site-tag .lucide {
  width: 14px;
  height: 14px;
}
.metric {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 0;
  border-top: 1px solid #e9edeb;
  font-size: 12px;
}
.metric > span {
  color: var(--muted);
}
.metric strong {
  font-size: 13px;
  text-align: right;
}
.metric.total strong {
  font-size: 19px;
  color: var(--green);
}
.metric.total {
  padding-top: 12px;
}
.metric.gross {
  border-top: 0;
  padding-top: 0;
}
.empty-metric {
  color: #8a948e;
  font-size: 12px;
  margin: 0;
}
.status-text {
  font-size: 12px;
  line-height: 1.5;
  color: var(--amber);
  margin: 12px 0 0;
}
.summary-line {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
  font-size: 14px;
}
.summary-line strong {
  color: var(--green);
}
.notice {
  padding: 12px 14px;
  border-left: 3px solid #c9952e;
  background: #fff5dd;
  font-size: 13px;
  line-height: 1.5;
  margin-top: 14px;
  color: #6b4b12;
}
.notice.error {
  border-color: var(--red);
  background: #fbeeed;
  color: #862e2e;
}
.notice.success {
  border-color: var(--green);
  background: #e8f1eb;
  color: var(--green);
}
.footer {
  max-width: 1500px;
  padding: 20px 32px;
  margin: auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 14px;
  font-size: 11px;
  color: var(--muted);
}
.footer a:hover {
  text-decoration: underline;
}
.skip-link {
  position: absolute;
  top: -80px;
  left: 20px;
  background: #fff;
  padding: 10px;
  z-index: 2000;
}
.skip-link:focus {
  top: 10px;
}
[hidden] {
  display: none !important;
}
.narrow {
  max-width: 840px;
}
.content-section {
  border-top: 1px solid var(--line);
  padding: 24px 0;
}
.content-section:first-of-type {
  margin-top: 28px;
}
.content-section p {
  font-size: 14px;
}
.download {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 15px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #fff;
  font-size: 14px;
  font-weight: 600;
}
.file-upload {
  display: block;
  width: 100%;
  padding: 18px;
  border: 1px dashed #aabcb0;
  border-radius: 5px;
  background: #fff;
  margin: 12px 0 16px;
}
.file-upload input {
  border: none !important;
  padding: 0 !important;
}
.validation-list {
  font-size: 13px;
  padding-left: 20px;
}
.login-wrap {
  max-width: 420px;
  padding: 0 20px;
  margin: 70px auto 100px;
}
.login-wrap h1 {
  margin-bottom: 26px;
}
.login-wrap input {
  margin-bottom: 18px;
}
.login-wrap button.primary {
  width: 100%;
  margin-top: 8px;
}
.login-wrap .notice {
  margin-bottom: 20px;
}
.meta-list {
  display: flex;
  gap: 30px;
  flex-wrap: wrap;
  font-size: 13px;
}
.meta-list dt {
  color: var(--muted);
}
.meta-list dd {
  margin: 2px 0 0;
  font-weight: 600;
}
.leaflet-container {
  font-family: Arial, Helvetica, sans-serif;
}
.leaflet-container .leaflet-control-zoom a {
  width: var(--control-size);
  height: var(--control-size);
  line-height: var(--control-size);
  font-size: 26px;
}
.leaflet-control-attribution {
  font-size: 10px !important;
}
@media (min-width: 1450px) {
  #map {
    height: 410px;
  }
}
@media (max-width: 1050px) {
  .workspace {
    padding: 24px;
  }
  .work-grid {
    grid-template-columns: 290px minmax(0, 1fr);
    gap: 20px;
  }
  .location-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .map-legend {
    gap: 10px;
  }
  .map-legend span:last-child {
    margin-left: 0;
  }
  .topbar {
    padding: 16px 24px;
  }
}
@media (max-width: 700px) {
  .topbar {
    padding: 14px 16px;
    align-items: flex-start;
    gap: 8px;
  }
  .brand {
    font-size: 18px;
    gap: 8px;
  }
  .brand-symbol {
    width: 35px;
    height: 35px;
  }
  .brand small {
    font-size: 10px;
  }
  nav {
    gap: 2px;
  }
  nav > a {
    padding: 8px;
  }
  nav > a > span {
    display: none;
  }
  nav > a::after {
    content: attr(aria-label);
  }
  nav form {
    margin-left: 2px;
  }
  nav .icon-button {
    width: 34px;
    height: 36px;
    min-height: 36px;
    flex-basis: 34px;
  }
  .workspace {
    padding: 22px 16px;
  }
  .page-heading {
    margin-bottom: 20px;
  }
  .page-heading > .subtle {
    display: none;
  }
  h1 {
    font-size: 23px;
  }
  .mode-switch button {
    padding: 12px 10px;
    font-size: 12px;
    gap: 6px;
    flex: 1;
    min-width: 0;
  }
  .mode-switch .lucide {
    width: 17px;
  }
  .work-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .input-column {
    display: grid;
    grid-template-columns: 1fr;
  }
  .address-form {
    margin-bottom: 18px;
  }
  .map-toolbar {
    padding: 10px;
  }
  #map {
    height: 330px;
  }
  .map-toolbar h2 {
    font-size: 13px;
  }
  .map-tools {
    gap: 5px;
  }
  .check-label {
    font-size: 14px;
  }
  .location-grid {
    gap: 10px;
  }
  .location-card {
    padding: 13px;
  }
  .location-card.recommended {
    padding-top: 11px;
  }
  .location-card h3 {
    font-size: 15px;
  }
  .metric {
    display: block;
  }
  .metric strong {
    display: block;
    text-align: left;
    margin-top: 2px;
  }
  .metric.total strong {
    font-size: 20px;
  }
  .section-heading {
    align-items: flex-start;
  }
  .section-heading > span {
    text-align: right;
    max-width: 50%;
    font-size: 11px;
  }
  .footer {
    padding: 20px 16px;
  }
  .login-wrap {
    margin-top: 45px;
  }
}
@media (max-width: 360px) {
  .location-grid {
    grid-template-columns: 1fr;
  }
  .mode-switch button {
    font-size: 11px;
  }
  .metric {
    display: flex;
  }
  .metric strong {
    text-align: right;
  }
  .brand small {
    max-width: 120px;
  }
  .map-toolbar {
    flex-wrap: wrap;
  }
}
nav > a::after {
  content: none;
}
