/* ============================================================================
   The Trinity Beast Infrastructure — Shared Mermaid Diagram Styles
   ============================================================================
   Used by all documents that contain Mermaid diagrams.
   Change diagram backgrounds, labels, or spacing here — applies everywhere.
   Document-specific overrides (swim lane colors, edge label tints) stay inline.
   ============================================================================ */

/* Diagram wrapper — soft grey, low glare */
.diagram-wrap {
  background: #2a2f3d;
  border: 1px solid #3d4455;
  border-radius: 10px;
  padding: 1.8rem 1.5rem 1rem;
  margin: 1.2rem 0;
  text-align: center;
  overflow-x: auto;
}

/* Diagram label — uppercase section tag + normal-weight subtitle */
.diagram-label {
  color: #8b95a8;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.3px;
  text-transform: uppercase;
  margin-bottom: 1rem;
  text-align: left;
}

.diagram-label span {
  color: #94a3b8;
  font-weight: 400;
  text-transform: none;
  font-size: 0.82rem;
}

/* Mermaid <pre> reset — transparent on the soft grey wrapper */
.diagram-wrap pre.mermaid {
  background: transparent !important;
  border: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

/* Edge labels — match the wrapper background */
.diagram-wrap .edgeLabel {
  background-color: #2a2f3d !important;
  color: #cbd5e1 !important;
  padding: 2px 6px !important;
  border-radius: 3px !important;
  font-weight: 600 !important;
  font-size: 13px !important;
}

.diagram-wrap .edgeLabel p {
  color: #cbd5e1 !important;
  background: #2a2f3d !important;
}

/* Default text fills for dark-on-grey readability */
.diagram-wrap .label { color: #cbd5e1 !important; }
.diagram-wrap text { fill: #cbd5e1 !important; }
.diagram-wrap .nodeLabel { fill: #ffffff !important; color: #ffffff !important; }
.diagram-wrap .node rect,
.diagram-wrap .node polygon { stroke-width: 2px !important; }
.diagram-wrap .edgePaths path { stroke: #64748b !important; stroke-width: 2px !important; }
