:root {
  --primary: #0f766e;
  --accent: #f59e0b;
  --surface: #f0fdfa;
  --ink: #17312f;
  --muted: #627875;
  --line: #d9e7e4;
  --white: #fff;
}
* {
  box-sizing: border-box;
}
[hidden] {
  display: none !important;
}
body {
  margin: 0;
  background: #f8fbfa;
  color: var(--ink);
  font:
    15px/1.5 ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    sans-serif;
}
.skip-link {
  background: var(--white);
  border: 2px solid var(--primary);
  border-radius: 6px;
  left: 16px;
  padding: 10px 14px;
  position: fixed;
  top: -80px;
  z-index: 10;
}
.skip-link:focus {
  top: 8px;
}
:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 3px;
}
.topbar {
  align-items: center;
  background: var(--white);
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  padding: 22px max(24px, calc((100% - 1180px) / 2));
  position: sticky;
  top: 0;
  z-index: 2;
}
.topbar h1 {
  font-size: 22px;
  margin: 3px 0;
}
.eyebrow {
  color: var(--primary);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
}
.topbar label {
  color: var(--muted);
  font-size: 13px;
}
.topbar select {
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  font-size: 14px;
  margin-left: 8px;
  padding: 9px 12px;
}
.hero,
main {
  margin: auto;
  max-width: 1180px;
}
.hero {
  align-items: end;
  display: flex;
  gap: 35px;
  justify-content: space-between;
  padding: 48px 24px 30px;
}
.hero h2 {
  font-size: 38px;
  line-height: 1.08;
  margin: 7px 0 13px;
  max-width: 700px;
}
.hero p {
  color: var(--muted);
  margin: 0;
  max-width: 720px;
}
.stat {
  background: var(--surface);
  border: 1px solid #bce3db;
  border-radius: 18px;
  min-width: 160px;
  padding: 20px;
}
.stat strong {
  display: block;
  color: var(--primary);
  font-size: 34px;
}
.stat span {
  color: var(--muted);
  font-size: 12px;
}
.layout {
  display: grid;
  gap: 18px;
  grid-template-columns: 2fr 1fr;
  padding: 0 24px 18px;
}
.panel {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: 0 5px 20px #0b3b3210;
  overflow: hidden;
}
.panel-head {
  align-items: center;
  display: flex;
  justify-content: space-between;
  padding: 17px 20px;
}
.panel h3 {
  font-size: 16px;
  margin: 0;
}
.legend {
  color: var(--muted);
  font-size: 12px;
}
.dot {
  border-radius: 50%;
  display: inline-block;
  height: 9px;
  margin: 0 3px 0 8px;
  width: 9px;
}
.dot:first-child {
  margin-left: 0;
}
.verified {
  background: var(--primary);
}
.candidate {
  background: var(--accent);
}
.map {
  background: #e7f3ef;
  height: 355px;
  overflow: hidden;
  position: relative;
}
.map-grid {
  background-image:
    linear-gradient(#ffffff80 1px, transparent 1px),
    linear-gradient(90deg, #ffffff80 1px, transparent 1px);
  background-size: 42px 42px;
  height: 100%;
  transform: rotate(-6deg) scale(1.2);
}
.map:before,
.map:after {
  background: #c0dfd5;
  content: '';
  height: 45px;
  left: -10%;
  position: absolute;
  top: 40%;
  transform: rotate(13deg);
  width: 120%;
}
.map:after {
  background: #d2e9de;
  top: 67%;
  transform: rotate(-17deg);
}
#markers {
  inset: 0;
  position: absolute;
}
.marker {
  border: 3px solid white;
  border-radius: 50%;
  box-shadow: 0 2px 7px #153b3490;
  cursor: pointer;
  height: 20px;
  position: absolute;
  transform: translate(-50%, -50%);
  width: 20px;
  z-index: 1;
}
.marker.approved {
  background: var(--primary);
}
.marker.candidate {
  background: var(--accent);
}
.map-note {
  background: #ffffffd9;
  bottom: 10px;
  color: var(--muted);
  font-size: 11px;
  left: 10px;
  padding: 4px 7px;
  position: absolute;
  z-index: 2;
}
.panel aside {
  padding: 0 20px 20px;
}
dl {
  margin: 0;
  padding: 0 20px 18px;
}
dt {
  color: var(--muted);
  font-size: 12px;
  margin-top: 13px;
}
dd {
  font-weight: 700;
  margin: 1px 0;
}
.panel > button,
button {
  background: var(--primary);
  border: 0;
  border-radius: 8px;
  color: white;
  cursor: pointer;
  font-weight: 700;
  padding: 10px 13px;
  margin: 0 20px 20px;
}
.panel:nth-child(2) {
  padding-bottom: 0;
}
.table-wrap {
  overflow: auto;
}
.table-wrap:focus-visible {
  outline: 3px solid #176f72;
  outline-offset: 2px;
}
table {
  border-collapse: collapse;
  width: 100%;
}
th,
td {
  border-top: 1px solid var(--line);
  padding: 13px 20px;
  text-align: left;
  white-space: nowrap;
}
th {
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.badge {
  border-radius: 20px;
  font-size: 11px;
  font-weight: 800;
  padding: 4px 8px;
}
.badge.approved {
  background: #d9f4ed;
  color: #0d6d61;
}
.badge.candidate {
  background: #fff2d5;
  color: #966000;
}
.small {
  color: var(--muted);
  font-size: 12px;
}
a {
  color: var(--primary);
}
@media (max-width: 760px) {
  .hero {
    display: block;
  }
  .hero h2 {
    font-size: 30px;
  }
  .stat {
    margin-top: 20px;
  }
  .layout {
    grid-template-columns: 1fr;
  }
  .topbar {
    align-items: flex-start;
    gap: 10px;
    flex-direction: column;
  }
}
.map {
  position: relative;
  touch-action: none;
}
.map.picking-location,
.map.picking-location #public-map-overlay {
  cursor: crosshair;
}
.public-tile-surface {
  height: 355px;
  inset: 0;
  overflow: hidden;
  position: absolute;
  transform-origin: center;
}
.public-osm-tile {
  height: 256px;
  position: absolute;
  width: 256px;
}
.public-map-overlay {
  height: 355px;
  inset: 0;
  overflow: visible;
  pointer-events: all;
  position: absolute;
  width: 100%;
}
.public-entity-polygon {
  fill: #10b98155;
  stroke: #047857;
  stroke-width: 2;
}
.public-entity-polygon.candidate {
  fill: #fbbf2455;
  stroke: #b7791f;
}
.public-entity-line {
  fill: none;
  stroke: #047857;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 4;
}
.public-entity-line.candidate {
  stroke: #b7791f;
}
.public-entity-point {
  fill: #10b981;
  stroke: #fff;
  stroke-width: 3;
}
.public-entity-point.candidate {
  fill: #fbbf24;
}
.public-map-label {
  fill: #17312f;
  font-size: 11px;
  font-weight: 700;
  paint-order: stroke;
  stroke: #ffffffcc;
  stroke-width: 3px;
}
.public-map-controls {
  display: grid;
  gap: 5px;
  left: 12px;
  position: absolute;
  top: 12px;
  z-index: 4;
}
.public-map-controls button {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 6px;
  box-shadow: 0 2px 7px #17312f35;
  color: var(--ink);
  cursor: pointer;
  font-size: 18px;
  height: 32px;
  margin: 0;
  padding: 0;
  width: 32px;
}
.public-attribution {
  background: #ffffffdd;
  border-radius: 4px;
  bottom: 7px;
  color: #234f4b;
  font-size: 10px;
  padding: 3px 6px;
  position: absolute;
  right: 7px;
  z-index: 4;
}
.awards-panel {
  margin: 0 24px 30px;
  padding-bottom: 20px;
}
.public-content-panel {
  margin: 0 24px 18px;
  padding-bottom: 16px;
}
.public-content-panel .panel-head {
  gap: 16px;
}
.public-content-panel .panel-head label {
  color: var(--muted);
  font-size: 12px;
}
.public-content-panel select {
  border: 1px solid var(--line);
  border-radius: 6px;
  display: block;
  margin-top: 4px;
  padding: 7px 9px;
}
.public-content-item {
  border-top: 1px solid var(--line);
  padding: 14px 20px;
}
.public-content-item h4 {
  margin: 0 0 8px;
}
.public-content-value {
  line-height: 1.55;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}
.public-content-value pre {
  font-family: inherit;
  margin: 0;
  white-space: pre-wrap;
}
.public-content-panel > #content-status {
  padding: 0 20px;
}
.awards-panel .panel-head {
  align-items: flex-start;
}
.awards-panel .panel-head p {
  margin: 4px 0 0;
}
.public-award {
  border-top: 1px solid var(--line);
  display: flex;
  gap: 18px;
  justify-content: space-between;
  padding: 17px 20px;
}
.public-award h4 {
  margin: 0 0 4px;
}
.award-levels {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  justify-content: flex-end;
}
.award-level {
  background: var(--surface);
  border: 1px solid #bce3db;
  border-radius: 7px;
  color: var(--primary);
  font-size: 12px;
  margin: 0;
  padding: 8px 10px;
}
.award-login {
  align-items: end;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 17px 20px;
}
.award-login label {
  color: var(--muted);
  font-size: 12px;
}
.award-login input {
  border: 1px solid var(--line);
  border-radius: 6px;
  display: block;
  margin-top: 4px;
  padding: 8px;
}
.award-login button {
  margin: 0;
}
.award-login + div {
  padding: 0 20px;
}
.award-request-list {
  padding: 4px 20px 16px;
}
.award-request-list h4 {
  margin: 8px 0;
}
.award-request-item {
  align-items: center;
  border-top: 1px solid var(--line);
  display: flex;
  gap: 12px;
  justify-content: space-between;
  padding: 9px 0;
}
.award-request-item small {
  color: var(--muted);
  display: block;
}
.award-request-status {
  color: var(--primary);
  font-size: 11px;
  font-weight: 700;
}
.awards-panel .small {
  color: var(--muted);
  font-size: 12px;
}
@media (max-width: 760px) {
  .public-award {
    display: block;
  }
  .award-levels {
    justify-content: flex-start;
    margin-top: 10px;
  }
  .awards-panel {
    margin: 0 15px 25px;
  }
  .award-login {
    display: grid;
    grid-template-columns: 1fr;
  }
  .award-login input {
    width: 100%;
  }
}
.profile-panel {
  display: grid;
  gap: 1rem;
}
.profile-form,
.profile-image-editor,
.profile-callsigns {
  display: grid;
  gap: 1rem;
  max-width: 44rem;
}
.profile-form label,
.profile-image-editor label,
.profile-callsigns label {
  display: grid;
  gap: 0.4rem;
}
.profile-form input,
.profile-form textarea,
.profile-image-editor input,
.profile-callsigns input,
.profile-callsigns select,
.profile-callsigns textarea {
  width: 100%;
  box-sizing: border-box;
}
.profile-form textarea,
.profile-callsigns textarea {
  resize: vertical;
}
.profile-callsigns {
  border-top: 1px solid var(--line);
  padding-top: 1rem;
}
.profile-callsigns h4,
.profile-callsigns h5,
.profile-callsigns p {
  margin: 0;
}
.profile-callsign-list {
  border-top: 1px solid var(--line);
}
.profile-callsign-row {
  align-items: center;
  border-bottom: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: space-between;
  padding: 0.8rem 0;
}
.profile-callsign-row > div:first-child {
  display: grid;
  gap: 0.25rem;
}
.profile-callsign-actions,
.profile-callsign-actions button {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.profile-callsign-actions button {
  align-items: center;
  justify-content: center;
}
.profile-callsigns .small {
  color: var(--muted);
}
.proposal-form {
  border-top: 1px solid var(--line);
  margin: 20px 0 0;
  max-width: 36rem;
  padding: 20px 0 0;
}
.entity-pagination {
  align-items: center;
  display: flex;
  gap: 12px;
  justify-content: center;
  padding: 14px 20px 0;
}
.entity-pagination span {
  min-width: 10rem;
  text-align: center;
}
.proposal-form h4,
.proposal-form p {
  margin: 0;
}
.proposal-coordinates {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.profile-image-current {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
}
#profile-crop-canvas {
  display: block;
  width: min(100%, 240px);
  height: auto;
  border-radius: 50%;
  background: #e8edf4;
  touch-action: none;
}
.crop-controls {
  display: grid;
  grid-template-columns: repeat(3, 2.75rem);
  gap: 0.4rem;
}
.crop-controls button:nth-child(1) {
  grid-column: 2;
}
.crop-controls button:nth-child(2) {
  grid-column: 1;
  grid-row: 2;
}
.crop-controls button:nth-child(3) {
  grid-column: 2;
  grid-row: 2;
}
.crop-controls button:nth-child(4) {
  grid-column: 3;
  grid-row: 2;
}
.biography-preview {
  overflow-wrap: anywhere;
}
.biography-preview p:first-child {
  margin-top: 0;
}
.biography-preview p:last-child {
  margin-bottom: 0;
}
.biography-preview a {
  color: var(--primary);
}
.secondary {
  background: #64748b;
}
