:root {
  --md-primary-fg-color: #12324a;
  --md-primary-fg-color--light: #1f5871;
  --md-primary-fg-color--dark: #0a2234;
  --md-accent-fg-color: #007d78;
  --calmar-cyan: #2fb8b2;
  --calmar-ink: #102532;
}

[data-md-color-scheme="slate"] {
  --md-primary-fg-color: #102532;
  --md-accent-fg-color: #55d3ca;
}

.md-header {
  background: linear-gradient(110deg, #0a2234 0%, #164861 65%, #007d78 100%);
}

.md-typeset h1,
.md-typeset h2 {
  color: var(--calmar-ink);
  letter-spacing: -0.015em;
}

[data-md-color-scheme="slate"] .md-typeset h1,
[data-md-color-scheme="slate"] .md-typeset h2 {
  color: #eef9fb;
}

.md-typeset .grid.cards > ul > li {
  border-top: 3px solid var(--calmar-cyan);
}

.md-typeset table:not([class]) th {
  background: #12324a;
  color: white;
}

.md-typeset .admonition,
.md-typeset details {
  border-radius: 0.2rem;
}

.pipeline-caption {
  color: var(--md-default-fg-color--light);
  font-size: 0.85rem;
}

.calmar-figure {
  margin: 1.5rem 0 2rem;
}

.calmar-figure img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 42rem;
  margin: 0 auto;
  object-fit: contain;
  border: 1px solid var(--md-default-fg-color--lightest);
  border-radius: 0.5rem;
  background: #f4f8fa;
}

.calmar-figure--narrow img {
  max-width: 48rem;
}

.tissue-comparison {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  padding: 1rem;
  border: 1px solid var(--md-default-fg-color--lightest);
  border-radius: 0.5rem;
  background: #eef4f6;
}

.tissue-panel__title {
  margin-bottom: 0.45rem;
  color: #102532;
  font-weight: 700;
  text-align: center;
}

.tissue-panel__image {
  position: relative;
}

.calmar-figure .tissue-panel__image img {
  border-radius: 0.4rem;
  background: #081117;
}

.tissue-panel__image svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.tissue-panel__image line {
  stroke: #55d3ca;
  stroke-width: 0.8;
  vector-effect: non-scaling-stroke;
}

.tissue-callout {
  position: absolute;
  z-index: 1;
  padding: 0.25rem 0.45rem;
  border-radius: 0.3rem;
  background: rgb(255 255 255 / 92%);
  box-shadow: 0 1px 4px rgb(0 0 0 / 35%);
  color: #102532;
  font-size: clamp(0.55rem, 1.2vw, 0.75rem);
  font-weight: 700;
  line-height: 1.1;
}

.tissue-callout--csf {
  top: 5%;
  left: 5%;
}

.tissue-callout--gm {
  bottom: 5%;
  left: 5%;
}

.tissue-callout--wm {
  right: 5%;
  bottom: 5%;
}

.calmar-figure figcaption,
.figure-caption {
  margin: 0.65rem auto 0;
  color: var(--md-default-fg-color--light);
  font-size: 0.82rem;
  line-height: 1.55;
}

.modality-thumb {
  display: block;
  width: 7.5rem;
  min-width: 7.5rem;
  height: auto;
  max-height: 7.5rem;
  object-fit: contain;
  background: #081117;
  border: 1px solid var(--md-default-fg-color--lightest);
  border-radius: 0.35rem;
}

@media screen and (max-width: 44.984375em) {
  .tissue-comparison {
    grid-template-columns: 1fr;
  }

  .modality-thumb {
    width: 6rem;
    min-width: 6rem;
  }

  .md-typeset table:not([class]) {
    font-size: 0.72rem;
  }
}
