/* this_file: src/editorial/fontlab-layout.css */

/* ---- Full-width layout: edge sidebars, flexible space, wide content ------- */

.md-main__inner,
.md-content {
  min-width: 0 !important;
}

/* Let the main row span the whole viewport so sidebars reach the edges. */
.md-main__inner.md-grid {
  box-sizing: border-box !important;
  margin: 0 !important;
  margin-top: 0 !important;
  max-width: none !important;
  padding-inline: var(--fl-edge) !important;
}

/* ---- Reading column ------------------------------------------------------- */

/* The content fills all space between the left rail and the viewport's right
   edge (the right TOC floats above, it does not reserve a column). Text is
   width-limited and left-aligned, leaving a right margin for imagery. */
.md-content {
  padding: 0 0 var(--fl-space-12) var(--fl-content-gap) !important;
}

.md-content__inner.md-typeset {
  box-sizing: border-box !important;
  font-size: 1rem; /* fluid: rides the clamped root (issue 118) */
  margin: 0 !important;
  max-width: none !important;
  padding: var(--fl-space-12) 0 var(--fl-space-12) !important;
  width: 100% !important;
}

/* Text-carrying blocks keep a comfortable measure. */
.md-content__inner.md-typeset > h1,
.md-content__inner.md-typeset > h2,
.md-content__inner.md-typeset > h3,
.md-content__inner.md-typeset > h4,
.md-content__inner.md-typeset > p,
.md-content__inner.md-typeset > ul,
.md-content__inner.md-typeset > ol,
.md-content__inner.md-typeset > blockquote,
.md-content__inner.md-typeset > .admonition,
.md-content__inner.md-typeset > details,
.md-content__inner.md-typeset > table,
.md-content__inner.md-typeset > .highlight {
  max-width: var(--fl-measure);
}

.md-content__inner.md-typeset > h1,
.md-content__inner.md-typeset > h2,
.md-content__inner.md-typeset > h3 {
  color: var(--color-base-content);
  font-family: var(--fl-font-head);
  letter-spacing: 0;
  text-wrap: balance;
}

.md-content__inner.md-typeset > h1 {
  font-family: var(--fl-font-post);
  font-size: var(--fl-h1);
  font-weight: var(--fl-heading-weight-min); /* biggest = lightest */
  line-height: 1.08;
  margin: 0 0 var(--fl-space-8);
}

.md-content__inner.md-typeset > h2 {
  font-size: var(--fl-h2);
  font-weight: var(--fl-heading-weight);
  line-height: 1.18;
  margin-top: var(--fl-space-12);
}

.md-content__inner.md-typeset > h3 {
  font-size: var(--fl-h3);
  font-weight: 500;
  line-height: 1.3;
  margin-top: var(--fl-space-8);
}

.md-content__inner.md-typeset > p,
.md-content__inner.md-typeset > ul,
.md-content__inner.md-typeset > ol {
  font-size: var(--fl-body-size);
  hyphens: auto; /* traditional justified-feel hyphenation in running text */
  line-height: var(--fl-line);
  text-wrap: pretty;
  -webkit-hyphens: auto;
}

.md-content__inner.md-typeset > p {
  margin-bottom: 0 !important; /* book style: no gap between paragraphs */
  max-width: 38rem;
}

/* Consecutive paragraphs indent instead of separating by vertical space. */
.md-content__inner.md-typeset > p + p {
  margin-top: 0 !important;
  text-indent: 2em;
}

/* Inline keycaps must not inherit the continued-paragraph first-line indent. */
.md-typeset kbd {
  text-indent: 0;
}

/* Inside blockquotes, separate consecutive paragraphs by space, not indent. */
.md-content__inner.md-typeset > blockquote p + p {
  margin-top: 0.75em;
  text-indent: 0;
}

/* Tight lists: no gap between items. */
.md-content__inner.md-typeset li {
  margin-bottom: 0 !important;
}

/* Blockquotes carry equal weight: same size as body, no border, framed by
   whitespace on all sides. Serif themes italicise; sans themes use the accent
   colour (issue 116). */
.md-content__inner.md-typeset > blockquote {
  border: 0;
  color: var(--fl-quote-color);
  font-size: var(--fl-body-size);
  font-style: var(--fl-quote-style);
  line-height: var(--fl-line);
  margin: var(--fl-space-4) 0;
  margin-left: 2em;
  padding: var(--fl-space-2) var(--fl-space-4);
  padding-left: 0;
}

.md-content__inner.md-typeset > blockquote > :first-child { margin-top: 0; }
.md-content__inner.md-typeset > blockquote > :last-child { margin-bottom: 0; }

/* Redundant per-heading permalinks are hidden (issue 113). */
.md-typeset .headerlink {
  display: none !important;
}

/* ---- Imagery: measure-width, right-margin, or full-bleed ------------------ */

.md-content__inner.md-typeset img {
  border-radius: 6px;
  height: auto;
  max-width: 100%;
}

/* glightbox wraps each image in an <a>; make it block so widths propagate. */
.md-content__inner.md-typeset .glightbox {
  display: block;
  width: 100%;
}

.md-content__inner.md-typeset .glightbox img {
  display: block;
  width: 100%;
}

/* An image-only paragraph keeps the text measure by default (descendant
   selectors so the glightbox <a> wrapper does not defeat them)... */
.md-content__inner.md-typeset > p:has(img) {
  margin-block: var(--fl-space-6) !important;
  max-width: var(--fl-measure);
}

.md-content__inner.md-typeset > p:has(img) + p {
  text-indent: 0;
}

/* ...unless the image opts into a wider treatment, which uncaps its wrapper. */
.md-content__inner.md-typeset > p:has(.fl-wide) {
  max-width: min(100%, 60rem);
}

.md-content__inner.md-typeset > p:has(.fl-bleed) {
  max-width: none;
  width: calc(100vw - var(--fl-edge) - var(--fl-content-gap) - 12.1rem);
}

/* .fl-aside — float the media paragraph into the right margin beside text. */
@media (min-width: 76.25em) {
  .md-content__inner.md-typeset > p:has(.fl-aside) {
    clear: right;
    float: right;
    margin: 0.4rem 0 var(--fl-space-6) var(--fl-space-8);
    max-width: min(40%, 360px);
  }
}

/* ---- Left sidebar: search + site nav, receding by default ----------------- */

.md-sidebar--primary .md-sidebar__scrollwrap {
  background: transparent;
  box-shadow: none;
}

/* The lifted-nav section header/label carries a white background + glow. Strip
   that decoration everywhere (MaterialX's own rule can override display:none on
   single-page sections, so kill background + shadow with !important too). */
.md-nav--primary .md-nav__title {
  background: transparent !important;
  box-shadow: none !important;
  display: none;
}

.md-nav--primary label.md-nav__link,
.md-nav--primary .md-nav__link--active {
  background: transparent !important;
  box-shadow: none !important;
}

.md-nav--primary .md-nav__link {
  color: color-mix(in oklab, var(--color-base-content) 62%, transparent);
  font-family: var(--fl-font-navi);
  font-size: 13px;
  line-height: 1.4;
  text-wrap: balance;
}

body[data-md-color-primary] .md-nav--primary .md-nav__item .md-nav__link--active,
.md-nav--primary .md-nav__link:focus,
.md-nav--primary .md-nav__link:hover {
  color: var(--color-secondary);
}

/* Recede the whole left rail on hover-capable wide viewports; reveal on hover. */
@media (hover: hover) and (min-width: 76.25em) {
  .md-sidebar--primary {
    opacity: 0.42;
    transition: opacity 280ms ease;
  }

  .md-sidebar--primary:hover,
  .md-sidebar--primary:focus-within {
    opacity: 1;
  }
}

/* ---- Native MaterialX search, restyled for the sidebar -------------------- */

.md-sidebar--primary .md-search {
  display: block !important; /* theme only reveals .md-search inside .md-header */
  margin: 0 var(--fl-space-3) var(--fl-space-6);
  position: relative;
}

.md-search__overlay {
  display: none;
}

.md-sidebar--primary .md-search__inner {
  float: none;
  position: static;
  width: 100%;
  transform: none;
  opacity: 1;
}

.md-sidebar--primary .md-search__form {
  background: var(--color-base-200);
  border-radius: var(--radius-field);
  box-shadow: none;
  height: 40px;
}

.md-sidebar--primary .md-search__form:hover {
  background: var(--color-base-300);
}

.md-sidebar--primary .md-search__input {
  color: var(--color-base-content);
  font: 500 14px/1.4 var(--fl-font-navi);
  height: 40px;
  padding-left: 36px;
}

.md-sidebar--primary .md-search__input::placeholder {
  color: color-mix(in oklab, var(--color-base-content) 55%, transparent);
}

.md-sidebar--primary .md-search__icon[for="__search"] {
  color: color-mix(in oklab, var(--color-base-content) 60%, transparent);
  height: 18px;
  left: 10px;
  top: 11px;
  width: 18px;
}

.md-sidebar--primary .md-search__output {
  background: var(--color-base-100);
  border-radius: var(--radius-box);
  left: 0;
  opacity: 0;
  overflow: hidden;
  pointer-events: none;
  position: absolute;
  right: 0;
  top: calc(100% + 0.25rem);
  visibility: hidden;
  z-index: 5;
}

/* The theme reveals results via a header-sibling selector that no longer
   matches; show them whenever the relocated search box has focus. */
.md-sidebar--primary .md-search:focus-within .md-search__output {
  opacity: 1;
  pointer-events: auto;
  visibility: visible;
}

.md-sidebar--primary .md-search__scrollwrap {
  background: var(--color-base-100);
  max-height: 60vh;
  width: 100%;
}

/* ---- Right TOC: floating overlay at the viewport's right edge ------------- */

/* "Contents" label from the theme is redundant next to the handle. */
.md-nav--secondary > .md-nav__title {
  display: none;
}

.md-nav--secondary .md-nav__link {
  color: color-mix(in oklab, var(--color-base-content) 58%, transparent);
  font-family: var(--fl-font-navi);
  font-size: 12.5px;
  text-wrap: balance;
}

body[data-md-color-primary] .md-nav--secondary .md-nav__item .md-nav__link--active,
.md-nav--secondary .md-nav__link:hover {
  color: var(--color-secondary);
}

.fl-toc-toggle {
  align-items: center;
  background: transparent;
  border: 0;
  border-radius: var(--radius-field);
  color: color-mix(in oklab, var(--color-base-content) 60%, transparent);
  cursor: pointer;
  display: flex;
  height: 30px;
  justify-content: center;
  margin: 0 0 var(--fl-space-2) auto;
  width: 30px;
}

.fl-toc-toggle:hover {
  color: var(--color-primary);
}

.fl-toc-toggle__icon {
  border-bottom: 1.5px solid currentColor;
  border-right: 1.5px solid currentColor;
  display: inline-block;
  height: 8px;
  transform: rotate(135deg); /* points left = "open me" */
  transition: transform 220ms ease;
  width: 8px;
}

html:not(.fl-toc-collapsed) .fl-toc-toggle__icon {
  transform: rotate(-45deg); /* points right = "collapse me" */
}

/* Desktop: detach the right sidebar from the flow so the content spans the
   full width, and float the TOC above the content — but below the header and
   tabs, so the subtheme switcher stays clickable. */
@media (min-width: 76.25em) {
  .md-sidebar--secondary {
    height: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    position: fixed !important; /* beats MaterialX's sidebar JS inline styles */
    right: var(--fl-edge) !important;
    top: var(--fl-toc-top, calc(var(--fl-header-h) + var(--fl-space-4))) !important;
    width: auto;
    z-index: 6;
  }

  .md-sidebar--secondary .md-sidebar__scrollwrap {
    background: transparent;
    box-shadow: none;
    margin: 0 !important;
    max-height: calc(100vh - var(--fl-toc-top, calc(var(--fl-header-h) + var(--fl-space-4))) - var(--fl-space-4));
    overflow-y: auto;
    padding: 0;
    width: auto;
  }

  .md-sidebar--secondary .md-sidebar__inner {
    margin: 0;
  }

  /* Expanded: the nav sits in a solid floating card above the content. */
  html:not(.fl-toc-collapsed) .md-sidebar--secondary .md-sidebar__inner {
    background: var(--color-base-100);
    border-radius: var(--radius-box);
    padding: var(--fl-space-3) var(--fl-space-4) var(--fl-space-4);
    width: 15rem;
  }

  /* Collapsed: only the handle remains, floating at the edge. */
  html.fl-toc-collapsed .md-sidebar--secondary .md-nav {
    display: none;
  }
}

/* Expanded on hover-capable devices: the panel fades until hovered. This fade
   is intentional feedback and is kept even under reduced-motion (see below). */
@media (hover: hover) and (min-width: 76.25em) {
  html:not(.fl-toc-collapsed) .md-sidebar--secondary .md-sidebar__inner {
    opacity: 0; /* fully transparent until hovered (issue: right sidebar) */
    transition: opacity 280ms ease;
  }

  html:not(.fl-toc-collapsed) .md-sidebar--secondary:hover .md-sidebar__inner,
  html:not(.fl-toc-collapsed) .md-sidebar--secondary:focus-within .md-sidebar__inner {
    opacity: 1;
  }
}

/* ---- Subtheme switcher: subtle icon + popup, injected into the tabs nav --- */

/* Tabs bar keeps the theme's dark treatment so it reads as one header block
   with the FontLab menu above it. Only layout is adjusted to host the switcher. */
.md-tabs {
  overflow: visible !important; /* let the subtheme popup escape the bar */
  z-index: 10; /* keep the switcher above the floating TOC overlay (z-index 6) */
}

.md-tabs > .md-grid {
  align-items: center;
  display: flex;
  gap: var(--fl-space-4);
  margin: 0 !important;
  max-width: none !important; /* nav spans the full viewport width (issue 113) */
  padding: 0 var(--fl-edge);
}

.md-tabs__list {
  flex: 0 1 auto;
}

.md-tabs__link {
  font-family: var(--fl-font-navi);
  font-size: 14px;
}

/* Header unification: the tabs bar shares the FontLab menu's treatment so the
   two read as one band (issue 116 follow-up). */
html[data-fl-menu="dark"] .md-tabs {
  background: var(--fl-menu-dark) !important;
  color: rgba(255, 255, 255, 0.92);
}

html[data-fl-menu="dark"] .md-tabs__link {
  color: rgba(255, 255, 255, 0.72);
}

html[data-fl-menu="dark"] .md-tabs__item--active .md-tabs__link,
html[data-fl-menu="dark"] .md-tabs__link:hover {
  color: #fff;
}

html[data-fl-menu="light"] .md-tabs {
  background: transparent !important;
  box-shadow: inset 0 -1px var(--fl-hairline);
  color: var(--color-base-content);
}

html[data-fl-menu="light"] .md-tabs__link {
  color: color-mix(in oklab, var(--color-base-content) 58%, transparent);
}

html[data-fl-menu="light"] .md-tabs__item--active .md-tabs__link,
html[data-fl-menu="light"] .md-tabs__link:hover {
  color: var(--color-base-content);
}

/* flat-dark: transparent bar, light text — the whole page is one dark colour
   (issue 117). The menu bar is made transparent via the shadow-root patch. */
html[data-fl-menu="flat-dark"] .md-tabs {
  background: transparent !important;
  color: rgba(255, 255, 255, 0.92);
}

html[data-fl-menu="flat-dark"] .md-tabs__link {
  color: rgba(255, 255, 255, 0.66);
}

html[data-fl-menu="flat-dark"] .md-tabs__item--active .md-tabs__link,
html[data-fl-menu="flat-dark"] .md-tabs__link:hover {
  color: #fff;
}

/* Small-caps runs use Outfit across all themes (issue 117). */
.md-typeset .fl-smallcaps {
  font-family: var(--fl-font-smcp);
  font-variant: small-caps;
  letter-spacing: 0.02em;
}

/* Rendered prompt templates (issue 115): the ```markdown source is rendered
   to formatted Markdown in a tinted panel; a button copies the raw source. */
.md-content__inner.md-typeset .fl-prompt {
  background: color-mix(in oklab, var(--color-base-200) 60%, transparent);
  border-radius: var(--radius-box);
  margin: var(--fl-space-6) 0;
  max-width: var(--fl-measure);
  padding: var(--fl-space-4) var(--fl-space-6) var(--fl-space-6);
  position: relative;
}

.fl-prompt__bar {
  display: flex;
  justify-content: flex-end;
}

.fl-prompt__copy {
  background: transparent;
  border: 0;
  border-radius: var(--radius-field);
  color: color-mix(in oklab, var(--color-base-content) 62%, transparent);
  cursor: pointer;
  font: 500 12px/1 var(--fl-font-navi);
  padding: var(--fl-space-2) var(--fl-space-3);
}

.fl-prompt__copy:hover,
.fl-prompt__copy:focus-visible {
  color: var(--color-primary);
  outline: none;
}

.fl-prompt__body > :first-child {
  margin-top: 0;
}

.fl-prompt__body > :last-child {
  margin-bottom: 0;
}

.fl-theme {
  margin-left: auto;
  position: relative;
}

.fl-theme__btn {
  align-items: center;
  background: transparent;
  border: 0;
  border-radius: var(--radius-field);
  color: currentColor;
  cursor: pointer;
  display: flex;
  height: 34px;
  justify-content: center;
  opacity: 0.8;
  width: 34px;
}

.fl-theme__btn:hover,
.fl-theme__btn[aria-expanded="true"] {
  opacity: 1;
}

.fl-theme__pop {
  background: var(--color-base-100);
  border-radius: var(--radius-box);
  box-shadow: 0 0 0 1px var(--fl-hairline);
  display: grid;
  gap: 2px;
  min-width: 12rem;
  padding: var(--fl-space-2);
  position: absolute;
  right: 0;
  top: calc(100% + 0.4rem);
  z-index: 20;
}

.fl-theme__pop[hidden] {
  display: none;
}

.fl-theme__opt {
  background: transparent;
  border: 0;
  border-radius: var(--radius-field);
  color: var(--color-base-content);
  cursor: pointer;
  font: 500 14px/1.3 var(--fl-font-navi);
  padding: var(--fl-space-2) var(--fl-space-3);
  text-align: left;
}

.fl-theme__opt:hover {
  background: var(--color-base-200);
}

.fl-theme__opt[aria-pressed="true"] {
  color: var(--color-primary);
  font-weight: 650;
}

/* ---- Shared focus ring ---------------------------------------------------- */

.fl-toc-toggle:focus-visible,
.fl-theme__btn:focus-visible,
.fl-theme__opt:focus-visible,
.md-sidebar--primary .md-search__input:focus-visible {
  outline: none;
  box-shadow: var(--fl-focus);
}

/* ---- Showcase ------------------------------------------------------------- */

.fl-showcase-grid {
  display: grid;
  gap: var(--fl-space-8);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 20rem), 1fr));
  margin: var(--fl-space-12) 0;
}

.fl-showcase-card {
  background: transparent;
  padding: 0;
}

.fl-showcase-card img {
  aspect-ratio: 16 / 10;
  object-fit: cover;
  width: 100%;
}


/* ---- Responsive ----------------------------------------------------------- */

@media (max-width: 76.1875em) {
  /* Below the tabs breakpoint the switcher is injected into the sidebar. */
  .md-sidebar--primary .fl-theme {
    margin: 0 var(--fl-space-3) var(--fl-space-4);
  }

  .md-sidebar--primary .fl-theme__pop {
    left: 0;
    right: auto;
  }

  html.fl-toc-collapsed .md-sidebar--secondary {
    width: auto;
  }
}

@media (max-width: 700px) {
  .md-content__inner.md-typeset {
    padding: var(--fl-space-8) 0 var(--fl-space-12) var(--fl-space-4) !important;
  }

  html[data-fl-subtheme="retro"] .md-content__inner.md-typeset > h1 {
    font-size: clamp(2.35em, 12vw, 2.7em);
    overflow-wrap: normal;
    word-break: normal;
  }

  .md-content__inner.md-typeset .stats {
    box-sizing: border-box;
    display: grid;
    grid-auto-flow: row;
    grid-template-columns: minmax(0, 1fr);
    max-width: 100%;
    overflow-x: clip;
    width: 100%;
  }

  .md-content__inner.md-typeset p.label {
    min-width: 0;
    overflow-wrap: anywhere;
    white-space: normal;
  }

  .md-content__inner.md-typeset ul.steps {
    display: grid;
    grid-auto-flow: row;
    grid-template-columns: minmax(0, 1fr);
    width: 100%;
  }

  .md-content__inner.md-typeset div.steps:has(> h4) {
    grid-template-columns: minmax(0, 1fr);
  }

  .md-content__inner.md-typeset div.steps:has(> h4) > * {
    grid-column: 1;
  }

  .md-content__inner.md-typeset .tooltip-open::before {
    left: auto;
    right: 0;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition-duration: 0.001ms !important;
    animation-duration: 0.001ms !important;
  }

  /* The sidebars' opacity fade is deliberate hover feedback — keep it gentle
     even under reduced-motion (explicit user request). */
  .md-sidebar--primary,
  .md-sidebar--secondary .md-sidebar__inner {
    transition: opacity 280ms ease !important;
  }
}

/* ---- Design-system catalog -------------------------------------------------
   Shared helpers for the design-system catalog pages. Every value derives from
   an existing token, so all five subthemes adapt. daisyUI's component rules live
   in @layer daisyui and are therefore overridden by MaterialX's unlayered
   `.md-typeset` element rules; the resets below re-assert daisyUI's own layout
   for the list-based components (menu, steps) and neutralise MaterialX's list
   and link styling inside a demo. No existing rule is modified. */

/* Lead paragraph — one notch up from body, same measure and reading colour. */
.md-content__inner.md-typeset > p.fl-lead {
  color: color-mix(in oklab, var(--color-base-content) 82%, transparent);
  font-size: 1.28em;
  font-weight: var(--fl-heading-weight-min);
  line-height: 1.5;
  margin-bottom: var(--fl-space-8);
}

/* Fourth-level heading — layout.css styles only h1–h3 as direct children;
   keep h4 in the same light-heading family. */
.md-content__inner.md-typeset > h4 {
  color: var(--color-base-content);
  font-family: var(--fl-font-head);
  font-size: 1em;
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: 1.4;
  margin-top: var(--fl-space-6);
  max-width: var(--fl-measure);
}

/* Demo wrapper + simple layout helpers. */
.md-content__inner.md-typeset .fl-ui {
  margin: var(--fl-space-6) 0;
}

.md-content__inner.md-typeset .fl-ui-row {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: var(--fl-space-3);
}

.md-content__inner.md-typeset .fl-ui-row + .fl-ui-row {
  margin-top: var(--fl-space-3);
}

.md-content__inner.md-typeset .fl-ui-stack {
  display: grid;
  gap: var(--fl-space-3);
  max-width: var(--fl-measure);
}

.md-content__inner.md-typeset .btn {
  align-items: center;
  background-color: var(--btn-bg);
  border-color: var(--btn-border);
  border-end-end-radius: var(--join-ee, var(--radius-field));
  border-end-start-radius: var(--join-es, var(--radius-field));
  border-start-end-radius: var(--join-se, var(--radius-field));
  border-start-start-radius: var(--join-ss, var(--radius-field));
  border-style: var(--btn-border-style, solid);
  border-width: var(--border);
  box-shadow: none;
  color: var(--btn-fg);
  cursor: pointer;
  display: inline-flex;
  flex-shrink: 0;
  flex-wrap: nowrap;
  font-family: var(--fl-font-body);
  font-size: var(--fontsize, 0.875rem);
  font-weight: 600;
  gap: 0.375rem;
  height: var(--size);
  justify-content: center;
  outline-color: var(--btn-color, var(--color-base-content));
  outline-offset: 2px;
  padding-inline: var(--btn-p);
  text-align: center;
  touch-action: manipulation;
  transition-duration: 0.2s;
  transition-property: color, background-color, border-color, box-shadow, transform;
  transition-timing-function: cubic-bezier(0, 0, 0.2, 1);
  user-select: none;
  vertical-align: middle;
  -webkit-user-select: none;
}

.md-content__inner.md-typeset .btn:focus-visible,
.md-content__inner.md-typeset .btn:has(:focus-visible) {
  isolation: isolate;
  outline-style: solid;
  outline-width: 2px;
}

.md-content__inner.md-typeset .btn-disabled,
.md-content__inner.md-typeset .btn:is(:disabled, [disabled], [aria-disabled="true"]) {
  --btn-bg: transparent;
  --btn-border: transparent;
  background-color: color-mix(in oklab, var(--color-base-content) 10%, transparent);
  color: color-mix(in oklch, var(--color-base-content) 20%, transparent);
  pointer-events: none;
}

.md-content__inner.md-typeset .btn-disabled:is(.btn-link, .btn-ghost),
.md-content__inner.md-typeset .btn:is(:disabled, [disabled], [aria-disabled="true"]):is(.btn-link, .btn-ghost) {
  background-color: transparent;
}

.md-content__inner.md-typeset .btn:hover {
  opacity: 1;
}

.md-content__inner.md-typeset .badge {
  align-items: center;
  background-color: var(--badge-bg);
  border: var(--border) solid var(--badge-color, var(--color-base-200));
  border-radius: var(--radius-selector);
  color: var(--badge-fg);
  display: inline-flex;
  font-size: .875rem;
  font-weight: 600;
  gap: var(--fl-space-2);
  height: var(--size);
  justify-content: center;
  padding-inline: calc(var(--size) / 2 - var(--border));
  vertical-align: middle;
  width: fit-content;
}

.md-content__inner.md-typeset .badge-secondary {
  --badge-color: var(--color-neutral);
  --badge-bg: var(--color-neutral);
  --badge-fg: var(--color-neutral-content);
  background-color: var(--color-neutral);
  border-color: var(--color-neutral);
  color: var(--color-neutral-content);
}

.md-content__inner.md-typeset .alert {
  align-items: center;
  background-color: var(--alert-color, var(--color-base-200));
  border: var(--border) solid var(--alert-border-color, var(--color-base-200));
  border-radius: var(--radius-box);
  color: var(--color-base-content);
  display: grid;
  font-size: .875rem;
  gap: var(--fl-space-4);
  grid-auto-flow: column;
  justify-content: start;
  line-height: 1.25rem;
  padding: var(--fl-space-3) var(--fl-space-4);
  text-align: start;
}

.md-content__inner.md-typeset > p.alert {
  margin-block: var(--fl-space-4) !important;
  text-indent: 0;
}

.md-content__inner.md-typeset .link {
  cursor: pointer;
  text-decoration-line: underline;
}

.md-content__inner.md-typeset .link-primary { color: var(--color-primary); }
.md-content__inner.md-typeset .link-secondary { color: var(--color-secondary); }
.md-content__inner.md-typeset .link-info { color: var(--color-info); }
.md-content__inner.md-typeset .link-success { color: var(--color-success); }
.md-content__inner.md-typeset .link-warning { color: var(--color-warning); }
.md-content__inner.md-typeset .link-error { color: var(--color-error); }

.md-content__inner.md-typeset .tab {
  font-family: var(--fl-font-body);
}

/* List-based components: strip MaterialX list cosmetics, then re-assert the
   daisyUI display those rules would otherwise defeat. */
.md-content__inner.md-typeset .menu,
.md-content__inner.md-typeset ul.steps {
  list-style: none;
  margin: 0;
}

.md-content__inner.md-typeset .menu li,
.md-content__inner.md-typeset ul.steps li {
  margin: 0;
}

.md-content__inner.md-typeset .menu {
  display: flex;
  flex-flow: column wrap;
  max-width: 20rem;
  padding: var(--fl-space-2);
}

.md-content__inner.md-typeset ul.steps {
  display: inline-grid;
  grid-auto-columns: 1fr;
  grid-auto-flow: column;
  padding: 0;
}

/* Menu links read in the body colour, not the link accent. */
.md-content__inner.md-typeset .menu a {
  color: var(--color-base-content);
  text-decoration: none;
}

/* Surfaces: cards, stats, menu, and the hero read as tinted panels. */
.md-content__inner.md-typeset .fl-card,
.md-content__inner.md-typeset .menu,
.md-content__inner.md-typeset .stats,
.md-content__inner.md-typeset .fl-hero {
  background: var(--color-base-200);
  border-radius: var(--radius-box);
}

.md-content__inner.md-typeset .fl-card {
  padding: var(--fl-space-6);
}

.md-content__inner.md-typeset .fl-card > :first-child {
  margin-top: 0;
}

.md-content__inner.md-typeset .fl-card > :last-child {
  margin-bottom: 0;
}

.md-content__inner.md-typeset .fl-card .card-title {
  font-family: var(--fl-font-head);
  font-size: 1.05em;
  font-weight: 500;
  margin: 0 0 var(--fl-space-2);
}

/* Hero / CTA band. */
.md-content__inner.md-typeset .fl-hero {
  padding: var(--fl-space-12) var(--fl-space-8);
  text-align: center;
}

.md-content__inner.md-typeset .fl-hero .fl-hero__title {
  font-family: var(--fl-font-head);
  font-size: var(--fl-h2);
  font-weight: var(--fl-heading-weight);
  line-height: 1.15;
  margin: 0 0 var(--fl-space-3);
}

.md-content__inner.md-typeset .fl-hero p {
  margin: 0 auto var(--fl-space-6);
  max-width: 34rem;
}

/* ---- Renderer/component parity --------------------------------------------
   MaterialX emits unlayered form and prose rules. Class-unique daisyUI
   components therefore recover their primitives directly in the reading
   surface; `.fl-ui` remains an optional arrangement helper only. */

.md-content__inner.md-typeset > ul,
.md-content__inner.md-typeset > blockquote {
  color: var(--color-base-content);
}

.md-content__inner.md-typeset a:not(.btn, .md-button),
.md-nav__link--active,
.md-nav__link:hover,
.fl-toc-toggle:hover {
  color: var(--color-secondary);
}

.md-content__inner.md-typeset mark {
  background: color-mix(in oklab, var(--color-secondary) 14%, transparent);
  color: var(--color-secondary);
}

.md-content__inner.md-typeset figcaption {
  --fl-caption-size: max(.91em, 14px);
  color: color-mix(in oklab, var(--color-base-content) 72%, transparent);
  font-family: var(--fl-font-capt);
  font-size: var(--fl-caption-size);
  line-height: 1.35;
  margin-top: var(--fl-space-2);
}

.md-content__inner.md-typeset code,
.md-content__inner.md-typeset pre,
.md-content__inner.md-typeset .countdown {
  font-family: var(--fl-font-mono);
}

.md-content__inner.md-typeset .otp input {
  box-sizing: border-box;
  font: inherit;
  inline-size: 100%;
  margin: 0;
  padding: 0;
  text-align: center;
}

.md-content__inner.md-typeset .rating input {
  margin: 0;
  padding: 0;
}

.md-content__inner.md-typeset fieldset.fieldset {
  border: 1px solid var(--color-base-300);
  min-inline-size: 0;
  padding: var(--fl-space-4);
}

.md-content__inner.md-typeset .rating {
  align-items: center;
  display: inline-flex;
}

.md-content__inner.md-typeset .toggle,
.md-content__inner.md-typeset .checkbox,
.md-content__inner.md-typeset .radio {
  appearance: none;
  border-color: color-mix(in oklab, var(--color-base-content) 45%, transparent);
  border-style: solid;
  border-width: 1px;
  margin: 0;
}

.md-content__inner.md-typeset .input,
.md-content__inner.md-typeset .file-input,
.md-content__inner.md-typeset .select,
.md-content__inner.md-typeset .textarea {
  border-color: color-mix(in oklab, var(--color-base-content) 35%, transparent);
  border-style: solid;
  border-width: 1px;
  box-sizing: border-box;
  font-family: var(--fl-font-body);
}

.md-content__inner.md-typeset .btn-secondary {
  --btn-color: var(--color-neutral);
  --btn-bg: var(--color-neutral);
  --btn-border: var(--color-neutral);
  --btn-fg: var(--color-neutral-content);
}

.md-content__inner.md-typeset .md-button {
  --btn-bg: var(--btn-color, var(--color-base-200));
  --btn-border: var(--btn-bg);
  --btn-fg: var(--color-base-content);
  --btn-p: 1rem;
  --size: calc(var(--size-field, .25rem) * 10);
  align-items: center;
  background-color: var(--btn-bg);
  border-color: var(--btn-border);
  border-style: solid;
  border-width: var(--border);
  border-radius: var(--radius-field);
  box-shadow: none;
  color: var(--btn-fg);
  display: inline-flex;
  font: 600 var(--fontsize, .875rem)/1 var(--fl-font-body);
  height: var(--size);
  justify-content: center;
  opacity: 1;
  padding: 0;
  padding-inline: var(--btn-p);
  text-decoration: none;
}

.md-content__inner.md-typeset .md-button:hover {
  --btn-bg: color-mix(in oklab, var(--btn-color, var(--color-base-200)), #000 7%);
  --btn-border: var(--btn-bg);
  background-color: var(--btn-bg);
  border-color: var(--btn-border);
  color: var(--btn-fg);
  opacity: 1;
  text-decoration: none;
}

.md-content__inner.md-typeset .md-button--primary {
  --btn-color: var(--color-primary);
  --btn-bg: var(--color-primary);
  --btn-border: var(--color-primary);
  --btn-fg: var(--color-primary-content);
}

.md-content__inner.md-typeset .md-button--primary:hover {
  --btn-bg: color-mix(in oklab, var(--color-primary), #000 7%);
  --btn-border: var(--btn-bg);
  color: var(--color-primary-content);
}

.md-content__inner.md-typeset .md-button:focus-visible {
  outline: 2px solid var(--btn-color, var(--color-base-content));
  outline-offset: 2px;
}

.md-content__inner.md-typeset > p:has(> .md-button),
.md-content__inner.md-typeset > p:has(> .btn) {
  text-indent: 0;
}

.md-content__inner.md-typeset .swap {
  display: inline-grid;
  grid-template-areas: "swap";
  place-items: center;
}

.md-content__inner.md-typeset .swap > :not(input) {
  grid-area: swap;
}

.md-content__inner.md-typeset .countdown {
  display: inline-grid;
  font-size: 2rem;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  min-inline-size: 2ch;
  place-items: center;
}

.md-content__inner.md-typeset kbd.kbd,
.md-content__inner.md-typeset code.kbd {
  background: var(--color-base-200);
  border: 1px solid var(--color-base-300);
  border-radius: 3px;
  box-shadow: none;
  color: var(--color-base-content);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  vertical-align: baseline;
  font-family: var(--fl-font-mono);
  font-size: .85em;
  min-height: 1.7em;
  min-width: 1.7em;
  padding: .1em .4em;
}

.md-content__inner.md-typeset .aura.aura-glow {
  animation: none;
  background: color-mix(in oklab, var(--color-primary) 10%, transparent);
  border: 1px solid color-mix(in oklab, var(--color-primary) 38%, transparent);
  filter: none;
  padding: var(--fl-space-1);
  transform: none;
}

.md-content__inner.md-typeset .aura::before,
.md-content__inner.md-typeset .aura::after {
  animation: none !important;
  background: none;
  content: none;
  filter: none;
  transform: none;
}

.md-content__inner.md-typeset details.collapse {
  background: var(--color-base-100);
  border: 1px solid var(--fl-hairline);
  border-radius: var(--radius-box);
  color: var(--color-base-content);
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: max-content 0fr;
  overflow: clip;
  visibility: visible;
  width: 100%;
}

.md-content__inner.md-typeset details.collapse[open] {
  grid-template-rows: max-content 1fr;
}

.md-content__inner.md-typeset details.collapse > summary.collapse-title {
  background: var(--color-base-200);
  color: var(--color-base-content);
  display: block;
  font-weight: 500;
  line-height: 1.35;
  margin: 0;
  min-height: 0;
  padding: .7rem 2.5rem .7rem 1rem;
  position: relative;
}

.md-content__inner.md-typeset details.collapse > summary.collapse-title::before {
  background: none !important;
  content: none !important;
  display: none !important;
  mask-image: none !important;
  -webkit-mask-image: none !important;
}

.md-content__inner.md-typeset details.collapse > summary.collapse-title::after {
  background: none;
  color: color-mix(in oklab, var(--color-base-content) 72%, transparent);
  mask: none;
}

.md-content__inner.md-typeset details.collapse > .collapse-content {
  color: var(--color-base-content);
  margin: 0;
  min-height: 0;
  padding: 0 var(--fl-space-4);
}

.md-content__inner.md-typeset details.collapse[open] > .collapse-content {
  padding-block: var(--fl-space-3);
}

.md-content__inner.md-typeset details.collapse:has(summary:focus),
.md-content__inner.md-typeset details.collapse:has(summary:focus-visible) {
  outline: 2px solid var(--color-base-content);
  outline-offset: 2px;
}

.md-content__inner.md-typeset .stack {
  box-sizing: border-box;
  display: grid;
  grid-template: minmax(0, 1fr) / minmax(0, 1fr);
  width: min(20rem, 100%);
  height: 8rem;
  isolation: isolate;
  max-width: 100%;
  overflow: visible;
  padding: 0 var(--fl-space-3) var(--fl-space-3) 0;
  position: relative;
}

.md-content__inner.md-typeset .stack > * {
  box-sizing: border-box;
  grid-area: 1 / 1;
  height: 100%;
  min-width: 0;
  place-self: stretch;
  width: 100%;
}

.md-content__inner.md-typeset .stack > :nth-child(1) {
  transform: translate(0, 0);
  z-index: 3;
}

.md-content__inner.md-typeset .stack > :nth-child(2) {
  transform: translate(var(--fl-space-2), var(--fl-space-2));
  z-index: 2;
}

.md-content__inner.md-typeset .stack > :nth-child(3) {
  transform: translate(var(--fl-space-3), var(--fl-space-3));
  z-index: 1;
}

@media (prefers-reduced-motion: reduce) {
  .md-content__inner.md-typeset .aura,
  .md-content__inner.md-typeset .aura::before,
  .md-content__inner.md-typeset .aura::after {
    animation: none !important;
    filter: none !important;
    transform: none;
  }
}

.md-content__inner.md-typeset .mockup-code {
  background: var(--color-neutral);
  border-radius: var(--radius-box);
  color: var(--color-neutral-content);
  display: grid;
  max-width: var(--fl-measure);
  overflow: auto;
  padding-block: var(--fl-space-4);
}

.md-content__inner.md-typeset .mockup-code pre {
  background: transparent;
  color: inherit;
  margin: 0;
  min-width: 0;
  padding: .2rem 1rem .2rem 3rem;
  white-space: pre;
}

.md-content__inner.md-typeset .mockup-code code {
  background: transparent;
  color: inherit;
  padding: 0;
}

.md-content__inner.md-typeset .footer {
  box-sizing: border-box;
  display: grid;
  gap: var(--fl-space-8);
  grid-auto-flow: column;
  justify-content: start;
  max-width: var(--fl-measure);
  padding: var(--fl-space-8);
  width: 100%;
}

.md-content__inner.md-typeset .footer nav {
  display: grid;
  gap: var(--fl-space-2);
}

.md-content__inner.md-typeset .footer :is(a, h3, strong, span) {
  color: inherit;
}

.md-content__inner.md-typeset .hero-overlay {
  background-color: rgb(0 0 0 / .68);
}

.md-content__inner.md-typeset .fl-hero:has(.hero-overlay) .hero-content {
  color: white;
  position: relative;
  text-shadow: 0 1px 12px rgb(0 0 0 / .45);
}

.md-content__inner.md-typeset .alert-error {
  background: var(--color-error);
  color: var(--color-error-content);
}

.md-content__inner.md-typeset .dock {
  bottom: 0;
  contain: layout paint;
  left: 0;
  position: absolute;
  right: 0;
  top: auto;
}

.md-content__inner.md-typeset .drawer {
  contain: layout paint;
  overflow: clip;
  position: relative;
}

.md-content__inner.md-typeset .drawer-side {
  height: 100%;
  inset: 0;
  position: absolute;
  transition-property: opacity !important;
}

.md-content__inner.md-typeset .drawer-toggle:not(:checked) ~ .drawer-side {
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
}

.md-content__inner.md-typeset .drawer-toggle:checked ~ .drawer-side {
  opacity: 1;
  pointer-events: auto;
  visibility: visible;
}

.md-content__inner.md-typeset .drawer-side .menu {
  height: 100%;
  width: min(18rem, 82%);
}

.md-content__inner.md-typeset .drawer-side > nav {
  height: 100%;
  min-width: min(12.5rem, 82%);
  width: min(18rem, 82%);
}

.md-content__inner.md-typeset .drawer-side .menu a {
  overflow-wrap: normal;
  white-space: nowrap;
  word-break: normal;
}

.md-content__inner.md-typeset .fl-dropdown-specimen {
  min-height: 4rem;
  overflow: clip;
  position: relative;
}

.md-content__inner.md-typeset .fl-dropdown-specimen:has(> details.dropdown[open]) {
  min-height: 14rem;
}

.md-content__inner.md-typeset details.dropdown {
  display: inline-block;
  position: relative;
}

.md-content__inner.md-typeset details.dropdown:not([open]) {
  block-size: 2.5rem;
  border: 0;
  box-sizing: border-box;
  padding: 0;
}

.md-content__inner.md-typeset .dropdown-content {
  background: var(--color-base-100);
  border: 1px solid var(--color-base-300);
  border-radius: var(--radius-box);
  box-shadow: 0 10px 30px color-mix(in oklab, var(--color-base-content) 16%, transparent);
  margin-top: var(--fl-space-2);
  inline-size: min(16rem, calc(100vw - (2 * var(--fl-edge)) - var(--fl-space-4)));
  position: absolute;
  z-index: 4;
}

.md-content__inner.md-typeset details.dropdown > summary::before {
  content: none !important;
  display: none !important;
}

.md-content__inner.md-typeset details.dropdown > summary::after,
.md-content__inner.md-typeset .menu details > summary::after {
  content: none !important;
  display: none !important;
}

.md-content__inner.md-typeset #navigation-megamenu:popover-open {
  block-size: auto;
  background: var(--color-base-100);
  border: 1px solid var(--color-base-300);
  box-shadow: 0 12px 36px color-mix(in oklab, var(--color-base-content) 18%, transparent);
  display: grid !important;
  gap: var(--fl-space-2) var(--fl-space-4);
  grid-template-columns: repeat(3, minmax(0, 1fr));
  inline-size: min(36rem, calc(100vw - (2 * var(--fl-edge))));
  margin: var(--fl-space-2) 0 0;
  max-width: none;
  padding: var(--fl-space-4);
  position-area: block-end span-inline-end;
}

.md-content__inner.md-typeset #navigation-megamenu::backdrop {
  background: transparent;
}

.md-content__inner.md-typeset #navigation-megamenu:popover-open > li {
  display: block;
  opacity: 1;
  pointer-events: auto;
  position: static;
  transform: none;
  visibility: visible;
}

.md-content__inner.md-typeset .menu {
  background: var(--color-base-200);
  gap: 2px;
}

.md-content__inner.md-typeset .menu :is(a, button, summary) {
  border-radius: var(--radius-field);
  box-sizing: border-box;
  color: var(--color-base-content);
  line-height: 1.35;
  min-height: 2.25rem;
  padding: .45rem .7rem;
}

.md-content__inner.md-typeset .menu :is(a, button, summary):hover,
.md-content__inner.md-typeset .menu .menu-active {
  background: var(--color-base-300);
}

.md-content__inner.md-typeset .tabs {
  border-bottom: 1px solid var(--color-base-300);
  display: flex;
  gap: var(--fl-space-4);
}

.md-content__inner.md-typeset .tabs .tab {
  background: transparent;
  border: 0;
  border-bottom: 1px solid transparent;
  border-radius: 0;
  color: var(--color-base-content);
  font-size: .7rem;
  font-weight: 500;
  height: 2.296rem;
  line-height: 1.8;
  margin: 0;
  padding: 0;
  padding-inline: 0;
}

.md-content__inner.md-typeset .tabs .tab:checked,
.md-content__inner.md-typeset .tabs .tab:is(.tab-active, [aria-selected="true"]) {
  border-bottom-color: currentcolor;
  color: var(--color-base-content);
}

.md-content__inner.md-typeset .tabs .tab::before {
  content: none !important;
  display: none !important;
}

.md-content__inner.md-typeset table:not([class]),
.md-content__inner.md-typeset .table {
  border-collapse: collapse;
  border-radius: 0;
  font-size: .9em;
  overflow: hidden;
  width: 100%;
}

.md-content__inner.md-typeset table:not([class]) :is(th, td),
.md-content__inner.md-typeset .table :is(th, td) {
  border: 0;
  border-bottom: 1px solid var(--color-base-300);
  padding: .65rem .8rem;
  text-align: start;
}

.md-content__inner.md-typeset table:not([class]) thead,
.md-content__inner.md-typeset .table thead {
  background: var(--color-base-200);
}

.md-sidebar--primary .md-search__icon[for="__search"] {
  top: 50%;
  transform: translateY(-50%);
}

@media (max-width: 700px) {
  .md-content__inner.md-typeset > p + p {
    margin-top: var(--fl-space-4) !important;
    text-indent: 0;
  }

  .md-content__inner.md-typeset > blockquote {
    margin-left: 0;
  }

  .md-content__inner.md-typeset > p:has(.fl-bleed) {
    width: calc(100vw - (2 * var(--fl-edge)) - var(--fl-space-4));
  }

  .md-content__inner.md-typeset .footer {
    grid-auto-flow: row;
  }
}
