/* ── Page navigation ─────────────────────────────────────────────────── */
.page-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 2.5rem;
  padding: 0.9rem 1.2rem;
  border-top: 1px solid #c8cdd2;
  font-size: 0.92rem;
  color: #444;
}
.page-nav a {
  color: #3a5a8a;
  text-decoration: none;
  font-weight: 500;
}
.page-nav a:hover { text-decoration: underline; }

/* ── WebR loading banner ─────────────────────────────────────────────── */
.webr-loading-note {
  background: #fff8e1;
  border-left: 4px solid #f0a500;
  padding: 0.6rem 1rem;
  border-radius: 4px;
  font-size: 0.88rem;
  color: #555;
  margin-bottom: 1rem;
}

/* ── Section block colours ───────────────────────────────────────────── */
/* Foundations – warm teal */
body.foundations { background-color: #e6f2f0; }
/* Regression – slate blue */
body.regression  { background-color: #e8eef4; }
/* Classification – warm sage */
body.classification { background-color: #e8f0e8; }
/* Unsupervised – warm sand */
body.unsupervised { background-color: #f0ece4; }

/* Content cards sit on white so they pop against the background */
.quarto-title-block,
.cell,
.callout,
table {
  background-color: #ffffff;
}

/* Side-by-side plot layout for bias-variance demos */
.bv-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin: 1rem 0;
}
.bv-grid .cell { margin: 0; }

/* Tighten code blocks on mobile */
@media (max-width: 768px) {
  pre { font-size: 0.78rem; }
  .page-nav { flex-direction: column; gap: 0.5rem; text-align: center; }
  .bv-grid { grid-template-columns: 1fr; }
}
