.minimap-frame {
  color: var(--cream);
  cursor: pointer;
  pointer-events: auto;
  text-align: left;
  -webkit-tap-highlight-color: transparent;
}

.minimap-frame:hover { border-color: #ffcb4799; }

.minimap-frame:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
}

.route-map-dialog {
  width: min(860px, 94vw);
  max-height: 92dvh;
  margin: auto;
  overflow: auto;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: clamp(12px, 3vw, 26px);
  color: var(--cream);
  background: #103d37;
  box-shadow: 0 14px 58px #031d1bd9;
}

.route-map-dialog::backdrop { background: #062927bb; }

.route-map-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 12px;
}

.route-map-heading h2 {
  margin: 0;
  font: 800 clamp(27px, 6vw, 48px)/1 var(--display-font);
  overflow-wrap: anywhere;
}

.route-map-heading p {
  margin: 7px 0 0;
  color: var(--muted);
  font-size: .9rem;
}

.route-map-resume {
  flex: none;
  border: 0;
  border-radius: 8px;
  padding: 11px 14px;
  background: var(--gold);
  color: var(--deep);
  font: 800 .9rem/1.15 var(--body-font);
}
.job-controls { margin-top: 0; }
.job-controls #trackJob {
  padding: 8px 12px; border: 1px solid var(--gold); border-radius: 8px;
  color: var(--deep); background: var(--gold); font: 800 12px var(--body-font);
}
.job-controls #trackJob:disabled { opacity: .5; }
.job-brief { margin: 6px 0 12px; color: var(--muted); font-size: .84rem; }
.postcard-album { margin-top: 12px; font-size: .85rem; }
.postcard-album summary { cursor: pointer; }
.postcard-album div { display: flex; flex-wrap: wrap; gap: 10px; }
.postcard-album figure { width: min(155px,43%); margin: 10px 0 0; }
.postcard-album canvas { width: 100%; height: auto; border-radius: 4px; }

.route-map-canvas-wrap {
  position: relative;
  overflow: hidden;
  border: 1px solid #92bea250;
  border-radius: 10px;
  background: #174746;
}

.route-map-canvas {
  display: block;
  width: 100%;
  height: min(60dvh, 560px);
}

.route-map-north {
  position: absolute;
  top: 8px;
  right: 9px;
  color: var(--gold);
  font: 800 .78rem/1 var(--body-font);
}
.map-north i { display:inline-block; font-style:normal; transform:rotate(var(--north-bearing,0rad)); }
.route-guidance {
  position:absolute; bottom:10px; left:10px; display:grid; gap:1px 8px;
  grid-template-columns:auto 1fr; align-items:center; width:max-content; max-width:calc(100% - 20px);
  padding:7px 12px 7px 9px; color:#f5f6f3; background:#182322ef;
  border:1px solid #b99ae48a; border-radius:7px; pointer-events:none;
  font:700 .84rem/1.25 var(--body-font);
}
.route-guidance[hidden] { display:none; }
.route-guidance b { grid-row:span 2; font:700 25px/1 sans-serif; color:#d2b2ff; }
.route-guidance small { grid-column:2; color:#c9d1c8; font-size:.73rem; }
.route-map-line-key { height:4px; width:15px; border-radius:3px; background:#c69bff; box-shadow:0 0 0 1px #362349; }

.route-map-legend {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem 1rem;
  padding: 0;
  margin: 12px 0 0;
  list-style: none;
  color: var(--muted);
  font: 700 .8rem/1.2 var(--body-font);
}

.route-map-legend li { display: inline-flex; align-items: center; gap: 5px; }
.route-map-legend i { display: inline-block; }
.map-civic-symbol {
  display:inline-grid; width:13px; height:13px; place-items:center; border-radius:2px;
  color:#fff; font:bold 12px/1 Arial,sans-serif;
}
.medical-symbol { background:#17675c; }
.police-symbol { background:#294c80; }
.route-map-kart-key { height: 10px; width: 10px; background: var(--cream); clip-path: polygon(50% 0%, 100% 100%, 50% 73%, 0 100%); }
.route-map-stop-key { height: 8px; width: 8px; border-radius: 50%; background: #ffd977; }
.route-map-road-key { height: 4px; width: 12px; border-radius: 2px; background: #a6afa5; }
.route-map-checkpoint-key { height: 8px; width: 8px; background: #f4bf6d; }
.map-selection { margin: 8px 0 0; font-size: .82rem; line-height: 1.4; }
.route-map-dialog a { color: #bce9dd; text-underline-offset: 2px; }

@media (max-width: 460px) {
  .route-map-resume { max-width: 105px; min-height: 40px; padding: 8px 10px; }
  .route-map-canvas { height: min(56dvh, 420px); }
}
