/* Light mode — Off White + Dark Teal */
[data-md-color-scheme="default"] {
  --md-primary-fg-color: #163a3c;
  --md-primary-fg-color--light: #2a6b6b;
  --md-primary-fg-color--dark: #0e2a2c;
  --md-accent-fg-color: #4ecb8d;
  --md-default-fg-color: #163a3c;
  --md-default-fg-color--light: #2a6b6b;
  --md-default-bg-color: #f5ece0;
  --md-default-bg-color--light: #faf6f0;
  --md-typeset-a-color: #105257;
}

/* Underline body links in light mode for clear distinction from text */
[data-md-color-scheme="default"] .md-typeset a:not(.headerlink) {
  text-decoration: underline;
}

/* Dark mode — Dark Teal + Off White/Green */
[data-md-color-scheme="slate"] {
  --md-primary-fg-color: #163a3c;
  --md-primary-fg-color--light: #2a6b6b;
  --md-primary-fg-color--dark: #0e2a2c;
  --md-accent-fg-color: #4ecb8d;
  --md-default-fg-color: #f5ece0;
  --md-default-fg-color--light: #ddd4c8;
  --md-default-bg-color: #0e2a2c;
  --md-default-bg-color--light: #163a3c;
}

/* The theme sets --md-typeset-a-color via a two-attribute selector
   ([scheme][primary] -> #5488e8), which outranks a scheme-only rule. Match
   that specificity to override it once; this single variable drives both
   body link color and the active nav item, and hover still falls back to
   --md-accent-fg-color via the theme's own a:hover rule. */
[data-md-color-scheme="slate"][data-md-color-primary] {
  --md-typeset-a-color: #0FCB8C;
}

/* Underline body links in dark mode for clear distinction from text */
[data-md-color-scheme="slate"] .md-typeset a:not(.headerlink) {
  text-decoration: underline;
}

/* Remove the outer mkdocstrings container "card" */
.md-typeset .doc.doc-object.doc-module {
  border: none;
  padding: 0;
  margin: 0;
  background: none;
  box-shadow: none;
}

/* Remove any nested wrapper padding */
.md-typeset .doc.doc-contents {
  padding: 0;
  margin: 0;
}

/* Function-level cards */
.md-typeset .doc.doc-object.doc-function {
  border: 1px solid var(--md-default-fg-color--lightest);
  border-radius: 8px;
  padding: 1rem 1.2rem;
  margin-bottom: 1.5rem;
  background-color: rgba(255, 255, 255, 0.02); /* subtle contrast */
}

/* Make signature blend into card */
.md-typeset .mkdocstrings-source {
  background-color: transparent;
}
