/* Keep Mermaid rank/subgraph containers light enough for their labels to read clearly. */
svg.mermaid-js .cluster rect {
  fill: #f8fafc !important;
  stroke: #94a3b8 !important;
}

svg.mermaid-js .cluster-label text,
svg.mermaid-js .cluster-label span {
  fill: #334155 !important;
  color: #334155 !important;
}

.pp-single-batch-timeline {
  margin: 0.75rem 0 1.5rem;
  color: var(--bs-body-color, #212529);
}

.pp-single-batch-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  align-items: center;
  margin-bottom: 0.55rem;
  font-size: 0.84rem;
  color: var(--bs-secondary-color, #5c636a);
}

.pp-single-batch-mark {
  display: inline-block;
  width: 0.8rem;
  height: 0.8rem;
  margin-right: 0.25rem;
  border-radius: 0.18rem;
  vertical-align: -0.08rem;
}

.pp-single-batch-mark.forward,
.pp-single-batch-operation.forward {
  background: #1971c2;
}

.pp-single-batch-mark.backward,
.pp-single-batch-operation.backward {
  background: #2b8a3e;
}

.pp-single-batch-mark.wait,
.pp-single-batch-lane {
  background: var(--bs-tertiary-bg, #f1f3f5);
  border: 1px solid var(--bs-border-color, #dee2e6);
}

.pp-single-batch-scroll {
  overflow-x: auto;
  padding-bottom: 0.35rem;
}

.pp-single-batch-grid {
  display: grid;
  grid-template-columns: 5.4rem repeat(12, minmax(2.55rem, 1fr));
  grid-template-rows: auto repeat(4, 3.05rem);
  gap: 0.3rem;
  min-width: 48rem;
  align-items: stretch;
}

.pp-single-batch-time {
  align-self: end;
  padding-bottom: 0.1rem;
  text-align: center;
  font-size: 0.72rem;
  color: var(--bs-secondary-color, #6c757d);
  font-variant-numeric: tabular-nums;
}

.pp-single-batch-stage {
  grid-column: 1;
  display: flex;
  align-items: center;
  padding-right: 0.35rem;
  font-size: 0.83rem;
  font-weight: 600;
  white-space: nowrap;
}

.pp-single-batch-lane {
  grid-column: 2 / -1;
  border-radius: 0.28rem;
}

.pp-single-batch-operation {
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.28rem;
  color: #fff;
  font-size: 0.86rem;
  font-weight: 700;
}

.no-code-copy .code-copy-button {
  display: none;
}

.benchmark-charts figure {
  margin: 0;
}

.benchmark-charts figure > h2 {
  margin-top: 0;
}
