/* Fix for site name using sidebar link clamping with preview build of Docsify v5 theme */
:is(body.sidebar-link-clamp .sidebar) a.app-name-link {
    white-space: normal;
}

/* Fix for Coverpage title link colors with preview build of Docsify v5 theme */
.cover h1 a {
  color: var(--cover-title-color);
}
.cover h1 a .hover {
  color: var(--link-color) !important;
}

/* Fix for Transparent iframe support for both light and dark modes with preview build of Docsify v5 theme */
iframe,
iframe *,
iframe[src],
iframe[src] * {
    color-scheme: light dark !important;
}
@media (prefers-color-scheme: dark) {
    iframe,
    iframe *,
    iframe[src],
    iframe[src] * {
        color-scheme: light !important;
    }
}

/* Fix for inline codeblock contrast within shaded table rows with preview build of Docsify v5 theme */
.markdown-section code {
  background: var(--color-mono-2);
}

/* Patch for legacy use of Pre on mobile with preview build of Docsify v5 theme */
.markdown-section pre {
  margin-top: 1rem;
  overflow: auto;
}
.markdown-section pre {
  white-space: pre-wrap !important;
  overflow-wrap: break-word;
}

/* Patch for legacy use of inline Code on mobile with preview build of Docsify v5 theme */
.markdown-section code {
  white-space: pre-wrap !important;
  overflow-wrap: break-word;
}

/* Patch for legacy use of non-Markdown long links to wrap */
.markdown-section a {
  word-break: break-word;
  overflow-wrap: break-word;
}

/* Patch for Font Awesome plugin Header content compatibility with Docsify v5 */
[id]:is(.markdown-section :where(h1,h2,h3,h4,h5,h6)) a:first-of-type {
  display: unset;
}

/* Patch for Topics index links with Docsify v5 */
.markdown-section a[href$="?id=a"],
.markdown-section a[href$="?id=b"],
.markdown-section a[href$="?id=c"],
.markdown-section a[href$="?id=d"],
.markdown-section a[href$="?id=e"],
.markdown-section a[href$="?id=f"],
.markdown-section a[href$="?id=g"],
.markdown-section a[href$="?id=h"],
.markdown-section a[href$="?id=i"],
.markdown-section a[href$="?id=j"],
.markdown-section a[href$="?id=k"],
.markdown-section a[href$="?id=l"],
.markdown-section a[href$="?id=m"],
.markdown-section a[href$="?id=n"],
.markdown-section a[href$="?id=o"],
.markdown-section a[href$="?id=p"],
.markdown-section a[href$="?id=q"],
.markdown-section a[href$="?id=r"],
.markdown-section a[href$="?id=s"],
.markdown-section a[href$="?id=t"],
.markdown-section a[href$="?id=u"],
.markdown-section a[href$="?id=v"],
.markdown-section a[href$="?id=w"],
.markdown-section a[href$="?id=x"],
.markdown-section a[href$="?id=y"],
.markdown-section a[href$="?id=z"] {
  display: inline-flex;
  padding-top: 0px;
  padding-right: 4px;
  padding-bottom: 0px;
  padding-left: 4px;
  line-height: 1.4;
}

/* Support for Docsify-This classes with preview build of Docsify v5 theme */

/* Target first paragraphs with 5+ links (reasonable index minimum) */
.markdown-section p:first-of-type:has(a[href^="#"]):has(a:nth-of-type(5)) {
    display: flex;
    flex-wrap: wrap;
    gap: 2px;
    font-size: var(--font-size-l);
    font-weight: 500;
    line-height: 1.4;
}

.markdown-section p:first-of-type:has(a[href^="#"]):has(a:nth-of-type(5)) a {
    color: var(--theme-color);
}

.markdown-section p:first-of-type:has(a[href^="#"]):has(a:nth-of-type(5)) a {
    padding: 0 2px;
}

.markdown-section #a,
.markdown-section #b,
.markdown-section #c,
.markdown-section #d,
.markdown-section #e,
.markdown-section #f,
.markdown-section #g,
.markdown-section #h,
.markdown-section #i,
.markdown-section #j,
.markdown-section #k,
.markdown-section #l,
.markdown-section #m,
.markdown-section #n,
.markdown-section #o,
.markdown-section #p,
.markdown-section #q,
.markdown-section #r,
.markdown-section #s,
.markdown-section #t,
.markdown-section #u,
.markdown-section #v,
.markdown-section #w,
.markdown-section #x,
.markdown-section #y,
.markdown-section #z {
  width: 2em;
  color: var(--color-mono-min);
  font-size: var(--font-size-l);
  font-weight: 700;
  margin-top: 1rem;
  padding-left: 0.25rem;
  background: color-mix(in srgb, var(--color-mono-max) 70%, transparent);
}

.markdown-section blockquote.announcement {
  background-color: var(--color-mono-1);
}

.markdown-section blockquote.announcement {
  overflow: visible;
  padding-top: .75em;
  padding-bottom: .75em;
  padding-right: 1em;
  color: var(--color-text);
}

.markdown-section blockquote.announcement ul {
  list-style: none;
  margin-top: 0.2em;
  margin-bottom: 0.8em;
}

.markdown-section blockquote.announcement ul li {
  margin: 2px 0;
}

.markdown-section blockquote.announcement ul li:before {
  position: absolute;
  content: "\2B29";
  margin-left: -18px;
}

.markdown-section blockquote.announcement hr {
  margin: 1em 0;
}

.markdown-section blockquote.announcement h1 {
  font-size: 1.45rem;
  line-height: 1.8rem;
  margin-top: 0.6rem;
  margin-bottom: 0;
  padding-top: 0;
  padding-bottom: 0;
}

.markdown-section blockquote.announcement h2 {
  font-size: 1.35rem;
  line-height: 1.7rem;
  margin-top: 0.5rem;
  margin-bottom: 0;
  padding-top: 0;
  padding-bottom: 0;
  border-style: none;
}

.markdown-section blockquote.announcement h3 {
  font-size: 1.2rem;
  line-height: 1.5rem;
  margin-top: 0.4rem;
  margin-bottom: 0;
  padding-top: 0;
  padding-bottom: 0;
}

.markdown-section blockquote.announcement h4 {
  font-size: 1.15rem;
  line-height: 1.3rem;
  margin-top: 0.3rem;
  margin-bottom: 0;
  padding-top: 0;
  padding-bottom: 0;
}

.markdown-section blockquote.announcement h5 {
  font-size: 1.1rem;
  line-height: 1.25rem;
  margin-top: 0.2rem;
  margin-bottom: 0;
  padding-top: 0;
  padding-bottom: 0;
}

.markdown-section blockquote.announcement h6 {
  font-size: 1rem;
  line-height: 1.1rem;
  margin-top: 0.1rem;
  margin-bottom: 0;
  padding-top: 0;
  padding-bottom: 0;
}

.markdown-section blockquote.announcement .button {
    background: var(--button-bg);
    color: var(--button-color);
    border-color: var(--button-bg);
}

.markdown-section .navpill {
  cursor: pointer;
  color: var(--color-mono-max) !important;
  height: auto;
  display: inline-block;
  border: 1px solid var(--color-mono-max);
  border-radius: 4rem;
  padding: 4px 14px 4px 14px;
  margin-bottom: 4px;
  margin-right: 6px;
  font-size: 0.8rem;
  line-height: 1.2;
  background-color: var(--color-mono-min);
  font-family: system-ui, sans-serif;
  font-weight: bold;
  text-decoration: none;
}

.markdown-section a.navpill {
  cursor: pointer;
  color: var(--color-mono-max);
  border: 1px solid var(--color-mono-max);
  text-decoration: none !important;
}

.markdown-section .badge {
  color: var(--badge-text-color, var(--color-mono-min));
  background-color: var(
    --badge-bg-color,
    color-mix(in srgb, var(--color-mono-max) 60%, transparent)
  );
  display: inline-block;
  padding: 0.25em 0.4em 0.25em 0.4em;
  font-family: system-ui, sans-serif;
  font-size: 75%;
  font-weight: 700;
  line-height: 1;
  text-align: center;
  white-space: nowrap;
  vertical-align: middle;
  margin-top: -0.4em;
  border-radius: 0.25rem;
  transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out,
    border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
  text-decoration: none;
  
  /* Add maximum width and ellipsis */
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}

.markdown-section .badge a {
  color: var(--badge-text-color, var(--color-mono-min)) !important;
  text-decoration: none !important;
}

.markdown-section .accordion {
  margin-top: 1.05rem;
  position: relative;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-direction: column;
  flex-direction: column;
  min-width: 0;
  word-wrap: break-word;
  background-clip: border-box;
  border-top: 1px solid var(--color-mono-3);
  border-right: 1px solid var(--color-mono-3);
  border-left: 1px solid var(--color-mono-3);
  border-radius: 0.15rem;
}

.markdown-section .accordion details {
  padding: 0 1.25rem 1rem 1.25rem;
  margin-bottom: 0;
  border-bottom: 1px solid var(--color-mono-3);
}

.markdown-section .video-container-4by3 {
  position: relative;
  padding-bottom: 75%;
  height: 0;
  overflow: hidden;
  max-width: 100%;
}

.markdown-section .video-container-16by9 {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  max-width: 100%;
}

.video-container-16by9 iframe,
.video-container-4by3 iframe,
.embed-container object,
.embed-container embed {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 93%;
}

.markdown-section .responsive-container iframe {
  max-width: 100%;
}

.markdown-section .responsive {
  max-width: 100%;
  height: auto;
}

.markdown-section .banner-image {
  width: 100%;
  height: 125px;
  object-fit: cover;
  object-position: 50% 50%;
}

@media (min-width: 576px) {
  .markdown-section .banner-image {
    height: 250px;
  }
}

.markdown-section .banner-tall-image {
  width: 100%;
  height: 175px;
  object-fit: cover;
  object-position: 50% 50%;
}

@media (min-width: 576px) {
  .markdown-section .banner-tall-image {
    height: 350px;
  }
}

.markdown-section .header-image-fade {
  width: 100%;
  margin: 0px auto;
  position: absolute;
  top: 0px;
  left: 0;
  -webkit-mask-image: -webkit-gradient(
    linear,
    left top,
    left bottom,
    from(rgba(0, 0, 0, 1)),
    to(rgba(0, 0, 0, 0))
  );
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 1), rgba(0, 0, 0, 0));
  opacity: 0.4;
  z-index: -1;
}

/* CSS currently only works with sidebar and standalone pages */
.markdown-section .header-image-fade-full-width {
  transform: none;
  margin-top: -3rem;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  position: absolute;
  width: 100vw;
  max-width: 100vw;
  -webkit-mask-image: -webkit-gradient(
    linear,
    left top,
    left bottom,
    from(rgba(0, 0, 0, 1)),
    to(rgba(0, 0, 0, 0))
  );
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 1), rgba(0, 0, 0, 0));
  opacity: 0.4;
  z-index: -1;
}

/* CSS currently only works with sidebar and standalone pages */
.markdown-section .header-image-full-width,
.markdown-section .header-image-full-width-headings-overlay {
  margin-top: -3rem;
  left: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  max-width: 100vw;
  position: relative;
  right: 50%;
  width: 100vw;
  height: 30dvh;
  object-fit: cover;
  object-position: center 50%;
}

.markdown-section .header-tall-image-full-width,
.markdown-section .header-tall-image-full-width-headings-overlay {
  margin-top: -3rem;
  left: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  max-width: 100vw;
  position: relative;
  right: 50%;
  width: 100vw;
  height: 40dvh;
  object-fit: cover;
  object-position: center 50%;
}

.markdown-section p:has(.header-tall-image-full-width, .header-image-full-width) + h1[tabindex="-1"],
.markdown-section p:has(.header-tall-image-full-width, .header-image-full-width) + * + h1[tabindex="-1"] {
  font-size: clamp(2rem, 5vw, 3.0rem); /* Scales between 2rem and 3.0rem */
  line-height: clamp(2.2rem, 5.5vw, 3.4rem);
  margin-left: -3px;
  font-weight: 600;
  letter-spacing: clamp(-0.02em, -0.5vw, -0.01em); /* Tighten large text */
  margin-top: clamp(1.5rem, 3vw, 2.5rem);
  margin-bottom: clamp(0.75rem, 1.5vw, 1.25rem);
}

.markdown-section p:has(.header-tall-image-full-width, .header-image-full-width) + h1[tabindex="-1"] + h2[tabindex="-1"],
.markdown-section p:has(.header-tall-image-full-width, .header-image-full-width) + * + h1[tabindex="-1"] + h2[tabindex="-1"] {
  font-size: clamp(1.2rem, 3vw, 1.8rem); /* Scales between 1.2rem and 1.8rem */
  line-height: clamp(1.4rem, 3.5vw, 2rem);
  margin-left: -2px;
  font-weight: 500;
  margin-bottom: clamp(1.5rem, 3vw, 2.5rem);
}

/* CSS generated/assisted by Anthropic Claude AI */
.markdown-section p:has(.header-tall-image-full-width-headings-overlay,
.header-image-full-width-headings-overlay) + h1[tabindex="-1"] {
  position: absolute;
  top: calc(-3rem + 20dvh + 1rem); /* h1 center + spacing */
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  text-shadow:
    2px 2px 4px rgba(0,0,0,0.8),
    0 0 20px rgba(0,0,0,0.4);
  z-index: 10;
  margin: 0;
  font-size: clamp(2rem, 5vw, 3.0rem); /* Scales between 2rem and 3.0rem */
  line-height: clamp(2.2rem, 5.5vw, 3.4rem);
  width: 100%;
  text-align: center;
  font-weight: 500;
  letter-spacing: -0.03em;
  backdrop-filter: blur(2px);
  background: linear-gradient(
    135deg,
    rgba(0,0,0,0.3) 0%,
    rgba(0,0,0,0.1) 100%
  );
  padding: clamp(0.5rem, 2vw, 1rem) clamp(1rem, 4vw, 2rem);
  border-radius: 8px;
  max-width: 90vw;
}

.markdown-section p:has(.header-image-full-width-headings-overlay) + h1[tabindex="-1"] {
  top: calc(-3rem + 15dvh + 1rem); /* h1 center + spacing for regular images */
}

.markdown-section p:has(.header-tall-image-full-width-headings-overlay,
.header-image-full-width-headings-overlay) + h1[tabindex="-1"] + h2[tabindex="-1"] {
  position: absolute;
  top: calc(-3rem + 20dvh + 3.5rem); /* h1 center + spacing */
  left: 50%;
  transform: translateX(-50%); /* Only center horizontally */
  color: rgba(255,255,255,0.95);
  text-shadow:
    1px 1px 3px rgba(0,0,0,0.7),
    0 0 15px rgba(0,0,0,0.3);
  z-index: 10;
  margin: 0;
  font-size: clamp(1.2rem, 3vw, 1.8rem); /* Scales between 1.2rem and 1.8rem */
  line-height: clamp(1.4rem, 3.5vw, 2rem);
  width: 100%;
  text-align: center;
  font-weight: 300;
  letter-spacing: 0.05em;
  padding: clamp(0.25rem, 1vw, 0.5rem) clamp(0.75rem, 3vw, 1.5rem);
  max-width: 80vw;
  border: 0;
}

.markdown-section p:has(.header-image-full-width-headings-overlay) + h1[tabindex="-1"] + h2[tabindex="-1"] {
  top: calc(-3rem + 15dvh + 3.5rem); /* h2 center + spacing for regular images */
}

/* Keep text-shadow for links in h1 and h2 (same as parent) */
.markdown-section p:has(.header-tall-image-full-width-headings-overlay,
.header-image-full-width-headings-overlay) + h1[tabindex="-1"] a,
.markdown-section p:has(.header-tall-image-full-width-headings-overlay,
.header-image-full-width-headings-overlay) + h1[tabindex="-1"] + h2[tabindex="-1"] a {
  text-shadow: inherit; /* Inherit shadow from parent */
  text-decoration: none; /* Remove default underline */
}

/* Apply underline only on hover */
.markdown-section p:has(.header-tall-image-full-width-headings-overlay,
.header-image-full-width-headings-overlay) + h1[tabindex="-1"] a:hover,
.markdown-section p:has(.header-tall-image-full-width-headings-overlay,
.header-image-full-width-headings-overlay) + h1[tabindex="-1"] + h2[tabindex="-1"] a:hover {
  text-decoration: underline; /* Show underline on hover */
}

.markdown-section .image-75 {
  width: 75%;
  height: auto;
}

.markdown-section .image-50 {
  width: 50%;
  height: auto;
}

.markdown-section .image-25 {
  width: 25%;
  height: auto;
}

.markdown-section .image-75-border {
  width: 75%;
  height: auto;
  border: 1px solid var(--color-mono-3);
}

.markdown-section .image-50-border {
  width: 50%;
  height: auto;
  border: 1px solid var(--color-mono-3);
}

.markdown-section .image-25-border {
  width: 25%;
  height: auto;
  border: 1px solid var(--color-mono-3);
}

.markdown-section .image-border {
  border: 1px solid var(--color-mono-3);
}

.markdown-section .image-border-rounded {
  border-radius: 0.35em;
  border: 1px solid var(--color-mono-3);
}

.markdown-section .column {
  float: left;
  padding-right: 1rem;
  width: 50%;
}

.markdown-section .column-right {
  float: right;
  padding-left: 1rem;
  width: 50%;
}

.markdown-section .column img {
  margin-top: 0.35rem;
}

.markdown-section .column-right img {
  margin-top: 0.35rem;
}

.markdown-section .reverse-columns .column {
  float: right;
}

.markdown-section .row:after {
  content: "";
  display: table;
  clear: both;
}

@media screen and (max-width: 768px) {
  .markdown-section .column,
  .markdown-section .column-right {
    width: 100%;
    padding-right: 0rem;
    padding-left: 0rem;
  }

  .markdown-section .image-75,
  .markdown-section .image-50,
  .markdown-section .image-25,
  .markdown-section .image-75-border,
  .markdown-section .image-50-border,
  .markdown-section .image-25-border {
    width: 100%;
    height: auto;
  }
}

/* CSS generated/assisted by Anthropic Claude AI */
.markdown-section .card-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  margin-top: 2rem;
}

.markdown-section .card:not(.card-list .card),
.markdown-section .card-rounded:not(.card-list .card-rounded) {
  margin-top: 2rem;
}

.markdown-section .card,
.markdown-section .card-rounded {
  border: 1px solid var(--color-mono-3);
  padding: 1rem;
  display: flex;
  flex-direction: column;
  overflow: hidden; /* This ensures images respect border-radius */
}

.markdown-section .card-rounded {
  border-radius: 0.35em;
}

.markdown-section .card h2,
.markdown-section .card-rounded h2 {
  margin: 0 0 .1rem 0;
  padding-bottom: .5rem;
  font-size: 1.3rem;
}

/* Adjust space above and below h2 that follows edge-to-edge images */
.markdown-section .card p:has(img):first-child + h2,
.markdown-section .card-rounded p:has(img):first-child + h2 {
  margin-top: 1rem;
  padding-bottom: .25rem;
}

/* All images have normal padding by default */
.markdown-section .card p:has(img),
.markdown-section .card-rounded p:has(img) {
  margin: 0;
}

/* First images extend to card edges */
.markdown-section .card p:has(img):first-child,
.markdown-section .card-rounded p:has(img):first-child {
  margin: -1.6rem -1.5rem -1rem -1.5rem;
}

.markdown-section .card img,
.markdown-section .card-rounded img {
  width: 100%;
  height: 240px;
  object-fit: cover;
}

.markdown-section .card p,
.markdown-section .card-rounded p {
  flex-grow: 1;
  margin-bottom: .1rem;
}

/* Mobile */
@media screen and (max-width: 768px) {
  .markdown-section .card-list {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .markdown-section .card,
  .markdown-section .card-rounded {
    padding: 1.25rem;
  }

  .markdown-section .card img,
  .markdown-section .card-rounded img {
    height: 200px;
  }

  .markdown-section .card p:has(img):first-child,
  .markdown-section .card-rounded p:has(img):first-child {
    margin: -1.35rem -1.25rem -0.75rem -1.25rem;
  }
}

@media only screen and (max-width: 480px) {
  .markdown-section blockquote.announcement h1 {
    font-size: 1.3rem;
    line-height: 1.5rem;
  }

  .markdown-section blockquote.announcement h2 {
    font-size: 1.2rem;
    line-height: 1.4rem;
  }

  .markdown-section blockquote.announcement h3 {
    font-size: 1.15rem;
    line-height: 1.4rem;
  }

  .markdown-section blockquote.announcement h4 {
    font-size: 1.1rem;
    line-height: 1.3rem;
  }

  .markdown-section blockquote.announcement h5 {
    font-size: 1.05rem;
    line-height: 1.3rem;
  }

  .markdown-section blockquote.announcement h6 {
    font-size: 1rem;
    line-height: 1.15rem;
  }
}