/* Median Income -- what's specific to the four-point dollar chart.
   Everything else (panel, lines, highlight casing, chips, legend) reuses
   similar-counties.css and unemployment-experiment.css as-is. */

.mi-chart svg{
  height:520px;
}

.mi-chart{
  position:relative;
}

/* Custom hover label, positioned in real screen pixels (relative to .mi-chart
   itself) from the triggering mouse event -- not tied to the SVG's own
   viewBox/scale. Same look as the clickable map's own working hover label
   (.ue-jobs-map-hover-label in similar-counties.css). Native SVG <title>
   tooltips were tried first and dropped: unreliable in practice, especially
   with points this densely clustered. */
.mi-chart-hover-label{
  position:absolute;
  z-index:2;
  transform:translate(-50%, calc(-100% - 12px));
  padding:5px 9px;
  border-radius:3px;
  background:#123a2a;
  color:#fff;
  font-size:11px;
  font-weight:800;
  white-space:nowrap;
  pointer-events:none;
}

/* Dots are zero-length round-capped paths with non-scaling strokes so they
   stay circular even though the chart SVG uses preserveAspectRatio=none. */
.mi-chart path.mi-dot{
  fill:none;
  stroke-linecap:round;
  vector-effect:non-scaling-stroke;
  stroke-width:9;
}

.mi-chart path.mi-dot-casing{
  stroke:#123e2f;
  stroke-width:13;
}

.mi-chart path.mi-dot-reference{
  stroke:#c0392b;
  stroke-width:8;
}

/* Small markers for the unhighlighted Upstate County lines -- same muted
   green and opacity as .overlay-county-line (unemployment-experiment.css)
   itself, so each line's four points read without competing with the
   reference or highlighted lines. */
.mi-chart path.mi-dot-county{
  stroke:var(--sc-green, #34563e);
  stroke-width:5;
  opacity:.22;
}

/* Invisible, much wider hit target sitting on top of each mi-dot-county --
   the visible dot is only 5 units wide, too small to reliably hover with
   the Upstate Counties' points clustered together, so this carries the
   <title> instead and does the actual mouse hit-testing. A filled circle,
   not a non-scaling-stroke path: this chart's x/y scale isn't uniform
   (preserveAspectRatio="none"), which non-scaling-stroke handles poorly. */
.mi-chart circle.mi-dot-hit-target{
  fill:transparent;
  pointer-events:all;
}

/* Hover state, set by mapHoveredCounty (driven by hovering the clickable
   map, not the chart itself): the muted background line (opacity .22 from
   unemployment-experiment.css) becomes fully readable, on top of the other
   54 without needing to be reordered in the DOM. */
.mi-chart path.overlay-county-line-hovered{
  stroke:#123e2f;
  stroke-width:2.2;
  opacity:.9;
}

.mi-chart path.mi-dot-county-hovered{
  stroke:#123e2f;
  stroke-width:9;
  opacity:.9;
}

/* Dropdown + chips on the left, clickable NY county map on the right (same
   arrangement as the Unemployment page's top row); wraps below on narrow
   screens. Counties without income data render muted and inactive. */
.mi-selector-row{
  display:flex;
  flex-wrap:wrap;
  align-items:flex-start;
  justify-content:flex-start;
  gap:32px;
}

/* Dropdown, then map stacked directly under it, both flush to the far
   left; the tiles group (a separate flex item in .mi-selector-row) sits to
   their right and drops to a new line if there isn't room. */
.mi-dropdown-map-pair{
  display:flex;
  flex-direction:column;
  align-items:flex-start;
  gap:16px;
}

.mi-selector-row .ue-experiment-highlight{
  flex:none;
  width:340px;
  max-width:100%;
}

/* Map sits directly under the dropdown now, so it needs no top offset of
   its own -- the title's usual tall top padding is still dropped. */
.mi-selector-row .ue-top-row-map{
  margin-top:0;
}

.mi-selector-row .ue-jobs-map-title{
  height:auto;
  padding:0 0 4px;
  line-height:1.3;
}

/* Small italic map title, paired with the "Clear map" control on the same
   row -- the dropdown's own "Clear selections" was dropped as redundant,
   since both cleared the same shared highlight state. */
.mi-map-title-row{
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap:12px;
}

.mi-map-title{
  font-size:12px;
  font-weight:700;
  font-style:italic;
  text-align:left;
}

.mi-map-clear{
  border:0;
  background:none;
  padding:0;
  color:var(--sc-blue);
  font:600 12px/1.3 var(--font-body);
  text-decoration:underline;
  cursor:pointer;
}

.mi-map-clear:disabled{
  color:var(--sc-muted, #5d6b60);
  text-decoration:none;
  cursor:default;
}

.ue-jobs-map g.mi-map-nodata{
  cursor:default;
}

.ue-jobs-map g.mi-map-nodata path{
  fill:#eef2ef;
  stroke:#b9c6bd;
  stroke-width:.4;
}

/* Hard X and Y axis lines. The chart's axis <line>s carry no stroke style of
   their own (only .grid lines do), so they were invisible; a solid dark
   stroke, fixed in screen pixels because the SVG is stretched
   (preserveAspectRatio=none). Both charts share this component. */
.mi-chart svg line:not(.grid){
  stroke:#123e2f;
  stroke-width:1.6;
  vector-effect:non-scaling-stroke;
  shape-rendering:crispEdges;
}

/* Annual chart (19 points per county): smaller dots than the four-point
   charts so the reference line and highlighted counties don't turn into
   beads. */
.mi-chart-dense path.mi-dot{
  stroke-width:5;
}

.mi-chart-dense path.mi-dot-casing{
  stroke-width:8;
}

.mi-chart-dense path.mi-dot-reference{
  stroke-width:4;
}

/* Anchor + Comparison tiles (CountyTiles.tsx): the anchor tile on the left,
   one card per highlighted county to its right, reusing the Unemployment
   page's label/value rows (.ue-anchor-stack). Sits below the first chart,
   not in .mi-selector-row. */
.mi-tiles{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  align-items:stretch;
  margin-top:12px;
}

.mi-tile-panel{
  margin-top:0;
  display:flex;
  flex-direction:column;
  border:1px solid var(--sc-line, #bdcbbf);
  background:var(--page-bg); /* same light green as the page background (app/globals.css html,body) */
}

.mi-anchor{
  flex:none;
  width:280px;
  max-width:100%;
}

.mi-comparison{
  flex:1;
  min-width:280px;
}

.mi-tile-title{
  margin:0;
  padding:12px 16px 10px;
  color:var(--title-navy, #1f3a63);
  font:700 15px/1.2 var(--font-title, var(--font-body));
  text-transform:uppercase;
}

.mi-card-strip{
  display:flex;
  flex:1;
  align-items:stretch;
}

.mi-card{
  flex:1;
  min-width:0;
  max-width:260px;
  border-right:1px solid var(--sc-line, #bdcbbf);
  padding-bottom:6px;
}

.mi-card:last-child{
  border-right:0;
}

.mi-card-empty{
  margin:0;
  padding:12px 16px;
  color:var(--sc-muted, #5d6b60);
  font:400 13px/1.3 var(--font-body);
}

.mi-card-title{
  margin:0;
  padding:4px 16px 8px;
  display:flex;
  align-items:center;
  gap:8px;
  color:var(--forest, #1f5138);
  font:700 13px/1.3 var(--font-body);
}

.mi-card-title i{
  flex:none;
  width:12px;
  height:12px;
  border-radius:50%;
  box-shadow:0 0 0 1px #123e2f;
}
/* Click a county line on any graph to select it (2026-10-11): wide invisible copies of the lines take the click. */
.mi-chart path.mi-line-hit-target{fill:none;stroke:transparent;stroke-width:12;vector-effect:non-scaling-stroke;pointer-events:stroke;cursor:pointer}
.mi-chart circle.mi-dot-hit-target{cursor:pointer}
.mi-chart g.mi-highlight-clickable{cursor:pointer}
/* Title like Median Household Income by County (Robert, 2026-11-07). */
.sc-page h1.ue-page-title.mi-title{text-transform:none;font-size:36px;font-weight:700;letter-spacing:normal}
