/* Scoped notebook. The al-folio shell, typography and all other pages stay intact. */
body.mx-explorer-page {
  position:relative; isolation:isolate; background-color:#07131f;
  background-image:linear-gradient(#17354855 1px,transparent 1px),linear-gradient(90deg,#17354855 1px,transparent 1px);
  background-size:48px 48px;
}
.mx-page-backdrop { position:fixed; inset:0; width:100%; height:100%; z-index:-1; pointer-events:none; }
body.mx-explorer-page main.content-page,
body.mx-explorer-page .content-explorer-page,
body.mx-explorer-page .content-explorer-page>.post-content { background:transparent; }
body.mx-explorer-page .content-explorer-page>.post-header,
body.mx-explorer-page .matrix-explorer .mx-heading {
  padding:1.5rem; border:1px solid #d5e1e9; border-radius:18px;
  background:#fcfdfe; box-shadow:0 18px 44px #0002;
}
body.mx-explorer-page .content-explorer-page>.post-header h1,
body.mx-explorer-page .matrix-explorer .mx-heading h2 { color:#142b3c; }
body.mx-explorer-page .content-explorer-page>.post-header p,
body.mx-explorer-page .matrix-explorer .mx-heading p { color:#4b5a67; }
body.mx-explorer-page .matrix-explorer .mx-heading .mx-kicker { color:#146779; }
body.mx-explorer-page .matrix-explorer .mx-heading a { color:#0056b3; }
body.mx-explorer-page .matrix-explorer .mx-heading { max-width:none; }
body.mx-explorer-page .matrix-explorer .mx-runtime-bar { background:#f7f9fb; border:1px solid #d5e1e9; border-radius:12px; padding:.75rem 1rem; }
body.mx-explorer-page .matrix-explorer .mx-scene {
  background:#fcfdfe; border:1px solid #d5e1e9; border-radius:16px; padding:1.5rem; margin:0 0 1.25rem;
  box-shadow:0 12px 30px #0002;
}
body.mx-explorer-page .matrix-explorer .mx-visual-caption {
  color:#4b5a67; background:#fcfdfe; border:1px solid #d5e1e9; border-radius:12px; padding:.75rem 1rem;
}
body.mx-explorer-page .matrix-explorer .mx-example,
body.mx-explorer-page .matrix-explorer .mx-decompositions,
body.mx-explorer-page .matrix-explorer .mx-related,
body.mx-explorer-page .matrix-explorer .mx-citation,
body.mx-explorer-page .saved-language { background:#f7f9fb; border:1px solid #d5e1e9; border-radius:16px; padding:1.25rem; }
body.mx-explorer-page .migration-footer { background:#0a1828ed; border-top:1px solid #355468; }
body.mx-explorer-page .matrix-explorer .mx-related a { color:#0056b3; text-decoration:underline; }
@media(max-width:760px) {
  body.mx-explorer-page .matrix-explorer .mx-visual { background:#07131f; border-radius:18px; }
  body.mx-explorer-page .content-explorer-page>.post-header,
  body.mx-explorer-page .matrix-explorer .mx-heading,
  body.mx-explorer-page .matrix-explorer .mx-scene { padding:1.15rem; }
}
.content-explorer-page>.post-content { max-width:none; }
.content-explorer-page>.post-content>:not(.matrix-explorer) { max-width:82ch; }
.matrix-explorer { --mx-a:#75d6e2; --mx-b:#bcb0f3; --mx-c:#f4c583; --mx-bg:#0c1823; margin:3rem 0; min-width:0; }
.matrix-explorer * { box-sizing:border-box; }
.matrix-explorer .mx-heading { max-width:70ch; margin-bottom:1.75rem; }
.matrix-explorer .mx-kicker { color:#4b647b; font:500 .875rem/1.5 ui-monospace,Consolas,monospace; letter-spacing:.04em; margin:0 0 .65rem; }
.matrix-explorer .mx-heading h2 { font-size:clamp(1.8rem,4vw,2.75rem); line-height:1.15; font-weight:400; margin:.3rem 0 1rem; }
.matrix-explorer .mx-model-label { font-size:.875rem; color:#525b64; }
.matrix-explorer .mx-help { font-size:.875rem; line-height:1.65; color:#525b64; }
.matrix-explorer .mx-settings { border:1px solid var(--line); border-radius:12px; padding:0 1.1rem; margin-bottom:1rem; background:#f7f9fb; }
.matrix-explorer summary { cursor:pointer; padding:1rem 0; min-height:44px; font-weight:500; }
.matrix-explorer .mx-settings summary span { display:block; margin-top:.3rem; font:400 .875rem/1.5 ui-monospace,monospace; color:#525b64; }
.matrix-explorer fieldset { border:0; padding:.5rem 0; margin:0; min-width:0; }
.matrix-explorer legend { font-size:1rem; font-weight:500; }
.matrix-explorer .mx-field-row { display:flex; flex-wrap:wrap; gap:.8rem; align-items:end; margin-bottom:.75rem; }
.matrix-explorer label { display:grid; gap:.3rem; flex:1 1 95px; min-width:0; font-size:.875rem; line-height:1.5; margin:0; }
.matrix-explorer input,.matrix-explorer select { width:100%; min-width:0; min-height:44px; padding:.5rem; border:1px solid #8495a4; border-radius:6px; color:#142b3c; background:#fff; font:inherit; font-size:1rem; line-height:1.5; font-weight:400; }
.matrix-explorer select { padding-right:1.8rem; appearance:none; background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='m1 1 5 5 5-5' fill='none' stroke='%232e4b61' stroke-width='2'/%3E%3C/svg%3E"); background-repeat:no-repeat; background-position:right .65rem center; }
.matrix-explorer .mx-status { min-height:1.5rem; color:#525b64; font-size:.875rem; margin:.75rem 0; }
.matrix-explorer .mx-runtime-bar { display:flex; flex-wrap:wrap; justify-content:space-between; align-items:center; gap:.5rem 1rem; margin:.75rem 0 1rem; }
.matrix-explorer .mx-runtime-bar .mx-status { flex:1 1 260px; margin:0; }
.matrix-explorer .mx-backdrop-control { display:flex; flex:0 1 auto; align-items:center; gap:.6rem; color:#4b5a67; }
.matrix-explorer .mx-backdrop-control select { width:150px; font-size:.875rem; }
.matrix-explorer .mx-story { display:grid; grid-template-columns:minmax(0,1.45fr) minmax(0,1fr); gap:2rem; align-items:start; }
.matrix-explorer .mx-visual { position:sticky; top:5rem; min-width:0; }
.matrix-explorer .mx-screen { background:var(--mx-bg); color:#edf4fa; border:1px solid #2b4153; border-radius:18px; overflow:hidden; box-shadow:0 16px 48px #10283d15; }
.matrix-explorer .mx-screen-top { display:flex; justify-content:space-between; flex-wrap:wrap; gap:.5rem; padding:1rem 1rem .6rem; color:#c1d0dd; font:.875rem/1.5 ui-monospace,monospace; }
.matrix-explorer .mx-screen-top span { color:inherit; }
.matrix-explorer .mx-legend { display:flex; justify-content:center; flex-wrap:wrap; gap:.4rem 1rem; font-size:.875rem; padding:.2rem .75rem .6rem; }
.matrix-explorer .mx-inspection-controls { display:flex; gap:.45rem; padding:0 .75rem .6rem; align-items:center; }
.matrix-explorer .mx-inspection-controls label { flex:1 1 0; }
.matrix-explorer .mx-inspection-controls select { background-color:#162d3f; color:#edf4fa; font-size:.875rem; padding-left:.4rem; background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='m1 1 5 5 5-5' fill='none' stroke='%23b7c8d7' stroke-width='2'/%3E%3C/svg%3E"); }
.matrix-explorer .mx-inspection-controls select:disabled { opacity:.65; }
.matrix-explorer[data-mx-geometric="true"] canvas { cursor:grab; }
.matrix-explorer[data-mx-geometric="true"] canvas:active { cursor:grabbing; }
.matrix-explorer .mx-decompositions { margin-top:1rem; border-bottom:1px solid var(--line); }
.matrix-explorer .mx-decompositions dl { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:1.5rem; }
.matrix-explorer .mx-decompositions dt { color:#173e59; font-size:1rem; font-weight:500; }
.matrix-explorer .mx-decompositions dd { font:inherit; margin:.5rem 0; }
.matrix-explorer .mx-decompositions code { white-space:normal; overflow-wrap:anywhere; }
.matrix-explorer .mx-a,.matrix-explorer .mx-static-A { color:var(--mx-a); }
.matrix-explorer .mx-b,.matrix-explorer .mx-static-B { color:var(--mx-b); }
.matrix-explorer .mx-c,.matrix-explorer .mx-static-C { color:var(--mx-c); }
.matrix-explorer .mx-canvas-wrap { position:relative; width:100%; height:340px; }
.matrix-explorer canvas { display:block; width:100%; height:100%; opacity:0; }
.matrix-explorer[data-mx-ready="true"]:not([data-mx-fallback="true"]):not([data-mx-reduced="true"]) canvas { opacity:1; }
.matrix-explorer .mx-poster { position:absolute; inset:0; display:flex; align-items:center; padding:1rem; }
.matrix-explorer[data-mx-ready="true"]:not([data-mx-fallback="true"]):not([data-mx-reduced="true"]) .mx-poster { display:none; }
.matrix-explorer .mx-screen .mx-static-diagram { color:#c1d0dd; width:100%; }
.matrix-explorer .mx-inspector { display:flex; gap:.5rem; align-items:center; margin:.3rem 1rem; }
.matrix-explorer .mx-view-label { color:#c1d0dd; margin:0; font-size:.875rem; flex:1; }
.matrix-explorer .mx-output { flex:0 1 145px; }
.matrix-explorer .mx-output select { background-color:#162d3f; color:#edf4fa; font-size:.875rem; background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='m1 1 5 5 5-5' fill='none' stroke='%23b7c8d7' stroke-width='2'/%3E%3C/svg%3E"); }
.matrix-explorer .mx-trace { color:#edf4fa; margin:.6rem 1rem 1rem; min-height:2.8rem; font:400 .95rem/1.55 ui-monospace,Consolas,monospace; overflow-wrap:anywhere; }
.matrix-explorer .mx-transport { padding:.8rem 1rem 1rem; border-top:1px solid #314555; }
.matrix-explorer button { min-height:44px; border:1px solid #506575; border-radius:6px; padding:.45rem .7rem; background:#152a3a; color:#edf4fa; font:inherit; font-size:.875rem; line-height:1.4; font-weight:400; cursor:pointer; }
.matrix-explorer button:hover { background:#23435a; border-color:#a7c4d8; }
.matrix-explorer button:disabled { cursor:default; color:#a9b7c2; background:#16232d; }
.matrix-explorer .mx-transport-buttons,.matrix-explorer .mx-step-buttons { display:flex; flex-wrap:wrap; gap:.5rem; }
.matrix-explorer .mx-step-buttons { justify-content:space-between; margin-top:.5rem; }
.matrix-explorer .mx-seek { margin:.65rem 0 0; color:#c1d0dd; }
.matrix-explorer input[type="range"] { accent-color:#75d6e2; padding:0; min-height:30px; background:transparent; border:0; }
.matrix-explorer .mx-visual-caption { color:#525b64; font-size:.875rem; line-height:1.6; margin:.75rem .25rem; }
.matrix-explorer .mx-scene { min-height:78vh; padding:3.5rem 0; border-top:1px solid var(--line); scroll-margin-top:7rem; }
.matrix-explorer .mx-scene:first-child { border-top:0; padding-top:1rem; }
.matrix-explorer .mx-scene h3 { font-size:1.6rem; line-height:1.2; font-weight:400; margin:.4rem 0 1.25rem; }
.matrix-explorer .mx-scene.is-active>.mx-kicker { color:#0056b3; }
.matrix-explorer .mx-narrative { min-width:0; }
.matrix-explorer .mx-equation { overflow-x:auto; overflow-y:hidden; max-width:100%; font-size:.9rem; padding:.25rem 0; margin:1rem 0; }
.matrix-explorer .katex { position:relative; }
.matrix-explorer .katex-display { margin:.5rem 0; }
.matrix-explorer .mx-code { font-size:.8rem; border-radius:8px; }
.matrix-explorer .mx-scene>.mx-static-diagram { display:block; width:100%; margin:1.5rem 0; color:#25445a; }
.matrix-explorer .mx-scene .mx-static-A { color:#096375; }
.matrix-explorer .mx-scene .mx-static-B { color:#644794; }
.matrix-explorer .mx-scene .mx-static-C { color:#81520d; }
.matrix-explorer[data-mx-ready="true"]:not([data-mx-fallback="true"]):not([data-mx-reduced="true"]) .mx-scene>.mx-static-diagram { display:none; }
.matrix-explorer .mx-dashboard { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:1px; background:#cdd8e1; border:1px solid #cdd8e1; border-radius:10px; overflow:hidden; margin:1.5rem 0; }
.matrix-explorer .mx-dashboard>div { background:#f7f9fb; padding:.85rem; min-width:0; }
.matrix-explorer dt { font-size:.875rem; font-weight:400; line-height:1.5; color:#4b5a67; }
.matrix-explorer dd { font:500 1rem/1.5 ui-monospace,monospace; color:#112d41; margin:.4rem 0 0; overflow-wrap:anywhere; }
.matrix-explorer .mx-bound { font-weight:500; color:#173e59; }
.matrix-explorer .mx-example { border-block:1px solid var(--line); margin-top:1.5rem; }
.matrix-explorer .mx-tables { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:1rem; }
.matrix-explorer .mx-tables table { display:table; width:100%; font:400 .95rem/1.6 ui-monospace,monospace; }
.matrix-explorer .mx-table-scroll { min-width:0; overflow-x:auto; }
.matrix-explorer .mx-table-scroll table { min-width:260px; }
.matrix-explorer .mx-citation { margin-top:2rem; padding:1.25rem; border:1px solid var(--line); border-radius:12px; }
.matrix-explorer .mx-citation pre { overflow-x:auto; max-width:100%; font-size:.875rem; }
.matrix-explorer .mx-citation h3 { font-size:1.25rem; }
.matrix-explorer .mx-citation a { color:#0056b3; text-decoration:underline; text-underline-offset:.15em; }
.matrix-explorer .mx-citation .bibliography { list-style:none; margin:0; padding:0; }
.matrix-explorer .mx-tables td { text-align:center; padding:.5rem .2rem; }
.matrix-explorer .mx-tables caption { caption-side:top; font-weight:500; color:#173e59; }
.matrix-explorer .mx-related { display:flex; flex-direction:column; align-items:start; gap:.6rem; margin-top:2rem; }
.matrix-explorer .mx-related h3 { font-size:1.25rem; }
.matrix-explorer :focus-visible { outline:3px solid #0056b3; outline-offset:4px; }
.matrix-explorer .mx-screen :focus-visible { outline-color:#a7eaf2; }
.matrix-explorer[data-mx-reduced="true"] .mx-story,.matrix-explorer[data-mx-fallback="true"] .mx-story { display:block; }
.matrix-explorer[data-mx-reduced="true"] .mx-visual,.matrix-explorer[data-mx-fallback="true"] .mx-visual { position:static; max-width:600px; margin-bottom:2rem; }
.matrix-explorer[data-mx-reduced="true"] .mx-scene,.matrix-explorer[data-mx-fallback="true"] .mx-scene { min-height:0; padding:2rem 0; }
.matrix-explorer[data-mx-reduced="true"] .mx-scene>.mx-static-diagram,.matrix-explorer[data-mx-fallback="true"] .mx-scene>.mx-static-diagram { max-width:500px; }
@media(max-width:760px) {
  .matrix-explorer .mx-story { grid-template-columns:minmax(0,1fr); gap:0; }
  .matrix-explorer .mx-visual { top:4.25rem; z-index:2; padding-bottom:.75rem; background:var(--global-bg-color); }
  .matrix-explorer .mx-canvas-wrap { height:230px; }
  .matrix-explorer .mx-screen-top { padding:.6rem .75rem .3rem; }
  .matrix-explorer .mx-legend { gap:.3rem .65rem; padding:.15rem .4rem; }
  .matrix-explorer .mx-trace { margin:.35rem .75rem .5rem; min-height:1.5rem; font-size:.875rem; }
  .matrix-explorer .mx-view-label { margin:.2rem .75rem; }
  .matrix-explorer .mx-transport { padding:.5rem .75rem; display:grid; grid-template-columns:1fr 1fr; gap:.25rem .5rem; }
  .matrix-explorer .mx-transport-buttons { grid-column:1/-1; }
  .matrix-explorer .mx-seek { margin:0; }
  .matrix-explorer .mx-step-buttons { margin:0; }
  .matrix-explorer .mx-step-buttons button { flex:1; padding:.3rem; }
  .matrix-explorer .mx-visual-caption { display:none; }
  .matrix-explorer .mx-scene { min-height:60vh; padding:2rem 0; }
  .matrix-explorer .mx-tables { gap:.35rem; }
  .matrix-explorer .mx-tables { grid-template-columns:minmax(0,1fr); }
  .matrix-explorer .mx-tables td { font-size:.875rem; }
  .matrix-explorer .mx-decompositions dl { grid-template-columns:minmax(0,1fr); }
}
@media(max-height:700px) { .matrix-explorer .mx-visual { position:relative; top:0; } }
@media(max-width:380px) {
  .matrix-explorer .mx-inspection-controls { gap:.35rem; padding-inline:.5rem; }
  .matrix-explorer .mx-inspection-controls button { padding-inline:.4rem; }
}
@media(prefers-reduced-motion:reduce) {
  .matrix-explorer .mx-story { display:block; }
  .matrix-explorer .mx-visual { position:static; max-width:600px; }
  .matrix-explorer .mx-scene { min-height:0; }
}
