/* Native MarkdownTheme presentation. Numbers come from tokens.js.
   The default face is the vendored Inter, not a system-font shorthand.
   Native MarkdownTheme has no letter-spacing and uses bold for every heading. */

@font-face {
  font-family: Inter;
  font-style: normal;
  font-weight: 400;
  font-display: block;
  src: url("../../assets/fonts/Inter/Inter-Regular.ttf") format("truetype");
}
@font-face {
  font-family: Inter;
  font-style: normal;
  font-weight: 500;
  font-display: block;
  src: url("../../assets/fonts/Inter/Inter-Medium.ttf") format("truetype");
}
@font-face {
  font-family: Inter;
  font-style: normal;
  font-weight: 600;
  font-display: block;
  src: url("../../assets/fonts/Inter/Inter-SemiBold.ttf") format("truetype");
}
@font-face {
  font-family: Inter;
  font-style: normal;
  font-weight: 700;
  font-display: block;
  src: url("../../assets/fonts/Inter/Inter-Bold.ttf") format("truetype");
}

:root {
  color-scheme: light dark;
  --sm-font: Inter, sans-serif;
  --sm-mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;
  --sm-text: light-dark(rgb(0 0 0 / 0.85), rgb(255 255 255 / 0.85));
  --sm-secondary: light-dark(rgb(0 0 0 / 0.49804), rgb(255 255 255 / 0.54902));
  --sm-canvas: light-dark(#ffffff, #1c1c1e);
  --sm-accent: light-dark(#007aff, #0a84ff);
  --sm-quote: light-dark(rgb(0 122 255 / 0.65), rgb(10 132 255 / 0.65));
  --sm-code-bg: light-dark(rgb(142 142 147 / 0.12), rgb(152 152 157 / 0.12));
  --sm-highlight: light-dark(rgb(255 214 10 / 0.32), rgb(255 214 10 / 0.28));
  --sm-find: light-dark(rgb(255 214 10 / 0.55), rgb(255 196 0 / 0.45));
  --sm-find-current: light-dark(rgb(255 149 0 / 0.55), rgb(255 159 10 / 0.55));
  --sm-table-bg: light-dark(rgb(0 0 0 / 0.0153), rgb(255 255 255 / 0.0153));
  --sm-table-head: light-dark(rgb(0 122 255 / 0.095), rgb(10 132 255 / 0.095));
  --sm-table-alt: light-dark(rgb(0 0 0 / 0.0272), rgb(255 255 255 / 0.0272));
  --sm-table-border: light-dark(rgb(0 0 0 / 0.1105), rgb(255 255 255 / 0.1105));
  --sm-table-accent: light-dark(rgb(0 122 255 / 0.85), rgb(10 132 255 / 0.85));
  --sm-caption: light-dark(rgb(0 0 0 / 0.72), rgb(255 255 255 / 0.72));
  --sm-focus: var(--sm-accent);
  --sm-selection: light-dark(rgb(0 122 255 / 0.28), rgb(10 132 255 / 0.4));
}

html[data-appearance="light"] { color-scheme: light; }
html[data-appearance="dark"] { color-scheme: dark; }
html[data-appearance="system"] { color-scheme: light dark; }

html[data-preset="gitHub"] {
  --sm-quote: light-dark(rgb(0 0 0 / 0.14), rgb(255 255 255 / 0.16));
  --sm-code-bg: light-dark(rgb(0 0 0 / 0.055), rgb(255 255 255 / 0.06));
  --sm-table-bg: transparent;
  --sm-table-head: light-dark(rgb(0 0 0 / 0.05), rgb(255 255 255 / 0.06));
  --sm-table-alt: light-dark(rgb(0 0 0 / 0.03), rgb(255 255 255 / 0.035));
  --sm-table-border: light-dark(rgb(0 0 0 / 0.14), rgb(255 255 255 / 0.16));
  --sm-table-accent: light-dark(rgb(0 0 0 / 0.2), rgb(255 255 255 / 0.22));
}

.sm-video {
  position: relative;
  width: min(100%, 640px);
  background: var(--sm-code-bg);
  border-radius: 8px;
  overflow: hidden;
}
.sm-video-poster, .sm-video-player { width: 100%; height: 100%; object-fit: contain; display: block; }
.sm-video-print { display: none; }
.sm-video-play {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 22px;
  background: rgb(0 0 0 / 0.45);
  color: white;
}
@media print {
  .sm-video-player, .sm-video-play { display: none !important; }
  .sm-video-print { display: block !important; width: 100%; height: auto; }
}
.sm-frame { position: relative; min-width: 0; }
.sm-doc {
  display: flex;
  flex-direction: column;
  gap: var(--sm-block-spacing, 12px);
  font-family: var(--sm-font);
  font-size: var(--sm-paragraph-size, 16px);
  line-height: var(--sm-paragraph-line, 22px);
  color: var(--sm-text);
  background: var(--sm-canvas);
  padding: 4px 2px 24px;
  outline: none;
}
.sm-doc ::selection { background: var(--sm-selection); }
.sm-doc:focus-visible { outline: 2px solid var(--sm-focus); outline-offset: 3px; }
.sm-block:focus {
  outline: 3px solid var(--sm-focus);
  outline-offset: 4px;
  scroll-margin-top: 16px;
}

.sm-block { margin: 0 0 var(--sm-block-spacing, 12px); min-width: 0; }
.sm-doc > .sm-block { margin-bottom: 0; }
.sm-doc > .sm-block[data-kind="hostBoundary"]:has(> .sm-host:empty) { display: none; }
.sm-block:last-child { margin-bottom: 0; }
.sm-p, .sm-h, .sm-quote, .sm-list { margin: 0; }
.sm-h {
  font-weight: var(--sm-heading-weight, 700);
}
.sm-block[data-kind="heading"] h1 { font-size: var(--sm-h1-size); line-height: var(--sm-h1-line); }
.sm-block[data-kind="heading"] h2 { font-size: var(--sm-h2-size); line-height: var(--sm-h2-line); }
.sm-block[data-kind="heading"] h3 { font-size: var(--sm-h3-size); line-height: var(--sm-h3-line); }
.sm-block[data-kind="heading"] h4 { font-size: var(--sm-h4-size); line-height: var(--sm-h4-line); }
.sm-block[data-kind="heading"] h5 { font-size: var(--sm-h5-size); line-height: var(--sm-h5-line); }
.sm-block[data-kind="heading"] h6 { font-size: var(--sm-h6-size); line-height: var(--sm-h6-line); }

[data-preset="gitHub"] .sm-block[data-kind="heading"] h1,
[data-preset="gitHub"] .sm-block[data-kind="heading"] h2 {
  border-bottom: 1px solid var(--sm-table-border);
  padding-bottom: 6px;
}
[data-preset="gitHub"] .sm-block[data-kind="heading"] h6 { color: var(--sm-secondary); }

.sm-flow { white-space: normal; overflow-wrap: anywhere; }
.sm-lines, .sm-flow, .sm-p { max-width: 100%; }
.sm-line {
  display: block;
  white-space: pre;
  overflow-wrap: normal;
  word-break: normal;
  box-sizing: border-box;
  width: max-content;
  max-width: none;
}
.sm-p > .sm-line, .sm-line:not(.sm-h) {
  line-height: var(--sm-paragraph-line, 22px);
  min-height: var(--sm-paragraph-line, 22px);
}
.sm-h > .sm-line { line-height: inherit; min-height: 0; }
.sm-line + .sm-line {
  margin-top: calc((var(--sm-inline-base-line, var(--sm-paragraph-line, 22px)) - var(--sm-inline-base-size, var(--sm-paragraph-size, 16px))) * 0.25);
}
.sm-h:is(h1) { --sm-inline-base-line: var(--sm-h1-line); --sm-inline-base-size: var(--sm-h1-size); }
.sm-h:is(h2) { --sm-inline-base-line: var(--sm-h2-line); --sm-inline-base-size: var(--sm-h2-size); }
.sm-h:is(h3) { --sm-inline-base-line: var(--sm-h3-line); --sm-inline-base-size: var(--sm-h3-size); }
.sm-h:is(h4) { --sm-inline-base-line: var(--sm-h4-line); --sm-inline-base-size: var(--sm-h4-size); }
.sm-h:is(h5) { --sm-inline-base-line: var(--sm-h5-line); --sm-inline-base-size: var(--sm-h5-size); }
.sm-h:is(h6) { --sm-inline-base-line: var(--sm-h6-line); --sm-inline-base-size: var(--sm-h6-size); }
.sm-line .sm-code-span { line-height: inherit; }

.sm-em { font-style: italic; }
.sm-strong { font-weight: 700; }
.sm-strike { text-decoration: line-through; }
.sm-code-span, .sm-token, .sm-code-text {
  font-family: var(--sm-mono);
  font-size: var(--sm-code-size, 14px);
  line-height: var(--sm-code-line, 20px);
}
.sm-code-span {
  background: transparent;
  border-radius: 4px;
  font-size: inherit;
  padding: 0;
}
.sm-mark { background: var(--sm-highlight); border-radius: 2px; }
.sm-sub { font-size: 0.75em; vertical-align: sub; }
.sm-sup { font-size: 0.75em; vertical-align: super; }
.sm-soft { white-space: pre-wrap; }

.sm-link {
  color: var(--sm-accent);
  text-decoration-line: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
  cursor: pointer;
}
.sm-link:hover { text-decoration-thickness: 1.5px; }
[data-links-decorated="all"] .sm-link { text-decoration: none; }
.sm-link:focus-visible { outline: 2px solid var(--sm-focus); outline-offset: 2px; border-radius: 2px; }
.sm-decoration {
  display: inline-block;
  width: min(var(--sm-decoration-cap, 16px), max(8px, 1em));
  height: min(var(--sm-decoration-cap, 16px), max(8px, 1em));
  margin-right: 0.28em;
  vertical-align: -0.2em;
  color: var(--sm-accent);
}
.sm-glyph { width: 100%; height: 100%; display: block; }
.sm-decoration-icon { width: 100%; height: 100%; object-fit: contain; }
.sm-denied { color: var(--sm-text); text-decoration: none; cursor: not-allowed; }

.sm-quote {
  display: flex;
  gap: var(--sm-quote-gap, 8px);
  color: var(--sm-secondary);
}
.sm-quote-body { flex: 1; min-width: 0; color: var(--sm-text); }
.sm-quote::before {
  content: "";
  flex: 0 0 var(--sm-quote-bar, 3px);
  width: var(--sm-quote-bar, 3px);
  background: var(--sm-quote);
  border-radius: 1px;
}
.sm-quote .sm-quote { margin-top: 4px; }

.sm-list { list-style: none; padding: 0; }
ul.sm-list > li.sm-item,
ol.sm-list > li.sm-item,
.sm-item { display: flex; align-items: flex-start; list-style: none; gap: 8px; }
.sm-item + .sm-item { margin-top: 4px; }
.sm-item-body > .sm-block { margin-bottom: 0; }
.sm-item-body > .sm-block + .sm-block { margin-top: var(--sm-block-spacing, 12px); }
.sm-item-body { min-width: 0; flex: 1; }
.sm-marker {
  flex: 0 0 var(--sm-marker-unordered, 28px);
  width: var(--sm-marker-unordered, 28px);
  text-align: end;
  padding-right: 0;
  box-sizing: border-box;
  color: var(--sm-secondary);
  font-family: var(--sm-mono);
  font-size: var(--sm-code-size, 14px);
  line-height: var(--sm-paragraph-line, 22px);
}
.sm-list-orderedList > .sm-item > .sm-marker { flex-basis: var(--sm-marker-ordered, 34px); width: var(--sm-marker-ordered, 34px); }
.sm-list-taskList > .sm-item > .sm-marker {
  flex-basis: var(--sm-marker-task, 28px);
  display: flex;
  justify-content: flex-end;
  align-items: center;
  height: var(--sm-paragraph-line, 22px);
  padding-right: 0;
}
.sm-task {
  width: 14px;
  height: 14px;
  box-sizing: border-box;
  border: 1.5px solid var(--sm-secondary);
  border-radius: 3px;
  display: inline-block;
  position: relative;
}
.sm-task-on { background: var(--sm-accent); border-color: var(--sm-accent); }
.sm-task-on::after {
  content: "";
  position: absolute;
  left: 4px;
  top: 1px;
  width: 3px;
  height: 7px;
  border: solid #fff;
  border-width: 0 1.5px 1.5px 0;
  transform: rotate(40deg);
}

.sm-rule {
  border: 0;
  border-top: 1px solid var(--sm-table-border);
  margin: 4px 0;
}
[data-preset="gitHub"] .sm-rule { margin: 8px 0; }

.sm-code, .sm-diagram, .sm-figure { margin: 0; }
.sm-code, .sm-diagram {
  background: var(--sm-code-bg);
  border-radius: var(--sm-code-radius, 6px);
  overflow: hidden;
}
/* Native diagram card: white in light, rgb(19,20,23) in dark, 12pt corners,
   hairline border. The figure hugs the drawing. The toolbar does not widen it. */
.sm-diagram {
  width: fit-content;
  max-width: 100%;
  background: light-dark(#ffffff, rgb(19 20 23));
  border-radius: 12px;
  box-shadow: inset 0 0 0 0.5px light-dark(rgb(0 0 0 / 0.18), rgb(255 255 255 / 0.16));
}
figure.sm-code.sm-diagram > .sm-code-bar,
.sm-diagram > .sm-diagram-bar {
  width: 0;
  min-width: 100%;
  box-sizing: border-box;
}
figure.sm-code.sm-diagram .sm-diagram-slot,
figure.sm-code.sm-diagram .sirius-mermaid-frame {
  width: max-content;
  max-width: 100%;
}
.sm-code-bar, .sm-diagram-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 10px 0;
  color: var(--sm-secondary);
  font-size: 12px;
  line-height: 16px;
}
.sm-code:not(.sm-diagram) > .sm-code-bar { padding: 4px 10px 2px; font-size: 11px; line-height: 14px; }
.sm-code-actions, .sm-diagram-bar { display: flex; gap: 4px; align-items: center; }
.sm-code-lang { font-weight: 600; margin-right: auto; }
.sm-code-btn, .sm-format-key {
  font: 600 12px/16px var(--sm-font);
  color: var(--sm-accent);
  background: transparent;
  border: 0;
  border-radius: 6px;
  padding: 4px 8px;
  cursor: pointer;
}
.sm-code:not(.sm-diagram) .sm-code-btn { display: inline-flex; align-items: center; justify-content: center; gap: 5px; min-height: 28px; min-width: 28px; font: 500 11px/14px var(--sm-font); color: var(--sm-secondary); padding: 0 8px; }
.sm-code-btn[data-copy] .sm-code-action-label { min-width: 3.5em; text-align: left; }
.sm-code-action-icon { width: 13px; height: 13px; flex: none; }
.sm-code-btn:hover, .sm-format-key:hover { background: light-dark(rgb(0 0 0 / 0.05), rgb(255 255 255 / 0.08)); }
.sm-code-btn:focus-visible, .sm-format-key:focus-visible { outline: 2px solid var(--sm-focus); outline-offset: 1px; }
.sm-code-scroll, .sm-table-scroll, .sm-math-scroll { overflow-x: auto; max-width: 100%; }
.sm-pre { margin: 0; }
.sm-code-text {
  display: block;
  padding: 4px var(--sm-code-pad, 10px) var(--sm-code-pad, 10px);
  white-space: pre;
  tab-size: 4;
}
.sm-code-text[data-trailing-newline="1"]::after { content: "\200b"; }
.sm-code[data-collapsed="1"] .sm-code-scroll,
.sm-code[data-collapsed="1"] .sm-diagram-slot { display: none; }
.sm-diagram[data-mermaid-presentation="markdown"] { width: 100%; position: relative; box-shadow: none; }
.sm-diagram[data-mermaid-presentation="markdown"]::after { content: ""; position: absolute; inset: 0; z-index: 2; border: 0.5px solid color-mix(in srgb, var(--sm-table-border) 55%, transparent); border-radius: 12px; pointer-events: none; }
.sm-diagram[data-mermaid-presentation="markdown"] > .sm-code-bar { display: none; }
.sm-diagram[data-mermaid-presentation="markdown"][data-collapsed="1"] > .sm-code-bar { display: flex; }
figure.sm-code.sm-diagram[data-mermaid-presentation="markdown"] .sm-diagram-slot,
figure.sm-code.sm-diagram[data-mermaid-presentation="markdown"] .sirius-mermaid-frame { width: 100%; }
.sirius-mermaid-frame[data-presentation="markdown"] .sirius-mermaid-viewport { display: flex; justify-content: center; align-items: center; min-height: 100%; }
.sirius-mermaid-frame[data-presentation="markdown"] svg { flex: none; }
.sm-mermaid-toolbar { display: flex; justify-content: flex-end; gap: 4px; padding: 0 12px; position: relative; }
.sm-mermaid-toolbar[hidden] { display: none; }
.sm-mermaid-overflow-expand { display: flex; align-items: center; justify-content: center; gap: 4px; width: 100%; min-height: 44px; color: var(--sm-accent); background: transparent; border: 0; font: 13px var(--sm-font); cursor: pointer; }
.sm-mermaid-overflow-expand svg { width: 16px; height: 16px; }
.sm-mermaid-overflow-expand[hidden] { display: none; }
.sm-mermaid-control { width: 28px; height: 28px; color: var(--sm-secondary); background: transparent; border: 0; cursor: pointer; font: 20px var(--sm-font); border-radius: 6px; padding: 4px; }
.sm-mermaid-control svg { width: 16px; height: 16px; }
.sm-mermaid-control:focus-visible { outline: 2px solid var(--sm-focus); outline-offset: -2px; }
.sm-mermaid-options { color: var(--sm-text); position: fixed; box-sizing: border-box; overflow-y: auto; z-index: 55; padding: 4px; border: 1px solid var(--sm-table-border); background: light-dark(white, #242a36); border-radius: 8px; box-shadow: 0 4px 12px #0003; }
.sm-mermaid-options button[hidden] { display: none; }
.sm-mermaid-options button { display: block; width: 100%; height: auto; min-height: 28px; text-align: left; font: 13px var(--sm-font); padding: 5px 12px; white-space: normal; }
.sm-mermaid-control:hover { background: light-dark(#0001, #fff1); }
.sm-mermaid-expanded { width: calc(100vw - 48px); height: calc(100vh - 48px); max-width: none; max-height: none; padding: 0; border: 0; background: light-dark(white, #131417); }
.sm-mermaid-expanded::backdrop { background: #0008; }
.sm-mermaid-expanded-actions { position: absolute; right: 16px; top: 16px; z-index: 2; display: flex; gap: 8px; }
.sm-mermaid-expanded .sirius-mermaid-frame { height: 100% !important; max-height: none !important; }
.sm-mermaid-modes { position: absolute; top: 16px; left: 16px; z-index: 2; display: flex; gap: 4px; }
.sm-mermaid-modes button { width: auto; padding: 0 12px; font: 14px var(--sm-font); }
.sm-mermaid-modes button[aria-pressed="true"] { font-weight: 600; color: var(--sm-text); }
.sm-mermaid-zoom { position: absolute; z-index: 2; bottom: 16px; left: 50%; transform: translateX(-50%); display: flex; gap: 8px; background: light-dark(#fffe, #131417ee); border-radius: 8px; }
.sm-mermaid-expanded::before, .sm-mermaid-expanded::after { content: ""; position: absolute; z-index: 1; left: 0; right: 0; height: 80px; pointer-events: none; }
.sm-mermaid-expanded::before { top: 0; background: linear-gradient(light-dark(white, #131417), light-dark(#ffffffe6, #131417e6), transparent); }
.sm-mermaid-expanded::after { bottom: 0; background: linear-gradient(transparent, light-dark(#ffffffe6, #131417e6), light-dark(white, #131417)); }
.sm-mermaid-zoom[hidden] { display: none; }
.sm-mermaid-zoom button { width: auto; min-width: 44px; font: 14px var(--sm-font); }
.sm-mermaid-expanded-source { position: absolute; inset: 60px 16px; margin: 0; padding: 16px; overflow: auto; white-space: pre; font: var(--sm-code-size)/var(--sm-code-line) var(--sm-mono); background: light-dark(white, #131417); color: var(--sm-text); }
.sm-code[data-provisional="code"] { outline: 1px dashed var(--sm-table-border); }

.sm-token-keyword { color: light-dark(var(--sm-syn-keyword-light), var(--sm-syn-keyword-dark)); }
.sm-token-string { color: light-dark(var(--sm-syn-string-light), var(--sm-syn-string-dark)); }
.sm-token-number { color: light-dark(var(--sm-syn-number-light), var(--sm-syn-number-dark)); }
.sm-token-comment { color: light-dark(var(--sm-syn-comment-light), var(--sm-syn-comment-dark)); }
.sm-token-property { color: light-dark(var(--sm-syn-property-light), var(--sm-syn-property-dark)); }
.sm-token-type { color: light-dark(var(--sm-syn-type-light), var(--sm-syn-type-dark)); }
.sm-token-function { color: light-dark(var(--sm-syn-function-light), var(--sm-syn-function-dark)); }
.sm-token-literal { color: light-dark(var(--sm-syn-literal-light), var(--sm-syn-literal-dark)); }
.sm-token-operator { color: light-dark(var(--sm-syn-operator-light), var(--sm-syn-operator-dark)); }
.sm-token-punctuation { color: light-dark(var(--sm-syn-punctuation-light), var(--sm-syn-punctuation-dark)); }
.sm-token-addition { color: light-dark(var(--sm-syn-addition-light), var(--sm-syn-addition-dark)); }
.sm-token-deletion { color: light-dark(var(--sm-syn-deletion-light), var(--sm-syn-deletion-dark)); }
.sm-token-meta { color: light-dark(var(--sm-syn-meta-light), var(--sm-syn-meta-dark)); }
.sm-token-section { color: light-dark(var(--sm-syn-section-light), var(--sm-syn-section-dark)); }

.sm-table {
  border: 0;
  box-shadow: inset 0 0 0 1px var(--sm-table-border);
  border-radius: var(--sm-table-radius, 8px);
  border-collapse: separate;
  border-spacing: 0;
  background: var(--sm-table-bg);
  overflow: hidden;
  min-width: max-content;
}
.sm-table-prepared { table-layout: fixed; min-width: 0; width: max-content; max-width: none; }
.sm-table-scroll { padding-block: 4px; }
.sm-cell {
  padding: var(--sm-table-pad-y, 9px) var(--sm-table-pad-x, 12px);
  border: 0;
  box-shadow: inset -1px 0 0 color-mix(in srgb, var(--sm-table-border) 72%, transparent), inset 0 -1px 0 var(--sm-table-border);
  text-align: start;
  vertical-align: top;
  min-height: var(--sm-table-min-row, 38px);
  font-size: inherit;
  line-height: inherit;
}
.sm-cell:last-child { box-shadow: inset 0 -1px 0 var(--sm-table-border); }
.sm-table tbody tr:last-child .sm-cell { box-shadow: inset -1px 0 0 color-mix(in srgb, var(--sm-table-border) 72%, transparent); }
.sm-table tbody tr:last-child .sm-cell:last-child { box-shadow: none; }
.sm-cell[data-align="center"] { text-align: center; }
.sm-cell[data-align="right"] { text-align: end; }
.sm-cell[data-align="center"] .sm-line { margin-inline: auto; }
.sm-cell[data-align="right"] .sm-line { margin-left: auto; }
thead .sm-cell { background: linear-gradient(to bottom, var(--sm-table-accent) 2px, transparent 2px), var(--sm-table-head); font-weight: 400; }
tbody tr:nth-child(even) .sm-cell { background: var(--sm-table-alt); }

.sm-frame,
.sm-lines,
.sm-flow,
.sm-cell-flow { container-type: inline-size; }
.sm-math { color: var(--sm-text); }
.sm-math-inline {
  display: inline-block;
  vertical-align: baseline;
  width: max-content;
  max-width: 100%;
  max-width: 100cqi;
  line-height: normal;
}
/* Horizontal scrolling stays on this outer box. Its overflow is not visible,
   so the baseline is the bottom margin edge; slot.js shifts that edge by the
   prepared descent. The slot itself contributes no strut. */
.sm-math-inline:has(.sm-math-has-svg) {
  overflow-x: auto;
  overflow-y: hidden;
  line-height: 0;
}
.sm-math-block { padding: 6px 0; text-align: center; }
.sm-math-slot { display: block; line-height: 0; }
.sm-math-fallback { font-family: var(--sm-mono); font-size: var(--sm-code-size, 14px); }
.sm-math-fallback-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.sm-math-slot svg { display: block; margin-inline: auto; max-width: none; }
.sm-math[data-sm-selected] .sm-math-slot > svg { background: var(--sm-selection); }
.sm-math[data-provisional="math"] .sm-math-fallback { opacity: 0.85; }

.sm-diagram-canvas { max-height: var(--sm-diagram-max-h, 420px); overflow: auto; padding: 8px 12px 12px; }
.sm-diagram-source, .sm-diagram-note {
  margin: 0;
  font-family: var(--sm-mono);
  font-size: var(--sm-code-size, 14px);
  line-height: var(--sm-code-line, 20px);
  white-space: pre-wrap;
  color: var(--sm-secondary);
}
.sm-diagram-svg svg { max-width: 100%; height: auto; }

.sm-image {
  display: inline-block;
  vertical-align: calc(-1 * var(--sm-descent, 0px));
  width: 320px;
  height: 52px;
  max-width: min(100%, var(--sm-image-max-w, 660px));
  max-height: var(--sm-image-max-h, 520px);
  background: light-dark(rgb(128 128 128 / 0.055), rgb(255 255 255 / 0.06));
  border: 1px solid light-dark(rgb(128 128 128 / 0.14), rgb(255 255 255 / 0.14));
  border-radius: 8px;
  overflow: hidden;
  box-sizing: border-box;
}
.sm-image-bitmap { width: 100%; height: 100%; object-fit: contain; display: block; }
.sm-image-reason {
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  width: 100%;
  height: 100%;
  padding: 10px;
  overflow: hidden;
  text-align: center;
  font-size: 13px;
  line-height: 1.2;
  color: var(--sm-secondary);
}
.sm-image-icon .sm-image-reason { display: none; }
.sm-image[data-align="center"] { display: block; margin-inline: auto; }
.sm-image[data-align="right"] { display: block; margin-left: auto; }
.sm-image-inline { vertical-align: baseline; max-width: min(var(--sm-image-container-width, 660px), var(--sm-image-max-w, 660px), var(--sm-image-natural-w, 660px)); }
.sm-image-inline[data-align] { display: inline-block; margin: 0; }
.sm-image-flow { position: relative; min-width: 0; }
.sm-image-flow > .sm-block { margin: 0; }
.sm-image-flow > .sm-block:first-child { z-index: 1; }
.sm-image-flow .sm-image-paragraph .sm-image { display: block; margin: 0;
  max-width: min(var(--sm-image-container-width, 660px), var(--sm-image-max-w, 660px), var(--sm-image-natural-w, 660px)); }
.sm-image-fit { width: 100%; height: auto; }
.sm-image-paragraph .sm-image { max-width: min(100%, var(--sm-image-max-w, 660px), var(--sm-image-natural-w, 660px)); }
.sm-image-selected { outline: 2px solid var(--sm-link, #087fff); outline-offset: 2px; }
.sm-image-actions { position: fixed; z-index: 50; display: flex; flex-wrap: wrap; box-sizing: border-box; gap: 4px; padding: 5px; border-radius: 9px;
  background: light-dark(#fff, #25262a); color: var(--sm-text); border: 1px solid light-dark(#d4d5d8, #505156);
  box-shadow: 0 3px 14px #0002; font: 13px system-ui; user-select: none; }
.sm-image-actions button { font: inherit; color: inherit; background: transparent; border: 0; border-radius: 5px; padding: 5px 7px; cursor: pointer; }
.sm-image-actions button:hover { background: light-dark(#eff0f3, #393b40); }
.sm-image-resize { position: fixed; z-index: 51; width: 44px; height: 44px; border: 0; padding: 16px;
  background: transparent; cursor: nwse-resize; touch-action: none; }
.sm-image-resize:disabled { cursor: progress; opacity: .4; }
.sm-image-resize::after { content: ""; display: block; width: 10px; height: 10px; background: white;
  border: 2px solid var(--sm-link, #087fff); border-radius: 50%; box-shadow: 0 1px 3px #0004; }
.sm-image-actions[hidden], .sm-image-resize[hidden] { display: none; }
@media print { .sm-image-actions, .sm-image-resize { display: none !important; } .sm-image-selected { outline: none; } }

.sm-caption {
  margin-top: 8px;
  font-size: 15px;
  line-height: 22px;
  color: var(--sm-caption);
}
.sm-caption-ordinal { font-weight: 650; color: var(--sm-text); }
html:not([data-preset="document"]) .sm-caption-ordinal { display: none; }

.sm-html { display: contents; }
.sm-html-empty { margin: 0; }
.sm-blank { height: 0; margin: 0; overflow: hidden; }
.sm-host { min-height: 8px; }
.sm-host:empty { display: none; }

.sm-format {
  position: fixed;
  box-sizing: border-box;
  z-index: 50;
  display: flex;
  flex-wrap: wrap;
  max-width: calc(100vw - 32px);
  align-items: center;
  gap: 3px;
  padding: 4px 6px;
  border-radius: 10px;
  background: light-dark(rgb(255 255 255 / 0.86), rgb(44 44 46 / 0.9));
  border: 1px solid light-dark(rgb(0 0 0 / 0.14), rgb(255 255 255 / 0.14));
  box-shadow: 0 2px 10px rgb(0 0 0 / 0.18);
  backdrop-filter: blur(16px);
}
.sm-format[hidden] { display: none; }
.sm-format-group { display: flex; flex-wrap: wrap; gap: 2px; }
.sm-format-key {
  min-width: 28px;
  min-height: 28px;
  padding: 0 6px;
  color: var(--sm-text);
  font-size: 13px;
}
.sm-format > .sm-format-key:last-child { min-width: 126px; }
.sm-format-sep { width: 1px; height: 16px; background: light-dark(rgb(0 0 0 / 0.16), rgb(255 255 255 / 0.16)); }

::highlight(sm-find) { background: var(--sm-find); color: inherit; }
::highlight(sm-find-current) { background: var(--sm-find-current); color: inherit; }

@media (prefers-reduced-motion: reduce) {
  .sm-doc, .sm-block, .sm-format { scroll-behavior: auto; transition: none; animation: none; }
}
@media (forced-colors: active) {
  .sm-doc { background: Canvas; color: CanvasText; }
  .sm-link { color: LinkText; }
  .sm-code, .sm-table, .sm-quote::before, .sm-task { forced-color-adjust: none; border-color: CanvasText; }
  .sm-code { background: Canvas; border: 1px solid CanvasText; }
  .sm-task-on { background: Highlight; }
  .sm-format { background: Canvas; border: 1px solid CanvasText; }
}
@media print {
  :root { color-scheme: light !important; }
  .sm-code-bar, .sm-diagram-bar, .sm-format, .sm-mermaid-toolbar,
  .sm-mermaid-overflow-expand, .sm-mermaid-options, [data-sm-find-overlay] { display: none !important; }
  .sm-code-scroll, .sm-table-scroll, .sm-math-scroll { overflow: visible; }
  .sm-code[data-collapsed="1"] .sm-code-scroll { display: block; }
  .sm-code-text { white-space: pre-wrap; }
  .sm-block { break-inside: avoid; content-visibility: visible; }
  .sm-math-fallback-hidden { display: none; }
  .sm-line { white-space: pre-wrap !important; width: auto; max-width: 100%; }
  .sm-math-slot svg { max-width: 100%; height: auto; }
  figure.sm-code.sm-diagram .sirius-mermaid-frame {
    overflow: visible !important; height: auto !important; max-height: none !important;
  }
  .sirius-mermaid-viewport { transform: none !important; display: block !important; }
  .sirius-mermaid-viewport > svg {
    width: auto !important; max-width: 100% !important; height: auto !important;
    background: var(--sm-diagram-canvas, white);
    print-color-adjust: exact; -webkit-print-color-adjust: exact;
  }
}

/* Export snapshots use semantic cell runs, never reader-width line boxes. */
.sm-print-measure { position: absolute; left: -100000px; top: 0; visibility: hidden; pointer-events: none; }
.sm-readable-document { color-scheme: light; --sm-text: rgb(0 0 0 / 0.85); --sm-secondary: rgb(0 0 0 / 0.5); --sm-canvas: white; background: white; }
.sm-readable-document .sm-cell-flow { white-space: normal; overflow-wrap: anywhere; container-type: normal; }
.sm-readable-document .sm-flow { container-type: normal; }
.sm-readable-document .sm-cell { overflow: visible; }
.sm-readable-document .sm-table { max-width: 100%; min-width: 0; table-layout: fixed; }
.sm-readable-document tr { break-inside: avoid; }
/* Every sheet already contains its header. Browser header repetition can
   pull a new table's header into the preceding fragment's page margin. */
.sm-readable-document thead { display: table-row-group; }
.sm-readable-table-scroll { overflow: visible; max-width: none; }
.sm-readable-table-page { margin-bottom: 24px; break-inside: avoid; }
.sm-readable-table-page + .sm-readable-table-page { break-before: page; }
.sm-readable-continuation { margin: 8px 0 0; font: 11px/16px var(--sm-font); color: var(--sm-secondary); }
@media print {
  .sm-readable-document { width: var(--sm-print-width) !important; max-width: 100%; display: block; }
  .sm-readable-document .sm-block:has(.sm-readable-table-page) { break-inside: auto; }
  .sm-readable-document .sm-readable-table-page { margin: 0; padding: 0; }
  .sm-readable-document .sm-block { margin-bottom: var(--sm-block-spacing, 12px); }
}
.sm-readable-document .sm-code-scroll, .sm-readable-document .sm-math-scroll { overflow: visible; }
.sm-readable-document .sm-code[data-collapsed="1"] .sm-code-scroll { display: block; }
.sm-readable-document .sm-code-text { white-space: pre-wrap; }
.sm-readable-document .sirius-mermaid-frame { overflow: visible !important; height: auto !important; max-height: none !important; }
.sm-readable-document .sirius-mermaid-viewport { transform: none !important; display: block !important; }
.sm-readable-document .sirius-mermaid-viewport > svg { width: auto !important; max-width: 100% !important; height: auto !important; }

/* A prepared diagram is one source-backed Find destination. */
[data-sm-find-overlay] { pointer-events: none; }
