/* Ekalix Radar - the estate at a glance (CONTRACT-V30 P5).   web\estatemap.css, with estatemap.js

   The material is the chart kit's (chartkit.css): ONE light from the top left, and it is cheap to draw the first
   time - no filter, no blurred or inset shadow, no radial gradient, no gradient of more than two stops anywhere in
   this file. A sphere is its colour under a two-stop light with a point of light on it; a glow is two wider,
   fainter discs; a luminous link is the line over two wider, fainter copies of itself.

   Movement (transform and opacity only, each once, none endless): the arrival, an answer to the pointer, a live
   ring's one beat per reading and an incident's ripple along its links. `.em-still` (Animation: Off, or the system's
   reduced motion while the setting is Auto) stills every one of them and loses nothing: the links stay lit, the
   touched systems keep their ring, the words are the same.

   Classes em-*; colours are the theme's own tokens and the .t-<tone> classes (--tone), so every theme follows. */
.em { --em-field: color-mix(in srgb, var(--bg) 70%, #02050c); --em-orbit: color-mix(in srgb, var(--text) 13%, transparent);
  --em-orbit-near: color-mix(in srgb, var(--text) 30%, transparent); --em-sun: color-mix(in srgb, var(--accent) 34%, #fff);
  --em-plate: color-mix(in srgb, var(--surface-1) 90%, transparent); --em-star: #fff;
  display: flex; flex-direction: column; gap: 10px; min-width: 0; position: relative; }
:root[data-theme="daylight"] .em { --em-field: #eef2f8; --em-orbit: rgba(24, 44, 76, .13); --em-orbit-near: rgba(24, 44, 76, .34);
  --em-sun: color-mix(in srgb, var(--accent) 62%, #fff); --em-plate: rgba(255, 255, 255, .93); --em-star: #51627c; }

/* ---- the head: the verdict first, the tools beside it ---- */
.em-head { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px 18px; align-items: start; }
.em-verdict { min-width: 0; }
.em-eye { display: flex; align-items: center; gap: 7px; font: 700 11px/1 var(--font); letter-spacing: .14em; text-transform: uppercase; color: var(--tone); }
.em-verdict.calm .em-eye { color: var(--ok); }
.em-eyeg { font-size: 12px; letter-spacing: 0; }
.em-livetag { display: inline-flex; align-items: center; gap: 5px; margin-left: 4px; padding: 2px 7px 2px 5px; border: 1px solid var(--tone); border-radius: 9px; letter-spacing: .08em; font-size: 10px; }
.em .em-h, :root[data-ekx-template] .em h2.em-h { margin: 6px 0 3px; font: 700 clamp(19px, 2.1vw, 26px)/1.15 var(--font); letter-spacing: .005em; color: var(--text); overflow-wrap: anywhere; }
.em-state { display: inline-block; margin-left: 10px; padding: 2px 8px; border-radius: 4px; background: var(--tone); color: var(--bg); font: 700 11px/1.4 var(--font); letter-spacing: .08em; text-transform: uppercase; vertical-align: middle; }
:root[data-theme="daylight"] .em-state { color: #fff; }
.em-w { margin: 0; font-size: 14px; line-height: 1.4; color: var(--text); max-width: 70ch; }
.em-where { color: var(--text-3); }
.em-act { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin-top: 9px; }
.em .em-go { box-shadow: none; }
.em-blastw { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; color: var(--tone); }
.em-blasti { width: 11px; height: 11px; border-radius: 50%; border: 2px solid var(--tone); position: relative; }
.em-blasti::after { content: ''; position: absolute; inset: -5px; border-radius: 50%; border: 1px solid var(--tone); opacity: .45; }
.em-then { font-size: 12.5px; color: var(--text-3); }
.em-tools { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 6px 8px; max-width: 300px; }
.em-qin { position: absolute; right: 8px; top: 8px; z-index: 300; }
.em-qrow { display: flex; justify-content: flex-end; }
.em-q { width: 190px; max-width: 100%; height: 28px; padding: 0 9px; border: 1px solid var(--border-2); border-radius: 6px; background: var(--em-plate); color: var(--text); font: inherit; font-size: 12.5px; }
.em-tools kbd, .em-keys kbd { display: inline-block; margin-left: 5px; padding: 0 4px; border: 1px solid var(--border-2); border-radius: 3px; font: 600 10px/1.5 var(--mono); color: var(--text-3); }
.em-3dw { display: inline-flex; flex-wrap: wrap; justify-content: flex-end; align-items: center; gap: 4px 6px; }
.em-sw { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 9px 0 6px; border: 1px solid var(--border-2); border-radius: 14px; background: var(--surface-1); color: var(--text-2); font: 600 12px/1 var(--font); cursor: pointer; }
.em-swk { position: relative; width: 24px; height: 14px; border-radius: 7px; background: var(--border-2); }
.em-swk::after { content: ''; position: absolute; left: 2px; top: 2px; width: 10px; height: 10px; border-radius: 50%; background: var(--text-3); transition: transform .12s ease-out; }
.em-sw.on { color: var(--text); border-color: var(--accent); }
.em-sw.on .em-swk { background: color-mix(in srgb, var(--accent) 45%, transparent); }
.em-sw.on .em-swk::after { transform: translateX(10px); background: var(--accent); }
.em-sw:focus-visible, .em-chip:focus-visible, .em-rowb:focus-visible, .em-more:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.em-3dwhy { font-size: 11px; color: var(--text-3); white-space: nowrap; }
.em[data-3d="fallback"] .em-3dwhy { color: var(--warning); }

/* ---- the counts: systems by state (these are the picture's colours), each a filter ---- */
.em-chips { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 12px; }
.em-chl { color: var(--text-2); font-weight: 600; margin-right: 2px; }
.em-chl.q { color: var(--text-3); font-weight: 400; margin-left: 6px; }
.em-chip { display: inline-flex; align-items: center; gap: 5px; height: 24px; padding: 0 9px; border: 1px solid var(--hairline); border-radius: 12px; background: var(--surface-1); color: var(--text-2); font: inherit; font-size: 12px; cursor: pointer; }
.em-chip i { font-style: normal; color: var(--tone); font-size: 11px; }
.em-chip b { color: var(--text); font-variant-numeric: tabular-nums; }
.em-chip.on { border-color: var(--tone, var(--accent)); background: color-mix(in srgb, var(--tone, var(--accent)) 14%, var(--surface-1)); color: var(--text); }
.em-chip.live { --tone: var(--text); }
.em-ringk { display: inline-block; width: 9px; height: 9px; border-radius: 50%; border: 1.5px solid var(--text-2); }
.em-held { margin-left: 6px; color: var(--text-2); }

/* ---- the stage: a deep field, the orbits, the suns, the links ---- */
.em-stage { position: relative; overflow: hidden; border: 1px solid var(--hairline); border-radius: 10px; background: var(--em-field); isolation: isolate; }
.em-sky { position: absolute; left: 0; top: 0; display: block; }
.em-stars circle { fill: var(--em-star); }
.em-orbit { fill: none; stroke: var(--em-orbit); stroke-width: 1; }
.em-orbit.near { stroke: var(--em-orbit-near); }
.em-sung { fill: var(--em-sun); }
.em-sung.g1 { opacity: .17; } .em-sung.g2 { opacity: .085; } .em-sung.g3 { opacity: .04; }
.em-sun { fill: var(--em-sun); }
.em-sunp { fill: #fff; opacity: .85; }
.em-link .l { stroke: color-mix(in srgb, var(--accent) 55%, transparent); stroke-width: 1.1; }
.em-link.host .l { stroke-dasharray: 2 4; stroke: color-mix(in srgb, var(--text) 34%, transparent); }
.em-link.hot .l { stroke: var(--tone-hot, var(--serious)); stroke-width: 1.6; stroke-dasharray: none; }
.em-link.hot .g1 { stroke: var(--tone-hot, var(--serious)); stroke-width: 5; opacity: .2; }
.em-link.hot .g2 { stroke: var(--tone-hot, var(--serious)); stroke-width: 10; opacity: .08; }
.em-lead { stroke: var(--text-2); stroke-width: 1; }

/* ---- a system: a body (a lit sphere), its rings, its label ---- */
.em-nodes, .em-plates, .em-fx { position: absolute; inset: 0; }
.em-plates, .em-fx { pointer-events: none; }
.em-n { position: absolute; width: 0; height: 0; }
.em-n > .em-b, .em-n > .em-ret, .em-n > .em-glow, .em-n > .em-livering, .em-n > .em-hit, .em-n > .em-rip { position: absolute; left: 0; top: 0; transform: translate(-50%, -50%); border-radius: 50%; }
.em-b { padding: 0; border: 0; cursor: pointer; background-color: var(--tone);
  background-image: linear-gradient(135deg, rgba(255, 255, 255, .46), rgba(0, 0, 0, .3)); display: grid; place-items: center; }
.em-b::after { content: ''; position: absolute; left: 20%; top: 16%; width: 26%; height: 26%; border-radius: 50%; background: rgba(255, 255, 255, .8); }
:root[data-theme="daylight"] .em-b { background-color: color-mix(in srgb, var(--tone) 60%, #fff); background-image: linear-gradient(135deg, rgba(255, 255, 255, .6), rgba(10, 30, 60, .16)); }
:root[data-theme="daylight"] .em-glow .g1 { opacity: .2; } :root[data-theme="daylight"] .em-glow .g2 { opacity: .08; }
.em-b.t-ok { opacity: .92; }
.em-b.unk { background-color: transparent; background-image: none; border: 1.5px dashed var(--text-3); }
.em-b.unk::after, .em-b.unreach::after { display: none; }
.em-b.unreach { background-color: transparent; background-image: none; border: 2px dashed var(--critical); }
.em-gy { position: relative; z-index: 1; font: 700 9px/1 var(--font); font-style: normal; color: #fff; }
.em-b.t-warning .em-gy { color: #1c1400; }
.em-b.unk .em-gy { color: var(--text-3); } .em-b.unreach .em-gy { color: var(--critical); }
.em-b:focus-visible { outline: 2px solid var(--text); outline-offset: 3px; }
.em-n.off { opacity: .16; }
.em-n.off .em-b { cursor: default; }
/* what needs someone glows in its own colour: two wider, fainter discs behind it */
.em-glow { z-index: -1; }
.em-glow i { position: absolute; border-radius: 50%; background: var(--tone); }
.em-glow .g1 { inset: -4px; opacity: .3; } .em-glow .g2 { inset: -9px; opacity: .12; }
/* a problem the Sentinel has open now: a ring in ITS colour round a body that keeps the collection's */
.em-livering { border: 2px solid var(--tone); }
.em-livering::after { content: ''; position: absolute; right: -3px; top: -3px; width: 7px; height: 7px; border-radius: 50%; background: var(--tone); border: 1.5px solid var(--em-field); }
/* a system an open problem touches */
.em-hit { border: 1.5px solid var(--tone); opacity: .9; }
/* the worst one: a fine bracket round it, and its plate */
.em-ret { border: 1.5px solid transparent; border-left-color: var(--text); border-right-color: var(--text); opacity: .85; }
.em-lab { position: absolute; box-sizing: border-box; padding: 2px 6px; border: 1px solid var(--hairline); border-left: 2px solid var(--tone, var(--border-2)); border-radius: 3px; background: var(--em-plate);
  font: 500 11px/13px var(--font); color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; pointer-events: none; }
.em-lab b { font-weight: 600; color: var(--text); }
.em-lab.big { padding: 3px 8px; border-color: var(--tone); }
.em-lab.big b { display: block; font-size: 12.5px; line-height: 14px; overflow: hidden; text-overflow: ellipsis; }
.em-lab.big span { display: block; font: 700 10px/12px var(--font); letter-spacing: .08em; text-transform: uppercase; color: var(--tone); }
.em-lump { background-color: color-mix(in srgb, var(--tone) 22%, var(--em-field)); background-image: none; border: 1px solid color-mix(in srgb, var(--tone) 70%, transparent); }
.em-lump::after { display: none; }
.em-ln { font: 700 10.5px/1 var(--mono); color: var(--text); }
.em-lump.off { opacity: .3; }
.em-plate { position: absolute; box-sizing: border-box; text-align: center; white-space: nowrap; overflow: hidden; }
.em-plate b { display: block; font: 700 12px/15px var(--font); letter-spacing: .12em; text-transform: uppercase; color: var(--text); overflow: hidden; text-overflow: ellipsis; }
.em-plate span { display: block; font: 500 10.5px/14px var(--font); color: var(--text-3); overflow: hidden; text-overflow: ellipsis; }
.em-plate.need span { color: var(--text-2); }

/* ---- pointed at: the system's verdict ---- */
.em-tipw { position: absolute; left: 16px; top: 12px; z-index: 5; pointer-events: none; }
.em-tipw.l { left: auto; right: 16px; } .em-tipw.u { top: auto; bottom: 12px; }
.em-tip { display: flex; flex-direction: column; gap: 3px; width: max-content; max-width: 320px; padding: 8px 10px; border: 1px solid var(--border-2); border-left: 3px solid var(--tone); border-radius: 6px; background: var(--surface-1); color: var(--text-2); font-size: 12px; line-height: 1.35; text-align: left; white-space: normal; }
.em-tip b { font-size: 13px; color: var(--text); }
.em-tipm { color: var(--text-3); font-size: 11px; }
.em-tips { color: var(--text); } .em-tips i { font-style: normal; color: var(--tone); }
.em-tipl { display: flex; align-items: baseline; gap: 5px; color: var(--text); font-weight: 600; }
.em-tipl .ck-bead { flex: none; align-self: center; }
.em-tipb { color: var(--text-2); }

/* ---- the table: the same systems in the same order ---- */
.em-tablew { max-height: 520px; overflow: auto; border: 1px solid var(--hairline); border-radius: 10px; background: var(--surface-1); }
.em-table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.em-table th, .em-table td { padding: 6px 10px; text-align: left; border-bottom: 1px solid var(--hairline); white-space: nowrap; color: var(--text-2); font-weight: 400; }
.em-table thead th { position: sticky; top: 0; z-index: 1; background: var(--surface-2); font: 600 11px/1.3 var(--font); letter-spacing: .06em; text-transform: uppercase; color: var(--text-3); }
.em-table .r { text-align: right; }
.em-table tr.need th .em-rowb { font-weight: 700; }
.em-rowb { padding: 0; border: 0; background: none; color: var(--text); font: inherit; font-weight: 500; cursor: pointer; text-align: left; }
.em-rowb:hover { text-decoration: underline; }
.em-st { display: inline-flex; align-items: center; gap: 5px; color: var(--tone); font-weight: 600; }
.em-st i { font-style: normal; font-size: 11px; }
.em-what { max-width: 360px; overflow: hidden; text-overflow: ellipsis; color: var(--text); }
.em-more { display: block; width: 100%; padding: 9px; border: 0; background: none; color: var(--accent); font: inherit; font-size: 12.5px; cursor: pointer; }
.em-none { padding: 18px; text-align: center; color: var(--text-3); }

/* ---- the foot: what the picture's marks mean, in words ---- */
.em-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 16px; font-size: 11px; color: var(--text-3); }
.em-key { display: inline-flex; align-items: center; gap: 4px; }
.em-kb { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--tone, var(--text-3)); }
.em-kb.s1 { width: 11px; height: 11px; } .em-kb.s2 { width: 8px; height: 8px; } .em-kb.s3 { width: 6px; height: 6px; }
.em-kl { display: inline-block; width: 16px; height: 0; border-top: 1.5px solid color-mix(in srgb, var(--accent) 60%, transparent); }
.em-blastl { flex: 1 1 100%; order: -1; font-size: 12px; color: var(--text-2); }
.em-by { display: inline-flex; align-items: center; gap: 6px; margin-left: auto; }
.em-keys { }
.em-blastl b { color: var(--text); font-weight: 600; }
.em-keys kbd { margin: 0 3px 0 8px; }

/* ---- movement: each once, transform and opacity only ---- */
@keyframes emFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes emLand { from { opacity: 0; transform: translate(-50%, -50%) scale(2.3); } to { opacity: .85; transform: translate(-50%, -50%) scale(1); } }
@keyframes emRip { from { opacity: .75; transform: translate(-50%, -50%) scale(1); } to { opacity: 0; transform: translate(-50%, -50%) scale(5.2); } }
@keyframes emBeat { 0% { transform: translate(-50%, -50%) scale(1); } 35% { transform: translate(-50%, -50%) scale(1.32); } 100% { transform: translate(-50%, -50%) scale(1); } }
@keyframes emHit { 0%, 55% { opacity: 0; transform: translate(-50%, -50%) scale(1.9); } 100% { opacity: .9; transform: translate(-50%, -50%) scale(1); } }
@keyframes emGo { 0% { opacity: 0; transform: translate(var(--x0), var(--y0)); } 12% { opacity: 1; } 88% { opacity: 1; } 100% { opacity: 0; transform: translate(var(--x1), var(--y1)); } }
.em-arrive .em-sky { animation: emFade .35s ease-out both; }
.em-arrive .em-nodes, .em-arrive .em-plates { animation: emFade .35s ease-out both .12s; }
.em-arrive .em-ret { animation: emLand .5s cubic-bezier(.2, .7, .2, 1) both .4s; }
.em-rip { border: 2px solid var(--tone); opacity: 0; animation: emRip 1.15s cubic-bezier(.2, .6, .3, 1) both .15s; }
.em-hit { animation: emHit 1.25s ease-out both; }
.em-livering { animation: emBeat .7s ease-out both; }
.em-pkt { position: absolute; left: -4px; top: -4px; width: 8px; height: 8px; border-radius: 50%; background: var(--tone); opacity: 0; animation: emGo .85s cubic-bezier(.4, 0, .4, 1) both; animation-delay: calc(.2s + var(--d, 0ms)); }
.em-pkt::after { content: ''; position: absolute; inset: -4px; border-radius: 50%; background: var(--tone); opacity: .25; }
.em-still .em-sky, .em-still .em-nodes, .em-still .em-plates, .em-still .em-ret, .em-still .em-hit, .em-still .em-livering { animation: none; }
.em-still .em-rip, .em-still .em-pkt { display: none; }
.em-still .em-swk::after { transition: none; }
/* without a graphics card every frame is drawn on the CPU: the live ring rests there, as the overview's mark does */
:root[data-gfx="soft"]:not([data-motion-pref="full"]) .em-livering { animation: none; }

/* ---- the 3D layer over the picture (estate3d.js): the same layout in depth; the bodies stay the page's buttons ---- */
.em-gl { position: absolute; inset: 0; width: 100%; height: 100%; display: block; opacity: 0; transition: opacity .5s ease-out; }
@media screen {
  .em-3d .em-gl { opacity: 1; }
  .em-3d .em-stage { --em-field: #03060d; --em-plate: rgba(8, 14, 26, .82); background: #03060d; }
  .em-3d .em-sky, .em-3d .em-fx { opacity: 0; }
  .em-3d .em-b { background: none; opacity: 1; border-color: transparent; }
  .em-3d .em-b::after, .em-3d .em-gy, .em-3d .em-glow, .em-3d .em-rip, .em-3d .em-hit, .em-3d .em-livering { display: none; }
  .em-3d .em-lump { border-color: transparent; }
  .em-3d .em-ln { color: #fff; }
  .em-3d .em-ret { border-left-color: #fff; border-right-color: #fff; }
  .em-3d .em-lab { color: #c9d4e6; border-color: rgba(255, 255, 255, .16); border-left-color: var(--tone, rgba(255, 255, 255, .3)); }
  .em-3d .em-lab b { color: #fff; }
  .em-3d .em-plate b { color: #f2f5fb; } .em-3d .em-plate span { color: #9fb0c8; }
  .em-3d .em-b:focus-visible { outline-color: #fff; }
}

/* ---- narrower: the tools under the verdict; a phone ---- */
@media (max-width: 900px) { .em-head { grid-template-columns: minmax(0, 1fr); } .em-tools { justify-content: flex-start; max-width: none; } }
.ccmap.em-host { background: var(--surface-1); padding: 14px; }
@media (max-width: 560px) { .em-qin { position: static; padding: 8px 8px 0; } .em-q { width: 100%; } .em-by { margin-left: 0; } .em-keys { display: none; } .em-table th:nth-child(5), .em-table td:nth-child(5), .em-table th:nth-child(9), .em-table td:nth-child(9) { display: none; } }

/* ---- print and export: the complete 2D picture ---- */
@media print {
  .em-gl { display: none !important; }
  .em-tools, .em-keys { display: none; }
  .em-stage { background: #fff; }
  .em * { animation: none !important; }
}
