.user-menu {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.masthead {
  border-bottom: 1px solid light-dark(transparent, var(--line));
}
.map-page {
  padding-top: 42px;
}
.map-page .pagehead h1 {
  font-size: 2rem;
}
.map-layout {
  display: grid;
  grid-template-columns: minmax(0, 2.15fr) minmax(235px, 1fr);
  gap: 20px;
  align-items: start;
}
.map-main,
.map-aside {
  display: grid;
  gap: 20px;
  min-width: 0;
}
.map-panel {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--white);
  min-width: 0;
  overflow: hidden;
}
.map-panel > header {
  min-height: 56px;
  padding: 12px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--line);
}
.map-panel h2 {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 1rem;
  line-height: 1.3;
}
.map-panel h2 .icon {
  width: 16px;
  color: var(--muted);
}
.map-link,
.machine-name {
  font: inherit;
  text-decoration: none;
  color: var(--ink);
  font-weight: 560;
}
button.map-link {
  border: 0;
  background: none;
  padding: 0;
  text-align: left;
}
.map-panel header .map-link,
.map-count,
.observed {
  font-size: 0.79rem;
  color: var(--muted);
  font-weight: 450;
}
.map-link:hover,
.machine-name:hover {
  text-decoration: underline;
  color: var(--green);
}
.topology {
  --wire: light-dark(#a3b1a7, #525d58);
  padding: 26px 24px;
  display: flex;
  align-items: center;
  min-height: 236px;
  overflow: auto;
  background-color: light-dark(#f4f7f3, #131618);
  background-image: radial-gradient(light-dark(#cbd3ca, #303739) 0.8px, transparent 0.9px);
  background-size: 14px 14px;
}
.map-root,
.machine article,
.first-server {
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--white);
  min-width: 0;
}
.map-root {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px;
  flex: none;
  position: relative;
}
.map-root strong,
.machine-name {
  font-size: 0.9rem;
}
.map-root small,
.machine small,
.deployments td small,
.setup small,
.map-events small {
  display: block;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 400;
}
.branches,
.placements,
.map-events,
.setup ol {
  padding: 0;
  margin: 0;
  list-style: none;
}
.branches {
  flex: 1;
  min-width: 0;
  position: relative;
  padding-left: 24px;
}
.branches::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  width: 25px;
  border-top: 1px solid var(--wire);
}
.machine {
  position: relative;
  padding: 6px 0 6px 22px;
}
.machine::before,
.machine::after {
  content: '';
  position: absolute;
  left: 0;
}
.machine::before {
  inset-block: 0;
  border-left: 1px solid var(--wire);
}
.machine:first-child::before {
  top: 50%;
}
.machine:last-child::before {
  bottom: 50%;
}
.machine::after {
  width: 22px;
  top: 50%;
  border-top: 1px solid var(--wire);
}
.machine article {
  overflow: hidden;
}
.machine-info {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
}
.machine-info > div {
  min-width: 0;
  overflow-wrap: anywhere;
}
.machine-info .state {
  margin-left: auto;
  font-size: 0.72rem;
  flex: none;
}
.machine-icon {
  color: var(--muted);
  display: flex;
}
.placements {
  border-top: 1px solid var(--line);
  padding: 4px 12px;
}
.placements li {
  display: flex;
  gap: 7px;
  align-items: center;
  padding: 3px 0;
  font-size: 0.79rem;
}
.placements .icon {
  width: 13px;
  height: 13px;
  color: var(--muted);
}
.placements .map-link {
  min-width: 0;
  overflow-wrap: anywhere;
}
.placements li span {
  margin-left: auto;
  color: var(--muted);
  white-space: nowrap;
  font-size: 0.73rem;
}
.first-server {
  width: 100%;
  min-height: 56px;
  border-style: dashed;
  color: var(--green);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 550;
}
.first-server:hover {
  background: var(--soft);
}
.setup ol,
.map-events {
  padding: 8px 18px;
}
.setup li {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 10px 0;
}
.setup li strong,
.setup li .map-link {
  font-size: 0.88rem;
  font-weight: 550;
}
.setup .current .map-link,
.setup .done .step-mark {
  color: var(--green);
}
.step-mark {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.75rem;
  flex: none;
}
.step-mark .icon {
  height: 13px;
  width: 13px;
}
.setup .current .step-mark {
  border-color: var(--green);
  color: var(--green);
}
.map-events li {
  padding: 9px 0;
  font-size: 0.85rem;
  overflow-wrap: anywhere;
}
.map-events li + li {
  border-top: 1px solid var(--line);
}
.deployments td,
.deployments th {
  padding: 11px 14px;
}
.deployments .map-endpoint {
  font: 0.76rem/1.45 var(--mono);
  overflow-wrap: anywhere;
}
.map-endpoint .icon {
  width: 12px;
  height: 12px;
}
.observed {
  padding: 9px 16px;
}
@media (max-width: 960px) {
  .map-layout {
    grid-template-columns: 1fr;
  }
  .map-aside {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 620px) {
  .map-aside {
    grid-template-columns: 1fr;
  }
  .map-page {
    padding-top: 26px;
  }
  .map-page .pagehead {
    flex-wrap: wrap;
    gap: 14px;
  }
  .map-page .pagehead h1 {
    font-size: 1.8rem;
  }
  .topology {
    display: block;
    padding: 18px;
  }
  .map-root {
    width: fit-content;
  }
  .branches {
    padding: 8px 0 0 16px;
  }
  .branches::before {
    left: 16px;
    top: 0;
    width: 0;
    height: calc(50% + 4px);
    border: 0;
    border-left: 1px solid var(--wire);
  }
  .map-panel > header {
    min-height: 48px;
    padding: 10px 14px;
  }
  .mastinner nav {
    justify-content: space-between;
    gap: 0;
  }
  .navitem {
    gap: 4px;
  }
  .navitem .icon {
    width: 14px;
  }
  .identity .account {
    max-width: 90px;
  }
}
@media (max-width: 390px) {
  .navitem {
    font-size: 0.79rem;
  }
  .identity .account {
    display: none;
  }
}
@media (max-width: 360px) {
  .mastinner nav .icon {
    display: none;
  }
}
.fleet-globe { display:block; margin-bottom:20px }
.globe-body { display:grid; grid-template-columns:minmax(0,1.6fr) minmax(245px,1fr) }
.globe-stage { position:relative; min-width:0; background:#10181b; background-image:radial-gradient(#2d393c .7px,transparent .9px); background-size:18px 18px }
.globe-stage canvas {display:block;width:100%;height:310px;touch-action:none;cursor:grab}
.globe-stage canvas:active {cursor:grabbing}
.globe-stage canvas:focus-visible {outline:2px solid #9edcb7;outline-offset:-3px}
.globe-key {position:absolute;bottom:9px;left:0;right:0;display:flex;justify-content:center;gap:16px;color:#c6d3d2;font-size:.72rem;pointer-events:none}
.globe-key span::before {content:'';display:inline-block;width:7px;height:7px;margin-right:5px;background:#a2efc0;border-radius:50%}
.globe-key span:nth-child(2)::before {background:#efc273}
.globe-key span:nth-child(3)::before {background:#f2a197}
.globe-inspector {padding:16px 22px;border-left:1px solid var(--line);min-width:0;align-self:center;overflow-wrap:anywhere}
.globe-inspector dl {margin:12px 0;display:grid;gap:3px;font-size:.84rem}
.globe-inspector dl div {display:flex;justify-content:space-between;gap:10px}
.globe-inspector dt,.globe-location small {color:var(--muted)}
.globe-inspector dd {margin:0;text-align:right}
.globe-inspector a {font-size:.84rem}
.globe-location {margin-top:12px}
.globe-location strong,.globe-location small {display:block}
.globe-location small {font-size:.77rem}
@media(max-width:650px) {
  .globe-body {grid-template-columns:1fr}
  .globe-stage canvas {height:235px}
  .globe-inspector {border:0;border-top:1px solid var(--line);padding:14px 16px}
}
