/* Change the font size of the body text */
.md-typeset {
    font-size: 16px; /* Change this value to the desired font size */
}
code {
    white-space: pre-wrap; /* Allows code to wrap and keeps indentation */
}

code, pre {
    tab-size: 4;  /* Ensures tabs are displayed as 4 spaces */
    white-space: pre;  /* Makes sure code preserves indentation and spaces */
}

/* Light theme: show -light images, hide -dark images */
[data-md-color-scheme="default"] .image-grid-light {
    display: grid;
}
[data-md-color-scheme="default"] .image-grid-dark {
    display: none !important;
    margin: 0 !important;
    height: 0 !important;
}

/* Dark theme: show -dark images, hide -light images */
[data-md-color-scheme="slate"] .image-grid-light {
    display: none !important;
    margin: 0 !important;
    height: 0 !important;
}
[data-md-color-scheme="slate"] .image-grid-dark {
    display: grid;
}

/* Center all Mermaid diagrams */
.mermaid {
    text-align: center;
    margin: 0 auto;
    display: block;
}

/* Enable hyphenation for justified paragraphs */
.justify {
    text-align: justify;
    text-justify: inter-word;
    hyphens: auto;
}

/* Fallback for browsers that don't support hyphenation */
/* This will simply align text to the left and prevent big gaps */
.justify:not([style*="hyphens"]) {
    text-align: left;
}

p {
    text-align: justify;
    text-justify: inter-word;
    hyphens: auto;
}

/* Custom "sourcecode" admonition type for mkdocstrings source code blocks.
   Uses magenta border color and a code-tags icon (</>).
   This is applied via JavaScript in source_open.js which adds the 'sourcecode'
   class to mkdocstrings source code details elements. */
:root {
  --md-admonition-icon--sourcecode: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M14.6,16.6L19.2,12L14.6,7.4L16,6L22,12L16,18L14.6,16.6M9.4,16.6L4.8,12L9.4,7.4L8,6L2,12L8,18L9.4,16.6Z"/></svg>');
}
/* Light mode: indigo */
[data-md-color-scheme="default"] .md-typeset .admonition.sourcecode,
[data-md-color-scheme="default"] .md-typeset details.sourcecode {
  border-color: rgb(63, 81, 181);
}
[data-md-color-scheme="default"] .md-typeset .sourcecode > .admonition-title,
[data-md-color-scheme="default"] .md-typeset .sourcecode > summary {
  background-color: rgba(63, 81, 181, 0.1);
}
[data-md-color-scheme="default"] .md-typeset .sourcecode > .admonition-title::before,
[data-md-color-scheme="default"] .md-typeset .sourcecode > summary::before {
  background-color: rgb(63, 81, 181);
  -webkit-mask-image: var(--md-admonition-icon--sourcecode);
          mask-image: var(--md-admonition-icon--sourcecode);
}

/* Dark mode: magenta */
[data-md-color-scheme="slate"] .md-typeset .admonition.sourcecode,
[data-md-color-scheme="slate"] .md-typeset details.sourcecode {
  border-color: rgb(139, 0, 139);
}
[data-md-color-scheme="slate"] .md-typeset .sourcecode > .admonition-title,
[data-md-color-scheme="slate"] .md-typeset .sourcecode > summary {
  background-color: rgba(139, 0, 139, 0.1);
}
[data-md-color-scheme="slate"] .md-typeset .sourcecode > .admonition-title::before,
[data-md-color-scheme="slate"] .md-typeset .sourcecode > summary::before {
  background-color: rgb(139, 0, 139);
  -webkit-mask-image: var(--md-admonition-icon--sourcecode);
          mask-image: var(--md-admonition-icon--sourcecode);
}
