/* ===== Inline links: visible as links in body text ===================== */
/* pydata-sphinx-theme's default gives body links a colour change but no
   underline, so they read as normal prose unless a reader is specifically
   scanning for them. External-reference icons already carry their own cue,
   so they are excluded. */
.bd-article a:not(.reference.external) {
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ===== Home page: a real "# RAVEN" H1 keeps the document structure valid
   (and helps a screen reader / search engine), but the logo image beneath it
   already carries the visible title -- "raven" is the id Sphinx slugifies
   that exact heading text to, and is unique site-wide. ==================== */
#raven > h1 {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ===== Tables: fit the article column instead of forcing a horizontal
   scrollbar. table-layout:auto sizes a table from its content's preferred
   width with no upper bound; capping it at the container's width makes long
   cells wrap instead of pushing the table wider than the page. ============ */
.bd-article table {
  table-layout: fixed;
  width: 100%;
  max-width: 100%;
}
.bd-article table td,
.bd-article table th {
  overflow-wrap: break-word;
}
/* Sphinx wraps inline code in a single white-space:nowrap span, which is
   right in prose but lets one long identifier list force a table cell wide.
   Table cells are the one place breaking a code token mid-word is better
   than the cell (and the whole table) overflowing. */
.bd-article table code .pre {
  white-space: normal;
  overflow-wrap: break-word;
}

/* ===== RAVEN brand colour ===============================================
   Sourced from raven-logo.png -- a flat single-tone navy raven icon +
   wordmark, RGB(12,29,56). */
html[data-theme="light"] {
  --raven-accent: #1A4888;
}
html[data-theme="dark"] {
  --raven-accent: #6aa6e8;
}

/* ===== Home page hero ================================================= */
.rh-hero { text-align: center; padding: 1.5rem 0 1rem; }
/* align-items:flex-end puts the badge's bottom edge on the logo's bottom
   edge, whatever the logo's rendered height turns out to be. */
.rh-logo-row {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  flex-wrap: wrap;
  gap: .6rem;
  margin-bottom: .8rem;
}
.rh-tag {
  display: inline-block; font-size: .7rem; font-weight: 700;
  letter-spacing: .07em; text-transform: uppercase;
  color: var(--raven-accent);
  background: rgba(26,72,136,.12);
  border-radius: 20px; padding: .2rem .75rem;
}
.rh-tagline {
  font-size: .95rem; color: var(--pst-color-text-muted);
  max-width: 560px; margin: 0 auto; line-height: 1.65;
}

/* ===== Home page logo: swap for the dark scheme ======================= */
.rh-logo-light, .rh-logo-dark {
  max-width: 340px;
  height: auto;
}
.rh-logo-dark { display: none; }
html[data-theme="dark"] .rh-logo-light { display: none; }
html[data-theme="dark"] .rh-logo-dark { display: inline; }
