/* Global Hybrid Topology — montystewart.com/topology.html
   The header, footer and hover card are ordinary page elements; the key is drawn on the stage. The diagram is drawn on a
   stage (sized per view in js/topology.js) that is scaled to fit the space between them. */

@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 400; font-display: swap; src: url(../fonts/manrope-latin-400-normal.woff2) format('woff2'); }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 500; font-display: swap; src: url(../fonts/manrope-latin-500-normal.woff2) format('woff2'); }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 600; font-display: swap; src: url(../fonts/manrope-latin-600-normal.woff2) format('woff2'); }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 700; font-display: swap; src: url(../fonts/manrope-latin-700-normal.woff2) format('woff2'); }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 800; font-display: swap; src: url(../fonts/manrope-latin-800-normal.woff2) format('woff2'); }

:root {
  --bg: #1c1e21;
  --text: #e8eaed;
  --muted: #a0a8b2;
  --soft: #c3c9d0;
  --line: #3a3f46;
  --card: #24282c;
  --onp: #6ed69c;   --onp-t: #8be3b2;
  --ms: #4db4ff;    --ms-t: #8fd0ff;
  --aws: #ff9f43;   --aws-t: #ffb36b;
  --dfs: #f2c14e;
  --sql: #d98cff;   --sql-t: #e2b0ff;
  --edge: #c9ced4;  --edge-t: #dfe3e8;
  --cf: #f38020;    /* Cloudflare orange */
  --warn: #f2c14e;  --bad: #ff7b72;
  --mono: 'Cascadia Mono', Consolas, 'SFMono-Regular', Menlo, monospace;
  --top: 104px;
  --bottom: 44px;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  background-color: var(--bg);
  background-image: radial-gradient(rgba(255,255,255,0.045) 1px, transparent 1px);
  background-size: 24px 24px;
  color: var(--text);
  font-family: Manrope, 'Segoe UI', system-ui, sans-serif;
  overflow: hidden;
}
a { color: #c9ced4; text-decoration: none; }
a:hover { color: #fff; }
svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.mono { font-family: var(--mono); }
.mu { color: var(--muted); }
.flag { display: inline-block; width: 22px; height: 16px; border-radius: 2px; object-fit: cover; box-shadow: 0 0 0 1px rgba(255,255,255,0.18); flex: none; vertical-align: -3px; }
.flag.sm { width: 16px; height: 12px; vertical-align: -1px; }
.flag.lg { width: 32px; height: 24px; border-radius: 3px; }

/* ---------- header (outside the stage) ---------- */
#top { position: fixed; left: 0; right: 0; top: 0; height: var(--top); padding: 12px 24px 0; display: flex; flex-direction: column; gap: 10px; z-index: 30; background: linear-gradient(var(--bg) 70%, rgba(28,30,33,0)); }
.top-row { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 16px; min-width: 0; }
.brand { font-size: 15px; font-weight: 400; letter-spacing: -0.01em; color: var(--text); }
.center-link { position: absolute; left: 50%; transform: translateX(-50%); font-size: 15px; font-weight: 400; letter-spacing: -0.01em; color: var(--text); text-decoration: none; }
.brand, .center-link, .site-nav .pill-btn { transition: color .15s, border-color .15s; }
.center-link:hover, .brand:hover, .center-link:focus-visible, .brand:focus-visible { color: #4ade80; }
.site-nav .pill-btn:hover, .site-nav .pill-btn:focus-visible { color: #4ade80; border-color: #4ade80; }
.controls { display: flex; align-items: center; gap: 12px; min-width: 0; }
.crumbs { display: flex; align-items: center; gap: 10px; font-size: 13px; font-weight: 700; white-space: nowrap; min-width: 0; color: var(--muted); }
.crumbs .sep { color: #5d646d; }
#crumb { display: flex; align-items: center; gap: 10px; }
#crumb span:last-child { color: var(--text); }
#tabs { display: flex; gap: 4px; padding: 4px; border: 1px solid var(--line); border-radius: 22px; }
#tabs a { height: 32px; padding: 0 14px; display: flex; align-items: center; gap: 8px; border-radius: 16px; font-size: 13px; font-weight: 600; white-space: nowrap; }
#tabs a[aria-current="page"] { background: var(--text); color: var(--bg); }
.site-nav { display: flex; gap: 8px; }
.pill-btn { height: 38px; padding: 0 14px; display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 19px; font-size: 13px; font-weight: 600; white-space: nowrap; }
#back { border: 2px solid #4ade80; color: #e8eaed; box-shadow: 0 0 0 3px rgba(74,222,128,0.15); }
#back:hover { border-color: #86efac; background: rgba(74,222,128,0.12); color: #fff; }
.pill-btn.round { width: 38px; padding: 0; justify-content: center; }
.pill-btn:hover { border-color: #6a717b; }
.titles { display: flex; align-items: baseline; gap: 16px; min-width: 0; }
#title { margin: 0; font-size: 26px; line-height: 34px; font-weight: 800; letter-spacing: -0.01em; white-space: nowrap; display: flex; align-items: center; gap: 10px; }
#sub { margin: 0; font-size: 14px; line-height: 20px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
#filters { display: flex; gap: 6px; flex: none; }
#filters button { height: 34px; padding: 0 13px; border-radius: 17px; border: 1px solid var(--line); background: transparent; color: #c9ced4; font: 600 12.5px Manrope, sans-serif; cursor: pointer; }
#filters button:hover { border-color: #6a717b; color: #fff; }
#filters button[aria-pressed="true"] { background: var(--text); border-color: var(--text); color: var(--bg); }
#filters button[data-layer="issues"][aria-pressed="true"] { background: var(--warn); border-color: var(--warn); }
.hidden { display: none !important; }

/* ---------- stage ---------- */
#viewport { position: fixed; left: 0; right: 0; top: var(--top); bottom: var(--bottom); overflow: hidden; touch-action: none; }
#viewport.zoomed { cursor: grab; }
#viewport.panning { cursor: grabbing; }
#stage { position: absolute; left: 0; top: 0; transform-origin: 0 0; }
#bands, #labels, #nodes { position: absolute; inset: 0; pointer-events: none; }
#nodes > * { pointer-events: auto; }
#links { position: absolute; left: 0; top: 0; overflow: visible; pointer-events: none; }

.band { position: absolute; border-radius: 16px; border: 1px solid; }
.bd-edge { background: rgba(223,227,232,0.03); border-color: rgba(223,227,232,0.14); }
.bd-ms   { background: rgba(77,180,255,0.04); border-color: rgba(77,180,255,0.18); }
.bd-onp  { background: rgba(110,214,156,0.03); border-color: rgba(110,214,156,0.16); }
.bd-dfs  { background: rgba(242,193,78,0.03); border-color: rgba(242,193,78,0.2); }
.bd-sql  { background: rgba(217,140,255,0.03); border-color: rgba(217,140,255,0.2); }
.bd-grp-ms  { background: #24282d; border-color: rgba(77,180,255,0.35); border-radius: 12px; }
.bd-grp-aws { background: #24282d; border-color: rgba(255,159,67,0.4); border-radius: 12px; }
.bd-lane { background: #212428; border-color: #30343a; border-radius: 12px; }
.bd-grp { background: #212428; border-color: #34383e; border-radius: 12px; }

.lbl { position: absolute; font-size: 12px; line-height: 16px; white-space: nowrap; }
.sec { display: flex; align-items: center; gap: 8px; font-size: 11px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; }
.sec svg { width: 14px; height: 14px; }
.sec .cnt { letter-spacing: 0.04em; color: var(--muted); }
.s-edge { color: var(--edge); } .s-ms { color: var(--ms-t); } .s-aws { color: var(--aws-t); }
.s-onp { color: var(--onp-t); } .s-mu { color: var(--muted); } .s-dfs { color: var(--dfs); } .s-sql { color: var(--sql-t); }
.lane-t { font-size: 15px; letter-spacing: 0.08em; }
.ll { font-weight: 600; }
.ll-edge { color: var(--edge); } .ll-sql { color: var(--sql-t); } .ll-mu { color: var(--muted); font-weight: 400; }
.para { font-size: 13px; line-height: 20px; color: var(--soft); white-space: normal; }
.pill { height: 28px; display: flex; align-items: center; justify-content: center; border-radius: 14px; background: var(--bg); border: 1px solid; font-weight: 600; }
.p-ms { border-color: rgba(77,180,255,0.55); color: var(--ms-t); }
.p-aws { border-color: rgba(255,159,67,0.6); color: var(--aws-t); }
.p-edge { border-color: rgba(223,227,232,0.5); color: var(--edge-t); }

/* ---------- links ---------- */
.lk { fill: none; stroke-linecap: round; stroke-linejoin: round; transition: opacity .15s; }
.l-edge     { stroke: var(--edge); stroke-width: 2; stroke-dasharray: 2 6; }
.l-tunnel   { stroke: var(--edge); stroke-width: 2.5; }
.l-repl     { stroke: var(--onp); stroke-width: 2; }
.l-interhub { stroke: var(--onp); stroke-width: 2.5; }
.l-dag      { stroke: var(--sql); stroke-width: 3; stroke-dasharray: 6 6; }
.l-sync     { stroke: var(--ms); stroke-width: 2.5; stroke-dasharray: 8 6; }
.l-er       { stroke: var(--ms); stroke-width: 4; }
.l-dx       { stroke: var(--aws); stroke-width: 4; }
.l-dfs      { stroke: var(--dfs); stroke-width: 2; }
#stage.focusing .lk { opacity: .16; }
#stage.focusing .lk.hl { opacity: 1; stroke-width: 5; }
#stage.focusing .lk.hl.l-repl { stroke-width: 3.5; }
#stage.focusing .lk.hl.l-interhub { stroke-width: 3.5; }
#stage.focusing .lk.hl.l-edge, #stage.focusing .lk.hl.l-sync, #stage.focusing .lk.hl.l-dag { animation: flow 0.9s linear infinite; }
@keyframes flow { to { stroke-dashoffset: -24; } }

/* ---------- nodes ---------- */
.n {
  position: absolute; display: flex; align-items: flex-start; gap: 8px; margin: 0;
  background: var(--card); border: 1px solid var(--line); border-radius: 8px;
  color: var(--text); font-size: 12px; line-height: 18px; text-align: left;
  cursor: default; transition: opacity .15s, box-shadow .15s, border-color .15s;
}
.n:hover, .n:focus-visible, .n.on { border-color: #e8eaed; box-shadow: 0 0 0 4px rgba(232,234,237,0.12), 0 10px 28px rgba(0,0,0,0.45); outline: none; z-index: 2; }
#stage.focusing .n.rel { border-color: #9aa3ad; }
.n .t { font-weight: 700; }
.n-hub .t { font-size: 20px; line-height: 24px; }
.st { position: absolute; top: 8px; right: 8px; width: 9px; height: 9px; border-radius: 50%; background: var(--warn); box-shadow: 0 0 0 3px rgba(242,193,78,0.18); }
.st.bad { background: var(--bad); box-shadow: 0 0 0 3px rgba(255,123,114,0.18); }

.b { display: inline-flex; align-items: center; justify-content: center; flex: none; min-width: 30px; height: 20px; padding: 0 6px; border-radius: 4px; font-family: var(--mono); font-size: 10px; font-weight: 700; }
.b-ms   { background: rgba(77,180,255,0.16);  color: var(--ms-t); }
.b-aws  { background: rgba(255,159,67,0.16);  color: var(--aws-t); }
.b-onp  { background: rgba(110,214,156,0.16); color: var(--onp-t); }
.b-dfs  { background: rgba(242,193,78,0.16);  color: var(--dfs); }
.b-sql  { background: rgba(217,140,255,0.16); color: var(--sql-t); }
.b-grey { background: rgba(160,168,178,0.16); color: var(--soft); }
.b-edge { background: rgba(223,227,232,0.12); color: var(--edge-t); }
.b-t0   { background: rgba(255,123,114,0.16); color: #ffa198; }

.dc-chip { display: inline-flex; align-items: center; gap: 4px; height: 20px; padding: 0 6px; margin: 0; border-radius: 4px; border: 1px solid rgba(110,214,156,0.4); background: rgba(110,214,156,0.08); color: var(--onp-t); font: 600 11px/1 var(--mono); cursor: pointer; white-space: nowrap; }
.dc-chip:hover, .dc-chip:focus-visible, .dc-chip.on { background: rgba(110,214,156,0.24); border-color: var(--onp-t); outline: none; }
.dc-chip i { font-style: normal; color: var(--muted); font-family: Manrope, sans-serif; font-weight: 600; }
.dc-chip.warn { border-color: rgba(242,193,78,0.6); }
.chips { display: flex; flex-wrap: wrap; gap: 4px; }
.mini { display: inline-flex; align-items: center; height: 18px; padding: 0 6px; border-radius: 4px; background: #2f343a; color: var(--soft); font-size: 10.5px; font-weight: 600; white-space: nowrap; }
.mini b { color: var(--text); margin-left: 4px; }

.n-site { flex-direction: column; gap: 3px; padding: 9px 11px; background: #24282c; }
.n-site .row1 { display: flex; align-items: center; gap: 7px; font-size: 14px; line-height: 18px; max-width: 100%; }
.n-site .row1 .t { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.n-site .meta { font-size: 11px; line-height: 15px; color: var(--muted); white-space: nowrap; }
.n-hub { flex-direction: column; gap: 7px; padding: 14px 16px; background: #262a2f; border-color: var(--onp); box-shadow: 0 0 0 4px rgba(110,214,156,0.10); border-radius: 12px; }
.n-hub .row1 { display: flex; align-items: center; gap: 10px; padding-right: 8px; }
.n-hub .tag { margin-left: auto; height: 22px; padding: 0 9px; display: inline-flex; align-items: center; border-radius: 11px; border: 1px solid rgba(110,214,156,0.6); color: var(--onp-t); font-size: 10px; font-weight: 700; letter-spacing: 0.08em; }
.n-hub .meta { font-size: 12px; color: var(--muted); line-height: 16px; }
.n-hub .st { top: 8px; right: 8px; left: auto; }

.n-link { flex-direction: column; align-items: center; justify-content: center; gap: 1px; padding: 4px 32px 4px 12px; border-radius: 22px; background: var(--bg); border: 1.5px solid var(--onp); text-align: center; }
.n-link .nm { display: flex; align-items: center; gap: 5px; font: 700 11px/14px var(--mono); color: var(--onp-t); white-space: nowrap; }
.n-link .cs { font-size: 11px; line-height: 14px; color: var(--soft); white-space: nowrap; }
.lk-ico { position: absolute; right: 11px; top: 50%; width: 15px; height: 15px; margin-top: -7.5px; color: var(--onp-t); pointer-events: none; }
.lk-ico svg { width: 100%; height: 100%; stroke-width: 2.2; }
.n-link.regional { border-width: 1px; border-color: rgba(110,214,156,0.55); border-radius: 10px; }

.n-svc  { flex-direction: column; gap: 6px; padding: 12px; background: #1f2226; line-height: 16px; }
.n-svc .t { font-size: 13px; }
.n-svc .svc-ico { position: absolute; top: 9px; right: 10px; width: 28px; height: 28px; object-fit: contain; pointer-events: none; }
.n-svc .tx { display: flex; flex-direction: column; min-width: 0; width: 100%; }
.n-svc .tx .mu { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.n-edge { padding: 12px 14px; gap: 12px; align-items: center; background: #1f2226; border-color: #5a6069; border-radius: 10px; }
.n-edge .t { font-size: 14px; }
.n-cf { background: none; border: none; padding: 30px 0 0; flex-direction: column; align-items: center; justify-content: center; gap: 4px; text-align: center; isolation: isolate; }
.n-cf:hover, .n-cf:focus-visible, .n-cf.on { box-shadow: none; }
.cf-shape { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; overflow: visible; }
.cf-shape path { fill: #2e2219; stroke: var(--cf); stroke-width: 1.8; transition: fill .15s, stroke .15s; }
.n-cf:hover .cf-shape path, .n-cf:focus-visible .cf-shape path, .n-cf.on .cf-shape path { fill: #3a2a1c; stroke: #ff9a45; stroke-width: 2.6; }
.cf-t { display: flex; align-items: center; gap: 8px; font-size: 17px; line-height: 20px; font-weight: 800; color: var(--cf); }
.cf-t svg { width: 18px; height: 18px; }
.cf-s { font-size: 12px; line-height: 16px; color: #f8a964; }

.n-dc  { flex-direction: column; gap: 4px; padding: 12px 14px; background: #262a2f; border-color: rgba(110,214,156,0.6); border-radius: 10px; }
.n-dc .row1 { display: flex; align-items: center; gap: 8px; }
.n-dc .t { font-family: var(--mono); font-size: 14px; }
.n-dc .meta { font-size: 11.5px; color: var(--muted); line-height: 16px; }
.n-srv { padding: 9px 12px; gap: 10px; align-items: center; }
.n-srv .t { font-family: var(--mono); font-size: 12.5px; }
.n-srv .b { width: 52px; }
.n-srv .tx, .n-plain .tx { display: flex; flex-direction: column; min-width: 0; }
.n-srv .tx > span, .n-plain .tx > span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.n-sum { flex-direction: column; gap: 6px; padding: 12px 14px; }
.n-sum .t { font-size: 13px; }
.n-plain { padding: 10px 14px; gap: 10px; align-items: center; }
.n-plain .t { font-family: var(--mono); font-size: 12.5px; }
.n-grp { flex-direction: column; gap: 4px; padding: 12px 14px; background: #2a2e33; border-radius: 10px; }
.n.ms  { border-color: rgba(77,180,255,0.55); }
.n.aws { border-color: rgba(255,159,67,0.6); }
.n.dfs { border-color: rgba(242,193,78,0.55); }
.n.sql { border-color: rgba(217,140,255,0.55); }
.n.sel { border: 2px solid var(--onp-t); box-shadow: 0 0 0 6px rgba(110,214,156,0.14); }

/* ---------- site view: world map + location ---------- */
.n-map { padding: 0; overflow: hidden; background: #191b1e; border-color: #34383e; border-radius: 10px; }
.n-map svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.n-map .m-off { fill: #2b2f35; stroke: #191b1e; stroke-width: .25; }
.n-map .m-on  { fill: rgba(110,214,156,0.30); stroke: rgba(139,227,178,0.65); stroke-width: .25; }
.n-map .m-peer { fill: #8be3b2; opacity: .55; }
.n-map .m-hub  { fill: #191b1e; stroke: #8be3b2; stroke-width: .6; }
.n-map .m-link { stroke: #8be3b2; stroke-width: .5; stroke-dasharray: 1.4 1.4; opacity: .8; }
.n-map .m-dot  { fill: #fff; stroke: #6ed69c; stroke-width: .8; }
.n-map .m-pulse { fill: none; stroke: #8be3b2; stroke-width: .7; transform-box: fill-box; transform-origin: center; animation: m-pulse 2.2s ease-out infinite; }
.n-map .m-label { fill: #e8eaed; font: 700 5px Manrope, sans-serif; paint-order: stroke; stroke: #191b1e; stroke-width: 1.4; stroke-linejoin: round; }
@keyframes m-pulse { from { transform: scale(1); opacity: .95; } to { transform: scale(3.6); opacity: 0; } }
.map-cap { position: absolute; left: 12px; top: 10px; font-size: 10px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--onp-t); background: rgba(25,27,30,0.75); padding: 2px 6px; border-radius: 4px; }
.n-loc { flex-direction: column; gap: 14px; padding: 18px 20px; background: #24282c; border-radius: 10px; }
.loc-head { display: flex; align-items: center; gap: 12px; }
.loc-head .t { font-size: 22px; line-height: 26px; font-weight: 800; }
.loc-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 18px; margin: 0; }
.loc-facts div { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.loc-facts div:nth-child(n+4) { grid-column: 1 / -1; }
.loc-facts dt { font-size: 10px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.loc-facts dd { margin: 0; font-size: 12.5px; }

.site-ico { position: absolute; right: 9px; bottom: 8px; width: 18px; height: 18px; color: var(--onp-t); opacity: .85; pointer-events: none; }
.site-ico svg { width: 100%; height: 100%; stroke-width: 1.8; }
.n-hub .site-ico { right: 12px; bottom: 10px; width: 22px; height: 22px; }
.n-hub .chips:last-of-type, .n-site .meta:last-of-type { padding-right: 24px; }
.tile-ico { position: absolute; right: 14px; top: 50%; width: 44px; height: 38px; margin-top: -19px; object-fit: contain; pointer-events: none; }
.n-ico { background: none; border: none; padding: 0; border-radius: 6px; z-index: 5; }  /* stays above the Cloudflare cloud, which rises on hover */
.n-ico img { width: 100%; height: 100%; object-fit: contain; pointer-events: none; }
.n-ico:hover, .n-ico:focus-visible, .n-ico.on { border: none; box-shadow: 0 0 0 4px rgba(232,234,237,0.15); }
.dim { opacity: .1 !important; pointer-events: none !important; }

/* ---------- key (on the stage, see js/topology.js) ---------- */
.key { display: flex; flex-direction: column; gap: 10px; padding: 18px 20px; background: #24282c; border: 1px solid #34383e; border-radius: 12px; color: var(--soft); white-space: normal; }
.key-up { transform: translateY(-100%); }
.key-t { font-size: 11px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); margin-bottom: 2px; }
.key-r { display: flex; align-items: center; gap: 10px; }
.key svg { flex: none; width: 28px; height: 8px; }
.key .st { position: static; display: inline-block; flex: none; }
.key-hint { margin-top: 4px; padding-top: 10px; border-top: 1px solid #34383e; color: var(--muted); }

/* ---------- footer: links only ---------- */
#foot { position: fixed; left: 0; right: 0; bottom: 0; height: var(--bottom); padding: 0 24px; display: flex; align-items: center; gap: 22px; font-size: 12px; color: var(--soft); z-index: 30; background: linear-gradient(rgba(28,30,33,0), var(--bg) 35%); white-space: nowrap; overflow: hidden; }
#foot .city-btn { margin-left: auto; flex: none; width: 34px; height: 34px; display: flex; align-items: center; justify-content: center; color: #c9ced4; }
#foot .city-btn:hover { color: #fff; }
#foot .city-btn + .city-btn { margin-left: -12px; }   /* sit next to the previous footer icon */
#foot .city-btn svg { width: 18px; height: 18px; stroke-width: 1.8; }

/* ---------- hover card ---------- */
.card { display: flex; flex-direction: column; gap: 14px; padding: 20px; background: #25292e; border: 1px solid #4a5058; border-radius: 14px; box-shadow: 0 24px 64px rgba(0,0,0,0.55); color: var(--text); font-size: 12.5px; line-height: 18px; }
#card { position: fixed; left: 0; top: 0; width: 460px; max-height: calc(100vh - 24px); overflow: hidden; z-index: 50; pointer-events: none; display: none; }
#card.show { display: flex; }
#card.clip::after { content: 'Click to pin and scroll for more'; position: sticky; bottom: -20px; margin: -14px -20px -20px; padding: 26px 20px 12px; background: linear-gradient(rgba(37,41,46,0), #25292e 55%); color: var(--muted); font-size: 11px; text-align: center; }
#card.pinned { pointer-events: auto; overflow: auto; border-color: #8a929c; overscroll-behavior: contain; }
#card.pinned::after { display: none; }
#dock { position: absolute; display: none; }
#dock.show { display: block; }
#dock .card { height: 100%; overflow: auto; padding: 24px; }
.cd-head { display: flex; align-items: flex-start; gap: 12px; }
.cd-head .b { min-width: 44px; height: 32px; font-size: 11px; border-radius: 8px; }
.cd-head .flag.lg { margin-top: 4px; }
.cd-tagcol { flex: none; display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
.cd-site-ico { width: 26px; height: 26px; margin-right: 2px; color: var(--onp-t); }
.cd-site-ico svg { width: 100%; height: 100%; stroke-width: 1.8; }
.cd-head .cd-ico { width: 40px; height: 40px; object-fit: contain; flex: none; }
.cd-tt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.cd-title { font-size: 18px; line-height: 24px; font-weight: 800; overflow-wrap: anywhere; }
.cd-sub { font-size: 12px; line-height: 17px; color: var(--muted); }
.cd-tag { flex: none; height: 22px; padding: 0 9px; display: inline-flex; align-items: center; border-radius: 11px; border: 1px solid; font-size: 10px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }
.t-onp { border-color: rgba(110,214,156,0.6); color: var(--onp-t); }
.t-ms  { border-color: rgba(77,180,255,0.6); color: var(--ms-t); }
.t-aws { border-color: rgba(255,159,67,0.6); color: var(--aws-t); }
.t-edge { border-color: rgba(223,227,232,0.5); color: var(--edge-t); }
.cd-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 16px; margin: 0; }
.cd-facts div { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.cd-facts dt, .cd-sec { font-size: 10px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.cd-facts dd { margin: 0; overflow-wrap: anywhere; }
.cd-facts .wide { grid-column: 1 / -1; }
.cd-sec { margin-bottom: -8px; display: flex; justify-content: space-between; gap: 8px; }
.cd-used { margin: 0; color: #d5d9de; }
.cd-tbl { width: 100%; border-collapse: collapse; font-size: 11.5px; line-height: 15px; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.cd-tbl th { text-align: left; background: #2c3137; color: var(--muted); font-weight: 700; padding: 6px 8px; }
.cd-tbl td { padding: 5px 8px; border-top: 1px solid #33383e; vertical-align: top; }
.cd-tbl td.num, .cd-tbl th.num { text-align: right; }
.cd-tbl .mono { white-space: nowrap; }
.cd-tbl .flag { margin-right: 5px; }
.ok { color: var(--onp-t); } .warn { color: var(--warn); } .bad { color: var(--bad); }
.cd-issues { margin: 0; padding: 10px 12px 10px 28px; border-radius: 8px; background: rgba(242,193,78,0.08); border: 1px solid rgba(242,193,78,0.3); color: #f6d98a; }
.cd-issues li + li { margin-top: 3px; }
.cd-list { display: flex; flex-wrap: wrap; gap: 6px; }
.cd-list span { display: inline-flex; align-items: center; gap: 5px; height: 24px; padding: 0 8px; border-radius: 12px; background: #2f343a; font-size: 11.5px; white-space: nowrap; }
.cd-list span b { font-weight: 700; }
.cd-bar { height: 6px; border-radius: 3px; background: #33383e; overflow: hidden; margin-top: 3px; }
.cd-bar i { display: block; height: 100%; background: var(--onp); }
.cd-foot { margin-top: auto; font-size: 11px; color: var(--muted); display: flex; justify-content: space-between; gap: 10px; }
.cd-foot a { color: var(--onp-t); font-weight: 700; }

/* ---------- zoom controls ---------- */
#zoom { position: fixed; right: 12px; top: 50%; transform: translateY(-50%); display: flex; flex-direction: column; gap: 6px; z-index: 40; }
#zoom button { width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; border-radius: 18px; border: 1px solid var(--line); background: rgba(28,30,33,0.9); color: #c9ced4; font: 600 18px Manrope, sans-serif; cursor: pointer; }
#zoom button:hover { color: #fff; border-color: #6a717b; }

.noscript, .load-msg { position: fixed; inset: 0; display: grid; place-items: center; margin: 0; color: var(--muted); }

@media (max-width: 1500px) { .crumbs #crumb span:not(:last-child):not(.sep) { display: none; } }
@media (max-width: 1180px) { #filters button { padding: 0 9px; } .site-nav .pill-btn:not(.round) { display: none; } }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

/* ---------- CV pop-up (same markup and js/cv-modal.js as the city page, topology colours) ---------- */
.cvm { position: fixed; inset: 0; z-index: 200; display: flex; align-items: center; justify-content: center; padding: 24px; background: rgba(12,13,15,.72); backdrop-filter: blur(3px); }
.cvm[hidden] { display: none; }
.cvm__panel { width: min(920px, 100%); height: min(1100px, 100%); display: flex; flex-direction: column; background: #25292e; border: 1px solid #4a5058; border-radius: 16px; overflow: hidden; box-shadow: 0 30px 80px rgba(0,0,0,.55); }
.cvm__bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 12px 12px 12px 20px; border-bottom: 1px solid var(--line); }
.cvm__title { font-weight: 700; font-size: 16px; }
.cvm__title span { margin-left: 8px; font-size: 12px; font-weight: 600; color: var(--muted); }
.cvm__acts { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.cvm__btn { height: 38px; padding: 0 14px 0 12px; display: inline-flex; align-items: center; gap: 7px; border-radius: 999px; border: 1px solid var(--line); background: none; color: var(--text); font: 700 13.5px/1 Manrope, system-ui, sans-serif; text-decoration: none; cursor: pointer; }
.cvm__btn:hover { border-color: #8a929c; color: #fff; }
.cvm__btn--solid { background: var(--text); color: var(--bg); border-color: var(--text); }
.cvm__btn--solid:hover { background: #fff; border-color: #fff; color: var(--bg); }
.cvm__btn svg, .cvm__close svg { width: 16px; height: 16px; }
.cvm__close { width: 38px; height: 38px; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; border: 1px solid var(--line); background: none; color: var(--text); cursor: pointer; margin-left: 4px; }
.cvm__close:hover { border-color: #8a929c; color: #fff; }
.cvm__frame { flex: 1; width: 100%; border: 0; background: #E9ECF3; }
.cvm__note { display: none; margin: 0; padding: 24px 20px 28px; color: var(--soft); font-size: 15px; line-height: 1.5; }
body.cvm-open { overflow: hidden; }
@media (max-width: 760px), (hover: none) and (pointer: coarse) {
  .cvm { padding: 16px; }
  .cvm__panel { height: auto; position: relative; }
  .cvm__frame { display: none; }
  .cvm__note { display: block; }
  .cvm__bar { border-bottom: 0; padding: 16px; }
  .cvm__title { padding-right: 48px; }
  .cvm__close { position: absolute; top: 12px; right: 12px; margin: 0; }
}
