/* HCPC Interactive Map V1.0.6 - scoped dark theme, no gradients, 5px radii */
.hcpc-map{--hm-bg:#121b23;--hm-panel:#1b2833;--hm-border:#354554;--hm-muted:#a9bac8;--hm-text:#eef3f8;color:var(--hm-text);font:inherit;min-width:0}
.hcpc-map *,.hcpc-map *::before,.hcpc-map *::after{box-sizing:border-box}
.hcpc-map__shell{display:grid;grid-template-columns:minmax(0,1fr) minmax(205px,260px);gap:14px;align-items:start;width:100%}
.hcpc-map__main,.hcpc-map__sidebar{min-width:0}
.hcpc-map__toolbar{display:flex;gap:10px;justify-content:space-between;align-items:center;min-height:34px;margin:0 0 11px}
.hcpc-map__title{font-size:clamp(16px,2vw,22px);letter-spacing:.035em;font-weight:800}
.hcpc-map__controls{display:flex;gap:5px;align-items:center}
.hcpc-map__control{font-size:12px;background:var(--hm-panel);color:var(--hm-text);border:1px solid var(--hm-border);padding:6px 9px;border-radius:5px;cursor:pointer;white-space:nowrap}
.hcpc-map__control:hover,.hcpc-map__control:focus-visible{border-color:#9cc5dd;outline-offset:2px}
.hcpc-map__viewport{width:100%;aspect-ratio:772/776;position:relative;overflow:hidden;cursor:grab;touch-action:none;user-select:none;background:#293843;border:1px solid var(--hm-border);border-radius:5px}
.hcpc-map__viewport.is-dragging{cursor:grabbing}
.hcpc-map__canvas{width:100%;height:100%;position:absolute;inset:0;transform-origin:0 0}
.hcpc-map__image{display:block !important;position:absolute !important;inset:0 !important;width:100% !important;height:100% !important;max-width:none !important;object-fit:fill !important;transform:none !important;pointer-events:none;user-select:none}
.hcpc-map__pin{position:absolute;z-index:2;display:flex;align-items:center;justify-content:center;transform:scale(var(--hm-pin-inverse-zoom,1)) translate(-50%,-50%);width:23px;height:23px;padding:0;border:2px solid #fff;border-radius:50%;background:#2c4b60;color:#fff;font-size:14px;font-weight:800;cursor:pointer;line-height:1;box-shadow:0 1px 5px #000a}
.hcpc-map__pin--blue,.hcpc-map__pin--green,.hcpc-map__pin--red{width:19px;height:19px;border-radius:4px;font-size:10px}
.hcpc-map__pin--blue{background:#1089cf}.hcpc-map__pin--green{background:#23b647}.hcpc-map__pin--red{background:#d83d43}
.hcpc-map__pin:hover,.hcpc-map__pin.is-active{z-index:5;box-shadow:0 0 0 3px #ffffff75,0 2px 8px #000b}
.hcpc-map__pin:focus-visible{outline:2px solid #fff;outline-offset:3px}
.hcpc-map__tip{display:none;position:absolute;bottom:calc(100% + 9px);left:50%;transform:translateX(-50%);padding:8px 11px;min-width:max-content;max-width:240px;border:1px solid #6e889b;border-radius:5px;background:#121c25;color:white;box-shadow:0 5px 20px #0009;white-space:nowrap;text-align:left;font-size:12px;line-height:1.55;pointer-events:none}
.hcpc-map__tip strong{display:block}.hcpc-map__tip span{display:block}
.hcpc-map__pin:hover .hcpc-map__tip,.hcpc-map__pin:focus-visible .hcpc-map__tip,.hcpc-map__pin.is-active .hcpc-map__tip{display:block}
.hcpc-map__pin[hidden],.hcpc-map__item[hidden]{display:none !important}
.hcpc-map__sidebar{background:var(--hm-panel);border:1px solid var(--hm-border);border-radius:5px;padding:16px;color:var(--hm-text);min-height:0}
.hcpc-map__sidebar h3{margin:0 0 12px;color:#fff;font-size:16px;font-weight:800;letter-spacing:.03em}
.hcpc-map__section{border-top:1px solid var(--hm-border);padding-top:13px;margin-top:13px}
.hcpc-map__section-title{display:flex;align-items:center;gap:7px;text-transform:uppercase;font-size:12px;letter-spacing:.03em;font-weight:800;margin:0 0 7px}
.hcpc-map__section-title label{cursor:pointer}.hcpc-map__section-title input{accent-color:#56b9df;margin:0}
.hcpc-map__list{display:flex;flex-direction:column;gap:2px;max-height:350px;overflow-x:hidden;overflow-y:auto}
.hcpc-map__item{display:flex;width:100%;gap:8px;align-items:center;padding:7px 6px;text-align:left;border:1px solid transparent;border-radius:5px;background:transparent;color:var(--hm-text);font:inherit;font-size:12px;cursor:pointer}
.hcpc-map__item:hover,.hcpc-map__item:focus-visible,.hcpc-map__item.is-active{background:#304556;border-color:#50687b}
.hcpc-map__dot{display:block;flex:none;width:11px;height:11px;border-radius:50%;border:1px solid #c5d2db;background:#8ab4ca}
.hcpc-map__dot--blue{background:#1089cf}.hcpc-map__dot--green{background:#23b647}.hcpc-map__dot--red{background:#d83d43}
.hcpc-map__legend-name{min-width:0;overflow-wrap:anywhere;flex:1}
.hcpc-map__notice{color:var(--hm-muted);font-size:11px;line-height:1.45;margin:13px 0 0}
.hcpc-map__status{font-size:11px;color:var(--hm-muted);margin:8px 0 12px;min-height:1.5em}
.hcpc-map__info{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.hcpc-map__infocard{background:var(--hm-panel);border:1px solid var(--hm-border);border-radius:5px;padding:15px;min-width:0}
.hcpc-map__infocard h3{font-size:13px;font-weight:800;margin:0 0 10px;color:#fff}
.hcpc-map__infocard p{font-size:12px;margin:0 0 5px;line-height:1.5}
.hcpc-map__infocard .hcpc-map__small{font-size:11px;color:var(--hm-muted)}
@media(max-width:800px){.hcpc-map__shell{grid-template-columns:minmax(0,1fr) minmax(175px,220px);gap:9px}.hcpc-map__sidebar{padding:12px}}
@media(max-width:600px){.hcpc-map__shell{grid-template-columns:minmax(0,1fr)}.hcpc-map__list{max-height:190px}.hcpc-map__sidebar{padding:14px}.hcpc-map__info{grid-template-columns:1fr 1fr}}
@media(max-width:390px){.hcpc-map__info{grid-template-columns:1fr}.hcpc-map__control{padding:5px 7px}}
/* Enable only after A01 feed and original map image load; leave legacy stage intact as fallback. */
.server-dashboard__map.hcpc-map-enhanced > .server-dashboard__map-stage{display:none !important}
.server-dashboard__map.hcpc-map-enhanced > .hcpc-map{display:block !important;width:100% !important;max-width:none !important;min-width:0}
.hcpc-map[data-hcpc-interactive-map][hidden]{display:none !important}
.server-dashboard__map.hcpc-map-enhanced > :not(.hcpc-map):not(link):not(script){display:none !important}
.server-dashboard--settings > .server-dashboard__map.hcpc-map-enhanced{grid-column:1/-1 !important;grid-row:auto !important;min-height:0 !important;height:auto !important;max-height:none !important;min-width:0 !important}
/* Fix the V1.0.1 regression: the four existing server setting cards must fill available width. */
.server-dashboard--settings:has(> .server-dashboard__map.hcpc-map-enhanced){display:grid !important;grid-template-columns:repeat(4,minmax(0,1fr)) !important;gap:12px !important;align-items:stretch}
.server-dashboard--settings:has(> .server-dashboard__map.hcpc-map-enhanced) > :not(.server-dashboard__map){grid-column:auto !important;grid-row:auto !important;min-width:0 !important;width:auto !important}
@media(max-width:810px){.server-dashboard--settings:has(> .server-dashboard__map.hcpc-map-enhanced){grid-template-columns:repeat(2,minmax(0,1fr)) !important}}
@media(max-width:490px){.server-dashboard--settings:has(> .server-dashboard__map.hcpc-map-enhanced){grid-template-columns:1fr !important}}

/* V1.0.3: no duplicate map / base summary; original four HCPC cards below image. */
.hcpc-map__settings{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-top:14px;align-items:stretch;width:100%}
.hcpc-map__settings > *{box-sizing:border-box;display:block;min-width:0!important;max-width:none!important;width:100%!important;grid-column:auto!important;grid-row:auto!important;height:auto!important;min-height:0!important}
.server-dashboard--settings.hcpc-map-settings-relocated:has(> .server-dashboard__map.hcpc-map-enhanced){display:block!important;width:100%!important;max-width:none!important}
.server-dashboard--settings.hcpc-map-settings-relocated > .server-dashboard__map.hcpc-map-enhanced{display:block!important;width:100%!important;grid-column:auto!important;max-width:none!important}
.hcpc-map__legacy-tribes-hidden[hidden]{display:none!important}
.hcpc-map__calibration{margin-top:15px;padding-top:14px;border-top:1px solid var(--hm-border);font-size:12px}
.hcpc-map__calibration p{font-size:12px;color:var(--hm-muted);line-height:1.4}
.hcpc-map__calibration-output{display:block;width:100%;font:11px monospace;background:#101922;color:#fff;border:1px solid var(--hm-border);border-radius:5px;resize:vertical;margin:9px 0}
.hcpc-map__pin--calibratable{outline:2px dashed #fff;cursor:move}
@media(max-width:600px){.hcpc-map__settings{gap:9px}}
@media(max-width:390px){.hcpc-map__settings{grid-template-columns:1fr}}

/* V1.0.5: four existing cards are a SIBLING of .server-dashboard--settings,
   never a descendant of the narrower map panel or its internal grid. */
.server-detail > .hcpc-map__settings.hcpc-map__settings--external,
.hcpc-map__settings.hcpc-map__settings--external {
  display:grid !important;
  box-sizing:border-box !important;
  grid-template-columns:repeat(4,minmax(0,1fr)) !important;
  gap:12px !important;
  width:100% !important;
  min-width:0 !important;
  max-width:none !important;
  margin:12px 0 14px !important;
  align-items:stretch !important;
  position:relative !important;
}
.hcpc-map__settings.hcpc-map__settings--external > * {
  box-sizing:border-box !important;
  display:block !important;
  width:100% !important;
  min-width:0 !important;
  max-width:none !important;
  grid-column:auto !important;
  grid-row:auto !important;
  margin:0 !important;
}
.hcpc-map__empty-setting-wrapper[hidden]{display:none!important}
@media(max-width:810px) {
 .server-detail > .hcpc-map__settings.hcpc-map__settings--external,
 .hcpc-map__settings.hcpc-map__settings--external {
   grid-template-columns:repeat(2,minmax(0,1fr)) !important;
 }
}
@media(max-width:490px) {
 .server-detail > .hcpc-map__settings.hcpc-map__settings--external,
 .hcpc-map__settings.hcpc-map__settings--external {
   grid-template-columns:minmax(0,1fr) !important;
 }
}

/* HCPC Interactive Map V1.0.7 – all PvE ASA maps. Legend matches image bottom. */
.hcpc-map__sidebar{
  display:flex;
  flex-direction:column;
  overflow:hidden;
  box-sizing:border-box;
}
.hcpc-map__sidebar > .hcpc-map__section:last-of-type{
  display:flex;
  flex:1 1 auto;
  flex-direction:column;
  min-height:0;
}
.hcpc-map__sidebar > .hcpc-map__section:last-of-type .hcpc-map__list{
  flex:1 1 auto;
  min-height:0;
  max-height:none;
  overflow-y:auto;
}
.hcpc-map__sidebar > .hcpc-map__notice{flex:0 0 auto;}
/* The pre-existing map information and online/player cards, 2/3 + 1/3. */
.server-detail .hcpc-map__overview-row{
  display:grid !important;
  grid-template-columns:minmax(0,2fr) minmax(0,1fr) !important;
  gap:12px !important;
  align-items:stretch !important;
  width:100% !important;
  min-width:0 !important;
}
.server-detail .hcpc-map__overview-row > .hcpc-map__overview-about,
.server-detail .hcpc-map__overview-row > .hcpc-map__overview-online{
  min-width:0 !important;
  max-width:none !important;
  width:100% !important;
  grid-column:auto !important;
  grid-row:auto !important;
}
@media(max-width:600px){
  .hcpc-map__sidebar{height:auto !important;overflow:visible;}
  .hcpc-map__sidebar > .hcpc-map__section:last-of-type .hcpc-map__list{max-height:190px;flex:none;}
  .server-detail .hcpc-map__overview-row{grid-template-columns:minmax(0,1fr) !important;}
}

/* Fine-calibration controls must remain reachable even inside the height-matched legend. */
.hcpc-map__sidebar.hcpc-map__sidebar--calibrating{overflow-y:auto;}
.hcpc-map__sidebar.hcpc-map__sidebar--calibrating > .hcpc-map__section:last-of-type .hcpc-map__list{flex:none;max-height:190px;}

/* Empty but honest legend groups for PvE maps without calibration. */
.hcpc-map__no-pois{margin:7px 4px 12px;color:var(--hm-muted);font-size:12px;line-height:1.5}
.hcpc-map__section-title input:disabled{cursor:not-allowed;opacity:.55}
