/* Scale down all images so slides fit on screen */
.reveal section img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

/* Override Quarto's auto-stretch if applied */
.reveal section img.r-stretch {
  max-width: 100%;
  max-height: 100%;
  width: auto !important;
  height: auto !important;
}

/* Highlighted term (replaces <span style="color:#215293"> __...__ </span>) */
.reveal .term {
  color: #215293;
  font-weight: bold;
}

/* Exercise (replaces <span style="color:#215293"> __...__ </span>) */
.reveal .exercise {
  color: #459321;
  font-weight: bold;
}

/* Warning / caution (replaces <span style="color:#ee220c"> __...__ </span>) */
.reveal .warn {
  color: #ee220c;
  font-weight: bold;
}

/* Hide macro definition block */
.hidden { display: none; }

/* Example box */
.reveal .example {
  border: 1.5px solid #b07800;
  border-left: 5px solid #b07800;
  background: rgba(176, 120, 0, 0.06);
  padding: 0.4em 1.1em 0.6em;
  border-radius: 3px;
  margin: 0.6em 0;
}

.reveal .example .example-title {
  color: #b07800;
  font-weight: bold;
  margin-bottom: 0.3em;
}

/* Definition box */
.reveal .definition {
  border: 1.5px solid #459321;
  border-left: 5px solid #459321;
  background: rgba(69, 147, 33, 0.06);
  padding: 0.4em 1.1em 0.6em;
  border-radius: 3px;
  margin: 0.6em 0;
}

.reveal .definition .definition-title {
  color: #459321;
  font-weight: bold;
  margin-bottom: 0.3em;
}

/* Theorem / Definition box */
.reveal .theorem {
  border: 1.5px solid #215293;
  border-left: 5px solid #215293;
  background: rgba(33, 83, 147, 0.06);
  padding: 0.4em 1.1em 0.6em;
  border-radius: 3px;
  margin: 0.6em 0;
}

.reveal .theorem .theorem-title {
  color: #215293;
  font-weight: bold;
  margin-bottom: 0.3em;
}

/* Quiz question box */
.reveal .quiz {
  border: 1.5px solid #7C3AED;
  border-left: 5px solid #7C3AED;
  background: rgba(124, 58, 237, 0.06);
  padding: 0.4em 1.1em 0.6em;
  border-radius: 3px;
  margin: 0.6em 0;
}
.reveal .quiz .quiz-title {
  color: #7C3AED;
  font-weight: bold;
  margin-bottom: 0.3em;
}

/* Quiz answer/solution box */
.reveal .quiz-solution {
  border: 1.5px solid #0891B2;
  border-left: 5px solid #0891B2;
  background: rgba(8, 145, 178, 0.06);
  padding: 0.4em 1.1em 0.6em;
  border-radius: 3px;
  margin: 0.6em 0;
}
.reveal .quiz-solution .quiz-title {
  color: #0891B2;
  font-weight: bold;
  margin-bottom: 0.3em;
}

/* Center an image on the slide */
.reveal section img.center {
  display: block;
  margin-left: auto;
  margin-right: auto;
}

/* --- MPS additions --- */
/* Audio players fill their column */
.reveal audio { width: 100%; height: 2.2em; margin: 0.2em 0; }

/* Photo credit / source line under an image */
.reveal .credit { font-size: 0.45em; color: #888; display: block; margin-top: 0.2em; }

/* Landmark paper citation */
.reveal .paper {
  font-size: 0.6em;
  color: #444;
  border-left: 4px solid #215293;
  padding-left: 0.6em;
  margin: 0.5em 0;
}

/* Small-print lists (credits, reading lists) */
.reveal .smallprint { font-size: 0.55em; }

/* Titles of works and papers: italic (the emphasis filter reserves _x_ for terms) */
.reveal .work { font-style: italic; }

/* Graphviz diagrams: scale the static SVG to the slide width */
.reveal .diagram-wide svg { width: 100%; max-height: 420px; height: auto; }

/* Readable code block (MIDI bytes) */
.reveal .bigcode pre, .reveal .bigcode pre code { font-size: 26px !important; line-height: 1.35 !important; }

/* Simple side-by-side row, safe to nest inside a layout column */
.reveal .row { display: flex; gap: 0.8em; align-items: flex-start; }
.reveal .row > div { flex: 1; min-width: 0; }

/* Keep embedded videos inside the slide */
.reveal video { max-width: 100%; max-height: 360px; display: block; }
