/* corpus-paint.css — one meta HUD rail: FAMILY · INDEX(ν+NEAR+doors+nest) · corpus · CLUTCH · MINIMAP */
html[data-paint] { height: 100%; }
html[data-paint] body {
  display: grid !important;
  grid-template-columns: 15.5rem minmax(0, 1fr) 15rem !important;
  grid-template-rows: auto auto minmax(0, 1fr) 6.4rem !important;
  height: 100dvh !important;
  max-height: 100dvh;
  overflow: hidden !important;
  margin: 0 !important;
  padding: 0 !important;
  background: var(--bg, #0a0c0f);
}
html[data-paint] body > script { display: none !important; }
html[data-paint] body > .gaia-nav { grid-column: 1 / -1; grid-row: 1; }

/* family strip — one thin job */
html[data-paint] body > #sn-self-sort {
  grid-column: 1 / -1; grid-row: 2;
  display: flex !important; flex-wrap: nowrap !important;
  align-items: center; gap: 6px;
  overflow-x: auto; overflow-y: hidden;
  max-height: 2.4rem; padding: 4px 10px;
  border-bottom: 1px solid var(--border, #1e2228);
  background: var(--bg-raised, #0f1114);
  white-space: nowrap;
}
html[data-paint] #sn-self-sort > b {
  color: #f87171; letter-spacing: .08em; font-size: 10px; margin-right: 4px; flex: 0 0 auto;
}
html[data-paint] #sn-self-sort a,
html[data-paint] #sn-self-sort .grx-vbtn {
  display: inline-flex; align-items: center;
  padding: 2px 8px; margin: 0;
  border: 1px solid #2dd4bf44; border-radius: 999px;
  background: transparent; color: #9bb7c9;
  font: 10px/1.2 ui-monospace, monospace; text-decoration: none; flex: 0 0 auto;
}
html[data-paint] #sn-self-sort a.hot,
html[data-paint] #sn-self-sort[data-triad='public'] a.hot {
  border-color: #f8717188; color: #fca5a5;
}

/* LEFT meta rail — one composition */
html[data-paint] body > #sn-index {
  grid-column: 1; grid-row: 3;
  display: flex; flex-direction: column; gap: .55rem;
  overflow: auto; min-width: 0; min-height: 0;
  margin: 0; padding: .55rem .65rem .8rem;
  border: 0; border-right: 1px solid var(--border, #1e2228);
  border-radius: 0; position: static; top: auto; max-height: none;
  background: #070b10;
  font: 11px/1.35 ui-monospace, monospace;
}
html[data-paint] #sn-index > b {
  display: block; margin: 0; padding: 0 0 .2rem;
  color: #86efac; letter-spacing: .1em; font-size: 10px;
  border-bottom: 1px solid #1e293b;
}
html[data-paint] #sn-index #ν-pass { order: 1; flex: 0 0 auto; }
html[data-paint] #sn-index #sn-bard { order: 2; flex: 0 0 auto; }
html[data-paint] #sn-index #sn-bard b {
  display: block; color: #7dd3fc; letter-spacing: .08em; font-size: 10px; margin: 0 0 .25rem;
}
html[data-paint] #sn-index #sn-bard a,
html[data-paint] #sn-index #sn-catalog a,
html[data-paint] #sn-index #sn-nest a,
html[data-paint] #sn-index a.grx-vbtn {
  display: block; padding: .28rem 0;
  border-bottom: 1px solid #141a22; color: #c8d0d8;
  text-decoration: none; background: transparent; border-radius: 0; margin: 0;
}
html[data-paint] #sn-index a:hover { color: #fde047; }
html[data-paint] #sn-index #sn-catalog { order: 3; flex: 0 1 auto; min-height: 0; }
html[data-paint] #sn-index #sn-catalog:empty { display: none; }
html[data-paint] #sn-index #sn-bard:has(p.muted):not(:has(a)) { display: none; }
html[data-paint] #sn-index #sn-nest { order: 4; flex: 1 1 auto; min-height: 0; }
html[data-paint] #sn-index #sn-nest::before {
  content: 'DOORS'; display: block; color: #94a3b8; letter-spacing: .08em;
  font-size: 10px; margin: .4rem 0 .2rem;
}
/* collapse secondary facet dumps — one job for the rail */
html[data-paint] #sn-index #sn-epitope,
html[data-paint] #sn-index #sn-cogen-facets,
html[data-paint] #sn-index #sn-family { display: none !important; }
html[data-paint] body > #ν-pass,
html[data-paint] body > #outer-heart,
html[data-paint] body > #biome-heart { display: none !important; }
/* stabilize INDEX: one DOORS list — no folder grid / desk dump */
html[data-paint] #sn-index .phi-cluster,
html[data-paint] #sn-index #sn-detroit-triad,
html[data-paint] #sn-index #sn-detroit-lib,
html[data-paint] #sn-index #sn-detroit-faces { display: none !important; }

html[data-paint] body > #sn-corpus {
  grid-column: 2; grid-row: 3;
  overflow: auto; min-width: 0; min-height: 0;
  border-left: 0; border-right: 1px solid var(--border, #1e2228);
}
html[data-paint] body > main.gaia-shell {
  grid-column: 1 / -1; grid-row: 3;
  min-height: 0; overflow: hidden; height: 100%; margin: 0; padding: .382rem; border-radius: 0;
}
html[data-paint] body > #sn-clutch-pane {
  grid-column: 3; grid-row: 3;
  overflow: auto; min-width: 0; min-height: 0; height: auto;
  margin: 0; padding: .55rem .65rem; border-radius: 0; position: static; top: auto; max-height: none;
  border: 0; border-left: 0; background: #070b10;
}
html[data-paint] body > #sn-bottom {
  grid-column: 1 / -1; grid-row: 4;
  display: grid; grid-template-columns: 5.5rem minmax(0, 1fr) auto;
  gap: .45rem; align-items: stretch;
  padding: .25rem .55rem; border-top: 1px solid #7a5f3e66;
  background: var(--bg-raised, #0f1114); min-height: 0; overflow: hidden;
}
html[data-paint] #sn-bottom > b { color: #d4a574; letter-spacing: .08em; font-size: .7rem; align-self: center; }
html[data-paint] #sn-bottom #sn-bring {
  width: 100%; height: 5.5rem; background: #02060e;
  border: 1px solid #7a5f3e66; border-radius: 6px; cursor: crosshair; display: block;
}
html[data-paint] #sn-bottom p { margin: 0; align-self: center; font-size: 10px; }
html[data-paint] #sn-corpus[data-self] { outline: 0; }
html[data-paint] #sn-clutch-pane[data-self='unject'] .investigation-game { font-size: .72rem; }
html[data-paint] #sn-clutch-pane #investigation-canvas,
html[data-paint] #sn-clutch-pane #game-canvas { width: 100% !important; max-height: 12rem; height: 12rem !important; }

@media (max-width: 900px) {
  html[data-paint] body { display: flex !important; flex-direction: column; height: auto !important; overflow: auto !important; }
  html[data-paint] body > #sn-index, html[data-paint] body > #sn-clutch-pane { max-height: 32vh; }
}
