/* The site's WordPress theme owns typography, colors, header and navigation. */
:root {
  --map-frame: #fff;
  --map-surface: #fcfbfd;
  --map-outline: #ccc7d1;
  --map-grid: #d9d4e0;
  --map-coordinate: #6d6676;
  --map-galactic: #303843;
  --map-ecliptic: #b66b0c;
  --field-complete: #087e55;
  --field-followup: #b42d85;
  --field-calibration: #b5771b;
  --field-validation: #a86800;
  --field-preflight: #b44352;
  --field-deferred: #697587;
  --field-queued: #2478b4;
  --field-fill: .07;
  --field-fill-selected: .12;
}
.site-header { background-image: url('/wp-content/uploads/2020/12/cropped-Screen-Shot-2020-12-31-at-9.19.30-AM.png'); }
.site-main { max-width: var(--wide); }
.page-heading { margin-bottom: 1.8rem; }
.eyebrow, .small, button, select, .metrics, .map-caption, .state-legend, .reference-legend, .queue-status { font-family: var(--sans); }
.eyebrow { margin: 0 0 .6rem; font-size: .75rem; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); }
h1 { margin: 0; font-size: clamp(2.1rem, 4vw, 2.9rem); line-height: 1.15; letter-spacing: -.025em; }
h2 { margin: 0; font-size: 1.3rem; line-height: 1.3; }
.small, .muted { color: var(--text-soft); }
.small { font-size: .78rem; line-height: 1.6; }
#snapshot-time { margin: 0; }
.expectation-metrics { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; border-top: 1px solid var(--rule); padding: 1rem 0; font-family: var(--sans); }
.expectation-metrics strong { display: block; font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 500; line-height: 1.3; font-variant-numeric: tabular-nums; }
.metrics { display: flex; gap: clamp(1.5rem, 8vw, 6rem); border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); padding: 1rem 0; margin-bottom: 2.2rem; }
.metrics strong { display: block; font-size: 1.8rem; font-weight: 500; line-height: 1.3; font-variant-numeric: tabular-nums; }
.map-heading, .map-toolbar, .section-heading, .map-caption { display: flex; align-items: center; justify-content: space-between; gap: .75rem; }
.map-heading { margin-bottom: .9rem; }
.map-toolbar { flex-wrap: wrap; margin-bottom: .5rem; }
.regions, .zoom-controls { display: flex; align-items: center; gap: .25rem; flex-wrap: wrap; }
button, select { min-height: 2.75rem; font-size: .78rem; color: var(--text); border: 1px solid var(--rule); border-radius: 3px; background: var(--bg); padding: .4rem .7rem; }
button { cursor: pointer; }
button:hover { border-color: var(--accent); }
button:disabled { opacity: .4; cursor: default; }
button[aria-pressed="true"] { color: var(--accent); background: var(--code-bg); border-color: var(--accent); }
.metric-label { display: block; padding: .25rem 0; border: 0; background: none; text-align: left; font-size: .76rem; line-height: 1.5; color: var(--text-soft); text-decoration: underline dotted; text-underline-offset: .2em; }
.metric-label:hover { color: var(--accent); }
.metric-label:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
#metric-info { box-sizing: border-box; width: min(28rem, calc(100% - 2rem)); max-height: calc(100% - 2rem); padding: 1.5rem; border: 1px solid var(--rule); border-radius: 4px; color: var(--text); background: var(--bg); }
#metric-info::backdrop { background: #0006; }
#metric-info h2 { font-family: var(--sans); font-size: 1rem; font-weight: 500; }
#metric-info p { margin: 1rem 0; line-height: 1.6; }
#metric-info form { text-align: right; }
.zoom-controls button { min-width: 2.75rem; padding: .3rem; font-size: 1.2rem; }
#zoom-level { min-width: 3.3rem; text-align: center; font: .75rem var(--sans); }
.map-frame { position: relative; background: var(--map-frame); border: 1px solid var(--rule); border-radius: 3px; overflow: hidden; }
#sky { display: block; width: 100%; aspect-ratio: 2; cursor: zoom-in; touch-action: none; }
#sky.dragging { cursor: grabbing; }
#sky [data-code] { cursor: pointer; }
#cursor-coordinates { position: absolute; bottom: .4rem; left: .6rem; color: #55595f; background: #ffffffdc; font: .68rem var(--sans); pointer-events: none; }
#field-labels text { font-family: var(--sans); font-weight: 600; paint-order: stroke; stroke: var(--map-surface); stroke-linejoin: round; }
#field-labels .field-depth text { font-weight: 400; }
#coordinates text { font-family: var(--sans); fill: var(--map-coordinate); paint-order: stroke; stroke: var(--map-surface); stroke-linejoin: round; }
.map-caption { align-items: flex-start; font-size: .72rem; color: var(--text-soft); margin: .5rem 0 .8rem; }
.map-caption p { margin: .25rem 0; }
.map-caption button { flex: 0 0 auto; }
.state-legend { display: grid; grid-template-columns: repeat(3, 1fr); gap: .5rem 1.2rem; font-size: .76rem; }
.state-legend span { display: flex; align-items: center; gap: .5rem; }
.state-legend i { width: .65rem; height: .65rem; border: 1.5px solid var(--state-color); background: var(--state-color); flex: 0 0 auto; }
.state-legend .open { background: transparent; }
.state-legend .dashed { background: transparent; border-style: dashed; }
.reference-legend { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1.3rem; margin-top: 1rem; color: var(--text-soft); font-size: .7rem; }
.reference-legend > span { display: inline-flex; align-items: center; gap: .4rem; }
.line { width: 1.25rem; border-top: 1.5px solid; display: inline-block; }
.galactic { color: var(--map-galactic); border-top-style: dashed; }
.ecliptic { color: var(--map-ecliptic); }
.density-ramp { display: inline-block; height: .6rem; width: 4rem; background: linear-gradient(90deg, #fcfbfd, #9e9ac8, #3f007d); }
.lower-grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: 3rem; border-top: 1px solid var(--rule); padding-top: 1.7rem; margin-top: 2rem; }
.lower-grid p { margin: .8rem 0; }
.section-heading { flex-wrap: wrap; }
#field-select { max-width: 100%; }
.field-title { font-size: 1.1rem; margin: 1rem 0 .3rem; }
.field-state { font: .78rem var(--sans); }
.field-meta { font: .78rem/1.7 var(--sans); color: var(--text-soft); }
.sector-list { display: flex; flex-wrap: wrap; gap: .35rem; margin: .6rem 0; }
.sector-list button { min-height: 2.4rem; }
.injections { width: 100%; border-collapse: collapse; font: .78rem var(--sans); margin: .8rem 0; }
.injections th, .injections td { text-align: left; padding: .4rem .5rem .4rem 0; border-bottom: 1px solid var(--rule); }
.injections th { font-weight: 500; color: var(--text-soft); }
.queue-status { font-size: .88rem; font-weight: 500; }
.start-link { display: inline-block; font-family: var(--sans); font-size: .85rem; border-bottom: 1px solid var(--accent); padding: .4rem 0; }
.map-notes { border-top: 1px solid var(--rule); margin-top: 2rem; padding-top: 1rem; color: var(--text-soft); font-size: .84rem; }
.map-notes summary { cursor: pointer; font-family: var(--sans); font-size: .78rem; }
.map-notes p { max-width: 46rem; }
#load-error { border: 1px solid var(--accent); padding: 1rem; margin-bottom: 1rem; }
[hidden] { display: none !important; }
@media (prefers-color-scheme: dark) {
  :root {
    --map-frame: #10141a;
    --map-surface: #191b22;
    --map-outline: #626b7d;
    --map-grid: #3c4352;
    --map-coordinate: #aeb8ca;
    --map-galactic: #c5ccda;
    --map-ecliptic: #edb975;
    --field-complete: #60d7ad;
    --field-followup: #f28bc7;
    --field-calibration: #e8bf75;
    --field-validation: #d5a55d;
    --field-preflight: #f38391;
    --field-deferred: #a0adc0;
    --field-queued: #76b9ee;
    --field-fill: .035;
    --field-fill-selected: .06;
  }
  /* Transform the density image and its legend identically; data and scale stay fixed. */
  #prior-density, .density-ramp { filter: invert(1) hue-rotate(180deg) brightness(.96) contrast(.85); }
  #cursor-coordinates { color: #cad3e0; background: #181d26e8; }
}
@media (max-width: 44rem) {
  .metrics { gap: 1.2rem; justify-content: space-between; }
  .metrics strong { font-size: 1.55rem; }
  .metrics .metric-label { max-width: 6rem; font-size: .72rem; }
  .state-legend { grid-template-columns: repeat(2, 1fr); font-size: .7rem; gap: .5rem; }
  .lower-grid { grid-template-columns: 1fr; gap: 1.8rem; }
  .lower-grid > section + section { border-top: 1px solid var(--rule); padding-top: 1.5rem; }
  .regions { gap: .25rem; }
  .regions button { font-size: .72rem; padding: .4rem .5rem; }
  .map-heading .small { font-size: .68rem; }
}
