Skip to content

Turn any idea, plan, or codebase into a beautiful interactive diagram. An agent skill for Claude Code, Codex, and more.

fix(viewer): fit compact automatic sequences on the first screen

tt-a1i5e2c7ef671bb
diff --git a/archify.zip b/archify.zip
index d3da6b28..acc542a6 100644
Binary files a/archify.zip and b/archify.zip differ
diff --git a/archify/assets/template.html b/archify/assets/template.html
index b647d248..d5cc24a9 100644
--- a/archify/assets/template.html
+++ b/archify/assets/template.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9466,6 +9467,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9754,7 +9757,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9773,17 +9776,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9819,10 +9826,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/archify/examples/class-payment-processors-rendered.html b/archify/examples/class-payment-processors-rendered.html
index 0e11654d..adb2dd4a 100644
--- a/archify/examples/class-payment-processors-rendered.html
+++ b/archify/examples/class-payment-processors-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9657,6 +9658,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9945,7 +9948,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9964,17 +9967,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -10010,10 +10017,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/archify/examples/class-payments-rendered.html b/archify/examples/class-payments-rendered.html
index 7c6db689..b14b4e2e 100644
--- a/archify/examples/class-payments-rendered.html
+++ b/archify/examples/class-payments-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9463,6 +9464,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9751,7 +9754,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9770,17 +9773,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9816,10 +9823,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/archify/examples/dataflow-product-analytics.html b/archify/examples/dataflow-product-analytics.html
index 8c4324d8..61c0124a 100644
--- a/archify/examples/dataflow-product-analytics.html
+++ b/archify/examples/dataflow-product-analytics.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9577,6 +9578,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9865,7 +9868,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9884,17 +9887,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9930,10 +9937,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/archify/examples/erd-orders-rendered.html b/archify/examples/erd-orders-rendered.html
index 91af14e9..39f1bf9a 100644
--- a/archify/examples/erd-orders-rendered.html
+++ b/archify/examples/erd-orders-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9745,6 +9746,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -10033,7 +10036,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -10052,17 +10055,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -10098,10 +10105,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/archify/examples/lifecycle-agent-run.html b/archify/examples/lifecycle-agent-run.html
index a767d1d7..c87f6035 100644
--- a/archify/examples/lifecycle-agent-run.html
+++ b/archify/examples/lifecycle-agent-run.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9589,6 +9590,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9877,7 +9880,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9896,17 +9899,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9942,10 +9949,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/archify/examples/sequence-cache-miss-request.html b/archify/examples/sequence-cache-miss-request.html
index 0a061a5e..c57e6d3e 100644
--- a/archify/examples/sequence-cache-miss-request.html
+++ b/archify/examples/sequence-cache-miss-request.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9592,6 +9593,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9880,7 +9883,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9899,17 +9902,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9945,10 +9952,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/archify/examples/subscription-billing-rendered.html b/archify/examples/subscription-billing-rendered.html
index aa2620b8..efb24310 100644
--- a/archify/examples/subscription-billing-rendered.html
+++ b/archify/examples/subscription-billing-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9969,6 +9970,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -10257,7 +10260,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -10276,17 +10279,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -10322,10 +10329,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/archify/examples/timeline-archify-dev-activity-rendered.html b/archify/examples/timeline-archify-dev-activity-rendered.html
index d4b42263..038afc22 100644
--- a/archify/examples/timeline-archify-dev-activity-rendered.html
+++ b/archify/examples/timeline-archify-dev-activity-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9669,6 +9670,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9957,7 +9960,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9976,17 +9979,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -10022,10 +10029,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/archify/examples/timeline-payment-incident-rendered.html b/archify/examples/timeline-payment-incident-rendered.html
index 7c88097e..8b0de775 100644
--- a/archify/examples/timeline-payment-incident-rendered.html
+++ b/archify/examples/timeline-payment-incident-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9454,6 +9455,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9742,7 +9745,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9761,17 +9764,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9807,10 +9814,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/archify/examples/tree-archify-repository-rendered.html b/archify/examples/tree-archify-repository-rendered.html
index b3c3564d..b5029f81 100644
--- a/archify/examples/tree-archify-repository-rendered.html
+++ b/archify/examples/tree-archify-repository-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9688,6 +9689,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9976,7 +9979,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9995,17 +9998,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -10041,10 +10048,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/archify/examples/tree-payment-platform-rendered.html b/archify/examples/tree-payment-platform-rendered.html
index ff38a6e6..9355cb70 100644
--- a/archify/examples/tree-payment-platform-rendered.html
+++ b/archify/examples/tree-payment-platform-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9469,6 +9470,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9757,7 +9760,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9776,17 +9779,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9822,10 +9829,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/archify/examples/waterfall-checkout-request-rendered.html b/archify/examples/waterfall-checkout-request-rendered.html
index 21d8f377..e112b297 100644
--- a/archify/examples/waterfall-checkout-request-rendered.html
+++ b/archify/examples/waterfall-checkout-request-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9451,6 +9452,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9739,7 +9742,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9758,17 +9761,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9804,10 +9811,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/archify/examples/waterfall-example-rebuild-rendered.html b/archify/examples/waterfall-example-rebuild-rendered.html
index c5d2aee8..880e7723 100644
--- a/archify/examples/waterfall-example-rebuild-rendered.html
+++ b/archify/examples/waterfall-example-rebuild-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9637,6 +9638,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9925,7 +9928,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9944,17 +9947,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9990,10 +9997,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/archify/examples/web-app-rendered.html b/archify/examples/web-app-rendered.html
index 11ff2214..f8e9cb64 100644
--- a/archify/examples/web-app-rendered.html
+++ b/archify/examples/web-app-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9565,6 +9566,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9853,7 +9856,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9872,17 +9875,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9918,10 +9925,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/archify/examples/workflow-agent-tool-call-rendered.html b/archify/examples/workflow-agent-tool-call-rendered.html
index 314cca9f..8c58a40a 100644
--- a/archify/examples/workflow-agent-tool-call-rendered.html
+++ b/archify/examples/workflow-agent-tool-call-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9583,6 +9584,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9871,7 +9874,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9890,17 +9893,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9936,10 +9943,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/docs/assets/archify-live-proof.gif b/docs/assets/archify-live-proof.gif
index 8dd13151..2bc01140 100644
Binary files a/docs/assets/archify-live-proof.gif and b/docs/assets/archify-live-proof.gif differ
diff --git a/docs/assets/archify-live-proof.json b/docs/assets/archify-live-proof.json
index 9380c020..027a269f 100644
--- a/docs/assets/archify-live-proof.json
+++ b/docs/assets/archify-live-proof.json
@@ -7,13 +7,13 @@
"fps": 10,
"frameCount": 54,
"durationSeconds": 5.4,
- "bytes": 828556,
- "sha256": "95c8bcbbab6e1360d25db00c3664324c81fa731ac40015c6166e165a64431ae9",
+ "bytes": 818517,
+ "sha256": "d94b3b683c8bccadf48203d1f528b25c008da710c02f91d609f06da9cf2d4559",
"scenes": [
{
"id": "signal-flow",
"artifact": "docs/gallery/artifacts/agent-tool-call.workflow.html",
- "artifactSha256": "9e9d633be97f552d402895216ee622e469cd04709da0dfc8d24ee6af363ca124",
+ "artifactSha256": "44812a1028297c410aedd7f36f05838834bfd36e4877ca898ac5c643af518399",
"hash": "#focus=planner&reach=downstream",
"eyebrow": "WORKFLOW · SIGNAL FLOW",
"title": "Agent Tool Call",
@@ -22,7 +22,7 @@
{
"id": "blueprint",
"artifact": "docs/gallery/artifacts/production-deployment.architecture.html",
- "artifactSha256": "e9f5bdaa095dc900ffe4760838568bd83a1ab5024b46289adcc2d8b5c0bab5f8",
+ "artifactSha256": "70f5982619e0beebf5e4d1af6bcaece5ada17ab67ba71a1a0fd3e811e2d19ce3",
"hash": "#lens=backend~database",
"eyebrow": "ARCHITECTURE · BLUEPRINT",
"title": "Production Deployment",
@@ -31,7 +31,7 @@
{
"id": "classic",
"artifact": "docs/gallery/artifacts/cache-miss.sequence.html",
- "artifactSha256": "1a65397a6450427a4a9d51f1087917d9709181a2ccea99a1199fd1559be3fd71",
+ "artifactSha256": "cc0ca20654ff9de79485aeefff53beef25f6f6fd09489d763bb4644d885d2833",
"hash": "#route=web~db",
"eyebrow": "SEQUENCE · CLASSIC",
"title": "Cache Miss Request",
diff --git a/docs/gallery.html b/docs/gallery.html
index dbfd6813..4dcad7ca 100644
--- a/docs/gallery.html
+++ b/docs/gallery.html
@@ -302,7 +302,7 @@
<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div>
<div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div>
<div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">12N · 11E</span></div>
- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="9e9d633be97f552d402895216ee622e469cd04709da0dfc8d24ee6af363ca124">9e9d633be97f</span></div>
+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="44812a1028297c410aedd7f36f05838834bfd36e4877ca898ac5c643af518399">44812a102829</span></div>
</div>
<div class="card-actions">
<a class="card-link primary" href="gallery/artifacts/agent-tool-call.workflow.html#focus=planner" target="_blank" rel="noopener" data-en="Explore focus ↗" data-zh="探索聚焦路径 ↗">Explore focus ↗</a>
@@ -332,7 +332,7 @@
<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div>
<div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div>
<div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">12N · 12E</span></div>
- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="e9f5bdaa095dc900ffe4760838568bd83a1ab5024b46289adcc2d8b5c0bab5f8">e9f5bdaa095d</span></div>
+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="70f5982619e0beebf5e4d1af6bcaece5ada17ab67ba71a1a0fd3e811e2d19ce3">70f5982619e0</span></div>
</div>
<div class="card-actions">
<a class="card-link primary" href="gallery/artifacts/production-deployment.architecture.html#focus=gateway" target="_blank" rel="noopener" data-en="Explore focus ↗" data-zh="探索聚焦路径 ↗">Explore focus ↗</a>
@@ -361,7 +361,7 @@
<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div>
<div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div>
<div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">7N · 12E</span></div>
- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="1a65397a6450427a4a9d51f1087917d9709181a2ccea99a1199fd1559be3fd71">1a65397a6450</span></div>
+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="cc0ca20654ff9de79485aeefff53beef25f6f6fd09489d763bb4644d885d2833">cc0ca20654ff</span></div>
</div>
<div class="card-actions">
<a class="card-link primary" href="gallery/artifacts/cache-miss.sequence.html#focus=redis" target="_blank" rel="noopener" data-en="Explore focus ↗" data-zh="探索聚焦路径 ↗">Explore focus ↗</a>
@@ -390,7 +390,7 @@
<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div>
<div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div>
<div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">10N · 10E</span></div>
- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="fdaca4d85a11af6a7845d236d0386926f6d91acbb08439c48f5d6383b911cff3">fdaca4d85a11</span></div>
+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="38586b011cf2a95804e257a7507a04634ce1ceac13cebbddcd50c88cc949f684">38586b011cf2</span></div>
</div>
<div class="card-actions">
<a class="card-link primary" href="gallery/artifacts/release-delivery.workflow.html#focus=approval" target="_blank" rel="noopener" data-en="Explore focus ↗" data-zh="探索聚焦路径 ↗">Explore focus ↗</a>
@@ -419,7 +419,7 @@
<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div>
<div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div>
<div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">11N · 10E</span></div>
- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="ef51f025cce61793824fd154245b2bf5df343874a523e2146eff694e59a8ef50">ef51f025cce6</span></div>
+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="3846abbba5b4e8945dd73181e0faed8dd1848ecc092051e1191ffcd1fe001e1c">3846abbba5b4</span></div>
</div>
<div class="card-actions">
<a class="card-link primary" href="gallery/artifacts/incident-response.workflow.html#focus=triage" target="_blank" rel="noopener" data-en="Explore focus ↗" data-zh="探索聚焦路径 ↗">Explore focus ↗</a>
@@ -448,7 +448,7 @@
<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div>
<div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div>
<div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">10N · 10E</span></div>
- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="8896e6da9307ab452bcf8e0d478f708f0ea4ae517efd330d322bfbec5ce7b9f5">8896e6da9307</span></div>
+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="fbb53751b38b3db1c19190820d7bc38caa2e6a878fefdbd99b6c30f25d3cd1cf">fbb53751b38b</span></div>
</div>
<div class="card-actions">
<a class="card-link primary" href="gallery/artifacts/product-analytics.dataflow.html#focus=consent" target="_blank" rel="noopener" data-en="Explore focus ↗" data-zh="探索聚焦路径 ↗">Explore focus ↗</a>
@@ -477,7 +477,7 @@
<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div>
<div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div>
<div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">7N · 14E</span></div>
- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="aa5109b63fbbf452da0e8f40e36d7bef45c6989fa456ffbafc95bc9e01204f34">aa5109b63fbb</span></div>
+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="48b16128cd1443fb78fcc5610e87c070bfff9775a7b2a0cd1c643acf04c90677">48b16128cd14</span></div>
</div>
<div class="card-actions">
<a class="card-link primary" href="gallery/artifacts/async-job-roundtrip.sequence.html#focus=queue" target="_blank" rel="noopener" data-en="Explore focus ↗" data-zh="探索聚焦路径 ↗">Explore focus ↗</a>
@@ -506,7 +506,7 @@
<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div>
<div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div>
<div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">12N · 12E</span></div>
- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="ae05b0707f89de68ce58cd45a9069ad50cdd77edc79359992288ac83f5382a80">ae05b0707f89</span></div>
+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="3244a771570cec682c135da20fa03882d14f9f9d9991570e484ef56258b5b20f">3244a771570c</span></div>
</div>
<div class="card-actions">
<a class="card-link primary" href="gallery/artifacts/event-stream.dataflow.html#focus=orders" target="_blank" rel="noopener" data-en="Explore focus ↗" data-zh="探索聚焦路径 ↗">Explore focus ↗</a>
@@ -535,7 +535,7 @@
<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div>
<div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div>
<div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">10N · 12E</span></div>
- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="88e481d8a20d726c1123e616ac4d3ab48a18b482ef8e43ee8754ac66115c5b39">88e481d8a20d</span></div>
+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="ea4f4df7bdbad4c616097a251714263059837ce692d7ca43dbf527db7f87b4be">ea4f4df7bdba</span></div>
</div>
<div class="card-actions">
<a class="card-link primary" href="gallery/artifacts/agent-run.lifecycle.html#focus=approval" target="_blank" rel="noopener" data-en="Explore focus ↗" data-zh="探索聚焦路径 ↗">Explore focus ↗</a>
@@ -564,7 +564,7 @@
<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div>
<div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div>
<div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">12N · 15E</span></div>
- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="0cf925d4f3a4c056639f9fa5f32bf3e0a4676f05f24a306b241b6ae11ee09d56">0cf925d4f3a4</span></div>
+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="2450a280589d387dccd18b7d87d62f8e7dd18d234ba49ba8e17333f9dbbe305b">2450a280589d</span></div>
</div>
<div class="card-actions">
<a class="card-link primary" href="gallery/artifacts/deployment-release.lifecycle.html#focus=live" target="_blank" rel="noopener" data-en="Explore focus ↗" data-zh="探索聚焦路径 ↗">Explore focus ↗</a>
@@ -593,7 +593,7 @@
<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div>
<div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div>
<div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">10N · 9E</span></div>
- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="747dbf4a3de9ebd096f585ce431e52019557989b3d4fa197f8d88e54aab8e233">747dbf4a3de9</span></div>
+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="b9d5ea191aa122b89255941eee1a3ff5fdefc9b58df12de76a0425c2f8772ad4">b9d5ea191aa1</span></div>
</div>
<div class="card-actions">
<a class="card-link primary" href="gallery/artifacts/web-app.architecture.html#focus=api" target="_blank" rel="noopener" data-en="Explore focus ↗" data-zh="探索聚焦路径 ↗">Explore focus ↗</a>
@@ -622,7 +622,7 @@
<div class="receipt-cell"><span class="receipt-label">Artifact</span><span class="receipt-value ok">9/9 pass</span></div>
<div class="receipt-cell"><span class="receipt-label">Composition</span><span class="receipt-value ok" title="0 crossings · 0 border runs · 0 micro segments · 0 cramped turns">SHOWCASE · PASS</span></div>
<div class="receipt-cell"><span class="receipt-label">Graph</span><span class="receipt-value">6N · 5E</span></div>
- <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="d1f3bd878a9af715e4db96732a4f2b5b191f3cfc8bb1ba57ef6d8a09b2057bfd">d1f3bd878a9a</span></div>
+ <div class="receipt-cell"><span class="receipt-label">SHA-256</span><span class="receipt-value" title="308351ea90c8a4727589f52009b6c175240a9aa8acaa9806679e14e13696627d">308351ea90c8</span></div>
</div>
<div class="card-actions">
<a class="card-link primary" href="gallery/artifacts/orders.erd.html#focus=order" target="_blank" rel="noopener" data-en="Explore focus ↗" data-zh="探索聚焦路径 ↗">Explore focus ↗</a>
@@ -701,8 +701,8 @@ receipt 108 checks / 12 artifacts / deterministic hashes</pre>
"engineeringProfile": null,
"nodeCount": 12,
"edgeCount": 11,
- "artifactBytes": 783730,
- "artifactSha256": "9e9d633be97f552d402895216ee622e469cd04709da0dfc8d24ee6af363ca124",
+ "artifactBytes": 784427,
+ "artifactSha256": "44812a1028297c410aedd7f36f05838834bfd36e4877ca898ac5c643af518399",
"sourceBytes": 4939,
"sourceSha256": "d67965d50872c97e4ff3476271e645bf19fab6b3ab44e111bdb44b063e3aa36f",
"checks": [
@@ -836,8 +836,8 @@ receipt 108 checks / 12 artifacts / deterministic hashes</pre>
"engineeringProfile": "deployment-ownership",
"nodeCount": 12,
"edgeCount": 12,
- "artifactBytes": 786448,
- "artifactSha256": "e9f5bdaa095dc900ffe4760838568bd83a1ab5024b46289adcc2d8b5c0bab5f8",
+ "artifactBytes": 787145,
+ "artifactSha256": "70f5982619e0beebf5e4d1af6bcaece5ada17ab67ba71a1a0fd3e811e2d19ce3",
"sourceBytes": 4734,
"sourceSha256": "610a5614667e8f108bdcf1769c9d7af5c3ce0fb62be3ea50550b10eb752e4bda",
"checks": [
@@ -969,8 +969,8 @@ receipt 108 checks / 12 artifacts / deterministic hashes</pre>
"engineeringProfile": null,
"nodeCount": 7,
"edgeCount": 12,
- "artifactBytes": 778261,
- "artifactSha256": "1a65397a6450427a4a9d51f1087917d9709181a2ccea99a1199fd1559be3fd71",
+ "artifactBytes": 778958,
+ "artifactSha256": "cc0ca20654ff9de79485aeefff53beef25f6f6fd09489d763bb4644d885d2833",
"sourceBytes": 3805,
"sourceSha256": "f8486daa803fff6c295cecca4604c561fbbf9acb2e83326022b5a87639e8afe6",
"checks": [
@@ -1103,8 +1103,8 @@ receipt 108 checks / 12 artifacts / deterministic hashes</pre>
"engineeringProfile": null,
"nodeCount": 10,
"edgeCount": 10,
- "artifactBytes": 779234,
- "artifactSha256": "fdaca4d85a11af6a7845d236d0386926f6d91acbb08439c48f5d6383b911cff3",
+ "artifactBytes": 779931,
+ "artifactSha256": "38586b011cf2a95804e257a7507a04634ce1ceac13cebbddcd50c88cc949f684",
"sourceBytes": 4510,
"sourceSha256": "dbd5c174af66296caec372e7214cf4df7158b50a563508e16826b95ab8d1cd6c",
"checks": [
@@ -1243,8 +1243,8 @@ receipt 108 checks / 12 artifacts / deterministic hashes</pre>
"engineeringProfile": null,
"nodeCount": 11,
"edgeCount": 10,
- "artifactBytes": 776554,
- "artifactSha256": "ef51f025cce61793824fd154245b2bf5df343874a523e2146eff694e59a8ef50",
+ "artifactBytes": 777251,
+ "artifactSha256": "3846abbba5b4e8945dd73181e0faed8dd1848ecc092051e1191ffcd1fe001e1c",
"sourceBytes": 4723,
"sourceSha256": "630be98449925d2716ecb8439f404b2bff5fe65ba905b0ad0baea6d96890c526",
"checks": [
@@ -1429,8 +1429,8 @@ receipt 108 checks / 12 artifacts / deterministic hashes</pre>
"engineeringProfile": null,
"nodeCount": 10,
"edgeCount": 10,
- "artifactBytes": 780556,
- "artifactSha256": "8896e6da9307ab452bcf8e0d478f708f0ea4ae517efd330d322bfbec5ce7b9f5",
+ "artifactBytes": 781253,
+ "artifactSha256": "fbb53751b38b3db1c19190820d7bc38caa2e6a878fefdbd99b6c30f25d3cd1cf",
"sourceBytes": 5035,
"sourceSha256": "8a635db9e51a5b1a8d2955b9d66f5b9a450e0a298432ce8f2e2f0be11f372e05",
"checks": [
@@ -1564,8 +1564,8 @@ receipt 108 checks / 12 artifacts / deterministic hashes</pre>
"engineeringProfile": null,
"nodeCount": 7,
"edgeCount": 14,
- "artifactBytes": 778607,
- "artifactSha256": "aa5109b63fbbf452da0e8f40e36d7bef45c6989fa456ffbafc95bc9e01204f34",
+ "artifactBytes": 779304,
+ "artifactSha256": "48b16128cd1443fb78fcc5610e87c070bfff9775a7b2a0cd1c643acf04c90677",
"sourceBytes": 3766,
"sourceSha256": "b8c6c52f1763ede2933c77deb8da59b3e06917bc41d27e66df896136456b859a",
"checks": [
@@ -1716,8 +1716,8 @@ receipt 108 checks / 12 artifacts / deterministic hashes</pre>
"engineeringProfile": null,
"nodeCount": 12,
"edgeCount": 12,
- "artifactBytes": 784476,
- "artifactSha256": "ae05b0707f89de68ce58cd45a9069ad50cdd77edc79359992288ac83f5382a80",
+ "artifactBytes": 785173,
+ "artifactSha256": "3244a771570cec682c135da20fa03882d14f9f9d9991570e484ef56258b5b20f",
"sourceBytes": 4769,
"sourceSha256": "3bdd77674282009c7c68d588cf8a3c495bc98a3be1b9c45327fd1801a6f83a23",
"checks": [
@@ -1868,8 +1868,8 @@ receipt 108 checks / 12 artifacts / deterministic hashes</pre>
"engineeringProfile": null,
"nodeCount": 10,
"edgeCount": 12,
- "artifactBytes": 784643,
- "artifactSha256": "88e481d8a20d726c1123e616ac4d3ab48a18b482ef8e43ee8754ac66115c5b39",
+ "artifactBytes": 785340,
+ "artifactSha256": "ea4f4df7bdbad4c616097a251714263059837ce692d7ca43dbf527db7f87b4be",
"sourceBytes": 3260,
"sourceSha256": "5ba36f5ce91ed428cb48b599e275424916d82b619b9a3231cbd1bbc3966fc54b",
"checks": [
@@ -1990,8 +1990,8 @@ receipt 108 checks / 12 artifacts / deterministic hashes</pre>
"engineeringProfile": null,
"nodeCount": 12,
"edgeCount": 15,
- "artifactBytes": 791419,
- "artifactSha256": "0cf925d4f3a4c056639f9fa5f32bf3e0a4676f05f24a306b241b6ae11ee09d56",
+ "artifactBytes": 792116,
+ "artifactSha256": "2450a280589d387dccd18b7d87d62f8e7dd18d234ba49ba8e17333f9dbbe305b",
"sourceBytes": 4155,
"sourceSha256": "e3dc105d03c1c9881160006cdace23cb5d8533803e337caf0ec287c64e775275",
"checks": [
@@ -2112,8 +2112,8 @@ receipt 108 checks / 12 artifacts / deterministic hashes</pre>
"engineeringProfile": null,
"nodeCount": 10,
"edgeCount": 9,
- "artifactBytes": 778261,
- "artifactSha256": "747dbf4a3de9ebd096f585ce431e52019557989b3d4fa197f8d88e54aab8e233",
+ "artifactBytes": 778958,
+ "artifactSha256": "b9d5ea191aa122b89255941eee1a3ff5fdefc9b58df12de76a0425c2f8772ad4",
"sourceBytes": 3197,
"sourceSha256": "95e051b27a9e4a3307e194c0f666fca4af51470be7e2228d400ff48aea5b353b",
"checks": [
@@ -2258,8 +2258,8 @@ receipt 108 checks / 12 artifacts / deterministic hashes</pre>
"engineeringProfile": null,
"nodeCount": 6,
"edgeCount": 5,
- "artifactBytes": 792774,
- "artifactSha256": "d1f3bd878a9af715e4db96732a4f2b5b191f3cfc8bb1ba57ef6d8a09b2057bfd",
+ "artifactBytes": 793471,
+ "artifactSha256": "308351ea90c8a4727589f52009b6c175240a9aa8acaa9806679e14e13696627d",
"sourceBytes": 7321,
"sourceSha256": "1777a374647084466f4d7ce3a968004be6ab70ac9cf82459b96bed7c556cdfdd",
"checks": [
diff --git a/docs/gallery/artifacts/agent-run.lifecycle.html b/docs/gallery/artifacts/agent-run.lifecycle.html
index a767d1d7..c87f6035 100644
--- a/docs/gallery/artifacts/agent-run.lifecycle.html
+++ b/docs/gallery/artifacts/agent-run.lifecycle.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9589,6 +9590,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9877,7 +9880,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9896,17 +9899,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9942,10 +9949,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/docs/gallery/artifacts/agent-tool-call.workflow.html b/docs/gallery/artifacts/agent-tool-call.workflow.html
index 314cca9f..8c58a40a 100644
--- a/docs/gallery/artifacts/agent-tool-call.workflow.html
+++ b/docs/gallery/artifacts/agent-tool-call.workflow.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9583,6 +9584,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9871,7 +9874,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9890,17 +9893,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9936,10 +9943,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/docs/gallery/artifacts/async-job-roundtrip.sequence.html b/docs/gallery/artifacts/async-job-roundtrip.sequence.html
index 28030eab..74303fbb 100644
--- a/docs/gallery/artifacts/async-job-roundtrip.sequence.html
+++ b/docs/gallery/artifacts/async-job-roundtrip.sequence.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9604,6 +9605,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9892,7 +9895,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9911,17 +9914,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9957,10 +9964,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/docs/gallery/artifacts/cache-miss.sequence.html b/docs/gallery/artifacts/cache-miss.sequence.html
index 0a061a5e..c57e6d3e 100644
--- a/docs/gallery/artifacts/cache-miss.sequence.html
+++ b/docs/gallery/artifacts/cache-miss.sequence.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9592,6 +9593,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9880,7 +9883,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9899,17 +9902,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9945,10 +9952,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/docs/gallery/artifacts/deployment-release.lifecycle.html b/docs/gallery/artifacts/deployment-release.lifecycle.html
index e0813e1d..d648734e 100644
--- a/docs/gallery/artifacts/deployment-release.lifecycle.html
+++ b/docs/gallery/artifacts/deployment-release.lifecycle.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9653,6 +9654,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9941,7 +9944,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9960,17 +9963,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -10006,10 +10013,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/docs/gallery/artifacts/event-stream.dataflow.html b/docs/gallery/artifacts/event-stream.dataflow.html
index b028766b..6dc09105 100644
--- a/docs/gallery/artifacts/event-stream.dataflow.html
+++ b/docs/gallery/artifacts/event-stream.dataflow.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9616,6 +9617,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9904,7 +9907,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9923,17 +9926,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9969,10 +9976,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/docs/gallery/artifacts/incident-response.workflow.html b/docs/gallery/artifacts/incident-response.workflow.html
index c8decb4e..855af66d 100644
--- a/docs/gallery/artifacts/incident-response.workflow.html
+++ b/docs/gallery/artifacts/incident-response.workflow.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9543,6 +9544,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9831,7 +9834,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9850,17 +9853,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9896,10 +9903,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/docs/gallery/artifacts/orders.erd.html b/docs/gallery/artifacts/orders.erd.html
index 91af14e9..39f1bf9a 100644
--- a/docs/gallery/artifacts/orders.erd.html
+++ b/docs/gallery/artifacts/orders.erd.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9745,6 +9746,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -10033,7 +10036,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -10052,17 +10055,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -10098,10 +10105,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/docs/gallery/artifacts/product-analytics.dataflow.html b/docs/gallery/artifacts/product-analytics.dataflow.html
index 8c4324d8..61c0124a 100644
--- a/docs/gallery/artifacts/product-analytics.dataflow.html
+++ b/docs/gallery/artifacts/product-analytics.dataflow.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9577,6 +9578,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9865,7 +9868,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9884,17 +9887,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9930,10 +9937,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/docs/gallery/artifacts/production-deployment.architecture.html b/docs/gallery/artifacts/production-deployment.architecture.html
index 4667eb12..14fd0557 100644
--- a/docs/gallery/artifacts/production-deployment.architecture.html
+++ b/docs/gallery/artifacts/production-deployment.architecture.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9620,6 +9621,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9908,7 +9911,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9927,17 +9930,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9973,10 +9980,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/docs/gallery/artifacts/release-delivery.workflow.html b/docs/gallery/artifacts/release-delivery.workflow.html
index ed5ddc20..761eb3cb 100644
--- a/docs/gallery/artifacts/release-delivery.workflow.html
+++ b/docs/gallery/artifacts/release-delivery.workflow.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9569,6 +9570,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9857,7 +9860,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9876,17 +9879,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9922,10 +9929,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/docs/gallery/artifacts/web-app.architecture.html b/docs/gallery/artifacts/web-app.architecture.html
index 11ff2214..f8e9cb64 100644
--- a/docs/gallery/artifacts/web-app.architecture.html
+++ b/docs/gallery/artifacts/web-app.architecture.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9565,6 +9566,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9853,7 +9856,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9872,17 +9875,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9918,10 +9925,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/docs/gallery/manifest.json b/docs/gallery/manifest.json
index abe297f7..77c71833 100644
--- a/docs/gallery/manifest.json
+++ b/docs/gallery/manifest.json
@@ -19,8 +19,8 @@
"engineeringProfile": null,
"nodeCount": 12,
"edgeCount": 11,
- "artifactBytes": 783730,
- "artifactSha256": "9e9d633be97f552d402895216ee622e469cd04709da0dfc8d24ee6af363ca124",
+ "artifactBytes": 784427,
+ "artifactSha256": "44812a1028297c410aedd7f36f05838834bfd36e4877ca898ac5c643af518399",
"sourceBytes": 4939,
"sourceSha256": "d67965d50872c97e4ff3476271e645bf19fab6b3ab44e111bdb44b063e3aa36f",
"checks": [
@@ -154,8 +154,8 @@
"engineeringProfile": "deployment-ownership",
"nodeCount": 12,
"edgeCount": 12,
- "artifactBytes": 786448,
- "artifactSha256": "e9f5bdaa095dc900ffe4760838568bd83a1ab5024b46289adcc2d8b5c0bab5f8",
+ "artifactBytes": 787145,
+ "artifactSha256": "70f5982619e0beebf5e4d1af6bcaece5ada17ab67ba71a1a0fd3e811e2d19ce3",
"sourceBytes": 4734,
"sourceSha256": "610a5614667e8f108bdcf1769c9d7af5c3ce0fb62be3ea50550b10eb752e4bda",
"checks": [
@@ -287,8 +287,8 @@
"engineeringProfile": null,
"nodeCount": 7,
"edgeCount": 12,
- "artifactBytes": 778261,
- "artifactSha256": "1a65397a6450427a4a9d51f1087917d9709181a2ccea99a1199fd1559be3fd71",
+ "artifactBytes": 778958,
+ "artifactSha256": "cc0ca20654ff9de79485aeefff53beef25f6f6fd09489d763bb4644d885d2833",
"sourceBytes": 3805,
"sourceSha256": "f8486daa803fff6c295cecca4604c561fbbf9acb2e83326022b5a87639e8afe6",
"checks": [
@@ -421,8 +421,8 @@
"engineeringProfile": null,
"nodeCount": 10,
"edgeCount": 10,
- "artifactBytes": 779234,
- "artifactSha256": "fdaca4d85a11af6a7845d236d0386926f6d91acbb08439c48f5d6383b911cff3",
+ "artifactBytes": 779931,
+ "artifactSha256": "38586b011cf2a95804e257a7507a04634ce1ceac13cebbddcd50c88cc949f684",
"sourceBytes": 4510,
"sourceSha256": "dbd5c174af66296caec372e7214cf4df7158b50a563508e16826b95ab8d1cd6c",
"checks": [
@@ -561,8 +561,8 @@
"engineeringProfile": null,
"nodeCount": 11,
"edgeCount": 10,
- "artifactBytes": 776554,
- "artifactSha256": "ef51f025cce61793824fd154245b2bf5df343874a523e2146eff694e59a8ef50",
+ "artifactBytes": 777251,
+ "artifactSha256": "3846abbba5b4e8945dd73181e0faed8dd1848ecc092051e1191ffcd1fe001e1c",
"sourceBytes": 4723,
"sourceSha256": "630be98449925d2716ecb8439f404b2bff5fe65ba905b0ad0baea6d96890c526",
"checks": [
@@ -747,8 +747,8 @@
"engineeringProfile": null,
"nodeCount": 10,
"edgeCount": 10,
- "artifactBytes": 780556,
- "artifactSha256": "8896e6da9307ab452bcf8e0d478f708f0ea4ae517efd330d322bfbec5ce7b9f5",
+ "artifactBytes": 781253,
+ "artifactSha256": "fbb53751b38b3db1c19190820d7bc38caa2e6a878fefdbd99b6c30f25d3cd1cf",
"sourceBytes": 5035,
"sourceSha256": "8a635db9e51a5b1a8d2955b9d66f5b9a450e0a298432ce8f2e2f0be11f372e05",
"checks": [
@@ -882,8 +882,8 @@
"engineeringProfile": null,
"nodeCount": 7,
"edgeCount": 14,
- "artifactBytes": 778607,
- "artifactSha256": "aa5109b63fbbf452da0e8f40e36d7bef45c6989fa456ffbafc95bc9e01204f34",
+ "artifactBytes": 779304,
+ "artifactSha256": "48b16128cd1443fb78fcc5610e87c070bfff9775a7b2a0cd1c643acf04c90677",
"sourceBytes": 3766,
"sourceSha256": "b8c6c52f1763ede2933c77deb8da59b3e06917bc41d27e66df896136456b859a",
"checks": [
@@ -1034,8 +1034,8 @@
"engineeringProfile": null,
"nodeCount": 12,
"edgeCount": 12,
- "artifactBytes": 784476,
- "artifactSha256": "ae05b0707f89de68ce58cd45a9069ad50cdd77edc79359992288ac83f5382a80",
+ "artifactBytes": 785173,
+ "artifactSha256": "3244a771570cec682c135da20fa03882d14f9f9d9991570e484ef56258b5b20f",
"sourceBytes": 4769,
"sourceSha256": "3bdd77674282009c7c68d588cf8a3c495bc98a3be1b9c45327fd1801a6f83a23",
"checks": [
@@ -1186,8 +1186,8 @@
"engineeringProfile": null,
"nodeCount": 10,
"edgeCount": 12,
- "artifactBytes": 784643,
- "artifactSha256": "88e481d8a20d726c1123e616ac4d3ab48a18b482ef8e43ee8754ac66115c5b39",
+ "artifactBytes": 785340,
+ "artifactSha256": "ea4f4df7bdbad4c616097a251714263059837ce692d7ca43dbf527db7f87b4be",
"sourceBytes": 3260,
"sourceSha256": "5ba36f5ce91ed428cb48b599e275424916d82b619b9a3231cbd1bbc3966fc54b",
"checks": [
@@ -1308,8 +1308,8 @@
"engineeringProfile": null,
"nodeCount": 12,
"edgeCount": 15,
- "artifactBytes": 791419,
- "artifactSha256": "0cf925d4f3a4c056639f9fa5f32bf3e0a4676f05f24a306b241b6ae11ee09d56",
+ "artifactBytes": 792116,
+ "artifactSha256": "2450a280589d387dccd18b7d87d62f8e7dd18d234ba49ba8e17333f9dbbe305b",
"sourceBytes": 4155,
"sourceSha256": "e3dc105d03c1c9881160006cdace23cb5d8533803e337caf0ec287c64e775275",
"checks": [
@@ -1430,8 +1430,8 @@
"engineeringProfile": null,
"nodeCount": 10,
"edgeCount": 9,
- "artifactBytes": 778261,
- "artifactSha256": "747dbf4a3de9ebd096f585ce431e52019557989b3d4fa197f8d88e54aab8e233",
+ "artifactBytes": 778958,
+ "artifactSha256": "b9d5ea191aa122b89255941eee1a3ff5fdefc9b58df12de76a0425c2f8772ad4",
"sourceBytes": 3197,
"sourceSha256": "95e051b27a9e4a3307e194c0f666fca4af51470be7e2228d400ff48aea5b353b",
"checks": [
@@ -1576,8 +1576,8 @@
"engineeringProfile": null,
"nodeCount": 6,
"edgeCount": 5,
- "artifactBytes": 792774,
- "artifactSha256": "d1f3bd878a9af715e4db96732a4f2b5b191f3cfc8bb1ba57ef6d8a09b2057bfd",
+ "artifactBytes": 793471,
+ "artifactSha256": "308351ea90c8a4727589f52009b6c175240a9aa8acaa9806679e14e13696627d",
"sourceBytes": 7321,
"sourceSha256": "1777a374647084466f4d7ce3a968004be6ab70ac9cf82459b96bed7c556cdfdd",
"checks": [
diff --git a/docs/reading-evidence/compact-sequence/README.md b/docs/reading-evidence/compact-sequence/README.md
new file mode 100644
index 00000000..d927549b
--- /dev/null
+++ b/docs/reading-evidence/compact-sequence/README.md
@@ -0,0 +1,47 @@
+# Compact Sequence initial view
+
+The compact automatic Sequence in the regression fixture has three participants,
+six messages, and a 560×658 SVG. On `dev@9ef09617`, its ordinary initial view
+enlarges to 840×987, putting the final messages and legend below the first screen.
+The candidate fits the complete diagram without shrinking its source text.
+Long automatic sequences retain reading width and normal page scrolling.
+
+Both captures use the same redacted input, a 1396×830 viewport, dark theme,
+Classic preset, Read detail, camera at 100%, and page at scrollY=0.
+The baseline capture uses the unchanged base Reader fragment in the generated
+fixture; its CSS differs only by the updated explanatory comment. No runtime
+layout values are injected. [Observed bounds](observations.json) record the
+actual browser dimensions.
+
+| State | SVG size | Diagram bottom | Viewport height |
+| --- | --- | --- | --- |
+| Base | 840×987 | 1123 | 830 |
+| Candidate | 575×675.6 | 811.6 | 830 |
+
+| Before | After |
+| --- | --- |
+| ![Default view clips the last messages](before.png) | ![Complete default view](after.png) |
+
+The fixture removes repository and source references and uses generic labels.
+The reported real artifact was also inspected locally under the same conditions;
+its bounds match these captures. Perceptual review passed for the intended
+complete first-screen diagram, legend, and controls. Notes still belong below
+the diagram and may require ordinary page scrolling.
+
+Reproduce the candidate from the repository root:
+
+```sh
+node archify/bin/archify.mjs render sequence test/fixtures/reader-readability/compact-roundtrip.sequence.json /tmp/compact-sequence.html
+ARCHIFY_CHROME="/path/to/chrome" npm run test:focus -- test/reader-layout-browser.test.mjs
+```
+
+The added browser regression fails on the base and passes on the candidate.
+It also covers a shorter window and resize recovery, presentation entry/exit,
+a short wide sequence, a long automatic sequence, and an explicit canvas.
+Independent Chrome review exercised an expanded right rail across the fit
+threshold without layout oscillation or controls leaving the viewport. A window
+that cannot fit the original text size returns to the existing reading scale;
+the threshold transition is not a continuously interpolated scale.
+
+All SVG blocks in the 44 refreshed diagram HTML artifacts are byte-identical
+to the comparison base. The change affects the outer Reader layout only.
diff --git a/docs/reading-evidence/compact-sequence/after.png b/docs/reading-evidence/compact-sequence/after.png
new file mode 100644
index 00000000..46200141
Binary files /dev/null and b/docs/reading-evidence/compact-sequence/after.png differ
diff --git a/docs/reading-evidence/compact-sequence/before.png b/docs/reading-evidence/compact-sequence/before.png
new file mode 100644
index 00000000..6e47ec90
Binary files /dev/null and b/docs/reading-evidence/compact-sequence/before.png differ
diff --git a/docs/reading-evidence/compact-sequence/observations.json b/docs/reading-evidence/compact-sequence/observations.json
new file mode 100644
index 00000000..362703d3
--- /dev/null
+++ b/docs/reading-evidence/compact-sequence/observations.json
@@ -0,0 +1,64 @@
+{
+ "base": "9ef09617bd9ed2fe7bb4ad17fba7c8fce6b0ce76",
+ "input": "test/fixtures/reader-readability/compact-roundtrip.sequence.json",
+ "theme": "dark",
+ "preset": "classic",
+ "detail": "read",
+ "cameraScale": 1,
+ "records": [
+ {
+ "name": "before",
+ "viewport": [
+ 1396,
+ 830
+ ],
+ "viewBox": "0 0 560 658",
+ "svg": {
+ "top": 67,
+ "bottom": 1054,
+ "width": 840,
+ "height": 987
+ },
+ "stage": {
+ "top": 58,
+ "bottom": 1123,
+ "width": 1317,
+ "height": 1065
+ },
+ "controls": {
+ "top": 772,
+ "bottom": 814,
+ "width": 313.7421875,
+ "height": 42
+ },
+ "scale": 1.5
+ },
+ {
+ "name": "after",
+ "viewport": [
+ 1396,
+ 830
+ ],
+ "viewBox": "0 0 560 658",
+ "svg": {
+ "top": 67,
+ "bottom": 742.625,
+ "width": 575,
+ "height": 675.625
+ },
+ "stage": {
+ "top": 58,
+ "bottom": 811.625,
+ "width": 960,
+ "height": 753.625
+ },
+ "controls": {
+ "top": 752.625,
+ "bottom": 794.625,
+ "width": 313.7421875,
+ "height": 42
+ },
+ "scale": 1.0267857142857142
+ }
+ ]
+}
diff --git a/examples/checkout-platform-delta.html b/examples/checkout-platform-delta.html
index d9abf965..3644572c 100644
--- a/examples/checkout-platform-delta.html
+++ b/examples/checkout-platform-delta.html
@@ -435,7 +435,8 @@
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -5305,7 +5306,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -14201,6 +14203,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox &amp;&amp; viewBox.height &gt; 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg &amp;&amp; svg.getAttribute(&#39;data-reader-fit&#39;);
var widthFirstReading = readerFit === &#39;width-first&#39;;
+ var automaticSequence = widthFirstReading &amp;&amp; svg.hasAttribute(&#39;data-sequence-column-fit&#39;);
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === &#39;intrinsic-height&#39; || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -14489,7 +14493,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow &gt; 0 &amp;&amp; !widthFirstReading &amp;&amp; lastWidth &gt; Math.ceil(minWidth)) {
+ if (overflow &gt; 0 &amp;&amp; !readingScroll &amp;&amp; lastWidth &gt; Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute(&#39;data-reader-overflow&#39;, &#39;reduced&#39;);
@@ -14508,17 +14512,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox &amp;&amp; viewBox.width &gt; 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit &amp;&amp; ratio &lt; WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit &amp;&amp; ratio &lt; WIDE_RATIO
? readableWidth
: measuredHeightFit &amp;&amp; ratio &gt;= WIDE_RATIO &amp;&amp; Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit &amp;&amp; ratio &lt; WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit &amp;&amp; ratio &lt; WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit &amp;&amp; ratio &gt;= WIDE_RATIO &amp;&amp; Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -14554,10 +14562,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence &amp;&amp; Math.min(desiredWidth, maxWidth) &gt;=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading &amp;&amp; !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
@@ -19635,7 +19646,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -28533,6 +28545,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox &amp;&amp; viewBox.height &gt; 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg &amp;&amp; svg.getAttribute(&#39;data-reader-fit&#39;);
var widthFirstReading = readerFit === &#39;width-first&#39;;
+ var automaticSequence = widthFirstReading &amp;&amp; svg.hasAttribute(&#39;data-sequence-column-fit&#39;);
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === &#39;intrinsic-height&#39; || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -28821,7 +28835,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow &gt; 0 &amp;&amp; !widthFirstReading &amp;&amp; lastWidth &gt; Math.ceil(minWidth)) {
+ if (overflow &gt; 0 &amp;&amp; !readingScroll &amp;&amp; lastWidth &gt; Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute(&#39;data-reader-overflow&#39;, &#39;reduced&#39;);
@@ -28840,17 +28854,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox &amp;&amp; viewBox.width &gt; 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit &amp;&amp; ratio &lt; WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit &amp;&amp; ratio &lt; WIDE_RATIO
? readableWidth
: measuredHeightFit &amp;&amp; ratio &gt;= WIDE_RATIO &amp;&amp; Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit &amp;&amp; ratio &lt; WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit &amp;&amp; ratio &lt; WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit &amp;&amp; ratio &gt;= WIDE_RATIO &amp;&amp; Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -28886,10 +28904,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence &amp;&amp; Math.min(desiredWidth, maxWidth) &gt;=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading &amp;&amp; !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
@@ -33295,7 +33316,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
const status = document.querySelector('#review-status');
const receiptNode = document.querySelector('#archify-compare-receipt');
const reducedMotion = window.matchMedia('(prefers-reduced-motion: reduce)');
- const exportCss = "\n /* ==========================================================\n THEME VARIABLES — switch by toggling [data-theme] on \u003chtml\u003e\n ========================================================== */\n :root,\n [data-theme=\"dark\"] {\n --bg: #020617;\n --grid: #1e293b;\n --canvas-dot: rgba(148, 163, 184, 0.16);\n --text: #ffffff;\n --text-muted: #94a3b8;\n --text-dim: #475569;\n /* UI chrome and menu hints need more contrast than SVG .t-dim accents */\n --text-faint: #7d8da1;\n\n --panel: rgba(15, 23, 42, 0.5);\n --panel-border: #1e293b;\n --lane-fill: rgba(15, 23, 42, 0.22);\n --lane-stroke: #334155;\n\n --arrow: #64748b;\n --arrow-emphasis: #34d399;\n\n /* Opaque mask color used behind semi-transparent component fills\n so the arrows drawn underneath are properly hidden. */\n --mask: #0f172a;\n\n --frontend-fill: rgba(8, 51, 68, 0.4);\n --frontend-stroke: #22d3ee;\n --backend-fill: rgba(6, 78, 59, 0.4);\n --backend-stroke: #34d399;\n --database-fill: rgba(76, 29, 149, 0.4);\n --database-stroke: #a78bfa;\n --cloud-fill: rgba(120, 53, 15, 0.3);\n --cloud-stroke: #fbbf24;\n --security-fill: rgba(136, 19, 55, 0.4);\n --security-stroke: #fb7185;\n --messagebus-fill: rgba(251, 146, 60, 0.3);\n --messagebus-stroke:#fb923c;\n --external-fill: rgba(30, 41, 59, 0.5);\n --external-stroke: #94a3b8;\n\n --toolbar-bg: rgba(15, 23, 42, 0.8);\n --toolbar-border: #334155;\n --toolbar-text: #e2e8f0;\n --toolbar-hover: rgba(15, 23, 42, 0.95);\n --toolbar-menu-bg: #0f172a;\n }\n\n [data-theme=\"light\"] {\n --bg: #f4f5f7;\n --grid: #e9edf2;\n --canvas-dot: #d9dee5;\n --text: #111827;\n --text-muted: #5b6474;\n --text-dim: #9aa3b2;\n --text-faint: #6b7280;\n\n --panel: #ffffff;\n --panel-border: #e5e7eb;\n --lane-fill: rgba(248, 250, 252, 0.65);\n --lane-stroke: #cbd5e1;\n\n --arrow: #94a3b8;\n --arrow-emphasis: #059669;\n\n --mask: #ffffff;\n\n --frontend-fill: rgba(34, 211, 238, 0.15);\n --frontend-stroke: #0891b2;\n --backend-fill: rgba(52, 211, 153, 0.18);\n --backend-stroke: #059669;\n --database-fill: rgba(167, 139, 250, 0.2);\n --database-stroke: #7c3aed;\n --cloud-fill: rgba(251, 191, 36, 0.18);\n --cloud-stroke: #d97706;\n --security-fill: rgba(251, 113, 133, 0.15);\n --security-stroke: #e11d48;\n --messagebus-fill: rgba(251, 146, 60, 0.15);\n --messagebus-stroke: #ea580c;\n --external-fill: rgba(148, 163, 184, 0.18);\n --external-stroke: #64748b;\n\n --toolbar-bg: rgba(255, 255, 255, 0.92);\n --toolbar-border: #cbd5e1;\n --toolbar-text: #334155;\n --toolbar-hover: #ffffff;\n --toolbar-menu-bg: #ffffff;\n }\n\n /* ==========================================================\n SIGNAL FLOW — an opt-in, motion-forward visual preset.\n The variables also target a standalone exported SVG, whose\n root carries data-preset and data-theme directly.\n ========================================================== */\n [data-preset=\"signal-flow\"][data-theme=\"dark\"] {\n --bg: #030711;\n --grid: #15233a;\n --panel: rgba(6, 14, 28, 0.78);\n --panel-border: #1d3350;\n --lane-fill: rgba(9, 22, 40, 0.5);\n --lane-stroke: #2c4564;\n --text: #f5fbff;\n --text-muted: #9eb0c7;\n --text-dim: #52667f;\n --text-faint: #7890ad;\n --mask: #07101e;\n --frontend-fill: rgba(6, 182, 212, 0.14);\n --frontend-stroke: #67e8f9;\n --backend-fill: rgba(16, 185, 129, 0.14);\n --backend-stroke: #5eead4;\n --database-fill: rgba(139, 92, 246, 0.16);\n --database-stroke: #c4b5fd;\n --cloud-fill: rgba(245, 158, 11, 0.13);\n --cloud-stroke: #fcd34d;\n --security-fill: rgba(244, 63, 94, 0.13);\n --security-stroke: #fda4af;\n --messagebus-fill: rgba(249, 115, 22, 0.13);\n --messagebus-stroke: #fdba74;\n --external-fill: rgba(71, 85, 105, 0.24);\n --external-stroke: #a5b4c7;\n --arrow: #7890ad;\n --arrow-emphasis: #2dd4bf;\n --toolbar-bg: rgba(7, 16, 30, 0.86);\n --toolbar-border: #29415f;\n --toolbar-menu-bg: #07101e;\n }\n\n [data-preset=\"signal-flow\"][data-theme=\"light\"] {\n --bg: #f4f9fc;\n --grid: #d4e5ee;\n --panel: rgba(255, 255, 255, 0.82);\n --panel-border: #bfd5e2;\n --lane-fill: rgba(232, 243, 248, 0.62);\n --lane-stroke: #a9c5d5;\n --text: #102638;\n --text-muted: #587287;\n --text-dim: #8aa2b4;\n --text-faint: #668397;\n --mask: #ffffff;\n --frontend-fill: rgba(6, 182, 212, 0.09);\n --frontend-stroke: #0789a1;\n --backend-fill: rgba(5, 150, 105, 0.09);\n --backend-stroke: #087f69;\n --database-fill: rgba(124, 58, 237, 0.09);\n --database-stroke: #7254c7;\n --cloud-fill: rgba(217, 119, 6, 0.08);\n --cloud-stroke: #b9670b;\n --security-fill: rgba(225, 29, 72, 0.08);\n --security-stroke: #c53a59;\n --messagebus-fill: rgba(234, 88, 12, 0.08);\n --messagebus-stroke: #c65f27;\n --external-fill: rgba(100, 116, 139, 0.1);\n --external-stroke: #607a8c;\n --arrow: #7b97aa;\n --arrow-emphasis: #0d9488;\n }\n\n /* ==========================================================\n BLUEPRINT — a review-first drafting preset for deployment,\n infrastructure, and technical design documentation. It keeps\n the same semantic palette and geometry while trading glow for\n precise grid contrast, squared materials, and drafting marks.\n ========================================================== */\n [data-preset=\"blueprint\"][data-theme=\"dark\"] {\n --bg: #06131f;\n --grid: #17425a;\n --panel: rgba(7, 27, 43, 0.9);\n --panel-border: #27627f;\n --lane-fill: rgba(10, 43, 66, 0.36);\n --lane-stroke: #34799a;\n --text: #e3f6ff;\n --text-muted: #91b8ca;\n --text-dim: #557e92;\n --text-faint: #739caf;\n --mask: #0a2031;\n --frontend-fill: rgba(26, 157, 193, 0.14);\n --frontend-stroke: #66d9ef;\n --backend-fill: rgba(31, 155, 124, 0.13);\n --backend-stroke: #69dfbd;\n --database-fill: rgba(120, 105, 196, 0.14);\n --database-stroke: #b4a8ff;\n --cloud-fill: rgba(197, 145, 43, 0.13);\n --cloud-stroke: #ffd166;\n --security-fill: rgba(199, 76, 104, 0.13);\n --security-stroke: #ff8da1;\n --messagebus-fill: rgba(207, 112, 49, 0.13);\n --messagebus-stroke: #ffad66;\n --external-fill: rgba(84, 119, 139, 0.18);\n --external-stroke: #a7cad9;\n --arrow: #78a3b7;\n --arrow-emphasis: #64dfc1;\n --toolbar-bg: rgba(7, 28, 45, 0.92);\n --toolbar-border: #34799a;\n --toolbar-text: #d8f3ff;\n --toolbar-hover: rgba(18, 58, 83, 0.95);\n --toolbar-menu-bg: #0a2031;\n }\n\n [data-preset=\"blueprint\"][data-theme=\"light\"] {\n --bg: #edf7fa;\n --grid: #b5d5e1;\n --panel: rgba(249, 253, 255, 0.94);\n --panel-border: #78aabd;\n --lane-fill: rgba(210, 232, 240, 0.42);\n --lane-stroke: #83b2c4;\n --text: #123344;\n --text-muted: #4e7486;\n --text-dim: #86a6b4;\n --text-faint: #668c9d;\n --mask: #f9fdff;\n --frontend-fill: rgba(8, 145, 178, 0.08);\n --frontend-stroke: #087f9c;\n --backend-fill: rgba(5, 128, 101, 0.08);\n --backend-stroke: #08755f;\n --database-fill: rgba(100, 75, 180, 0.08);\n --database-stroke: #6757a8;\n --cloud-fill: rgba(181, 120, 15, 0.08);\n --cloud-stroke: #a86609;\n --security-fill: rgba(190, 48, 80, 0.07);\n --security-stroke: #b32f50;\n --messagebus-fill: rgba(196, 81, 22, 0.07);\n --messagebus-stroke: #b65120;\n --external-fill: rgba(79, 112, 128, 0.08);\n --external-stroke: #506f7e;\n --arrow: #6d93a5;\n --arrow-emphasis: #087f69;\n --toolbar-bg: rgba(247, 252, 254, 0.94);\n --toolbar-border: #8ab5c5;\n --toolbar-text: #294f61;\n --toolbar-hover: #ffffff;\n --toolbar-menu-bg: #f9fdff;\n }\n\n /* ==========================================================\n EDITORIAL — a warm, publication-minded preset for design\n reviews, launch notes, and documentation. The diagram keeps\n the same semantic palette and exact geometry, but trades\n software chrome for paper, ink, ruled structure, and one\n restrained vermilion accent.\n ========================================================== */\n [data-preset=\"editorial\"][data-theme=\"dark\"] {\n --bg: #181611;\n --grid: #39342a;\n --panel: rgba(35, 31, 24, 0.96);\n --panel-border: #625a4a;\n --lane-fill: rgba(52, 46, 35, 0.46);\n --lane-stroke: #726957;\n --text: #f4eddf;\n --text-muted: #b9ae9b;\n --text-dim: #776e60;\n --text-faint: #9d917e;\n --mask: #231f18;\n --frontend-fill: rgba(43, 133, 142, 0.16);\n --frontend-stroke: #7fc6c7;\n --backend-fill: rgba(63, 132, 92, 0.16);\n --backend-stroke: #8fc29e;\n --database-fill: rgba(117, 91, 141, 0.17);\n --database-stroke: #c0a4d0;\n --cloud-fill: rgba(170, 119, 49, 0.16);\n --cloud-stroke: #d8ad68;\n --security-fill: rgba(157, 69, 65, 0.17);\n --security-stroke: #df9085;\n --messagebus-fill: rgba(174, 79, 42, 0.16);\n --messagebus-stroke: #df946f;\n --external-fill: rgba(126, 115, 96, 0.18);\n --external-stroke: #b8ad99;\n --arrow: #948978;\n --arrow-emphasis: #dd6b3d;\n --toolbar-bg: rgba(35, 31, 24, 0.92);\n --toolbar-border: #625a4a;\n --toolbar-text: #eee5d5;\n --toolbar-hover: #302a20;\n --toolbar-menu-bg: #231f18;\n }\n\n [data-preset=\"editorial\"][data-theme=\"light\"] {\n --bg: #f2eee5;\n --grid: #d8d0c2;\n --panel: rgba(251, 248, 241, 0.97);\n --panel-border: #c4b9a6;\n --lane-fill: rgba(229, 221, 207, 0.42);\n --lane-stroke: #b8aa94;\n --text: #242018;\n --text-muted: #6f6658;\n --text-dim: #a09788;\n --text-faint: #817767;\n --mask: #fbf8f1;\n --frontend-fill: rgba(31, 117, 126, 0.09);\n --frontend-stroke: #287e84;\n --backend-fill: rgba(42, 119, 75, 0.09);\n --backend-stroke: #397b53;\n --database-fill: rgba(105, 75, 130, 0.09);\n --database-stroke: #765d86;\n --cloud-fill: rgba(157, 103, 31, 0.1);\n --cloud-stroke: #9a671f;\n --security-fill: rgba(153, 58, 52, 0.09);\n --security-stroke: #9e463f;\n --messagebus-fill: rgba(182, 70, 27, 0.09);\n --messagebus-stroke: #ad4b25;\n --external-fill: rgba(101, 91, 75, 0.09);\n --external-stroke: #746b5e;\n --arrow: #8a806f;\n --arrow-emphasis: #bb4c23;\n --toolbar-bg: rgba(251, 248, 241, 0.94);\n --toolbar-border: #c4b9a6;\n --toolbar-text: #40392f;\n --toolbar-hover: #fffdf8;\n --toolbar-menu-bg: #fbf8f1;\n }\n\n * { margin: 0; padding: 0; box-sizing: border-box; }\n\n body {\n --archify-page-top: 2rem;\n font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', 'Noto Sans CJK SC', 'Noto Sans', Roboto, 'Helvetica Neue', Arial, sans-serif;\n -webkit-font-smoothing: antialiased;\n background: var(--bg);\n min-height: 100vh;\n padding: var(--archify-page-top) 2rem 2rem;\n color: var(--text);\n /* Theme surfaces change together; animating the page background leaves it\n visibly out of sync with the SVG and panel for the first 200ms. */\n }\n\n html[data-preset=\"signal-flow\"] body {\n background-image:\n radial-gradient(circle at 18% -8%, rgba(34, 211, 238, 0.14), transparent 34rem),\n radial-gradient(circle at 92% 18%, rgba(139, 92, 246, 0.12), transparent 30rem);\n background-attachment: fixed;\n }\n html[data-preset=\"signal-flow\"][data-theme=\"light\"] body {\n background-image:\n radial-gradient(circle at 18% -8%, rgba(6, 182, 212, 0.12), transparent 34rem),\n radial-gradient(circle at 92% 18%, rgba(139, 92, 246, 0.08), transparent 30rem);\n }\n html[data-preset=\"blueprint\"] body {\n background-image:\n linear-gradient(var(--grid) 1px, transparent 1px),\n linear-gradient(90deg, var(--grid) 1px, transparent 1px);\n background-size: 32px 32px;\n background-position: -1px -1px;\n background-attachment: fixed;\n }\n html[data-preset=\"editorial\"] body {\n background-image:\n linear-gradient(90deg, transparent 0, transparent 5.4rem, color-mix(in srgb, var(--security-stroke) 18%, transparent) 5.4rem, color-mix(in srgb, var(--security-stroke) 18%, transparent) calc(5.4rem + 1px), transparent calc(5.4rem + 1px)),\n repeating-linear-gradient(0deg, transparent 0, transparent 31px, color-mix(in srgb, var(--grid) 36%, transparent) 31px, color-mix(in srgb, var(--grid) 36%, transparent) 32px);\n background-attachment: fixed;\n }\n\n /* Gallery/embed mode keeps the generated artifact as the source of truth\n while presenting only its diagram surface inside a proof card. */\n html[data-embed=\"true\"] body {\n min-height: 0;\n padding: 0;\n overflow: hidden;\n background: var(--bg);\n background-image: none;\n }\n html[data-embed=\"true\"] .toolbar,\n html[data-embed=\"true\"] .header,\n html[data-embed=\"true\"] .cards,\n html[data-embed=\"true\"] .diagram-nav,\n html[data-embed=\"true\"] .overview-map,\n html[data-embed=\"true\"] .focus-chip,\n html[data-embed=\"true\"] .route-probe,\n html[data-embed=\"true\"] .semantic-lens,\n html[data-embed=\"true\"] .diagram-guide,\n html[data-embed=\"true\"] .node-finder,\n html[data-embed=\"true\"] .node-outline { display: none !important; }\n html[data-embed=\"true\"] .container { max-width: none; }\n html[data-embed=\"true\"] .diagram-container {\n padding: 0.5rem;\n border: 0;\n border-radius: 0;\n box-shadow: none;\n }\n html[data-embed=\"true\"] .diagram-container svg { min-width: 0; }\n\n /* Presentation Stage is a viewer-only layer: it gives the live diagram\n the viewport while keeping guided views, theme, focus, and exports real.\n Embed mode wins when both query parameters are present. */\n html[data-present=\"true\"]:not([data-embed=\"true\"]) body {\n --archify-page-top: 1rem;\n height: 100dvh;\n min-height: 0;\n padding: 1rem;\n overflow: hidden;\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .container {\n display: flex;\n flex-direction: column;\n gap: 0.75rem;\n width: 100%;\n max-width: none;\n height: calc(100dvh - 2rem);\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .header {\n flex: none;\n min-width: 0;\n margin: 0;\n padding-right: 23rem;\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .header-row { margin-bottom: 0.25rem; }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .subtitle {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .diagram-container {\n display: flex;\n flex: 1 1 auto;\n align-items: center;\n justify-content: center;\n min-height: 0;\n padding: 0.75rem;\n padding-bottom: calc(0.75rem + var(--archify-nav-reserve));\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .diagram-container \u003e svg {\n flex: 1 1 auto;\n height: 100%;\n min-height: 0;\n width: 100%;\n min-width: 0;\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .cards { display: none; }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) #btn-present {\n border-color: var(--frontend-stroke);\n color: var(--frontend-stroke);\n }\n\n /* The reader owns only the outer scale. Long sequences and waterfall rows\n favor reading width and page scroll; other diagrams keep height fitting.\n Small automatic canvases retain a modest scale inside a usable shell.\n Every strategy preserves the authored SVG/viewBox and semantic geometry. */\n .container {\n width: 100%;\n max-width: var(--archify-reader-width, 1440px);\n margin: 0 auto;\n }\n html[data-reader-area=\"true\"] .diagram-container {\n min-height: var(--archify-diagram-min-height);\n display: flex;\n align-items: center;\n }\n html[data-reader-area=\"true\"] .diagram-container \u003e svg { flex-shrink: 0; }\n /* The original SVG legend can use the spare outer reader canvas while the\n capped diagram stays centered. The container still clips all outer paint. */\n .diagram-container:has([data-reader-legend-corner]) \u003e svg { overflow: visible; }\n .diagram-container [data-reader-legend-corner] {\n transform-origin: 0 0;\n transform-box: view-box;\n transform: var(--archify-reader-legend-transform);\n }\n html[data-reader-narrow=\"true\"]:not([data-present=\"true\"]) .diagram-container \u003e svg {\n min-width: 0;\n max-width: var(--archify-diagram-max-width);\n margin-inline: auto;\n }\n @media (min-width: 768px) and (max-height: 920px) {\n .header { margin-bottom: 1rem; }\n .diagram-container { padding: 1rem; }\n .cards { margin-top: 1rem; }\n .card { padding: 1rem; }\n }\n\n .header { margin-bottom: 1.5rem; padding-right: 29.5rem; }\n\n html[data-preset=\"signal-flow\"] .header,\n html[data-preset=\"blueprint\"] .header,\n html[data-preset=\"editorial\"] .header { padding-right: 29.5rem; }\n\n .header-row {\n display: flex;\n align-items: center;\n gap: 0.75rem;\n min-height: 2.75rem;\n margin-bottom: 0.25rem;\n }\n\n .pulse-dot {\n flex: none;\n width: 10px;\n height: 10px;\n background: var(--frontend-stroke);\n border-radius: 50%;\n box-shadow: 0 0 0 4px color-mix(in srgb, var(--frontend-stroke) 16%, transparent);\n animation: none;\n }\n\n html[data-motion-capable=\"true\"] .pulse-dot { animation: pulse 2s infinite; }\n\n @keyframes pulse {\n 0%, 100% { opacity: 1; }\n 50% { opacity: 0.5; }\n }\n\n h1 {\n font-size: 1.5rem;\n font-weight: 650;\n line-height: 1.25;\n letter-spacing: -0.015em;\n }\n\n .subtitle {\n color: var(--text-muted);\n font-size: 0.875rem;\n line-height: 1.55;\n margin-left: 1.375rem;\n }\n\n html[data-preset=\"signal-flow\"] .header-row::after {\n content: attr(data-preset-badge-signal-flow);\n flex: none;\n margin-left: 0.25rem;\n color: var(--frontend-stroke);\n border: 1px solid var(--frontend-stroke);\n border-radius: 999px;\n padding: 0.28rem 0.6rem;\n font-size: 0.625rem;\n letter-spacing: 0.12em;\n opacity: 0.82;\n box-shadow: 0 0 20px rgba(34, 211, 238, 0.12);\n white-space: nowrap;\n }\n\n html[data-preset=\"blueprint\"] .pulse-dot {\n width: 10px;\n height: 10px;\n border: 1px solid var(--frontend-stroke);\n border-radius: 1px;\n background: transparent;\n box-shadow: inset 0 0 0 2px var(--bg);\n transform: rotate(45deg);\n animation: none;\n }\n html[data-preset=\"blueprint\"] .header-row::after {\n content: attr(data-preset-badge-blueprint);\n flex: none;\n margin-left: 0.25rem;\n padding: 0.28rem 0.55rem;\n border-top: 1px solid var(--frontend-stroke);\n border-bottom: 1px solid var(--frontend-stroke);\n color: var(--frontend-stroke);\n font-size: 0.5625rem;\n font-weight: 700;\n letter-spacing: 0.14em;\n white-space: nowrap;\n }\n\n html[data-preset=\"editorial\"] h1,\n html[data-preset=\"editorial\"] .card h3 {\n font-family: Georgia, 'Times New Roman', 'Songti SC', STSong, serif;\n letter-spacing: -0.02em;\n }\n html[data-preset=\"editorial\"] h1 { font-size: 1.72rem; font-weight: 600; }\n html[data-preset=\"editorial\"] .pulse-dot {\n width: 9px;\n height: 9px;\n border: 1px solid var(--arrow-emphasis);\n border-radius: 0;\n background: var(--arrow-emphasis);\n box-shadow: 0 0 0 3px color-mix(in srgb, var(--arrow-emphasis) 14%, transparent);\n transform: rotate(45deg);\n animation: none;\n }\n html[data-preset=\"editorial\"] .header-row::after {\n content: attr(data-preset-badge-editorial);\n flex: none;\n margin-left: 0.25rem;\n padding: 0.32rem 0 0.24rem;\n border-bottom: 2px solid var(--arrow-emphasis);\n color: var(--arrow-emphasis);\n font-family: Georgia, 'Times New Roman', serif;\n font-size: 0.625rem;\n font-style: italic;\n font-weight: 600;\n letter-spacing: 0.08em;\n white-space: nowrap;\n }\n\n .diagram-container {\n --archify-nav-reserve: 0px;\n background: var(--panel);\n border-radius: 1rem;\n border: 1px solid var(--panel-border);\n box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 16px 40px -20px rgba(15, 23, 42, 0.18);\n padding: 1.5rem;\n padding-bottom: calc(1.5rem + var(--archify-nav-reserve));\n overflow: hidden;\n position: relative;\n }\n\n html[data-preset=\"signal-flow\"] .diagram-container {\n position: relative;\n overflow: hidden;\n background: linear-gradient(180deg, rgba(8, 20, 38, 0.82), rgba(3, 8, 18, 0.94));\n box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), 0 28px 80px rgba(0, 0, 0, 0.34);\n }\n html[data-preset=\"signal-flow\"][data-theme=\"light\"] .diagram-container {\n background: linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(237, 246, 250, 0.94));\n box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72), 0 24px 60px rgba(45, 78, 99, 0.12);\n }\n html[data-preset=\"blueprint\"] .diagram-container {\n border-color: var(--panel-border);\n border-radius: 0.35rem;\n background: var(--panel);\n box-shadow:\n inset 0 0 0 1px color-mix(in srgb, var(--panel-border) 34%, transparent),\n 0 18px 48px rgba(0, 0, 0, 0.16);\n }\n html[data-preset=\"blueprint\"] .diagram-container::after {\n content: \"\";\n position: absolute;\n z-index: 10;\n inset: 0.7rem;\n pointer-events: none;\n background:\n linear-gradient(var(--frontend-stroke), var(--frontend-stroke)) left top / 1.35rem 1px no-repeat,\n linear-gradient(var(--frontend-stroke), var(--frontend-stroke)) left top / 1px 1.35rem no-repeat,\n linear-gradient(var(--frontend-stroke), var(--frontend-stroke)) right top / 1.35rem 1px no-repeat,\n linear-gradient(var(--frontend-stroke), var(--frontend-stroke)) right top / 1px 1.35rem no-repeat,\n linear-gradient(var(--frontend-stroke), var(--frontend-stroke)) left bottom / 1.35rem 1px no-repeat,\n linear-gradient(var(--frontend-stroke), var(--frontend-stroke)) left bottom / 1px 1.35rem no-repeat,\n linear-gradient(var(--frontend-stroke), var(--frontend-stroke)) right bottom / 1.35rem 1px no-repeat,\n linear-gradient(var(--frontend-stroke), var(--frontend-stroke)) right bottom / 1px 1.35rem no-repeat;\n opacity: 0.58;\n }\n html[data-preset=\"editorial\"] .diagram-container {\n overflow: hidden;\n border-color: var(--panel-border);\n border-radius: 0.38rem;\n background:\n linear-gradient(90deg, color-mix(in srgb, var(--security-fill) 58%, transparent), transparent 12%),\n var(--panel);\n box-shadow:\n 0 1px 0 color-mix(in srgb, var(--text) 6%, transparent),\n 0 18px 48px color-mix(in srgb, #000 19%, transparent);\n }\n html[data-preset=\"editorial\"] .diagram-container::after {\n position: absolute;\n z-index: 10;\n top: 0.72rem;\n right: 1.25rem;\n padding: 0.2rem 0.52rem;\n border: 1px solid var(--panel-border);\n background: var(--panel);\n color: var(--arrow-emphasis);\n content: attr(data-preset-badge-editorial-plate);\n font-family: Georgia, 'Times New Roman', serif;\n font-size: 0.52rem;\n font-style: italic;\n font-weight: 600;\n letter-spacing: 0.09em;\n pointer-events: none;\n }\n html[data-embed=\"true\"][data-preset=\"editorial\"] .diagram-container::after { display: none; }\n html[data-motion-capable=\"true\"][data-preset=\"signal-flow\"][data-ambient-motion=\"running\"] .diagram-container::before {\n content: \"\";\n position: absolute;\n inset: 0;\n pointer-events: none;\n background: linear-gradient(115deg, transparent 28%, rgba(103, 232, 249, 0.035) 48%, transparent 68%);\n transform: translateX(-70%);\n animation: archify-signal-scan 4.8s ease-in-out 1 both;\n }\n\n /* Motion Governor gives the reader a real static state and gives the\n strongest semantic action the only motion budget. Atmosphere resets to\n its authored base instead of freezing mid-cycle. Static artifacts never\n start a decorative pulse or scan. */\n html:not([data-motion-capable=\"true\"]) svg[data-animation=\"trace\"] [data-animate] {\n animation: none !important;\n }\n html:not([data-motion-capable=\"true\"]) svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] {\n animation: none !important;\n }\n html[data-motion=\"still\"] .pulse-dot,\n html[data-motion=\"still\"] .diagram-container::before,\n html[data-motion=\"still\"] svg[data-animation=\"trace\"] [data-animate],\n html[data-motion-owner] .pulse-dot,\n html[data-motion-owner] .diagram-container::before,\n html[data-motion-owner] svg[data-animation=\"trace\"] [data-animate],\n html[data-embed=\"true\"] .pulse-dot,\n html[data-embed=\"true\"] .diagram-container::before,\n html[data-share-playback=\"true\"] .pulse-dot,\n html[data-share-playback=\"true\"] .diagram-container::before,\n html[data-document-hidden=\"true\"] .pulse-dot,\n html[data-document-hidden=\"true\"] .diagram-container::before,\n html[data-document-hidden=\"true\"] svg[data-animation=\"trace\"] [data-animate],\n html[data-motion=\"still\"] svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"],\n html[data-motion-owner] svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"],\n html[data-embed=\"true\"] svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"],\n html[data-share-playback=\"true\"] svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"],\n html[data-document-hidden=\"true\"] svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] {\n animation: none !important;\n }\n html[data-motion=\"still\"] .diagram-container::before,\n html[data-motion-owner] .diagram-container::before,\n html[data-embed=\"true\"] .diagram-container::before,\n html[data-share-playback=\"true\"] .diagram-container::before {\n opacity: 0;\n }\n html[data-motion=\"still\"] .intent-trace-flow,\n html[data-motion=\"still\"] .route-probe-flow,\n html[data-motion=\"still\"] .route-journey-flow,\n html[data-motion=\"still\"] .semantic-lens-flow,\n html[data-motion=\"still\"] .diagram-guide,\n html[data-motion=\"still\"] .overview-map-live,\n html[data-document-hidden=\"true\"] .intent-trace-flow,\n html[data-document-hidden=\"true\"] .route-probe-flow,\n html[data-document-hidden=\"true\"] .route-journey-flow,\n html[data-document-hidden=\"true\"] .semantic-lens-flow,\n html[data-document-hidden=\"true\"] .diagram-guide,\n html[data-document-hidden=\"true\"] .overview-map-live {\n animation: none !important;\n }\n\n html[data-motion=\"still\"] .intent-trace-flow,\n html[data-motion=\"still\"] .route-probe-flow {\n stroke-dasharray: none;\n stroke-dashoffset: 0;\n opacity: 0.72;\n }\n html[data-motion=\"still\"] .route-journey-overlay,\n html[data-document-hidden=\"true\"] .route-journey-overlay { display: none !important; }\n html[data-motion=\"still\"] .relationship-pulse-overlay { display: none !important; }\n\n html[data-motion=\"still\"] svg [data-node-id],\n html[data-motion=\"still\"] svg [data-edge-from],\n html[data-motion=\"still\"] svg [data-detail],\n html[data-motion=\"still\"] svg [data-detail-anchor],\n html[data-motion=\"still\"] svg [data-legend-hit],\n html[data-motion=\"still\"] svg {\n transition: none !important;\n }\n\n svg {\n font-family: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, 'DejaVu Sans Mono', 'Liberation Mono', 'Noto Sans Mono CJK SC', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', monospace;\n width: 100%;\n min-width: min(900px, 100%);\n display: block;\n transform-origin: 0 0;\n transition: transform 0.18s ease;\n }\n\n .diagram-container.is-camera-moving svg {\n transition: transform 0.42s cubic-bezier(0.22, 1, 0.36, 1);\n }\n .diagram-container.is-camera-transaction svg { transition: none; }\n .diagram-container.is-pannable { cursor: grab; }\n .diagram-container.is-panning { cursor: grabbing; user-select: none; }\n .diagram-container.is-panning svg { transition: none; }\n\n .diagram-nav {\n position: absolute;\n right: 1rem;\n bottom: 1rem;\n z-index: 12;\n translate: 0 calc(-1 * var(--archify-dock-lift, 0px));\n display: inline-flex;\n align-items: center;\n max-width: calc(100% - 2rem);\n padding: 0.25rem;\n gap: 0.0625rem;\n overflow-x: auto;\n border: 1px solid color-mix(in srgb, var(--panel-border) 80%, transparent);\n border-radius: 0.75rem;\n background: color-mix(in srgb, var(--panel) 84%, transparent);\n box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05), 0 10px 28px -14px rgba(15, 23, 42, 0.28);\n backdrop-filter: blur(14px) saturate(1.2);\n scrollbar-width: none;\n }\n .diagram-nav::-webkit-scrollbar { display: none; }\n .diagram-nav button,\n .focus-chip button {\n border: 0;\n background: transparent;\n color: var(--toolbar-text);\n font: inherit;\n cursor: pointer;\n }\n .diagram-nav button {\n min-width: 2rem;\n height: 2rem;\n padding: 0 0.4rem;\n border-radius: 0.5rem;\n color: var(--text-muted);\n font-size: 0.75rem;\n font-weight: 500;\n letter-spacing: 0;\n transition: background 0.15s, color 0.15s;\n }\n .diagram-nav button:hover,\n .diagram-nav button:focus-visible {\n color: var(--text);\n background: color-mix(in srgb, var(--text) 6%, transparent);\n }\n .diagram-nav button:hover,\n .diagram-nav button:focus-visible,\n .focus-chip button:hover,\n .focus-chip button:focus-visible { background: var(--toolbar-hover); }\n .diagram-nav button:focus-visible,\n .focus-chip button:focus-visible {\n outline: 2px solid var(--frontend-stroke);\n outline-offset: 1px;\n }\n .diagram-nav button:disabled { opacity: 0.38; cursor: default; }\n /* The Guide stays on the ? shortcut; Map only earns dock space once the\n reader has zoomed past the full diagram (or opened it from the keyboard). */\n .diagram-nav button[hidden] { display: none; }\n .diagram-container:not(.is-pannable) #btn-overview-map:not([data-radar-requested]):not(:focus) { display: none; }\n .diagram-nav button:disabled:hover { background: transparent; }\n .diagram-nav #btn-route-probe,\n .diagram-nav #btn-overview-map,\n .diagram-nav #btn-semantic-lens {\n min-width: auto;\n padding-inline: 0.6rem;\n color: var(--text-muted);\n font-weight: 500;\n }\n .diagram-nav #btn-node-finder,\n .diagram-nav [data-view=\"out\"] {\n position: relative;\n margin-left: 0.375rem;\n }\n .diagram-nav #btn-node-finder::before,\n .diagram-nav [data-view=\"out\"]::before {\n position: absolute;\n top: 0.55rem;\n bottom: 0.55rem;\n left: -0.19rem;\n width: 1px;\n background: color-mix(in srgb, var(--panel-border) 90%, transparent);\n content: \"\";\n pointer-events: none;\n }\n .diagram-nav-icon {\n display: block;\n width: 0.875rem;\n height: 0.875rem;\n margin: auto;\n background: currentColor;\n -webkit-mask-position: center;\n -webkit-mask-repeat: no-repeat;\n -webkit-mask-size: contain;\n mask-position: center;\n mask-repeat: no-repeat;\n mask-size: contain;\n }\n .diagram-nav-icon.find {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Ccircle cx='8.5' cy='8.5' r='4.5' fill='none' stroke='black' stroke-width='1.8'/%3E%3Cpath d='m12 12 4 4' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Ccircle cx='8.5' cy='8.5' r='4.5' fill='none' stroke='black' stroke-width='1.8'/%3E%3Cpath d='m12 12 4 4' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E\");\n }\n .diagram-nav-icon.guide {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Ccircle cx='10' cy='10' r='7' fill='none' stroke='black' stroke-width='1.7'/%3E%3Cpath d='M7.8 7.3a2.4 2.4 0 014.6.9c0 1.8-2.4 2-2.4 3.7M10 14.9h.01' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Ccircle cx='10' cy='10' r='7' fill='none' stroke='black' stroke-width='1.7'/%3E%3Cpath d='M7.8 7.3a2.4 2.4 0 014.6.9c0 1.8-2.4 2-2.4 3.7M10 14.9h.01' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round'/%3E%3C/svg%3E\");\n }\n .diagram-nav-icon.minus {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 10h10' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 10h10' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E\");\n }\n .diagram-nav-icon.plus {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M10 5v10M5 10h10' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M10 5v10M5 10h10' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E\");\n }\n .diagram-nav [data-view=\"reset\"] {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n gap: 0.2rem;\n min-width: 3.1rem;\n padding-inline: 0.35rem;\n }\n .diagram-nav [data-view=\"reset\"][data-detail-visible] {\n min-width: 3.8rem;\n }\n .diagram-nav-detail {\n color: color-mix(in srgb, var(--toolbar-text) 52%, transparent);\n font-size: 0.44rem;\n font-weight: 700;\n line-height: 1;\n letter-spacing: 0.07em;\n }\n .diagram-nav-percent {\n color: var(--text-muted);\n font-size: 0.75rem;\n font-weight: 500;\n font-variant-numeric: tabular-nums;\n line-height: 1;\n }\n /* Mode buttons carry a small glyph so the dock reads as one icon language. */\n .diagram-nav #btn-route-probe,\n .diagram-nav #btn-overview-map,\n .diagram-nav #btn-semantic-lens {\n display: inline-flex;\n align-items: center;\n gap: 0.375rem;\n padding-inline: 0.55rem 0.65rem;\n }\n .diagram-nav #btn-route-probe::before,\n .diagram-nav #btn-overview-map::before,\n .diagram-nav #btn-semantic-lens::before {\n flex: none;\n width: 0.875rem;\n height: 0.875rem;\n background: currentColor;\n content: \"\";\n opacity: 0.85;\n -webkit-mask: var(--nav-glyph) center / contain no-repeat;\n mask: var(--nav-glyph) center / contain no-repeat;\n }\n .diagram-nav #btn-route-probe { --nav-glyph: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cg fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round'%3E%3Ccircle cx='4.8' cy='14.8' r='2.2'/%3E%3Ccircle cx='15.2' cy='5.2' r='2.2'/%3E%3Cpath d='M6.9 13.9c3.8-1.4 2.6-6.3 6.2-7.8'/%3E%3C/g%3E%3C/svg%3E\"); }\n .diagram-nav #btn-overview-map { --nav-glyph: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cg fill='none' stroke='black' stroke-width='1.7' stroke-linejoin='round'%3E%3Cpath d='M2.8 5.4 7.4 3.5l5.2 2 4.6-1.9v11l-4.6 1.9-5.2-2-4.6 1.9z'/%3E%3Cpath d='M7.4 3.5v11M12.6 5.5v11'/%3E%3C/g%3E%3C/svg%3E\"); }\n .diagram-nav #btn-semantic-lens { --nav-glyph: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cg fill='none' stroke='black' stroke-width='1.7'%3E%3Ccircle cx='10' cy='10' r='6.8'/%3E%3Ccircle cx='10' cy='10' r='2.6'/%3E%3C/g%3E%3C/svg%3E\"); }\n /* Zoom out / level / zoom in join into one stepper well. */\n .diagram-nav [data-view=\"out\"],\n .diagram-nav [data-view=\"reset\"],\n .diagram-nav [data-view=\"in\"] {\n border-radius: 0;\n background: color-mix(in srgb, var(--text) 4.5%, transparent);\n }\n .diagram-nav [data-view=\"out\"] { margin-left: 0.375rem; border-radius: 0.5rem 0 0 0.5rem; }\n .diagram-nav [data-view=\"out\"]::before { display: none; }\n .diagram-nav [data-view=\"reset\"],\n .diagram-nav [data-view=\"in\"] { margin-left: -0.0625rem; }\n .diagram-nav [data-view=\"in\"] { border-radius: 0 0.5rem 0.5rem 0; }\n .diagram-nav [data-view=\"out\"]:hover,\n .diagram-nav [data-view=\"reset\"]:hover,\n .diagram-nav [data-view=\"in\"]:hover { background: color-mix(in srgb, var(--text) 9%, transparent); }\n .diagram-nav [data-view=\"out\"]:disabled,\n .diagram-nav [data-view=\"in\"]:disabled { opacity: 1; color: color-mix(in srgb, var(--text-muted) 40%, transparent); }\n .diagram-nav [data-view=\"out\"]:disabled:hover,\n .diagram-nav [data-view=\"in\"]:disabled:hover { background: color-mix(in srgb, var(--text) 4.5%, transparent); }\n .diagram-nav [data-view=\"reset\"] { min-width: 3.25rem; }\n .diagram-container[data-camera-indicator=\"true\"] .diagram-nav-detail,\n .diagram-container[data-camera-indicator=\"true\"] .diagram-nav-percent { color: var(--frontend-stroke); }\n .diagram-nav #btn-diagram-guide[aria-expanded=\"true\"] {\n color: var(--cloud-stroke);\n background: var(--toolbar-hover);\n }\n\n /* Semantic Radar is a deliberately simplified, viewer-only overview. It\n uses authored node bounds and the live camera viewport rather than\n cloning the canonical SVG, so IDs, filters, animation, and export state\n stay singular and deterministic. */\n .overview-map {\n position: absolute;\n right: 1rem;\n bottom: calc(4.15rem + var(--archify-nav-reserve));\n z-index: 12;\n width: 11.25rem;\n overflow: hidden;\n border: 1px solid color-mix(in srgb, var(--frontend-stroke) 52%, var(--toolbar-border));\n border-radius: 0.78rem;\n background: var(--toolbar-menu-bg);\n color: var(--toolbar-text);\n box-shadow: 0 16px 42px rgba(0, 0, 0, 0.3);\n backdrop-filter: blur(16px);\n font-size: 0.625rem;\n }\n .overview-map[hidden] { display: none; }\n .overview-map[data-docked=\"true\"] {\n position: fixed;\n right: var(--archify-radar-right, 1rem);\n top: var(--archify-radar-top, 1rem);\n bottom: auto;\n }\n .overview-map[data-docked=\"true\"][data-dock-side=\"left\"] {\n right: auto;\n left: var(--archify-radar-left, 1rem);\n }\n html[data-preset=\"blueprint\"] .overview-map { border-radius: 0.28rem; }\n .overview-map-head {\n display: grid;\n grid-template-columns: auto minmax(0, 1fr) auto;\n align-items: center;\n gap: 0.45rem;\n min-height: 2.25rem;\n padding: 0.42rem 0.48rem 0.38rem 0.55rem;\n border-bottom: 1px solid var(--toolbar-border);\n background: linear-gradient(110deg, color-mix(in srgb, var(--frontend-fill) 45%, transparent), transparent 68%);\n cursor: grab;\n touch-action: none;\n user-select: none;\n }\n .overview-map[data-panel-dragging=\"true\"] .overview-map-head { cursor: grabbing; }\n .overview-map[data-placement-invalid=\"true\"] {\n border-color: var(--security-stroke);\n box-shadow: 0 0 0 2px color-mix(in srgb, var(--security-stroke) 34%, transparent), 0 16px 42px rgba(0, 0, 0, 0.3);\n }\n .overview-map[data-compact=\"true\"] {\n width: 7.4rem;\n }\n .overview-map[data-compact=\"true\"] .overview-map-head {\n grid-template-columns: minmax(0, 1fr) auto;\n gap: 0.24rem;\n min-height: 1.5rem;\n padding: 0.05rem 0.16rem 0.05rem 0.32rem;\n border-bottom: 0;\n }\n .overview-map[data-compact=\"true\"] .overview-map-live,\n .overview-map[data-compact=\"true\"] .overview-map-copy,\n .overview-map[data-compact=\"true\"] .overview-map-surface,\n .overview-map[data-compact=\"true\"] .overview-map-hint {\n display: none;\n }\n .overview-map[data-compact=\"true\"] .overview-map-expand { display: inline-flex; }\n .overview-map[data-compact=\"true\"] .overview-map-close {\n width: 1.15rem;\n height: 1.15rem;\n font-size: 0.72rem;\n }\n .overview-map-live {\n width: 0.42rem;\n height: 0.42rem;\n border-radius: 50%;\n background: var(--backend-stroke);\n box-shadow: 0 0 0 0 color-mix(in srgb, var(--backend-stroke) 52%, transparent);\n animation: archify-radar-live 2.4s ease-out infinite;\n }\n .overview-map-copy { min-width: 0; line-height: 1.1; }\n .overview-map-copy strong {\n display: block;\n overflow: hidden;\n color: var(--frontend-stroke);\n font-size: 0.59rem;\n letter-spacing: 0.12em;\n text-transform: uppercase;\n white-space: nowrap;\n text-overflow: ellipsis;\n }\n .overview-map-copy small {\n display: block;\n margin-top: 0.18rem;\n overflow: hidden;\n color: var(--text-faint);\n font-size: 0.52rem;\n letter-spacing: 0.04em;\n white-space: nowrap;\n text-overflow: ellipsis;\n }\n .overview-map-expand {\n display: none;\n align-items: center;\n justify-content: center;\n min-width: 0;\n height: 1.2rem;\n padding: 0 0.34rem;\n overflow: hidden;\n border: 0;\n border-radius: 0.3rem;\n background: transparent;\n color: var(--frontend-stroke);\n font: inherit;\n font-size: 0.49rem;\n font-weight: 700;\n letter-spacing: 0.06em;\n text-transform: uppercase;\n white-space: nowrap;\n cursor: pointer;\n }\n .overview-map-close {\n width: 1.55rem;\n height: 1.55rem;\n padding: 0;\n border: 0;\n border-radius: 0.34rem;\n background: transparent;\n color: var(--toolbar-text);\n font: inherit;\n font-size: 0.9rem;\n cursor: pointer;\n }\n .overview-map-expand:hover,\n .overview-map-expand:focus-visible,\n .overview-map-close:hover,\n .overview-map-close:focus-visible { background: var(--toolbar-hover); }\n .overview-map-expand:focus-visible,\n .overview-map-close:focus-visible,\n .overview-map-surface:focus-visible,\n .overview-map-node:focus-visible {\n outline: 2px solid var(--frontend-stroke);\n outline-offset: 1px;\n }\n .overview-map-surface {\n position: relative;\n height: 7rem;\n margin: 0.42rem;\n overflow: hidden;\n border: 1px solid color-mix(in srgb, var(--panel-border) 72%, transparent);\n border-radius: 0.42rem;\n background:\n linear-gradient(color-mix(in srgb, var(--panel-border) 26%, transparent) 1px, transparent 1px),\n linear-gradient(90deg, color-mix(in srgb, var(--panel-border) 26%, transparent) 1px, transparent 1px),\n color-mix(in srgb, var(--bg) 86%, transparent);\n background-size: 12px 12px;\n cursor: crosshair;\n touch-action: none;\n }\n html[data-preset=\"blueprint\"] .overview-map-surface { border-radius: 0.1rem; }\n .overview-map-surface \u003e svg {\n width: 100%;\n height: 100%;\n min-width: 0;\n transform: none !important;\n transition: none !important;\n display: block;\n overflow: visible;\n }\n .overview-map-node {\n fill: var(--backend-stroke);\n fill-opacity: 0.52;\n stroke: var(--backend-stroke);\n stroke-opacity: 0.86;\n vector-effect: non-scaling-stroke;\n cursor: pointer;\n transition: fill-opacity 140ms ease, stroke-width 140ms ease, filter 140ms ease;\n }\n .overview-map-node[data-kind=\"frontend\"],\n .overview-map-node[data-kind=\"start\"] { fill: var(--frontend-stroke); stroke: var(--frontend-stroke); }\n .overview-map-node[data-kind=\"database\"],\n .overview-map-node[data-kind=\"success\"] { fill: var(--database-stroke); stroke: var(--database-stroke); }\n .overview-map-node[data-kind=\"cloud\"],\n .overview-map-node[data-kind=\"waiting\"] { fill: var(--cloud-stroke); stroke: var(--cloud-stroke); }\n .overview-map-node[data-kind=\"messagebus\"] { fill: var(--messagebus-stroke); stroke: var(--messagebus-stroke); }\n .overview-map-node[data-kind=\"security\"],\n .overview-map-node[data-kind=\"decision\"],\n .overview-map-node[data-kind=\"failure\"] { fill: var(--security-stroke); stroke: var(--security-stroke); }\n .overview-map-node[data-kind=\"external\"],\n .overview-map-node[data-kind=\"neutral\"] { fill: var(--external-stroke); stroke: var(--external-stroke); }\n .overview-map-node[data-radar-active=\"true\"],\n .overview-map-node:hover,\n .overview-map-node:focus-visible {\n fill-opacity: 0.92;\n stroke-width: 2.2;\n filter: drop-shadow(0 0 3px currentColor);\n }\n .overview-map-viewport {\n fill: color-mix(in srgb, var(--frontend-fill) 56%, transparent);\n stroke: var(--frontend-stroke);\n stroke-width: 2;\n vector-effect: non-scaling-stroke;\n pointer-events: none;\n filter: drop-shadow(0 0 3px color-mix(in srgb, var(--frontend-stroke) 54%, transparent));\n }\n .overview-map-hint {\n display: flex;\n justify-content: space-between;\n gap: 0.5rem;\n padding: 0 0.52rem 0.46rem;\n color: var(--text-faint);\n font-size: 0.49rem;\n letter-spacing: 0.06em;\n text-transform: uppercase;\n }\n .diagram-nav #btn-overview-map[aria-expanded=\"true\"] {\n color: var(--frontend-stroke);\n background: color-mix(in srgb, var(--frontend-stroke) 11%, transparent);\n }\n .overview-map-feedback {\n position: absolute;\n right: 1rem;\n bottom: 4.15rem;\n z-index: 13;\n max-width: min(16rem, calc(100% - 2rem));\n padding: 0.38rem 0.55rem;\n border: 1px solid color-mix(in srgb, var(--frontend-stroke) 52%, var(--toolbar-border));\n border-radius: 0.5rem;\n background: var(--toolbar-menu-bg);\n color: var(--toolbar-text);\n box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);\n font-size: 0.52rem;\n line-height: 1.35;\n pointer-events: none;\n }\n .overview-map-feedback[hidden] { display: none; }\n .focus-chip[data-radar-yielded=\"true\"] { display: none !important; }\n .diagram-nav #btn-route-probe[aria-pressed=\"true\"] {\n color: var(--backend-stroke);\n background: color-mix(in srgb, var(--backend-stroke) 11%, transparent);\n }\n .diagram-nav #btn-semantic-lens[aria-expanded=\"true\"],\n .diagram-nav #btn-semantic-lens[aria-pressed=\"true\"] {\n color: var(--database-stroke);\n background: color-mix(in srgb, var(--database-stroke) 11%, transparent);\n }\n\n /* Semantic Lens turns the compiled node-kind palette into an analytical\n legend. One kind reveals its real traffic; two kinds compare only their\n direct authored relationships. Geometry and the canonical SVG stay put. */\n .semantic-lens {\n position: absolute;\n right: 1rem;\n bottom: calc(4.15rem + var(--archify-nav-reserve));\n z-index: 24;\n width: min(20rem, calc(100% - 2rem));\n overflow: hidden;\n border: 1px solid color-mix(in srgb, var(--database-stroke) 58%, var(--toolbar-border));\n border-radius: 0.82rem;\n background:\n linear-gradient(135deg, color-mix(in srgb, var(--database-fill) 34%, transparent), transparent 48%),\n var(--toolbar-menu-bg);\n color: var(--toolbar-text);\n box-shadow: 0 18px 52px rgba(0, 0, 0, 0.36);\n backdrop-filter: blur(18px);\n animation: archify-lens-in 180ms cubic-bezier(0.22, 1, 0.36, 1);\n }\n .semantic-lens[hidden] { display: none; }\n .semantic-lens[data-dock-side=\"left\"] { left: 1rem; right: auto; }\n .semantic-lens[data-dock-side=\"right\"] { left: auto; right: 1rem; }\n html[data-preset=\"blueprint\"] .semantic-lens { border-radius: 0.28rem; }\n .semantic-lens-head {\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n align-items: start;\n gap: 0.75rem;\n padding: 0.72rem 0.78rem 0.62rem;\n border-bottom: 1px solid var(--toolbar-border);\n }\n .semantic-lens-eyebrow {\n display: block;\n color: var(--database-stroke);\n font-size: 0.5rem;\n font-weight: 800;\n letter-spacing: 0.16em;\n text-transform: uppercase;\n }\n .semantic-lens-title {\n display: block;\n margin-top: 0.16rem;\n color: var(--text);\n font-size: 0.82rem;\n letter-spacing: -0.02em;\n }\n .semantic-lens-close {\n width: 1.75rem;\n height: 1.75rem;\n padding: 0;\n border: 0;\n border-radius: 0.35rem;\n background: transparent;\n color: var(--toolbar-text);\n font: inherit;\n font-size: 1rem;\n cursor: pointer;\n }\n .semantic-lens-close:hover,\n .semantic-lens-close:focus-visible { background: var(--toolbar-hover); }\n .semantic-lens-instruction {\n margin: 0;\n padding: 0.52rem 0.78rem 0.48rem;\n color: var(--text-faint);\n font-size: 0.55rem;\n line-height: 1.45;\n }\n .semantic-lens-kinds {\n display: grid;\n grid-template-columns: 1fr 1fr;\n gap: 0.3rem;\n max-height: min(15rem, 40vh);\n padding: 0 0.5rem 0.5rem;\n overflow-y: auto;\n scrollbar-width: thin;\n }\n .semantic-lens-kind {\n --lens-color: var(--external-stroke);\n display: grid;\n grid-template-columns: auto minmax(0, 1fr) auto;\n align-items: center;\n gap: 0.42rem;\n min-width: 0;\n min-height: 2.15rem;\n padding: 0.35rem 0.42rem;\n border: 1px solid color-mix(in srgb, var(--lens-color) 24%, var(--toolbar-border));\n border-radius: 0.45rem;\n background: color-mix(in srgb, var(--panel) 76%, transparent);\n color: var(--toolbar-text);\n font: inherit;\n text-align: left;\n cursor: pointer;\n transition: border-color 140ms ease, background 140ms ease, opacity 140ms ease;\n }\n html[data-preset=\"blueprint\"] .semantic-lens-kind { border-radius: 0.12rem; }\n .semantic-lens-kind[data-kind=\"frontend\"],\n .semantic-lens-kind[data-kind=\"start\"] { --lens-color: var(--frontend-stroke); }\n .semantic-lens-kind[data-kind=\"backend\"],\n .semantic-lens-kind[data-kind=\"active\"] { --lens-color: var(--backend-stroke); }\n .semantic-lens-kind[data-kind=\"database\"],\n .semantic-lens-kind[data-kind=\"success\"] { --lens-color: var(--database-stroke); }\n .semantic-lens-kind[data-kind=\"cloud\"],\n .semantic-lens-kind[data-kind=\"waiting\"] { --lens-color: var(--cloud-stroke); }\n .semantic-lens-kind[data-kind=\"messagebus\"] { --lens-color: var(--messagebus-stroke); }\n .semantic-lens-kind[data-kind=\"security\"],\n .semantic-lens-kind[data-kind=\"decision\"],\n .semantic-lens-kind[data-kind=\"failure\"] { --lens-color: var(--security-stroke); }\n .semantic-lens-kind:hover,\n .semantic-lens-kind:focus-visible,\n .semantic-lens-kind[aria-pressed=\"true\"] {\n border-color: color-mix(in srgb, var(--lens-color) 78%, var(--toolbar-border));\n background: color-mix(in srgb, var(--lens-color) 11%, var(--panel));\n }\n .semantic-lens-kind:focus-visible,\n .semantic-lens-close:focus-visible,\n .semantic-lens-actions button:focus-visible {\n outline: 2px solid var(--database-stroke);\n outline-offset: 1px;\n }\n .semantic-lens-kind:disabled { opacity: 0.34; cursor: default; }\n .semantic-lens-swatch {\n width: 0.48rem;\n height: 0.48rem;\n border-radius: 50%;\n background: var(--lens-color);\n box-shadow: 0 0 8px color-mix(in srgb, var(--lens-color) 58%, transparent);\n }\n .semantic-lens-kind strong {\n overflow: hidden;\n color: var(--text);\n font-size: 0.61rem;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .semantic-lens-kind em {\n color: var(--lens-color);\n font-size: 0.54rem;\n font-style: normal;\n font-weight: 800;\n }\n .semantic-lens-status {\n min-height: 2.5rem;\n margin: 0;\n padding: 0.55rem 0.78rem;\n border-top: 1px solid var(--toolbar-border);\n color: var(--text-faint);\n font-size: 0.55rem;\n line-height: 1.45;\n }\n .semantic-lens-status strong { color: var(--database-stroke); font-weight: 800; }\n .semantic-lens-actions {\n display: flex;\n justify-content: flex-end;\n gap: 0.28rem;\n padding: 0 0.62rem 0.62rem;\n }\n .semantic-lens-actions button {\n min-height: 1.8rem;\n padding: 0.28rem 0.48rem;\n border: 0;\n border-radius: 0.35rem;\n background: transparent;\n color: var(--toolbar-text);\n font: inherit;\n font-size: 0.56rem;\n cursor: pointer;\n }\n .semantic-lens-actions button:hover { background: var(--toolbar-hover); }\n .semantic-lens-actions #semantic-lens-copy { color: var(--database-stroke); }\n @keyframes archify-lens-in {\n from { opacity: 0; transform: translateY(5px) scale(0.985); }\n to { opacity: 1; transform: translateY(0) scale(1); }\n }\n\n /* Route Probe answers a reader question over the compiled semantic graph:\n choose two stable nodes and reveal the shortest authored directed route.\n The receipt and signal live entirely in the viewer layer. */\n .route-probe {\n position: absolute;\n left: 1rem;\n bottom: calc(1rem + var(--archify-nav-reserve));\n z-index: 12;\n width: min(46rem, calc(100% - 25rem));\n min-width: 18rem;\n overflow: hidden;\n border: 1px solid color-mix(in srgb, var(--backend-stroke) 62%, var(--toolbar-border));\n border-radius: 0.82rem;\n background:\n linear-gradient(115deg, color-mix(in srgb, var(--backend-fill) 50%, transparent), transparent 62%),\n var(--toolbar-menu-bg);\n color: var(--toolbar-text);\n box-shadow: 0 18px 48px rgba(0, 0, 0, 0.3);\n backdrop-filter: blur(16px);\n font-size: 0.75rem;\n }\n .route-probe[hidden] { display: none; }\n /* Picking needs one line of guidance, not a wide empty card; the panel\n widens only when there is a traced route to show. */\n .route-probe:not([data-state=\"result\"]) { width: min(22rem, calc(100% - 2rem)); min-width: 0; }\n .route-probe-path:has(\u003e .route-probe-placeholder:only-child) { display: none; }\n .route-probe[data-route-dock=\"top\"] {\n top: 1rem;\n bottom: auto;\n }\n html[data-preset=\"blueprint\"] .route-probe { border-radius: 0.25rem; }\n .route-probe-head {\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n align-items: start;\n gap: 0.65rem;\n padding: 0.625rem 0.75rem 0.5rem;\n border-bottom: 1px solid color-mix(in srgb, var(--toolbar-border) 80%, transparent);\n }\n .route-probe-copy { min-width: 0; }\n .route-probe-eyebrow {\n display: block;\n color: var(--backend-stroke);\n font-size: 0.6875rem;\n font-weight: 600;\n letter-spacing: 0.02em;\n }\n .route-probe-title {\n display: block;\n margin-top: 0.14rem;\n overflow: hidden;\n color: var(--toolbar-text);\n font-size: 0.875rem;\n font-weight: 600;\n line-height: 1.3;\n white-space: nowrap;\n text-overflow: ellipsis;\n }\n .route-probe-actions { display: flex; gap: 0.2rem; }\n .route-probe button {\n min-height: 1.55rem;\n padding: 0.25rem 0.42rem;\n border: 0;\n border-radius: 0.36rem;\n background: transparent;\n color: var(--toolbar-text);\n font: inherit;\n cursor: pointer;\n }\n .route-probe button:hover,\n .route-probe button:focus-visible { background: var(--toolbar-hover); }\n .route-probe button:focus-visible {\n outline: 2px solid var(--backend-stroke);\n outline-offset: 1px;\n }\n .route-probe-copy-link { color: var(--frontend-stroke) !important; }\n .route-probe-find { color: var(--backend-stroke) !important; }\n .route-probe-copy-link[hidden] { display: none; }\n .route-probe-find[hidden] { display: none; }\n .route-probe-path {\n display: flex;\n align-items: center;\n min-height: 2.2rem;\n padding: 0.42rem 0.58rem 0.24rem;\n overflow-x: auto;\n scrollbar-width: thin;\n white-space: nowrap;\n }\n .route-probe-node,\n .route-probe button.route-probe-node {\n flex: none;\n max-width: 9.5rem;\n overflow: hidden;\n min-height: 1.75rem !important;\n padding: 0.22rem 0.38rem;\n border: 1px solid color-mix(in srgb, var(--backend-stroke) 46%, var(--toolbar-border));\n border-radius: 999px;\n background: color-mix(in srgb, var(--backend-fill) 52%, transparent);\n color: var(--text);\n font-size: 0.56rem;\n font-weight: 700;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .route-probe-node[data-endpoint=\"start\"] {\n border-color: var(--frontend-stroke);\n color: var(--frontend-stroke);\n }\n .route-probe-node[data-endpoint=\"end\"] {\n border-color: var(--security-stroke);\n color: var(--security-stroke);\n }\n .route-probe-node[data-route-journey-state=\"past\"] { opacity: 0.66; }\n .route-probe-node[data-route-journey-state=\"future\"] { opacity: 0.48; }\n .route-probe-node[aria-current=\"step\"] {\n border-color: var(--backend-stroke);\n background: color-mix(in srgb, var(--backend-fill) 82%, var(--toolbar-menu-bg));\n color: var(--text);\n box-shadow: 0 0 0 1px color-mix(in srgb, var(--backend-stroke) 42%, transparent), 0 0 14px color-mix(in srgb, var(--backend-stroke) 34%, transparent);\n opacity: 1;\n }\n html[data-preset=\"blueprint\"] .route-probe-node[aria-current=\"step\"] {\n border-style: double;\n border-width: 3px;\n border-radius: 0.2rem;\n box-shadow: none;\n }\n .route-probe-arrow {\n flex: none;\n padding: 0 0.28rem;\n color: var(--text-faint);\n font-size: 0.65rem;\n }\n .route-probe-placeholder {\n color: var(--text-faint);\n font-size: 0.75rem;\n }\n .route-probe-status {\n display: block;\n min-height: 1.45rem;\n padding: 0.5rem 0.75rem 0.625rem;\n color: var(--text-muted, var(--text-faint));\n font-size: 0.75rem;\n line-height: 1.45;\n }\n .route-journey-controls {\n display: grid;\n grid-template-columns: 2rem minmax(5.8rem, auto) 2rem minmax(4.8rem, auto);\n justify-content: start;\n gap: 0.22rem;\n padding: 0.08rem 0.58rem 0.28rem;\n }\n .route-journey-controls[hidden] { display: none; }\n .route-journey-controls button {\n min-height: 1.8rem;\n border: 1px solid color-mix(in srgb, var(--toolbar-border) 86%, transparent);\n background: color-mix(in srgb, var(--toolbar-bg) 72%, transparent);\n font-size: 0.54rem;\n font-weight: 700;\n }\n .route-journey-controls button:disabled {\n cursor: default;\n opacity: 0.34;\n }\n .route-journey-play { color: var(--backend-stroke) !important; }\n .route-journey-overview { color: var(--frontend-stroke) !important; }\n .route-journey-controls[data-playing=\"true\"] .route-journey-play {\n border-color: color-mix(in srgb, var(--backend-stroke) 64%, var(--toolbar-border));\n background: color-mix(in srgb, var(--backend-fill) 62%, transparent);\n }\n .route-probe[data-state=\"error\"] {\n border-color: color-mix(in srgb, var(--security-stroke) 72%, var(--toolbar-border));\n }\n .route-probe[data-state=\"error\"] .route-probe-status { color: var(--security-stroke); }\n\n .focus-chip {\n position: absolute;\n left: 1rem;\n top: 1rem;\n z-index: 12;\n display: block;\n width: min(22rem, calc(100% - 13rem));\n max-width: calc(100% - 13rem);\n overflow: hidden;\n border: 1px solid var(--frontend-stroke);\n border-radius: 0.85rem;\n background: var(--toolbar-menu-bg);\n color: var(--toolbar-text);\n box-shadow: 0 18px 48px rgba(0, 0, 0, 0.3);\n backdrop-filter: blur(16px);\n font-size: 0.6875rem;\n }\n .focus-chip[hidden] { display: none; }\n html[data-preset=\"blueprint\"] .focus-chip { border-radius: 0.3rem; }\n .focus-chip button {\n flex: none;\n padding: 0.3rem 0.45rem;\n border-radius: 0.35rem;\n font-size: 0.625rem;\n }\n .relationship-lens-head {\n position: relative;\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n align-items: start;\n gap: 0.75rem;\n padding: 0.9rem 0.75rem 0.65rem;\n border-bottom: 1px solid var(--toolbar-border);\n background: linear-gradient(120deg, color-mix(in srgb, var(--frontend-fill) 34%, transparent), transparent 72%);\n }\n .relationship-lens-drag-handle {\n position: absolute;\n top: 0.12rem;\n left: 50%;\n width: 2.5rem;\n height: 0.78rem;\n padding: 0 !important;\n transform: translateX(-50%);\n color: var(--text-faint) !important;\n cursor: grab;\n touch-action: none;\n user-select: none;\n }\n .relationship-lens-drag-handle::before {\n content: \"\";\n display: block;\n width: 1.25rem;\n margin: auto;\n border-top: 2px dotted currentColor;\n opacity: 0.72;\n }\n .focus-chip[data-panel-dragging=\"true\"] .relationship-lens-drag-handle { cursor: grabbing; }\n @media (hover: none), (pointer: coarse) {\n .relationship-lens-drag-handle { display: none; }\n }\n .relationship-lens-copy { min-width: 0; }\n .relationship-lens-actions {\n display: flex;\n flex-direction: column;\n align-items: flex-end;\n gap: 0.18rem;\n }\n .relationship-lens-actions button { white-space: nowrap; }\n .relationship-lens-actions #btn-focus-clear {\n display: grid;\n width: 1.75rem;\n height: 1.75rem;\n padding: 0;\n place-items: center;\n color: var(--text-muted);\n font-size: 1rem;\n line-height: 1;\n }\n .relationship-lens-actions #btn-focus-clear:hover,\n .relationship-lens-actions #btn-focus-clear:focus-visible {\n background: var(--toolbar-hover);\n color: var(--text);\n }\n .relationship-lens-actions #btn-focus-copy { color: var(--frontend-stroke); }\n .relationship-lens-actions #btn-focus-relations { display: none; }\n .relationship-lens-eyebrow {\n display: block;\n margin-bottom: 0.18rem;\n color: var(--frontend-stroke);\n font-size: 0.5rem;\n font-weight: 800;\n letter-spacing: 0.14em;\n text-transform: uppercase;\n }\n .relationship-lens-title {\n display: block;\n overflow: hidden;\n color: var(--text);\n font-size: 0.8rem;\n line-height: 1.35;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .semantic-passport-detail {\n display: block;\n margin-top: 0.12rem;\n overflow: hidden;\n color: var(--text-muted);\n font-size: 0.625rem;\n line-height: 1.4;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .semantic-passport-detail[hidden] { display: none; }\n .semantic-passport-meta {\n display: flex;\n flex-wrap: wrap;\n gap: 0.24rem;\n margin-top: 0.42rem;\n }\n .semantic-passport-meta span,\n .semantic-passport-meta code {\n max-width: 100%;\n overflow: hidden;\n padding: 0.14rem 0.34rem;\n border: 1px solid color-mix(in srgb, var(--toolbar-border) 82%, transparent);\n border-radius: 999px;\n background: color-mix(in srgb, var(--panel) 68%, transparent);\n color: var(--text-faint);\n font: inherit;\n font-size: 0.5rem;\n letter-spacing: 0.04em;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .semantic-passport-meta [data-passport=\"kind\"] {\n border-color: color-mix(in srgb, var(--frontend-stroke) 50%, var(--toolbar-border));\n color: var(--frontend-stroke);\n font-weight: 800;\n text-transform: uppercase;\n }\n .semantic-passport-meta [data-passport=\"tag\"] { color: var(--cloud-stroke); }\n .semantic-passport-meta [data-passport=\"brand\"] {\n border-color: color-mix(in srgb, var(--messagebus-stroke) 52%, var(--toolbar-border));\n color: var(--messagebus-stroke);\n font-weight: 700;\n }\n .semantic-passport-meta [hidden] { display: none; }\n html[data-preset=\"blueprint\"] .semantic-passport-meta span,\n html[data-preset=\"blueprint\"] .semantic-passport-meta code { border-radius: 0.1rem; }\n .semantic-passport-evidence {\n margin-top: 0.52rem;\n padding: 0.5rem;\n border: 1px solid color-mix(in srgb, var(--backend-stroke) 32%, var(--toolbar-border));\n border-radius: 0.55rem;\n background: color-mix(in srgb, var(--backend-fill) 18%, var(--panel));\n }\n .semantic-passport-evidence[hidden] { display: none; }\n html[data-preset=\"blueprint\"] .semantic-passport-evidence { border-radius: 0.18rem; }\n .semantic-passport-evidence-head {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: 0.55rem;\n margin-bottom: 0.35rem;\n }\n .semantic-passport-evidence-status {\n display: inline-flex;\n align-items: center;\n gap: 0.28rem;\n color: var(--backend-stroke);\n font-size: 0.5rem;\n font-weight: 800;\n letter-spacing: 0.08em;\n text-transform: uppercase;\n }\n .semantic-passport-evidence-status::before {\n content: '';\n width: 0.38rem;\n height: 0.38rem;\n border-radius: 50%;\n background: var(--backend-stroke);\n box-shadow: 0 0 0 3px color-mix(in srgb, var(--backend-stroke) 14%, transparent);\n }\n .semantic-passport-repository {\n min-width: 0;\n overflow: hidden;\n color: var(--text-faint);\n font-size: 0.5rem;\n text-decoration: none;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .semantic-passport-repository:hover,\n .semantic-passport-repository:focus-visible { color: var(--backend-stroke); }\n .semantic-passport-evidence-links { display: grid; gap: 0.22rem; }\n .semantic-passport-source {\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n gap: 0.15rem 0.45rem;\n align-items: center;\n padding: 0.34rem 0.4rem;\n border: 1px solid transparent;\n border-radius: 0.38rem;\n color: var(--text-muted);\n text-decoration: none;\n }\n a.semantic-passport-source:hover,\n a.semantic-passport-source:focus-visible {\n border-color: color-mix(in srgb, var(--backend-stroke) 42%, transparent);\n background: color-mix(in srgb, var(--backend-fill) 32%, transparent);\n color: var(--text);\n }\n .semantic-passport-source strong {\n overflow: hidden;\n font-size: 0.5625rem;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .semantic-passport-source code {\n color: var(--backend-stroke);\n font: inherit;\n font-size: 0.5rem;\n }\n .semantic-passport-source small {\n grid-column: 1 / -1;\n overflow: hidden;\n color: var(--text-faint);\n font-size: 0.5rem;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .relationship-lens-summary {\n display: block;\n margin-top: 0.12rem;\n color: var(--text-faint);\n font-size: 0.5625rem;\n }\n .semantic-passport-reach {\n display: grid;\n gap: 0.28rem;\n margin-top: 0.52rem;\n padding-top: 0.48rem;\n border-top: 1px solid color-mix(in srgb, var(--toolbar-border) 76%, transparent);\n }\n .semantic-passport-reach[hidden] { display: none; }\n .semantic-passport-reach-label {\n color: var(--text-faint);\n font-size: 0.5rem;\n font-weight: 800;\n letter-spacing: 0.1em;\n text-transform: uppercase;\n }\n .semantic-passport-reach-actions {\n display: grid;\n grid-template-columns: repeat(2, minmax(0, 1fr));\n gap: 0.25rem;\n }\n .semantic-passport-reach-actions button {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: 0.5rem;\n min-width: 0;\n min-height: 2rem;\n padding: 0.32rem 0.42rem;\n border: 1px solid color-mix(in srgb, var(--toolbar-border) 86%, transparent);\n background: color-mix(in srgb, var(--panel) 70%, transparent);\n color: var(--text-muted);\n text-align: left;\n }\n .semantic-passport-reach-actions button:hover:not(:disabled),\n .semantic-passport-reach-actions button:focus-visible {\n border-color: color-mix(in srgb, var(--frontend-stroke) 62%, var(--toolbar-border));\n color: var(--text);\n }\n .semantic-passport-reach-actions button:focus-visible {\n outline: 2px solid var(--frontend-stroke);\n outline-offset: 1px;\n }\n .semantic-passport-reach-actions button:disabled {\n cursor: default;\n opacity: 0.5;\n }\n .semantic-passport-reach-actions button[aria-pressed=\"true\"] {\n border-color: color-mix(in srgb, var(--reach-color, var(--frontend-stroke)) 72%, var(--toolbar-border));\n background: color-mix(in srgb, var(--reach-fill, var(--frontend-fill)) 48%, transparent);\n color: var(--text);\n }\n #btn-reach-upstream {\n --reach-color: var(--database-stroke);\n --reach-fill: var(--database-fill);\n }\n #btn-reach-downstream {\n --reach-color: var(--backend-stroke);\n --reach-fill: var(--backend-fill);\n }\n .semantic-passport-reach-actions strong {\n color: var(--reach-color, var(--frontend-stroke));\n font-size: 0.625rem;\n }\n .semantic-passport-reach-status {\n color: var(--text-faint);\n font-size: 0.525rem;\n line-height: 1.4;\n }\n .semantic-passport-reach-status[hidden] { display: none; }\n .relationship-lens-list {\n max-height: min(18rem, 46vh);\n overflow: auto;\n padding: 0.4rem;\n scrollbar-width: thin;\n scrollbar-color: var(--frontend-stroke) transparent;\n }\n .relationship-lens-list::-webkit-scrollbar { width: 4px; }\n .relationship-lens-list::-webkit-scrollbar-thumb {\n border-radius: 999px;\n background: color-mix(in srgb, var(--frontend-stroke) 68%, transparent);\n }\n .relationship-lens-group + .relationship-lens-group { margin-top: 0.35rem; }\n .relationship-lens-group-title {\n display: block;\n padding: 0.24rem 0.38rem 0.16rem;\n color: var(--text-faint);\n font-size: 0.5rem;\n font-weight: 800;\n letter-spacing: 0.12em;\n text-transform: uppercase;\n }\n .relationship-lens-row {\n display: grid;\n grid-template-columns: 2.1rem minmax(0, 1fr);\n gap: 0.06rem 0.45rem;\n width: 100%;\n padding: 0.45rem 0.5rem !important;\n text-align: left;\n }\n .relationship-lens-row:hover,\n .relationship-lens-row:focus-visible,\n .relationship-lens-row[data-preview-active=\"true\"] {\n background: var(--toolbar-hover);\n box-shadow: inset 2px 0 0 var(--frontend-stroke);\n }\n .relationship-lens-row:focus-visible {\n outline: 2px solid var(--frontend-stroke);\n outline-offset: -2px;\n }\n .relationship-lens-direction {\n grid-row: 1 / 3;\n align-self: center;\n color: var(--frontend-stroke);\n font-size: 0.5rem;\n font-weight: 800;\n letter-spacing: 0.08em;\n }\n .relationship-lens-row[data-direction=\"in\"] .relationship-lens-direction { color: var(--database-stroke); }\n .relationship-lens-row[data-direction=\"loop\"] .relationship-lens-direction { color: var(--security-stroke); }\n .relationship-lens-row strong {\n overflow: hidden;\n color: var(--text);\n font-size: 0.6875rem;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .relationship-lens-row small {\n overflow: hidden;\n color: var(--text-faint);\n font-size: 0.5625rem;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .relationship-lens-empty {\n margin: 0;\n padding: 0.75rem;\n color: var(--text-faint);\n font-size: 0.625rem;\n text-align: center;\n }\n\n /* Diagram Guide keeps the artifact's growing reader vocabulary\n discoverable without widening the permanent control bar. It derives\n honest counts at runtime and delegates every action to an existing\n production interaction instead of creating a second command system. */\n .diagram-guide {\n position: absolute;\n top: 1rem;\n right: 1rem;\n z-index: 26;\n width: min(32rem, calc(100% - 2rem));\n max-height: min(42rem, calc(100% - 2rem));\n overflow: auto;\n border: 1px solid color-mix(in srgb, var(--cloud-stroke) 58%, var(--toolbar-border));\n border-radius: 0.82rem;\n background:\n linear-gradient(135deg, color-mix(in srgb, var(--cloud-fill) 32%, transparent), transparent 42%),\n var(--toolbar-menu-bg);\n color: var(--toolbar-text);\n box-shadow: 0 22px 64px rgba(0, 0, 0, 0.4);\n backdrop-filter: blur(18px);\n animation: archify-guide-in 180ms cubic-bezier(0.22, 1, 0.36, 1);\n }\n .diagram-guide[hidden] { display: none; }\n html[data-preset=\"blueprint\"] .diagram-guide { border-radius: 0.28rem; }\n .diagram-guide-head {\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n align-items: start;\n gap: 1rem;\n padding: 0.82rem 0.9rem 0.68rem;\n border-bottom: 1px solid var(--toolbar-border);\n }\n .diagram-guide-eyebrow {\n display: block;\n color: var(--cloud-stroke);\n font-size: 0.5rem;\n font-weight: 800;\n letter-spacing: 0.16em;\n text-transform: uppercase;\n }\n .diagram-guide-title {\n display: block;\n margin-top: 0.16rem;\n color: var(--text);\n font-size: 0.86rem;\n letter-spacing: -0.02em;\n }\n .diagram-guide-close {\n width: 1.8rem;\n height: 1.8rem;\n border: 0;\n border-radius: 0.35rem;\n background: transparent;\n color: var(--toolbar-text);\n font: inherit;\n font-size: 1rem;\n cursor: pointer;\n }\n .diagram-guide-close:hover,\n .diagram-guide-close:focus-visible { background: var(--toolbar-hover); }\n .diagram-guide-stats {\n display: flex;\n align-items: center;\n gap: 0.5rem;\n margin: 0;\n padding: 0.54rem 0.9rem;\n border-bottom: 1px solid color-mix(in srgb, var(--toolbar-border) 74%, transparent);\n color: var(--text-faint);\n font-size: 0.56rem;\n letter-spacing: 0.025em;\n }\n .diagram-guide-stats::before {\n content: '';\n width: 0.42rem;\n height: 0.42rem;\n flex: none;\n border-radius: 50%;\n background: var(--backend-stroke);\n box-shadow: 0 0 10px color-mix(in srgb, var(--backend-stroke) 72%, transparent);\n }\n .diagram-guide-actions {\n display: grid;\n grid-template-columns: 1fr 1fr;\n gap: 0.38rem;\n padding: 0.62rem;\n }\n .diagram-guide-action {\n --guide-accent: var(--frontend-stroke);\n display: grid;\n grid-template-columns: auto minmax(0, 1fr) auto;\n align-items: center;\n gap: 0.55rem;\n min-height: 4.15rem;\n padding: 0.55rem 0.58rem;\n border: 1px solid color-mix(in srgb, var(--guide-accent) 22%, var(--toolbar-border));\n border-radius: 0.55rem;\n background: color-mix(in srgb, var(--panel) 78%, transparent);\n color: var(--toolbar-text);\n font: inherit;\n text-align: left;\n cursor: pointer;\n transition: border-color 140ms ease, background 140ms ease, transform 140ms ease;\n }\n .diagram-guide-action[data-guide-action=\"route\"] { --guide-accent: var(--backend-stroke); }\n .diagram-guide-action[data-guide-action=\"map\"] { --guide-accent: var(--database-stroke); }\n .diagram-guide-action[data-guide-action=\"lens\"] { --guide-accent: var(--messagebus-stroke); }\n\n .diagram-guide-action[data-guide-action=\"present\"] {\n --guide-accent: var(--cloud-stroke);\n }\n .diagram-guide-action:hover,\n .diagram-guide-action:focus-visible {\n border-color: color-mix(in srgb, var(--guide-accent) 76%, var(--toolbar-border));\n background: color-mix(in srgb, var(--guide-accent) 9%, var(--panel));\n transform: translateY(-1px);\n }\n .diagram-guide-action:focus-visible,\n .diagram-guide-close:focus-visible {\n outline: 2px solid var(--cloud-stroke);\n outline-offset: 1px;\n }\n .diagram-guide-action:disabled {\n opacity: 0.42;\n cursor: default;\n transform: none;\n }\n .diagram-guide-index {\n display: grid;\n place-items: center;\n width: 1.65rem;\n height: 1.65rem;\n border: 1px solid color-mix(in srgb, var(--guide-accent) 64%, var(--toolbar-border));\n border-radius: 0.35rem;\n color: var(--guide-accent);\n font-size: 0.5rem;\n font-weight: 800;\n letter-spacing: 0.06em;\n }\n .diagram-guide-action-copy { min-width: 0; }\n .diagram-guide-action strong {\n display: block;\n overflow: hidden;\n color: var(--text);\n font-size: 0.66rem;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .diagram-guide-action small {\n display: -webkit-box;\n margin-top: 0.18rem;\n overflow: hidden;\n color: var(--text-faint);\n font-size: 0.5rem;\n line-height: 1.35;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: 2;\n }\n .diagram-guide kbd {\n align-self: start;\n min-width: 1.45rem;\n padding: 0.12rem 0.3rem;\n border: 1px solid var(--toolbar-border);\n border-radius: 0.25rem;\n color: var(--text-faint);\n font: inherit;\n font-size: 0.5rem;\n text-align: center;\n }\n .diagram-guide-shortcuts {\n display: flex;\n flex-wrap: wrap;\n gap: 0.34rem 0.62rem;\n padding: 0.58rem 0.9rem 0.68rem;\n border-top: 1px solid var(--toolbar-border);\n color: var(--text-faint);\n font-size: 0.5rem;\n }\n .diagram-guide-shortcuts span {\n display: inline-flex;\n align-items: center;\n gap: 0.28rem;\n white-space: nowrap;\n }\n .diagram-guide-feedback {\n min-height: 1rem;\n margin: -0.18rem 0.9rem 0.62rem;\n color: var(--security-stroke);\n font-size: 0.5rem;\n }\n .diagram-guide-feedback:empty { display: none; }\n @keyframes archify-guide-in {\n from { opacity: 0; transform: translateY(-5px) scale(0.985); }\n to { opacity: 1; transform: translateY(0) scale(1); }\n }\n\n .node-finder {\n position: absolute;\n top: 1rem;\n left: 1rem;\n z-index: 24;\n display: flex;\n flex-direction: column;\n width: min(22rem, calc(100% - 2rem));\n max-height: calc(100% - 2rem);\n overflow: hidden;\n border: 1px solid var(--toolbar-border);\n border-radius: 0.85rem;\n background: var(--toolbar-menu-bg);\n color: var(--toolbar-text);\n box-shadow: 0 6px 8px rgba(0, 0, 0, 0.22);\n backdrop-filter: blur(16px);\n }\n .node-finder[hidden] { display: none; }\n .node-finder[data-context=\"route-source\"] {\n border-color: color-mix(in srgb, var(--frontend-stroke) 68%, var(--toolbar-border));\n }\n .node-finder[data-context=\"route-target\"] {\n border-color: color-mix(in srgb, var(--security-stroke) 68%, var(--toolbar-border));\n }\n html[data-preset=\"blueprint\"] .node-finder { border-radius: 0.3rem; }\n .node-finder-head {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: 1rem;\n padding: 0.7rem 0.8rem 0.45rem;\n }\n .node-finder-head strong {\n color: var(--text);\n font-size: 0.6875rem;\n letter-spacing: 0.08em;\n text-transform: uppercase;\n }\n .node-finder[data-context=\"route-source\"] .node-finder-head strong { color: var(--frontend-stroke); }\n .node-finder[data-context=\"route-target\"] .node-finder-head strong { color: var(--security-stroke); }\n .node-finder-close {\n width: 1.75rem;\n height: 1.75rem;\n border: 0;\n border-radius: 0.35rem;\n background: transparent;\n color: var(--toolbar-text);\n font: inherit;\n font-size: 1rem;\n cursor: pointer;\n }\n .node-finder-close:hover,\n .node-finder-close:focus-visible { background: var(--toolbar-hover); }\n .node-finder-close:focus-visible,\n .node-finder-result:focus-visible {\n outline: 2px solid var(--frontend-stroke);\n outline-offset: -2px;\n }\n .node-finder-search {\n display: grid;\n grid-template-columns: auto minmax(0, 1fr) auto;\n align-items: center;\n gap: 0.55rem;\n margin: 0 0.55rem 0.55rem;\n padding: 0 0.7rem;\n min-height: 2.6rem;\n border: 1px solid var(--toolbar-border);\n border-radius: 0.55rem;\n background: color-mix(in srgb, var(--panel) 78%, transparent);\n transition: border-color 160ms ease-out, box-shadow 160ms ease-out;\n }\n html[data-preset=\"blueprint\"] .node-finder-search { border-radius: 0.18rem; }\n .node-finder-search \u003e span { color: var(--frontend-stroke); font-size: 0.875rem; }\n .node-finder-search:focus-within {\n border-color: var(--frontend-stroke);\n box-shadow: 0 0 0 2px color-mix(in srgb, var(--frontend-stroke) 20%, transparent);\n }\n .node-finder-input {\n appearance: none;\n width: 100%;\n min-width: 0;\n border: 0;\n outline: 0;\n background: transparent;\n color: var(--text);\n font: inherit;\n font-size: 0.75rem;\n }\n .node-finder-input:focus-visible { outline: none; }\n .node-finder-input::placeholder { color: var(--text-faint); }\n .node-finder kbd {\n padding: 0.1rem 0.32rem;\n border: 1px solid var(--toolbar-border);\n border-radius: 0.25rem;\n color: var(--text-faint);\n font: inherit;\n font-size: 0.5625rem;\n }\n .node-finder-results {\n display: grid;\n flex: 1 1 auto;\n gap: 0;\n min-height: 0;\n max-height: min(18rem, 48vh);\n margin: 0 0.55rem 0.45rem;\n padding: 0;\n overflow-y: auto;\n overscroll-behavior: contain;\n border: 1px solid color-mix(in srgb, var(--toolbar-border) 78%, transparent);\n border-radius: 0.55rem;\n background: color-mix(in srgb, var(--panel) 54%, transparent);\n scroll-padding-block: 0.25rem;\n scrollbar-width: thin;\n }\n html[data-preset=\"blueprint\"] .node-finder-results { border-radius: 0.18rem; }\n .node-finder-result {\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n gap: 0.2rem 0.75rem;\n width: 100%;\n min-height: 3.25rem;\n padding: 0.58rem 0.65rem;\n border: 0;\n border-radius: 0;\n background: transparent;\n color: var(--text);\n font: inherit;\n text-align: left;\n cursor: pointer;\n transition: background-color 160ms ease-out;\n }\n .node-finder-result:not(:last-child) {\n border-bottom: 1px solid color-mix(in srgb, var(--toolbar-border) 62%, transparent);\n }\n .node-finder-result:hover,\n .node-finder-result:focus-visible {\n position: relative;\n z-index: 1;\n background: color-mix(in srgb, var(--frontend-fill) 48%, var(--toolbar-hover));\n }\n .node-finder-result strong {\n overflow: hidden;\n font-size: 0.75rem;\n line-height: 1.25;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .node-finder-result small {\n grid-column: 1 / -1;\n overflow: hidden;\n color: var(--text-faint);\n font-size: 0.5625rem;\n letter-spacing: 0.015em;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .node-finder-result em {\n align-self: center;\n color: var(--frontend-stroke);\n font-size: 0.625rem;\n font-style: normal;\n }\n .node-finder[data-context^=\"route-\"] .node-finder-result em {\n padding: 0.1rem 0.3rem;\n border: 1px solid color-mix(in srgb, currentColor 52%, transparent);\n border-radius: 999px;\n font-size: 0.5rem;\n font-weight: 800;\n letter-spacing: 0.05em;\n text-transform: uppercase;\n }\n .node-finder[data-context=\"route-target\"] .node-finder-result em { color: var(--security-stroke); }\n .node-finder-empty {\n padding: 1.1rem 0.75rem 1.25rem;\n color: var(--text-faint);\n font-size: 0.6875rem;\n text-align: center;\n }\n .node-finder-status {\n margin: 0;\n padding: 0.1rem 0.8rem 0.65rem;\n color: var(--text-faint);\n font-size: 0.5625rem;\n }\n\n .cards {\n display: grid;\n grid-template-columns: repeat(auto-fit, minmax(min(15rem, 100%), 1fr));\n gap: 1rem;\n margin-top: 2rem;\n }\n\n .card {\n background: var(--panel);\n border-radius: 0.75rem;\n border: 1px solid var(--panel-border);\n padding: 1.125rem 1.25rem;\n /* Card notes are authored prose and may carry an unbreakable run such as a\n slash-joined pipeline or a long identifier. Without this, that run sets the\n card's min-content width, spills past its track in every rail placement,\n and pushes the whole page into horizontal overflow at desktop widths.\n `anywhere` rather than `break-word` because only `anywhere` shrinks the\n intrinsic minimum the layout is sized from. */\n overflow-wrap: anywhere;\n }\n\n html[data-preset=\"signal-flow\"] .card {\n background: linear-gradient(145deg, rgba(10, 24, 43, 0.86), rgba(5, 12, 24, 0.92));\n box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035);\n }\n html[data-preset=\"signal-flow\"][data-theme=\"light\"] .card {\n background: linear-gradient(145deg, rgba(255, 255, 255, 0.92), rgba(237, 246, 250, 0.9));\n box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.82), 0 12px 32px rgba(45, 78, 99, 0.08);\n }\n\n /* Preserve the one-screen guarantee on ordinary laptop displays. The\n high-screen expansion above must not trade a fuller canvas for page\n scrolling at 900–1080px heights. */\n @media (min-width: 768px) and (max-height: 1100px) {\n .header { margin-bottom: 1rem; }\n .diagram-container {\n padding: 0.875rem;\n padding-bottom: calc(0.875rem + var(--archify-nav-reserve));\n }\n .cards { margin-top: 1rem; }\n .card { padding: 1rem; }\n }\n @media (min-width: 768px) and (max-height: 920px) {\n body { padding-block: 1.25rem; }\n body { --archify-page-top: 1.25rem; }\n .header { margin-bottom: 0.875rem; }\n .cards { margin-top: 0.75rem; }\n html[data-nav-stage-rail=\"true\"] body { padding-block: 0.375rem; }\n /* Align the fixed toolbar with the compact title row. Reserve its hit area\n above the guide without taking extra height from a fitted diagram. */\n html[data-nav-stage-rail=\"true\"] .toolbar { top: 0.25rem; }\n html[data-nav-stage-rail=\"true\"] .header { min-height: 2.625rem; margin-bottom: 0.5rem; }\n html[data-nav-stage-rail=\"true\"] .diagram-container[data-nav-stage-rail=\"true\"] { padding-top: 0.5rem; }\n html[data-nav-stage-rail=\"true\"] .cards { margin-top: 0.375rem; }\n }\n\n html[data-preset=\"blueprint\"] .card {\n position: relative;\n border-color: var(--panel-border);\n border-radius: 0.3rem;\n background: var(--panel);\n box-shadow: none;\n }\n html[data-preset=\"blueprint\"] .card::before {\n content: \"\";\n position: absolute;\n top: -1px;\n left: 1rem;\n width: 2.5rem;\n border-top: 2px solid var(--frontend-stroke);\n }\n\n html[data-preset=\"editorial\"] .card {\n position: relative;\n border-radius: 0.28rem;\n background: var(--panel);\n box-shadow: 0 10px 28px color-mix(in srgb, #000 10%, transparent);\n }\n html[data-preset=\"editorial\"] .card::before {\n position: absolute;\n top: -1px;\n left: 1.25rem;\n width: 3.25rem;\n border-top: 3px solid var(--arrow-emphasis);\n content: \"\";\n }\n html[data-preset=\"editorial\"] .card-dot { border-radius: 0; transform: rotate(45deg) scale(0.78); }\n\n /* Summary rail: the reader measures the viewport and enables it only when the\n diagram keeps its readable width beside the notes. */\n .reader-rail { display: contents; }\n html[data-reader-rail=\"true\"] .container {\n display: grid;\n grid-template-columns: minmax(0, 1fr) var(--archify-rail-width);\n grid-auto-flow: row dense;\n column-gap: var(--archify-rail-gap);\n align-items: start;\n }\n html[data-reader-rail=\"true\"] .container \u003e .header { grid-column: 1 / -1; }\n html[data-reader-rail=\"true\"] .container \u003e .diagram-container { grid-column: 1; }\n /* The rail is at least the diagram's height and may run on to the viewport\n floor (--archify-rail-max, set by the reader); past that, notes scroll and\n the index keeps a usable share instead of collapsing to its header. */\n html[data-reader-rail=\"true\"] .reader-rail {\n display: flex;\n flex-direction: column;\n grid-column: 2;\n align-self: stretch;\n min-height: 0;\n max-height: var(--archify-rail-max, none);\n }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards:empty { display: none; }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards {\n display: flex;\n flex: 0 1 auto;\n flex-direction: column;\n gap: 0;\n min-height: 0;\n margin-top: 0;\n padding: 0.125rem 0 0;\n overflow-y: auto;\n scrollbar-width: none;\n -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - 1.25rem), transparent);\n mask-image: linear-gradient(to bottom, #000 calc(100% - 1.25rem), transparent);\n }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards::-webkit-scrollbar { display: none; }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards .card { flex: none; }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards .card {\n padding: 0 0.25rem 1.125rem;\n border: 0;\n border-radius: 0;\n background: transparent;\n box-shadow: none;\n }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards .card + .card {\n padding-top: 1.125rem;\n border-top: 1px solid var(--panel-border);\n }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards .card::before { display: none; }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .card-header { gap: 0.55rem; margin-bottom: 0.45rem; }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards .card h3 { font-size: 0.875rem; letter-spacing: -0.005em; }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards .card ul { font-size: 0.8125rem; line-height: 1.6; }\n\n .node-outline { display: none; }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .node-outline:not([hidden]) {\n display: flex;\n flex: 1 0 min(13rem, 55%);\n flex-direction: column;\n min-height: 0;\n margin-top: 0.25rem;\n overflow: hidden;\n border-top: 1px solid var(--panel-border);\n }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards:empty + .node-outline:not([hidden]) { margin-top: 0; border-top: 0; }\n /* Collapsed: only the reveal control remains, so the diagram takes the width. */\n html[data-reader-rail=\"collapsed\"] .reader-rail { display: none; }\n /* Overlay: a drawer for diagrams whose readable floor leaves no room to dock. */\n html[data-reader-rail=\"overlay\"] .reader-rail {\n position: fixed;\n z-index: 150;\n top: 1rem;\n right: 1rem;\n bottom: 1rem;\n display: flex;\n flex-direction: column;\n width: var(--archify-rail-width);\n padding: 0.75rem 1rem 0.5rem;\n border: 1px solid color-mix(in srgb, var(--panel-border) 90%, transparent);\n border-radius: 1rem;\n background: var(--toolbar-menu-bg);\n box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06), 0 28px 64px -18px rgba(15, 23, 42, 0.38);\n animation: rail-drawer-in 0.2s cubic-bezier(0.22, 1, 0.36, 1);\n }\n @keyframes rail-drawer-in {\n from { opacity: 0; transform: translateX(0.75rem); }\n to { opacity: 1; transform: translateX(0); }\n }\n /* Bottom (default): the notes keep their full-width card row and the index\n follows as one panel whose groups flow into columns, so nothing scrolls\n inside it. The placement toggle sits in the index header. */\n html[data-reader-rail=\"bottom\"] .reader-rail {\n display: grid;\n grid-template-areas: \"cards\" \"index\";\n grid-template-columns: minmax(0, 1fr);\n row-gap: 1rem;\n margin-top: 1rem;\n }\n html[data-reader-rail=\"bottom\"] .cards { grid-area: cards; margin-top: 0; }\n html[data-reader-rail=\"bottom\"] .cards:empty { display: none; }\n html[data-reader-rail=\"bottom\"] .node-outline:not([hidden]) {\n display: block;\n grid-area: index;\n padding: 0 1.25rem 0.75rem;\n border: 1px solid var(--panel-border);\n border-radius: 0.75rem;\n background: var(--panel);\n }\n html[data-reader-rail=\"bottom\"] .reader-rail \u003e .rail-controls {\n z-index: 1;\n grid-area: index;\n align-self: start;\n justify-self: end;\n margin: 0.625rem 0.625rem 0 0;\n }\n html[data-reader-rail=\"bottom\"] .node-outline-head { padding: 1rem 2.5rem 0.375rem 0.25rem; }\n html[data-reader-rail=\"bottom\"] .node-outline-list {\n columns: 15rem;\n column-gap: 1.75rem;\n padding: 0;\n overflow: visible;\n -webkit-mask-image: none;\n mask-image: none;\n }\n /* Named groups stay whole; a single unnamed group may split across columns,\n where a continuous spine would read as a broken line. */\n html[data-reader-rail=\"bottom\"] .node-outline-group + .node-outline-group { margin-top: 0; }\n html[data-reader-rail=\"bottom\"] .node-outline-group:has(\u003e .node-outline-heading) { break-inside: avoid; padding-bottom: 0.25rem; }\n html[data-reader-rail=\"bottom\"] .node-outline-group:not(:has(\u003e .node-outline-heading)) \u003e ul::before { display: none; }\n html[data-reader-rail=\"bottom\"] .node-outline-group li { break-inside: avoid; }\n .rail-controls { display: none; }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"], [data-reader-rail=\"bottom\"]) .rail-controls {\n display: flex;\n flex: none;\n justify-content: flex-end;\n gap: 0.125rem;\n margin: -0.25rem -0.25rem 0.25rem 0;\n }\n .rail-control {\n display: inline-grid;\n place-items: center;\n width: 1.875rem;\n height: 1.875rem;\n border: 0;\n border-radius: 0.5rem;\n background: transparent;\n color: var(--text-faint);\n cursor: pointer;\n transition: background 0.14s ease, color 0.14s ease;\n }\n .rail-control[hidden] { display: none; }\n .rail-control:hover,\n .rail-control:focus-visible { color: var(--text); background: color-mix(in srgb, var(--text) 6%, transparent); }\n .rail-control:focus-visible { outline: 1.5px solid color-mix(in srgb, var(--frontend-stroke) 60%, transparent); outline-offset: -1.5px; }\n .rail-control-icon,\n .rail-reveal-icon {\n width: 1rem;\n height: 1rem;\n background: currentColor;\n -webkit-mask: var(--rail-glyph) center / contain no-repeat;\n mask: var(--rail-glyph) center / contain no-repeat;\n }\n /* Panel glyphs: a frame with the panel drawn on the side it moves to. */\n .rail-control-icon.placement,\n #rail-placement[data-placement=\"right\"] .rail-control-icon { --rail-glyph: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cg fill='none' stroke='black' stroke-width='1.6'%3E%3Crect x='2.8' y='3.8' width='14.4' height='12.4' rx='2'/%3E%3Cpath d='M2.8 12h14.4'/%3E%3C/g%3E%3C/svg%3E\"); }\n #rail-placement[data-placement=\"bottom\"] .rail-control-icon { --rail-glyph: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cg fill='none' stroke='black' stroke-width='1.6'%3E%3Crect x='2.8' y='3.8' width='14.4' height='12.4' rx='2'/%3E%3Cpath d='M12.6 3.8v12.4'/%3E%3C/g%3E%3C/svg%3E\"); }\n .rail-control-icon.collapse { --rail-glyph: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='m8 5.5 4.5 4.5L8 14.5' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E\"); }\n .rail-reveal-icon { --rail-glyph: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cg fill='none' stroke='black' stroke-width='1.6'%3E%3Crect x='2.8' y='3.8' width='14.4' height='12.4' rx='2'/%3E%3Cpath d='M12.6 3.8v12.4M14.4 7.2h1M14.4 9.6h1M14.4 12h1'/%3E%3C/g%3E%3C/svg%3E\"); }\n .rail-reveal[hidden] { display: none; }\n /* The collapsed rail leaves one quiet pill in the canvas corner. */\n .rail-reveal {\n position: absolute;\n z-index: 13;\n top: 0.75rem;\n right: 0.75rem;\n display: inline-flex;\n align-items: center;\n gap: 0.45rem;\n min-height: 2rem;\n padding: 0 0.75rem 0 0.625rem;\n border: 1px solid color-mix(in srgb, var(--panel-border) 85%, transparent);\n border-radius: 999px;\n background: color-mix(in srgb, var(--panel) 86%, transparent);\n color: var(--text-muted);\n box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05), 0 8px 20px -12px rgba(15, 23, 42, 0.28);\n backdrop-filter: blur(12px);\n font: inherit;\n font-size: 0.75rem;\n font-weight: 500;\n cursor: pointer;\n transition: color 0.14s ease, background 0.14s ease;\n }\n .rail-reveal:hover,\n .rail-reveal:focus-visible { color: var(--text); background: var(--panel); }\n .rail-reveal:focus-visible { outline: 1.5px solid color-mix(in srgb, var(--frontend-stroke) 60%, transparent); outline-offset: 2px; }\n html[data-motion=\"still\"] .reader-rail { animation: none !important; }\n .node-outline-head {\n display: flex;\n align-items: center;\n gap: 0.5rem;\n padding: 1.125rem 0.25rem 0.375rem;\n }\n .node-outline-head strong {\n color: var(--text);\n font-size: 0.875rem;\n font-weight: 600;\n letter-spacing: -0.005em;\n }\n .node-outline-count {\n min-width: 1.35rem;\n padding: 0.1rem 0.4rem;\n border-radius: 999px;\n background: color-mix(in srgb, var(--text) 6%, transparent);\n color: var(--text-muted);\n font-size: 0.6875rem;\n font-weight: 600;\n line-height: 1.3;\n text-align: center;\n font-variant-numeric: tabular-nums;\n }\n .node-outline-list {\n flex: 1 1 auto;\n min-height: 0;\n margin: 0 -0.375rem;\n padding: 0 0 1.25rem;\n overflow-y: auto;\n list-style: none;\n scrollbar-width: none;\n -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - 2rem), transparent);\n mask-image: linear-gradient(to bottom, #000 calc(100% - 2rem), transparent);\n }\n .node-outline-list::-webkit-scrollbar { display: none; }\n .node-outline-group + .node-outline-group { margin-top: 0.25rem; }\n .node-outline-group \u003e ul {\n position: relative;\n list-style: none;\n }\n /* A quiet spine ties each group's swatches together like a lane. */\n .node-outline-group \u003e ul::before {\n position: absolute;\n top: 0.95rem;\n bottom: 0.95rem;\n left: calc(0.625rem + 0.3125rem - 0.5px);\n width: 1px;\n background: var(--panel-border);\n content: \"\";\n }\n .node-outline-heading {\n display: flex;\n align-items: baseline;\n justify-content: space-between;\n padding: 0.7rem 0.625rem 0.25rem;\n color: var(--text-faint);\n font-size: 0.6875rem;\n font-weight: 600;\n letter-spacing: 0.02em;\n }\n .node-outline-heading small {\n color: var(--text-dim);\n font-size: 0.6875rem;\n font-weight: 500;\n font-variant-numeric: tabular-nums;\n }\n /* The rail frees the vertical budget, so compact viewports keep the normal\n title spacing instead of the stacked layout's tight stage rail. */\n html[data-reader-rail]:not([data-reader-rail=\"bottom\"]) body { --archify-page-top: 1.5rem; padding-block: 1.5rem; }\n html[data-reader-rail]:not([data-reader-rail=\"bottom\"]) .toolbar { top: calc(var(--archify-page-top) - 0.1875rem); }\n html[data-reader-rail]:not([data-reader-rail=\"bottom\"]) .header { min-height: 0; margin-bottom: 1.125rem; }\n .node-outline-item {\n position: relative;\n display: grid;\n grid-template-columns: 0.625rem minmax(0, auto) minmax(0, 1fr) 0.75rem;\n align-items: center;\n column-gap: 0.625rem;\n width: 100%;\n min-height: 1.95rem;\n padding: 0.28rem 0.5rem 0.28rem 0.625rem;\n border: 0;\n border-radius: 0.5rem;\n background: transparent;\n color: var(--text);\n font: inherit;\n text-align: left;\n cursor: pointer;\n transition: background 0.16s ease;\n }\n /* Trailing chevron hints that a click focuses the node. */\n .node-outline-item::after {\n grid-column: 4;\n width: 0.75rem;\n height: 0.75rem;\n background: currentColor;\n color: var(--text-muted);\n content: \"\";\n opacity: 0;\n transform: translateX(-3px);\n transition: opacity 0.16s ease, transform 0.16s ease;\n -webkit-mask: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='m4.5 3 3 3-3 3' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E\") center / contain no-repeat;\n mask: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='m4.5 3 3 3-3 3' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E\") center / contain no-repeat;\n }\n .node-outline-item:hover,\n .node-outline-item:focus-visible,\n .node-outline-item[data-previewing] { background: color-mix(in srgb, var(--text) 4.5%, transparent); }\n .node-outline-item:hover::after,\n .node-outline-item:focus-visible::after { opacity: 0.7; transform: translateX(0); }\n .node-outline-item:focus-visible { outline: 1.5px solid color-mix(in srgb, var(--outline-tone) 60%, transparent); outline-offset: -1.5px; }\n .node-outline-item[aria-current=\"true\"] { background: color-mix(in srgb, var(--outline-tone) 10%, transparent); }\n .node-outline-item[aria-current=\"true\"]::after { opacity: 0; }\n /* Swatches echo the diagram's node cards: tinted fill, hairline stroke. */\n .node-outline-dot {\n width: 0.625rem;\n height: 0.5rem;\n border: 1.25px solid var(--outline-tone);\n border-radius: 0.15rem;\n background: color-mix(in srgb, var(--outline-tone) 16%, var(--bg));\n transition: background 0.16s ease, transform 0.16s ease, box-shadow 0.16s ease;\n }\n .node-outline-item:hover .node-outline-dot,\n .node-outline-item:focus-visible .node-outline-dot,\n .node-outline-item[data-previewing] .node-outline-dot,\n .node-outline-item[aria-current=\"true\"] .node-outline-dot {\n background: var(--outline-tone);\n box-shadow: 0 0 0 3px color-mix(in srgb, var(--outline-tone) 18%, transparent);\n transform: scale(1.08);\n }\n .node-outline-item strong {\n overflow: hidden;\n font-size: 0.8125rem;\n font-weight: 500;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .node-outline-item[aria-current=\"true\"] strong { font-weight: 600; }\n .node-outline-item small {\n overflow: hidden;\n color: var(--text-faint);\n font-size: 0.6875rem;\n text-align: right;\n text-overflow: ellipsis;\n white-space: nowrap;\n transition: color 0.16s ease;\n }\n .node-outline-item:hover small,\n .node-outline-item[data-previewing] small,\n .node-outline-item[aria-current=\"true\"] small { color: var(--text-muted); }\n\n .card-header {\n display: flex;\n align-items: center;\n gap: 0.5rem;\n margin-bottom: 0.625rem;\n }\n\n .card-dot {\n flex: none;\n width: 8px;\n height: 8px;\n border-radius: 50%;\n }\n\n .card-dot.cyan { background: var(--frontend-stroke); }\n .card-dot.emerald { background: var(--backend-stroke); }\n .card-dot.violet { background: var(--database-stroke); }\n .card-dot.amber { background: var(--cloud-stroke); }\n .card-dot.rose { background: var(--security-stroke); }\n .card-dot.orange { background: var(--messagebus-stroke); }\n .card-dot.slate { background: var(--external-stroke); }\n\n .card h3 { font-size: 0.9375rem; font-weight: 600; line-height: 1.4; color: var(--text); }\n\n .card ul {\n list-style: none;\n color: var(--text-muted);\n font-size: 0.8125rem;\n line-height: 1.6;\n }\n\n .card li {\n position: relative;\n margin-bottom: 0.3rem;\n padding-left: 0.9rem;\n }\n .card li:last-child { margin-bottom: 0; }\n /* Hanging markers take the card's tone so wrapped lines align under text. */\n .card li::before {\n position: absolute;\n top: calc(0.8em - 2px);\n left: 0.2rem;\n width: 4px;\n height: 4px;\n border-radius: 50%;\n background: color-mix(in srgb, var(--card-tone, var(--text-muted)) 70%, transparent);\n content: \"\";\n }\n .card:has(.card-dot.cyan) { --card-tone: var(--frontend-stroke); }\n .card:has(.card-dot.emerald) { --card-tone: var(--backend-stroke); }\n .card:has(.card-dot.violet) { --card-tone: var(--database-stroke); }\n .card:has(.card-dot.amber) { --card-tone: var(--cloud-stroke); }\n .card:has(.card-dot.rose) { --card-tone: var(--security-stroke); }\n .card:has(.card-dot.orange) { --card-tone: var(--messagebus-stroke); }\n .card:has(.card-dot.slate) { --card-tone: var(--external-stroke); }\n .card-dot { box-shadow: 0 0 0 3px color-mix(in srgb, var(--card-tone, transparent) 16%, transparent); }\n\n /* ==========================================================\n Print stylesheet — hide interactive controls, force light,\n drop the grid so the diagram doesn't waste ink, use landscape\n so wide diagrams fit, pack summary cards into 2 columns to\n avoid an orphan card on a trailing page.\n ========================================================== */\n @page { size: landscape; margin: 1.5cm; }\n\n @media print {\n /* Force the FULL light palette — including component fills/strokes and\n lane/arrow colors — so printing from dark theme doesn't put neon\n strokes and translucent dark fills on white paper. */\n :root, [data-theme=\"dark\"], [data-theme=\"light\"] {\n --bg: #ffffff;\n --grid: transparent;\n --panel: #ffffff;\n --panel-border: #e2e8f0;\n --text: #0f172a;\n --text-muted: #475569;\n --text-dim: #94a3b8;\n --text-faint: #64748b;\n --mask: #ffffff;\n --lane-fill: rgba(248, 250, 252, 0.65);\n --lane-stroke: #cbd5e1;\n --arrow: #94a3b8;\n --arrow-emphasis: #059669;\n --frontend-fill: rgba(34, 211, 238, 0.15);\n --frontend-stroke: #0891b2;\n --backend-fill: rgba(52, 211, 153, 0.18);\n --backend-stroke: #059669;\n --database-fill: rgba(167, 139, 250, 0.2);\n --database-stroke: #7c3aed;\n --cloud-fill: rgba(251, 191, 36, 0.18);\n --cloud-stroke: #d97706;\n --security-fill: rgba(251, 113, 133, 0.15);\n --security-stroke: #e11d48;\n --messagebus-fill: rgba(251, 146, 60, 0.15);\n --messagebus-stroke:#ea580c;\n --external-fill: rgba(148, 163, 184, 0.18);\n --external-stroke: #64748b;\n }\n body { background: #ffffff !important; padding: 0; }\n .container { max-width: none; }\n .toolbar, .diagram-nav, .focus-chip, .archify-toast, .no-print { display: none !important; }\n \n .diagram-container, .card { box-shadow: none; border-color: #e2e8f0; }\n .diagram-container { --archify-nav-reserve: 0px !important; }\n html[data-preset=\"signal-flow\"] .diagram-container,\n html[data-preset=\"signal-flow\"] .card { background: #ffffff; }\n .cards { grid-template-columns: 1fr 1fr; }\n /* Ensure elements break sensibly across pages */\n .card { break-inside: avoid; page-break-inside: avoid; }\n .diagram-container { break-inside: avoid; page-break-inside: avoid; }\n .diagram-container svg [data-detail] {\n opacity: 1 !important;\n pointer-events: auto !important;\n }\n .diagram-container svg [data-detail-anchor] { transform: none !important; }\n .diagram-container svg[data-lens-active] [data-node-id],\n .diagram-container svg[data-lens-active] [data-edge-from],\n .diagram-container svg[data-legend-preview-active] [data-node-id],\n .diagram-container svg[data-legend-preview-active] [data-edge-from] {\n opacity: 1 !important;\n filter: none !important;\n }\n [data-legend-bridge-runtime] { display: none !important; }\n .semantic-lens-overlay { display: none !important; }\n .relationship-hit-overlay { display: none !important; }\n .relationship-pulse-overlay { display: none !important; }\n .route-probe-overlay, .route-journey-overlay { display: none !important; }\n .diagram-container svg[data-focus-active] [data-node-id],\n .diagram-container svg[data-focus-active] [data-edge-from],\n .diagram-container svg[data-focus-active] [data-graph-role=\"automatic-crossover-underlay\"],\n .diagram-container svg[data-reach-active] [data-node-id],\n .diagram-container svg[data-reach-active] [data-edge-from],\n .diagram-container svg[data-reach-active] [data-graph-role=\"automatic-crossover-underlay\"],\n .diagram-container svg[data-route-active] [data-node-id],\n .diagram-container svg[data-route-active] [data-edge-from],\n .diagram-container svg[data-route-active] [data-graph-role=\"automatic-crossover-underlay\"] {\n opacity: 1 !important;\n filter: none !important;\n animation: none !important;\n }\n h1, .subtitle { color: #0f172a; }\n }\n\n /* ==========================================================\n TOOLBAR (theme toggle + export menu)\n ========================================================== */\n /* The toolbar tracks the centered reader column and the title row, so\n an adaptive narrow reader does not leave its controls stranded at the\n viewport edge. */\n .toolbar {\n position: absolute;\n top: var(--archify-page-top);\n right: max(1rem, calc((100vw - min(100vw - 4rem, var(--archify-reader-width, 1440px))) / 2));\n display: flex;\n align-items: center;\n gap: 0.125rem;\n padding: 0;\n border: 0;\n background: transparent;\n box-shadow: none;\n z-index: 100;\n }\n /* Ghost controls keep a 44px hit area while the visible pill stays compact;\n Export is the one primary action. */\n .toolbar button {\n position: relative;\n isolation: isolate;\n background: transparent;\n color: var(--text-muted);\n border: 0;\n padding: 0.5rem 0.75rem;\n border-radius: 0.5625rem;\n font-family: inherit;\n font-size: 0.8125rem;\n font-weight: 500;\n cursor: pointer;\n white-space: nowrap;\n box-shadow: none;\n transition: color 0.15s;\n display: inline-flex;\n align-items: center;\n gap: 0.4rem;\n min-height: 2.75rem;\n }\n .toolbar button::before {\n position: absolute;\n z-index: -1;\n inset: 0.375rem 0;\n border-radius: 0.5rem;\n background: transparent;\n content: \"\";\n transition: background 0.15s, box-shadow 0.15s;\n }\n .toolbar button:hover { color: var(--text); }\n .toolbar button:hover::before { background: color-mix(in srgb, var(--text) 6%, transparent); }\n .toolbar button[aria-expanded=\"true\"],\n .toolbar button[aria-pressed=\"true\"]:not(#btn-theme) { color: var(--text); }\n .toolbar button[aria-expanded=\"true\"]::before,\n .toolbar button[aria-pressed=\"true\"]:not(#btn-theme)::before {\n background: color-mix(in srgb, var(--text) 8%, transparent);\n }\n .toolbar #btn-export {\n margin-left: 0.375rem;\n padding-right: 0.95rem;\n padding-left: 1rem;\n color: var(--bg);\n font-weight: 550;\n }\n .toolbar #btn-export::before {\n background: var(--text);\n box-shadow: 0 1px 2px rgba(15, 23, 42, 0.12), 0 6px 16px -8px rgba(15, 23, 42, 0.4);\n }\n .toolbar #btn-export:hover,\n .toolbar #btn-export[aria-expanded=\"true\"] { color: var(--bg); }\n .toolbar #btn-export:hover::before,\n .toolbar #btn-export[aria-expanded=\"true\"]::before { background: color-mix(in srgb, var(--text) 86%, var(--bg)); }\n .toolbar button:focus-visible {\n outline: 2px solid var(--frontend-stroke);\n outline-offset: -4px;\n }\n .toolbar { gap: 0.5rem; }\n .toolbar #btn-export { margin-left: 0; }\n .toolbar #btn-export::before { inset: 0.25rem 0; border-radius: 0.6875rem; }\n /* Tools share one quiet capsule; the capsule is drawn inside the 44px row\n so the controls keep their hit area without a tall visible box. */\n .toolbar-group {\n position: relative;\n isolation: isolate;\n display: flex;\n align-items: center;\n gap: 0.0625rem;\n padding: 0 0.25rem;\n }\n .toolbar-group::before {\n position: absolute;\n z-index: -1;\n inset: 0.25rem 0;\n border: 1px solid color-mix(in srgb, var(--panel-border) 85%, transparent);\n border-radius: 0.6875rem;\n background: color-mix(in srgb, var(--panel) 78%, transparent);\n box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 8px 20px -14px rgba(15, 23, 42, 0.22);\n backdrop-filter: blur(12px);\n content: \"\";\n }\n .toolbar-group button { padding-inline: 0.625rem; }\n .toolbar-group button::before { inset: 0.5rem 0; border-radius: 0.5rem; }\n /* Theme becomes a sliding switch; its label stays for assistive tech. */\n .toolbar #theme-label,\n .toolbar #present-label {\n position: absolute;\n width: 1px;\n height: 1px;\n overflow: hidden;\n clip: rect(0 0 0 0);\n white-space: nowrap;\n }\n .toolbar #btn-theme {\n width: 3.5rem;\n padding: 0;\n justify-content: center;\n }\n .toolbar #btn-theme::before {\n inset: 0.75rem 0.4375rem;\n border-radius: 999px;\n background: color-mix(in srgb, var(--text) 9%, transparent);\n box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.08);\n }\n .toolbar #btn-theme:hover::before { background: color-mix(in srgb, var(--text) 13%, transparent); }\n .toolbar #btn-theme::after {\n position: absolute;\n z-index: 0;\n top: 50%;\n left: 0.5625rem;\n width: 1.125rem;\n height: 1.125rem;\n border-radius: 50%;\n background: var(--panel);\n box-shadow: 0 1px 2px rgba(15, 23, 42, 0.18), 0 2px 6px rgba(15, 23, 42, 0.12);\n content: \"\";\n transform: translateY(-50%);\n transition: left 0.22s cubic-bezier(0.22, 1, 0.36, 1);\n }\n .toolbar #theme-icon {\n position: absolute;\n z-index: 1;\n top: 50%;\n left: calc(0.5625rem + 0.1875rem);\n width: 0.75rem;\n height: 0.75rem;\n color: var(--cloud-stroke);\n transform: translateY(-50%);\n transition: left 0.22s cubic-bezier(0.22, 1, 0.36, 1);\n }\n [data-theme=\"dark\"] .toolbar #btn-theme::before { background: rgba(148, 163, 184, 0.16); }\n [data-theme=\"dark\"] .toolbar #btn-theme::after { left: calc(100% - 0.5625rem - 1.125rem); background: #3b4a63; box-shadow: 0 1px 3px rgba(0, 0, 0, 0.4); }\n [data-theme=\"dark\"] .toolbar #theme-icon { left: calc(100% - 0.5625rem - 1.125rem + 0.1875rem); color: #c7d2fe; }\n .toolbar #btn-present { width: 2.5rem; padding: 0; justify-content: center; }\n .toolbar #btn-present .toolbar-icon { width: 1rem; height: 1rem; }\n html[data-motion=\"still\"] .toolbar #btn-theme::after,\n html[data-motion=\"still\"] .toolbar #theme-icon { transition: none; }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .toolbar { right: 1rem; }\n html[data-preset=\"editorial\"] .toolbar { border-radius: 0.45rem; }\n .toolbar #btn-motion[hidden] { display: none !important; }\n .toolbar #btn-motion { min-width: 4.4rem; }\n .toolbar #btn-motion:disabled { cursor: default; opacity: 0.58; }\n .toolbar .preset-wrap,\n .toolbar .export-wrap {\n position: relative;\n }\n .toolbar-icon {\n display: inline-block;\n width: 0.95rem;\n height: 0.95rem;\n flex: 0 0 auto;\n background: currentColor;\n -webkit-mask-position: center;\n -webkit-mask-repeat: no-repeat;\n -webkit-mask-size: contain;\n mask-position: center;\n mask-repeat: no-repeat;\n mask-size: contain;\n }\n .toolbar-chevron {\n width: 0.65rem;\n height: 0.65rem;\n transition: transform 0.15s ease;\n }\n [aria-expanded=\"true\"] \u003e .toolbar-chevron { transform: rotate(180deg); }\n [data-theme=\"light\"] #theme-icon {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cg fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round'%3E%3Ccircle cx='10' cy='10' r='3.1'/%3E%3Cpath d='M10 2.2v1.4M10 16.4v1.4M2.2 10h1.4M16.4 10h1.4M4.5 4.5l1 1M14.5 14.5l1 1M15.5 4.5l-1 1M5.5 14.5l-1 1'/%3E%3C/g%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cg fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round'%3E%3Ccircle cx='10' cy='10' r='3.1'/%3E%3Cpath d='M10 2.2v1.4M10 16.4v1.4M2.2 10h1.4M16.4 10h1.4M4.5 4.5l1 1M14.5 14.5l1 1M15.5 4.5l-1 1M5.5 14.5l-1 1'/%3E%3C/g%3E%3C/svg%3E\");\n }\n [data-theme=\"dark\"] #theme-icon {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M15.2 12.7A6.3 6.3 0 017.3 4.8a6.3 6.3 0 107.9 7.9Z' fill='none' stroke='black' stroke-width='1.7' stroke-linejoin='round'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M15.2 12.7A6.3 6.3 0 017.3 4.8a6.3 6.3 0 107.9 7.9Z' fill='none' stroke='black' stroke-width='1.7' stroke-linejoin='round'/%3E%3C/svg%3E\");\n }\n #btn-present[aria-pressed=\"false\"] #present-icon {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M7.2 3.2h-4v4M12.8 3.2h4v4M7.2 16.8h-4v-4M12.8 16.8h4v-4' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M7.2 3.2h-4v4M12.8 3.2h4v4M7.2 16.8h-4v-4M12.8 16.8h4v-4' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round'/%3E%3C/svg%3E\");\n }\n #btn-present[aria-pressed=\"true\"] #present-icon {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M7.2 7.2h-4v-4M12.8 7.2h4v-4M7.2 12.8h-4v4M12.8 12.8h4v4' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M7.2 7.2h-4v-4M12.8 7.2h4v-4M7.2 12.8h-4v4M12.8 12.8h4v4' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round'/%3E%3C/svg%3E\");\n }\n .toolbar-chevron {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='m3 4.5 3 3 3-3' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='m3 4.5 3 3 3-3' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E\");\n }\n .toolbar #btn-preset { min-width: 5.4rem; }\n .preset-control-mark {\n width: 0.58rem;\n height: 0.58rem;\n flex: 0 0 auto;\n border: 1px solid var(--frontend-stroke);\n border-radius: 0.2rem;\n background: color-mix(in srgb, var(--frontend-stroke) 28%, transparent);\n transition: border-radius 0.15s, box-shadow 0.15s, transform 0.15s;\n }\n #btn-preset[data-preset-option=\"signal-flow\"] .preset-control-mark {\n border-radius: 50%;\n box-shadow: 0 0 10px color-mix(in srgb, var(--frontend-stroke) 78%, transparent);\n }\n #btn-preset[data-preset-option=\"blueprint\"] .preset-control-mark {\n border-radius: 0.06rem;\n background: transparent;\n box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--frontend-stroke) 32%, transparent);\n transform: rotate(45deg) scale(0.84);\n }\n #btn-preset[data-preset-option=\"editorial\"] .preset-control-mark {\n border-color: var(--arrow-emphasis);\n border-radius: 0;\n background: var(--arrow-emphasis);\n box-shadow: 0 0 0 2px color-mix(in srgb, var(--arrow-emphasis) 14%, transparent);\n transform: rotate(45deg) scale(0.72);\n }\n /* Menus anchor to the tools capsule so they open flush under it. */\n .toolbar-group .preset-wrap { position: static; }\n .toolbar .preset-menu {\n position: absolute;\n top: calc(100% + 0.125rem);\n right: 0;\n display: none;\n width: 17.5rem;\n max-width: calc(100vw - 2rem);\n padding: 0.375rem;\n border: 1px solid color-mix(in srgb, var(--panel-border) 90%, transparent);\n border-radius: 0.875rem;\n background: var(--toolbar-menu-bg);\n box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06), 0 18px 44px -14px rgba(15, 23, 42, 0.3);\n }\n [data-theme=\"dark\"] .toolbar .preset-menu,\n [data-theme=\"dark\"] .toolbar .export-menu {\n border-color: rgba(148, 163, 184, 0.16);\n box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 18px 44px -12px rgba(0, 0, 0, 0.6);\n }\n /* Menu rows are not toolbar pills: drop the ghost-button pseudo surface. */\n .toolbar .preset-menu button,\n .toolbar .export-menu button { isolation: auto; min-height: 0; }\n .toolbar .preset-menu button::before { display: none; }\n .toolbar .preset-menu.open { display: block; }\n .toolbar .preset-menu.open,\n .toolbar .export-menu.open {\n animation: toolbar-menu-in 0.16s cubic-bezier(0.2, 0.8, 0.2, 1);\n transform-origin: top right;\n }\n @keyframes toolbar-menu-in {\n from { opacity: 0; transform: translateY(-0.25rem) scale(0.985); }\n to { opacity: 1; transform: translateY(0) scale(1); }\n }\n .preset-menu-heading {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: 1rem;\n padding: 0.45rem 0.55rem 0.4rem;\n color: var(--text-faint);\n font-size: 0.6875rem;\n font-weight: 600;\n letter-spacing: 0.01em;\n }\n .preset-menu-shortcut {\n display: inline-flex;\n align-items: center;\n gap: 0.35rem;\n font-weight: 500;\n }\n .preset-menu-shortcut kbd {\n min-width: 1.125rem;\n padding: 0.05rem 0.3rem;\n border: 1px solid var(--panel-border);\n border-bottom-width: 2px;\n border-radius: 0.3rem;\n background: color-mix(in srgb, var(--text) 3%, var(--toolbar-menu-bg));\n color: var(--text-muted);\n font-family: inherit;\n font-size: 0.625rem;\n font-weight: 600;\n line-height: 1.3;\n text-align: center;\n }\n .toolbar .preset-option {\n display: grid;\n grid-template-columns: 2.375rem minmax(0, 1fr) 1rem;\n align-items: center;\n gap: 0.75rem;\n width: 100%;\n min-height: 3.125rem;\n margin-top: 0.125rem;\n padding: 0.45rem 0.6rem 0.45rem 0.5rem;\n border: 0;\n border-radius: 0.625rem;\n background: transparent;\n color: var(--text);\n box-shadow: none;\n backdrop-filter: none;\n text-align: left;\n transition: background 0.14s ease;\n }\n .toolbar .preset-option:hover,\n .toolbar .preset-option:focus-visible { background: color-mix(in srgb, var(--text) 5%, transparent); }\n .toolbar .preset-option[aria-checked=\"true\"] { background: color-mix(in srgb, var(--frontend-stroke) 8%, transparent); }\n .toolbar .preset-option:focus-visible {\n outline: 1.5px solid color-mix(in srgb, var(--frontend-stroke) 55%, transparent);\n outline-offset: -1.5px;\n }\n .preset-option-swatch {\n position: relative;\n width: 2.375rem;\n height: 1.75rem;\n overflow: hidden;\n border: 0;\n border-radius: 0.4375rem;\n background: #0f172a;\n box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.28), 0 1px 2px rgba(15, 23, 42, 0.12);\n transition: box-shadow 0.14s ease, transform 0.14s ease;\n }\n .toolbar .preset-option:hover .preset-option-swatch { transform: translateY(-1px); }\n .toolbar .preset-option[aria-checked=\"true\"] .preset-option-swatch {\n box-shadow: 0 0 0 2px var(--toolbar-menu-bg), 0 0 0 3.5px var(--frontend-stroke);\n }\n .preset-option-swatch::before,\n .preset-option-swatch::after { position: absolute; content: \"\"; }\n .preset-option-swatch.classic::before {\n top: 0.42rem;\n right: 0.35rem;\n bottom: 0.42rem;\n left: 0.35rem;\n border: 1px solid #22d3ee;\n border-radius: 0.16rem;\n background: rgba(34, 211, 238, 0.14);\n }\n /* Classic previews the canvas it will actually produce in this theme. */\n [data-theme=\"light\"] .preset-option-swatch.classic {\n background:\n radial-gradient(circle at 1px 1px, #d9dee5 0.6px, transparent 0.9px) 0 0 / 5px 5px,\n #ffffff;\n }\n [data-theme=\"light\"] .preset-option-swatch.classic::before {\n border-color: #1b87a3;\n background: rgba(14, 116, 144, 0.08);\n box-shadow: 0 2px 4px rgba(17, 24, 39, 0.12);\n }\n .preset-option-swatch.signal-flow {\n border-color: #29415f;\n background: linear-gradient(135deg, #07101e 10%, #10243c 100%);\n }\n .preset-option-swatch.signal-flow::before {\n top: 50%;\n right: 0.2rem;\n left: 0.2rem;\n height: 1px;\n background: linear-gradient(90deg, #67e8f9, #c4b5fd);\n box-shadow: 0 0 8px #67e8f9;\n }\n .preset-option-swatch.signal-flow::after {\n top: calc(50% - 0.13rem);\n right: 0.28rem;\n width: 0.26rem;\n height: 0.26rem;\n border-radius: 50%;\n background: #67e8f9;\n box-shadow: 0 0 7px #67e8f9;\n }\n .preset-option-swatch.blueprint {\n border-color: #34799a;\n border-radius: 0.08rem;\n background-color: #0a2031;\n background-image:\n linear-gradient(rgba(102, 217, 239, 0.18) 1px, transparent 1px),\n linear-gradient(90deg, rgba(102, 217, 239, 0.18) 1px, transparent 1px);\n background-size: 0.42rem 0.42rem;\n }\n .preset-option-swatch.blueprint::before {\n top: 0.34rem;\n right: 0.38rem;\n bottom: 0.34rem;\n left: 0.38rem;\n border: 1px solid #66d9ef;\n }\n .preset-option-swatch.editorial {\n border-color: #b8aa94;\n border-radius: 0.08rem;\n background: repeating-linear-gradient(0deg, #f2eee5 0 0.34rem, #d8d0c2 0.36rem, #f2eee5 0.38rem);\n }\n .preset-option-swatch.editorial::before {\n top: 0;\n bottom: 0;\n left: 0.42rem;\n width: 1px;\n background: #c9502d;\n opacity: 0.72;\n }\n .preset-option-swatch.editorial::after {\n top: 0.52rem;\n right: 0.45rem;\n width: 0.38rem;\n height: 0.38rem;\n background: #c9502d;\n transform: rotate(45deg);\n }\n .preset-option-copy { min-width: 0; }\n .preset-option-copy strong,\n .preset-option-copy small { display: block; }\n .preset-option-copy strong {\n color: var(--text);\n font-size: 0.8125rem;\n font-weight: 550;\n letter-spacing: -0.005em;\n }\n .toolbar .preset-option[aria-checked=\"true\"] .preset-option-copy strong { font-weight: 650; }\n .preset-option-copy small {\n margin-top: 0.125rem;\n overflow: hidden;\n color: var(--text-faint);\n font-size: 0.6875rem;\n font-weight: 400;\n white-space: nowrap;\n text-overflow: ellipsis;\n }\n .preset-option-check {\n display: inline-block;\n width: 0.9rem;\n height: 0.9rem;\n color: var(--frontend-stroke);\n background: currentColor;\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='m3 8.5 3 3 7-7' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E\");\n -webkit-mask-position: center;\n -webkit-mask-repeat: no-repeat;\n -webkit-mask-size: contain;\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='m3 8.5 3 3 7-7' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E\");\n mask-position: center;\n mask-repeat: no-repeat;\n mask-size: contain;\n opacity: 0;\n }\n .preset-option[aria-checked=\"true\"] .preset-option-check { opacity: 1; }\n html[data-preset=\"editorial\"] .toolbar button,\n html[data-preset=\"editorial\"] .preset-menu,\n html[data-preset=\"editorial\"] .export-menu,\n html[data-preset=\"editorial\"] .overview-map,\n html[data-preset=\"editorial\"] .semantic-lens,\n html[data-preset=\"editorial\"] .route-probe,\n html[data-preset=\"editorial\"] .focus-chip,\n html[data-preset=\"editorial\"] .diagram-guide,\n html[data-preset=\"editorial\"] .node-finder {\n border-radius: 0.3rem;\n }\n .motion-control-dot {\n width: 0.46rem;\n height: 0.46rem;\n flex: 0 0 auto;\n border: 1px solid var(--frontend-stroke);\n border-radius: 50%;\n background: var(--frontend-stroke);\n box-shadow: 0 0 9px color-mix(in srgb, var(--frontend-stroke) 72%, transparent);\n }\n #btn-motion[aria-pressed=\"false\"] .motion-control-dot {\n background: transparent;\n box-shadow: none;\n }\n .toolbar .export-menu {\n position: absolute;\n top: calc(100% + 0.125rem);\n right: 0;\n background: var(--toolbar-menu-bg);\n border: 1px solid color-mix(in srgb, var(--panel-border) 90%, transparent);\n width: 19rem;\n max-width: calc(100vw - 2rem);\n max-height: calc(100vh - 5.5rem);\n overflow-y: auto;\n border-radius: 0.875rem;\n padding: 0.375rem;\n display: none;\n flex-direction: column;\n box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06), 0 18px 44px -14px rgba(15, 23, 42, 0.3);\n scrollbar-width: thin;\n }\n .toolbar .export-menu.open { display: flex; }\n .export-menu-header {\n display: flex;\n align-items: flex-start;\n justify-content: space-between;\n gap: 1rem;\n padding: 0.55rem 0.6rem 0.6rem;\n }\n .export-menu-header strong,\n .export-menu-header span { display: block; }\n .export-menu-header strong {\n color: var(--text);\n font-size: 0.875rem;\n font-weight: 600;\n letter-spacing: -0.005em;\n }\n .export-menu-header span {\n margin-top: 0.15rem;\n color: var(--text-faint);\n font-size: 0.75rem;\n }\n .export-menu-header kbd {\n min-width: 1.125rem;\n padding: 0.05rem 0.3rem;\n border: 1px solid var(--panel-border);\n border-bottom-width: 2px;\n border-radius: 0.3rem;\n background: color-mix(in srgb, var(--text) 3%, var(--toolbar-menu-bg));\n color: var(--text-muted);\n font-family: inherit;\n font-size: 0.625rem;\n font-weight: 600;\n line-height: 1.3;\n text-align: center;\n }\n .export-menu-section {\n display: grid;\n grid-template-columns: minmax(0, 1fr);\n gap: 0.0625rem;\n }\n .export-menu-section + .export-menu-section {\n margin-top: 0.3rem;\n padding-top: 0.3rem;\n border-top: 1px solid color-mix(in srgb, var(--panel-border) 80%, transparent);\n }\n .export-menu-heading {\n grid-column: 1 / -1;\n display: block;\n padding: 0.4rem 0.6rem 0.25rem;\n color: var(--text-faint);\n font-size: 0.6875rem;\n font-weight: 600;\n letter-spacing: 0.01em;\n }\n .toolbar .export-menu button {\n display: grid;\n grid-template-columns: 1rem minmax(0, 1fr);\n align-items: center;\n column-gap: 0.7rem;\n background: transparent;\n border: 0;\n box-shadow: none;\n backdrop-filter: none;\n width: 100%;\n min-height: 2.5rem;\n text-align: left;\n padding: 0.4rem 0.6rem;\n border-radius: 0.5625rem;\n color: var(--text);\n white-space: nowrap;\n transition: background 0.14s ease;\n }\n .toolbar .export-menu button:hover,\n .toolbar .export-menu button:focus-visible { background: color-mix(in srgb, var(--text) 5%, transparent); color: var(--text); }\n .toolbar .export-menu button:focus-visible {\n outline: 1.5px solid color-mix(in srgb, var(--frontend-stroke) 55%, transparent);\n outline-offset: -1.5px;\n }\n /* Name and format hint share one line, so each row stays compact. */\n .export-item-copy {\n display: flex;\n align-items: baseline;\n justify-content: space-between;\n gap: 0.75rem;\n min-width: 0;\n }\n .export-item-copy strong {\n overflow: hidden;\n color: inherit;\n font-size: 0.8125rem;\n font-weight: 500;\n text-overflow: ellipsis;\n }\n .export-item-copy small {\n flex: none;\n color: var(--text-faint);\n font-size: 0.6875rem;\n font-weight: 450;\n }\n .toolbar .export-menu button::before {\n position: static;\n z-index: auto;\n inset: auto;\n border-radius: 0;\n display: block;\n width: 1rem;\n height: 1rem;\n background: currentColor;\n color: var(--text-muted);\n content: \"\";\n opacity: 0.8;\n -webkit-mask-position: center;\n -webkit-mask-repeat: no-repeat;\n -webkit-mask-size: contain;\n mask-position: center;\n mask-repeat: no-repeat;\n mask-size: contain;\n }\n .toolbar .export-menu button[data-action=\"route-share-card\"]::before,\n .toolbar .export-menu button[data-action=\"reach-share-card\"]::before {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath fill='none' stroke='black' stroke-width='1.7' d='M3 4.5h14v11H3zM6 12l2.5-2.5 2 2 1.5-1.5 2 2'/%3E%3Ccircle cx='13.8' cy='7.3' r='1.2' fill='black'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath fill='none' stroke='black' stroke-width='1.7' d='M3 4.5h14v11H3zM6 12l2.5-2.5 2 2 1.5-1.5 2 2'/%3E%3Ccircle cx='13.8' cy='7.3' r='1.2' fill='black'/%3E%3C/svg%3E\");\n }\n .toolbar .export-menu button[data-action^=\"copy\"]::before {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Crect x='6' y='6' width='10' height='10' rx='1.5' fill='none' stroke='black' stroke-width='1.7'/%3E%3Cpath d='M4 13H3.5A1.5 1.5 0 012 11.5v-8A1.5 1.5 0 013.5 2h8A1.5 1.5 0 0113 3.5V4' fill='none' stroke='black' stroke-width='1.7'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Crect x='6' y='6' width='10' height='10' rx='1.5' fill='none' stroke='black' stroke-width='1.7'/%3E%3Cpath d='M4 13H3.5A1.5 1.5 0 012 11.5v-8A1.5 1.5 0 013.5 2h8A1.5 1.5 0 0113 3.5V4' fill='none' stroke='black' stroke-width='1.7'/%3E%3C/svg%3E\");\n }\n .toolbar .export-menu button[data-format=\"png\"]::before,\n .toolbar .export-menu button[data-format=\"jpeg\"]::before,\n .toolbar .export-menu button[data-format=\"webp\"]::before {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 2.5h7l3 3v12H5zM12 2.5v3h3' fill='none' stroke='black' stroke-width='1.7'/%3E%3Cpath d='M7.5 14l2-2 1.5 1.5 1.5-1.5' fill='none' stroke='black' stroke-width='1.7'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 2.5h7l3 3v12H5zM12 2.5v3h3' fill='none' stroke='black' stroke-width='1.7'/%3E%3Cpath d='M7.5 14l2-2 1.5 1.5 1.5-1.5' fill='none' stroke='black' stroke-width='1.7'/%3E%3C/svg%3E\");\n }\n .toolbar .export-menu button[data-format^=\"svg\"]::before,\n .toolbar .export-menu button[data-format=\"webm\"]::before {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M10 2.5l7 4v7l-7 4-7-4v-7zM3 6.5l7 4 7-4M10 10.5v7' fill='none' stroke='black' stroke-width='1.7'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M10 2.5l7 4v7l-7 4-7-4v-7zM3 6.5l7 4 7-4M10 10.5v7' fill='none' stroke='black' stroke-width='1.7'/%3E%3C/svg%3E\");\n }\n .toolbar .export-menu button[data-action=\"route-share-card\"],\n .toolbar .export-menu button[data-action=\"reach-share-card\"] {\n color: var(--text);\n background: color-mix(in srgb, var(--frontend-stroke) 7%, transparent);\n }\n .toolbar .export-menu button[data-action=\"route-share-card\"]::before,\n .toolbar .export-menu button[data-action=\"reach-share-card\"]::before { color: var(--frontend-stroke); opacity: 1; }\n .toolbar .export-menu button[hidden] { display: none; }\n .toolbar .export-menu button[data-action=\"route-share-card\"]:hover,\n .toolbar .export-menu button[data-action=\"reach-share-card\"]:hover {\n background: color-mix(in srgb, var(--frontend-stroke) 12%, transparent);\n }\n .toolbar .export-menu button:disabled {\n color: var(--text-faint);\n background: transparent;\n opacity: 0.55;\n cursor: not-allowed;\n }\n .toolbar .export-menu .hint {\n color: var(--text-faint);\n font-size: 0.6875rem;\n }\n\n /* Toast — brief feedback for actions like \"copied\" */\n .archify-toast {\n position: fixed;\n top: 1rem;\n left: 50%;\n transform: translateX(-50%) translateY(-8px);\n background: var(--toolbar-menu-bg);\n color: var(--text);\n border: 1px solid var(--toolbar-border);\n padding: 0.5rem 1rem;\n border-radius: 0.5rem;\n font-family: inherit;\n font-size: 0.75rem;\n opacity: 0;\n transition: opacity 0.2s, transform 0.2s;\n z-index: 200;\n pointer-events: none;\n box-shadow: 0 4px 20px rgba(0,0,0,0.25);\n }\n .archify-toast.show {\n opacity: 1;\n transform: translateX(-50%) translateY(0);\n }\n\n @media (max-width: 720px) {\n body { padding: 1rem; }\n .toolbar .preset-menu,\n .toolbar .export-menu {\n position: fixed;\n top: 4.5rem;\n right: 1rem;\n left: 1rem;\n width: auto;\n max-width: none;\n }\n .toolbar {\n position: relative;\n top: auto;\n right: auto;\n justify-content: flex-end;\n width: max-content;\n max-width: 100%;\n margin-left: auto;\n margin-bottom: 1rem;\n }\n .header { margin-bottom: 1.25rem; padding-right: 0; }\n html[data-preset=\"signal-flow\"] .header,\n html[data-preset=\"blueprint\"] .header,\n html[data-preset=\"editorial\"] .header { padding-right: 0; }\n .header-row {\n gap: 0.75rem;\n align-items: flex-start;\n }\n html[data-preset=\"signal-flow\"] .header-row,\n html[data-preset=\"blueprint\"] .header-row,\n html[data-preset=\"editorial\"] .header-row { flex-wrap: wrap; }\n html[data-preset=\"signal-flow\"] .header-row::after {\n margin-left: 0;\n order: 3;\n }\n html[data-preset=\"blueprint\"] .header-row::after {\n margin-left: 0;\n order: 3;\n }\n html[data-preset=\"editorial\"] .header-row::after {\n margin-left: 0;\n order: 3;\n }\n h1 {\n font-size: 1.25rem;\n line-height: 1.25;\n }\n .subtitle {\n margin-left: 0;\n font-size: 0.8125rem;\n line-height: 1.55;\n }\n .diagram-container {\n padding: 0.75rem;\n border-radius: 0.75rem;\n }\n html:not([data-embed=\"true\"]) .diagram-container {\n padding: 0.75rem 0.75rem 4.25rem;\n }\n html:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] {\n overflow-x: auto;\n overflow-y: hidden;\n overscroll-behavior-x: contain;\n scrollbar-width: thin;\n scroll-behavior: smooth;\n }\n html:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] \u003e svg {\n min-width: 720px;\n }\n html:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] .diagram-nav,\n html:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] .overview-map,\n html:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] .focus-chip,\n html:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] .route-probe,\n html:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] .semantic-lens,\n html:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] .diagram-guide,\n html:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] .node-finder {\n transform: translateX(var(--archify-scroll-x, 0px));\n }\n .diagram-nav { right: 0.5rem; bottom: 0.5rem; }\n .diagram-nav button {\n min-width: 2.75rem;\n height: 2.75rem;\n }\n .diagram-nav [data-view=\"reset\"] { min-width: 3.75rem; }\n .diagram-nav [data-view=\"reset\"][data-detail-visible] { min-width: 4.35rem; }\n .overview-map {\n right: 0.5rem;\n bottom: 3.7rem;\n width: min(10.25rem, calc(100% - 1rem));\n }\n .overview-map[data-docked=\"true\"] {\n right: var(--archify-radar-right, 0.5rem);\n top: var(--archify-radar-top, 0.5rem);\n bottom: auto;\n transform: none !important;\n }\n .overview-map[data-docked=\"true\"][data-dock-side=\"left\"] {\n right: auto;\n left: var(--archify-radar-left, 0.5rem);\n }\n .overview-map-surface { height: 4rem; }\n .overview-map-feedback { right: 0.5rem; bottom: 3.7rem; }\n .semantic-lens {\n right: 0.5rem;\n bottom: 3.7rem;\n width: calc(100% - 1rem);\n max-height: calc(100% - 4.2rem);\n }\n .semantic-lens[data-dock-side] { left: auto; right: 0.5rem; }\n .semantic-lens-kinds { max-height: min(12rem, 34vh); }\n .focus-chip {\n left: 0.5rem;\n top: 0.5rem;\n width: calc(100% - 1rem);\n max-width: none;\n }\n .relationship-lens-head { padding-top: 0.7rem; }\n .relationship-lens-drag-handle { display: none; }\n .relationship-lens-list { max-height: min(12rem, 38vh); }\n .relationship-lens-actions #btn-focus-relations { display: block; color: var(--database-stroke); }\n .focus-chip:not([data-relations-expanded=\"true\"]) .relationship-lens-head { border-bottom-color: transparent; }\n .focus-chip:not([data-relations-expanded=\"true\"]) .relationship-lens-list { display: none; }\n /* While a mobile reader previews one relationship, turn the full Lens\n into a compact peek card. This keeps the exact source and target on\n canvas instead of covering them with a long, scrollable list. */\n .focus-chip[data-relationship-previewing=\"true\"] .relationship-lens-list {\n max-height: none;\n padding: 0.35rem;\n overflow: hidden;\n }\n .focus-chip[data-relationship-previewing=\"true\"] .relationship-lens-group { margin: 0; }\n .focus-chip[data-relationship-previewing=\"true\"] .relationship-lens-group-title,\n .focus-chip[data-relationship-previewing=\"true\"] .relationship-lens-row:not([data-preview-active=\"true\"]) {\n display: none;\n }\n .node-finder {\n top: 0.5rem;\n left: 0.5rem;\n width: min(22rem, calc(100% - 1rem));\n max-height: calc(100% - 1rem);\n }\n .diagram-guide {\n top: 0.5rem;\n right: 0.5rem;\n left: 0.5rem;\n width: auto;\n max-height: calc(100% - 1rem);\n }\n .diagram-guide-head { padding: 0.62rem 0.7rem 0.52rem; }\n .diagram-guide-stats { padding: 0.42rem 0.7rem; }\n .diagram-guide-actions {\n grid-template-columns: 1fr;\n gap: 0.28rem;\n padding: 0.42rem;\n }\n .diagram-guide-action {\n min-height: 3.1rem;\n padding: 0.42rem 0.48rem;\n }\n .diagram-guide-action small {\n display: block;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .diagram-guide-index {\n width: 1.5rem;\n height: 1.5rem;\n }\n .diagram-guide-shortcuts { padding: 0.46rem 0.7rem 0.52rem; }\n .diagram-guide-action[data-guide-action=\"present\"] { grid-column: auto; }\n .route-probe[data-guide-open=\"true\"] {\n visibility: hidden;\n pointer-events: none;\n }\n .node-finder-results { max-height: min(16rem, 38vh); }\n .route-probe {\n left: 0.5rem;\n bottom: 3.7rem;\n width: calc(100% - 1rem);\n min-width: 0;\n }\n .route-probe[data-route-dock=\"top\"] {\n top: 0.5rem;\n bottom: auto;\n }\n .route-probe[data-finder-open=\"true\"] {\n visibility: hidden;\n pointer-events: none;\n }\n .route-probe-head { padding: 0.45rem 0.48rem 0.38rem; }\n .route-probe-path { padding: 0.35rem 0.48rem 0.2rem; }\n .route-probe-node { min-height: 2.75rem !important; }\n .route-journey-controls {\n grid-template-columns: 2.75rem minmax(0, 1fr) 2.75rem minmax(0, 1fr);\n padding: 0.08rem 0.48rem 0.32rem;\n }\n .route-journey-controls button { min-height: 2.75rem; }\n .route-probe-status { padding: 0.05rem 0.48rem 0.38rem; }\n .route-probe-node { max-width: 7.5rem; }\n \n \n \n \n \n \n \n \n \n \n \n html[data-embed=\"true\"][data-share-playback=\"true\"] .diagram-container {\n padding-top: 4.25rem;\n }\n html[data-embed=\"true\"][data-share-moment=\"true\"] .diagram-container {\n padding-top: 4.25rem;\n }\n \n .cards {\n grid-template-columns: 1fr;\n margin-top: 1rem;\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) body { padding: 0.5rem; }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .container {\n gap: 0.5rem;\n height: calc(100dvh - 1rem);\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .toolbar {\n position: fixed;\n top: 0.5rem;\n right: 0.5rem;\n margin: 0;\n gap: 0.25rem;\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .toolbar button {\n min-height: 2.75rem;\n padding: 0.42rem 0.58rem;\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .header {\n min-height: 2.25rem;\n padding: 3.5rem 0 0;\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .header-row {\n min-height: 2.25rem;\n margin: 0;\n align-items: center;\n flex-wrap: nowrap;\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .header-row::after,\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .pulse-dot,\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .subtitle { display: none; }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) h1 {\n flex: 1 1 auto;\n min-width: 0;\n max-width: 100%;\n overflow: hidden;\n font-size: 0.875rem;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n \n html[data-present=\"true\"]:not([data-embed=\"true\"]) .diagram-container { padding: 0.5rem 0.5rem 3.75rem; }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] \u003e svg {\n width: 720px;\n height: auto;\n min-width: 720px;\n }\n }\n\n @media (max-width: 420px) {\n .export-menu-section { grid-template-columns: 1fr; }\n .export-menu-heading,\n .toolbar .export-menu button[data-action=\"route-share-card\"],\n .toolbar .export-menu button[data-action=\"reach-share-card\"] { grid-column: 1; }\n }\n\n @media (prefers-reduced-motion: reduce) {\n .toolbar .preset-menu.open,\n .toolbar .export-menu.open { animation: none; }\n .toolbar-chevron { transition: none; }\n }\n\n @media (max-width: 360px) {\n .toolbar { gap: 0.25rem; }\n .toolbar button { padding-right: 0.58rem; padding-left: 0.58rem; }\n .toolbar #btn-motion { min-width: 4.4rem; padding-right: 0.58rem; padding-left: 0.58rem; }\n #theme-label, #preset-label, #present-label { display: none; }\n }\n\n /* ==========================================================\n SVG SEMANTIC CLASSES — use these instead of inline fill/stroke\n ========================================================== */\n .c-grid { stroke: var(--grid); fill: none; }\n .c-mask { fill: var(--mask); stroke: none; }\n .c-lane-rule { stroke: var(--lane-stroke); fill: none; opacity: 0.7; }\n .c-lane-wash { fill: var(--lane-fill); stroke: none; }\n\n .c-frontend { fill: var(--frontend-fill); stroke: var(--frontend-stroke); }\n .c-backend { fill: var(--backend-fill); stroke: var(--backend-stroke); }\n .c-database { fill: var(--database-fill); stroke: var(--database-stroke); }\n .c-cloud { fill: var(--cloud-fill); stroke: var(--cloud-stroke); }\n .c-security { fill: var(--security-fill); stroke: var(--security-stroke); }\n .c-messagebus { fill: var(--messagebus-fill); stroke: var(--messagebus-stroke); }\n .c-external { fill: var(--external-fill); stroke: var(--external-stroke); }\n\n /* Text helpers */\n .t-primary { fill: var(--text); }\n .t-muted { fill: var(--text-muted); }\n .t-dim { fill: var(--text-dim); }\n .t-frontend { fill: var(--frontend-stroke); }\n .t-backend { fill: var(--backend-stroke); }\n .t-database { fill: var(--database-stroke); }\n .t-cloud { fill: var(--cloud-stroke); }\n .t-security { fill: var(--security-stroke); }\n .t-messagebus { fill: var(--messagebus-stroke); }\n .t-external { fill: var(--external-stroke); }\n\n /* Relationship labels share the exact color token used by their path. */\n .t-edge-default { fill: var(--arrow); }\n .t-edge-emphasis { fill: var(--arrow-emphasis); }\n .t-edge-security { fill: var(--security-stroke); }\n .t-edge-dashed { fill: var(--database-stroke); }\n\n /* Classic canvas: a quiet dot field replaces drafting grid lines, and nodes\n read as lifted cards with hairline strokes. Paint only; authored geometry,\n hit areas and exports keep their canonical shapes. */\n html[data-preset=\"classic\"] .diagram-container {\n background:\n radial-gradient(circle at 1px 1px, var(--canvas-dot) 1px, transparent 1.4px) 0 0 / 20px 20px,\n var(--panel);\n }\n html[data-preset=\"classic\"] .diagram-container \u003e svg .c-grid { stroke: transparent; }\n html[data-preset=\"classic\"][data-theme=\"light\"] .diagram-container \u003e svg [data-node-id] \u003e rect:not(.c-mask) {\n filter: drop-shadow(0 1px 1px rgba(17, 24, 39, 0.05)) drop-shadow(0 6px 12px rgba(17, 24, 39, 0.06));\n }\n html[data-preset=\"classic\"][data-theme=\"dark\"] .diagram-container \u003e svg [data-node-id] \u003e rect:not(.c-mask) {\n filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.35));\n }\n html[data-preset=\"classic\"] .diagram-container \u003e svg [data-edge-from] {\n stroke-linecap: round;\n stroke-linejoin: round;\n }\n html[data-preset=\"classic\"] .diagram-container \u003e svg .c-lane-wash { fill: color-mix(in srgb, var(--text) 2.6%, transparent); }\n html[data-preset=\"classic\"] .diagram-container \u003e svg .c-lane-rule { stroke: var(--panel-border); opacity: 1; }\n html[data-preset=\"classic\"][data-theme=\"dark\"] .diagram-container \u003e svg .c-lane-rule { stroke: rgba(148, 163, 184, 0.16); }\n html[data-preset=\"classic\"] .diagram-container \u003e svg [data-node-id] {\n transition: transform 0.18s cubic-bezier(0.22, 1, 0.36, 1);\n }\n html[data-preset=\"classic\"]:not([data-motion=\"still\"]) .diagram-container \u003e svg [data-node-id]:hover {\n transform: translateY(-1.5px);\n }\n\n /* Semantic Sigils are small authored role stamps, not icons from a brand\n pack and not viewer controls. Prefix selectors with svg so the canonical\n export's SVG-only stylesheet collector keeps them automatically. */\n svg .semantic-sigil {\n fill: none;\n stroke: currentColor;\n stroke-width: 1.35;\n stroke-linecap: round;\n stroke-linejoin: round;\n opacity: 0.76;\n pointer-events: none;\n }\n svg .semantic-sigil \u003e * { vector-effect: non-scaling-stroke; }\n svg .semantic-sigil .sigil-fill { fill: currentColor; stroke: none; }\n svg .s-frontend { color: var(--frontend-stroke); }\n svg .s-backend { color: var(--backend-stroke); }\n svg .s-database { color: var(--database-stroke); }\n svg .s-cloud { color: var(--cloud-stroke); }\n svg .s-security { color: var(--security-stroke); }\n svg .s-messagebus { color: var(--messagebus-stroke); }\n svg .s-external { color: var(--external-stroke); }\n\n /* Brand Marks are authored identity badges. Their color is contained\n inside one neutral plate so vendor color never replaces Archify's\n semantic node and relationship vocabulary. */\n svg .brand-mark { pointer-events: none; }\n svg .brand-mark-badge { fill: #fff; stroke: none; }\n svg .brand-mark-frame {\n fill: none;\n stroke: #cbd5e1;\n stroke-width: 0.8;\n vector-effect: non-scaling-stroke;\n }\n svg .brand-mark-fallback {\n fill: none;\n stroke: #475569;\n stroke-width: 1.15;\n stroke-linecap: round;\n stroke-linejoin: round;\n }\n svg[data-preset=\"blueprint\"] .brand-mark-badge,\n svg[data-preset=\"blueprint\"] .brand-mark-frame { rx: 1px; }\n\n /* Reading Depth is a viewer-only level-of-detail layer. MAP preserves the\n authored structure and primary labels, READ restores relationship labels\n and node context, and FULL restores tags and fine annotations. Semantic\n intent can reveal the relevant detail without moving any geometry. */\n svg [data-detail] { transition: opacity 160ms ease; }\n svg [data-detail-anchor] {\n transform-box: fill-box;\n transform-origin: center;\n transition: transform 160ms ease;\n }\n .diagram-container[data-detail-level=\"map\"] svg [data-detail=\"context\"],\n .diagram-container[data-detail-level=\"map\"] svg [data-detail=\"fine\"],\n .diagram-container[data-detail-level=\"read\"] svg [data-detail=\"fine\"] {\n opacity: 0;\n pointer-events: none;\n }\n .diagram-container[data-detail-level=\"map\"] svg [data-detail-anchor] {\n transform: translateY(8px);\n }\n\n /* Focus, lens, preview, route, and story states are stronger reader intent than\n the global zoom level. Reveal only their exact semantic matches. */\n svg[data-focus-active] [data-focus-match][data-detail],\n svg[data-focus-active] [data-focus-match] [data-detail],\n svg[data-reach-active] [data-reach-match][data-detail],\n svg[data-reach-active] [data-reach-match] [data-detail],\n svg[data-lens-active] [data-lens-match][data-detail],\n svg[data-lens-active] [data-lens-match] [data-detail],\n svg[data-legend-preview-active] [data-legend-preview-match][data-detail],\n svg[data-legend-preview-active] [data-legend-preview-match] [data-detail],\n svg[data-intent-trace-active] [data-intent-trace-match][data-detail],\n svg[data-intent-trace-active] [data-intent-trace-match] [data-detail],\n svg[data-route-active] [data-route-match][data-detail],\n svg[data-route-active] [data-route-match] [data-detail],\n svg[data-relationship-preview-active] [data-relationship-preview][data-detail],\n svg[data-relationship-preview-active] [data-relationship-preview] [data-detail],\n svg [data-node-id]:hover [data-detail],\n svg [data-node-id]:focus-visible [data-detail] {\n opacity: 1;\n pointer-events: auto;\n }\n svg[data-focus-active] [data-focus-match] [data-detail-anchor],\n svg[data-reach-active] [data-reach-match] [data-detail-anchor],\n svg[data-lens-active] [data-lens-match] [data-detail-anchor],\n svg[data-legend-preview-active] [data-legend-preview-match] [data-detail-anchor],\n svg[data-intent-trace-active] [data-intent-trace-match] [data-detail-anchor],\n svg[data-route-active] [data-route-match] [data-detail-anchor],\n svg [data-node-id]:hover [data-detail-anchor],\n svg [data-node-id]:focus-visible [data-detail-anchor] { transform: none; }\n\n /* Arrows */\n .a-default { stroke: var(--arrow); fill: none; }\n .a-emphasis { stroke: var(--arrow-emphasis); fill: none; }\n .a-security { stroke: var(--security-stroke); fill: none; stroke-dasharray: 5,5; }\n .a-dashed { stroke: var(--database-stroke); fill: none; stroke-dasharray: 4,4; }\n\n /* Arrowhead markers reference these */\n .m-default { fill: var(--arrow); }\n .m-emphasis { fill: var(--arrow-emphasis); }\n .m-security { fill: var(--security-stroke); }\n .m-dashed { fill: var(--database-stroke); }\n\n /* Stable semantic exploration hooks emitted by every renderer. */\n svg [data-node-id] {\n cursor: pointer;\n transition: opacity 0.18s ease, fill-opacity 0.18s ease, stroke-opacity 0.18s ease, filter 0.18s ease;\n }\n svg [data-edge-from],\n svg [data-graph-role=\"automatic-crossover-underlay\"] { transition: opacity 0.18s ease, filter 0.18s ease; }\n svg [data-node-id]:hover,\n svg [data-node-id]:focus-visible {\n filter: drop-shadow(0 0 7px var(--frontend-stroke));\n outline: none;\n }\n svg [data-legend-kind][role=\"button\"] { cursor: pointer; }\n svg [data-legend-kind]:focus { outline: none; }\n svg [data-legend-hit] {\n fill: transparent;\n stroke: transparent;\n stroke-width: 1.4;\n pointer-events: all;\n vector-effect: non-scaling-stroke;\n transition: stroke 150ms ease, stroke-width 150ms ease, filter 150ms ease;\n }\n svg [data-legend-count-badge] { pointer-events: none; }\n svg [data-legend-count-badge] rect {\n fill: var(--mask);\n stroke: var(--panel-border);\n stroke-width: 1;\n vector-effect: non-scaling-stroke;\n }\n svg [data-legend-count-badge] text {\n fill: var(--text-muted);\n font-size: 8px;\n font-weight: 700;\n text-anchor: middle;\n }\n svg [data-legend-kind][role=\"button\"]:hover [data-legend-hit] {\n stroke: color-mix(in srgb, var(--database-stroke) 58%, transparent);\n }\n svg [data-legend-kind][role=\"button\"]:focus-visible [data-legend-hit] {\n stroke: var(--frontend-stroke);\n stroke-width: 1.8;\n filter: drop-shadow(0 0 3px var(--frontend-stroke));\n }\n svg [data-legend-kind][data-legend-selected] [data-legend-hit] {\n stroke: var(--database-stroke);\n stroke-width: 2.2;\n stroke-dasharray: 3 2;\n }\n svg [data-legend-kind][data-legend-selected] [data-legend-count-badge] rect {\n stroke: var(--database-stroke);\n stroke-width: 1.8;\n }\n svg [data-legend-kind][data-legend-zero] { opacity: 0.44; }\n svg[data-preset=\"signal-flow\"] [data-legend-kind][data-legend-selected] [data-legend-hit] {\n filter: drop-shadow(0 0 4px var(--database-stroke));\n }\n svg[data-preset=\"blueprint\"] [data-legend-hit],\n svg[data-preset=\"blueprint\"] [data-legend-count-badge] rect { rx: 0; filter: none; }\n svg[data-legend-preview-active] [data-node-id],\n svg[data-legend-preview-active] [data-edge-from] { opacity: 0.11; }\n svg[data-legend-preview-active] [data-legend-preview-match] { opacity: 1; }\n svg[data-legend-preview-active] [data-legend-preview-peer] { opacity: 0.62; }\n svg[data-legend-preview-active] [data-legend-preview-selected] {\n filter: drop-shadow(0 0 8px var(--database-stroke));\n }\n svg[data-lens-active] [data-node-id],\n svg[data-lens-active] [data-edge-from] { opacity: 0.11; }\n svg[data-lens-active] [data-lens-match] { opacity: 1; }\n svg[data-lens-active] [data-lens-peer] { opacity: 0.62; }\n svg[data-lens-active] [data-lens-selected] {\n filter: drop-shadow(0 0 10px var(--database-stroke));\n }\n .semantic-lens-overlay { pointer-events: none; }\n .semantic-lens-flow {\n fill: none;\n stroke-width: 3.05;\n stroke-linecap: round;\n stroke-dasharray: 0.075 0.925;\n stroke-dashoffset: 0;\n vector-effect: non-scaling-stroke;\n opacity: 0.9;\n animation: archify-semantic-lens-flow 1.35s linear 1 both;\n animation-delay: var(--lens-flow-delay, 0s);\n }\n .semantic-lens-flow[data-direction=\"out\"],\n .semantic-lens-flow[data-direction=\"forward\"] {\n stroke: var(--frontend-stroke);\n filter: drop-shadow(0 0 3px var(--frontend-stroke));\n }\n .semantic-lens-flow[data-direction=\"in\"],\n .semantic-lens-flow[data-direction=\"reverse\"] {\n stroke: var(--database-stroke);\n filter: drop-shadow(0 0 3px var(--database-stroke));\n }\n .semantic-lens-flow[data-direction=\"within\"] {\n stroke: var(--messagebus-stroke);\n filter: drop-shadow(0 0 3px var(--messagebus-stroke));\n }\n svg[data-preset=\"signal-flow\"] .semantic-lens-flow {\n stroke-width: 3.7;\n opacity: 1;\n }\n svg[data-preset=\"signal-flow\"] .semantic-lens-flow[data-direction=\"out\"],\n svg[data-preset=\"signal-flow\"] .semantic-lens-flow[data-direction=\"forward\"] {\n filter: drop-shadow(0 0 6px var(--frontend-stroke));\n }\n svg[data-preset=\"signal-flow\"] .semantic-lens-flow[data-direction=\"in\"],\n svg[data-preset=\"signal-flow\"] .semantic-lens-flow[data-direction=\"reverse\"] {\n filter: drop-shadow(0 0 6px var(--database-stroke));\n }\n svg[data-preset=\"signal-flow\"] .semantic-lens-flow[data-direction=\"within\"] {\n filter: drop-shadow(0 0 6px var(--messagebus-stroke));\n }\n svg[data-preset=\"blueprint\"] .semantic-lens-flow {\n stroke-width: 2.45;\n stroke-linecap: square;\n filter: none;\n opacity: 0.78;\n }\n html[data-embed=\"true\"] .semantic-lens-overlay { display: none; }\n /* Automatic crossover masks are visual companions of their one semantic\n edge. Keep the mask free of data-edge-* identity so graph traversal and\n export still observe exactly one edge, then mirror reader emphasis from\n the paired foreground path in this presentation-only wrapper. */\n svg[data-legend-preview-active] [data-graph-role=\"automatic-crossover\"] \u003e [data-graph-role=\"automatic-crossover-underlay\"],\n svg[data-lens-active] [data-graph-role=\"automatic-crossover\"] \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.11; }\n svg[data-legend-preview-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-legend-preview-match]) \u003e [data-graph-role=\"automatic-crossover-underlay\"],\n svg[data-lens-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-lens-match]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 1; }\n svg[data-legend-preview-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-legend-preview-peer]) \u003e [data-graph-role=\"automatic-crossover-underlay\"],\n svg[data-lens-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-lens-peer]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.62; }\n svg[data-focus-active] [data-node-id],\n svg[data-focus-active] [data-edge-from] { opacity: 0.13; }\n svg[data-focus-active] [data-graph-role=\"automatic-crossover\"] \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.13; }\n svg[data-focus-active] [data-lifecycle-rail] { opacity: 0; }\n svg[data-focus-active] [data-focus-match] { opacity: 1; }\n svg[data-focus-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-focus-match]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 1; }\n svg[data-focus-active] [data-focus-selected] {\n filter: drop-shadow(0 0 10px var(--frontend-stroke));\n }\n\n /* Authored Reachability is a bounded graph query over the relationships\n already present in the artifact. Upstream walks incoming edges;\n downstream walks outgoing edges. It never claims runtime causality and\n changes only viewer emphasis, not canonical geometry or export bytes. */\n svg[data-reach-active] [data-node-id],\n svg[data-reach-active] [data-edge-from] { opacity: 0.09; }\n svg[data-reach-active] [data-graph-role=\"automatic-crossover\"] \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.09; }\n svg[data-reach-active] [data-reach-match] { opacity: 1; }\n svg[data-reach-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-reach-match]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 1; }\n svg[data-reach-active=\"upstream\"] [data-reach-origin] {\n filter: drop-shadow(0 0 11px var(--database-stroke));\n }\n svg[data-reach-active=\"downstream\"] [data-reach-origin] {\n filter: drop-shadow(0 0 11px var(--backend-stroke));\n }\n svg[data-reach-active=\"upstream\"] [data-edge-from][data-reach-match] {\n filter: drop-shadow(0 0 4px color-mix(in srgb, var(--database-stroke) 72%, transparent));\n }\n svg[data-reach-active=\"downstream\"] [data-edge-from][data-reach-match] {\n filter: drop-shadow(0 0 4px color-mix(in srgb, var(--backend-stroke) 72%, transparent));\n }\n svg[data-preset=\"blueprint\"][data-reach-active] [data-reach-origin],\n svg[data-preset=\"blueprint\"][data-reach-active] [data-edge-from][data-reach-match] {\n filter: none;\n }\n\n /* Direct Relationship Explorer makes authored paths a real input surface\n without changing their visible stroke or canonical SVG. A transparent\n runtime rail supplies forgiving pointer geometry; the exact authored\n path and endpoints continue to carry every visible state. */\n .relationship-hit-overlay { pointer-events: none; }\n .relationship-hit-target { outline: none; }\n .relationship-hit-rail {\n fill: none;\n stroke: transparent;\n stroke-width: 24;\n stroke-linecap: round;\n stroke-linejoin: round;\n vector-effect: non-scaling-stroke;\n pointer-events: stroke;\n cursor: pointer;\n }\n .relationship-focus-rail {\n fill: none;\n stroke: color-mix(in srgb, var(--frontend-stroke) 34%, transparent);\n stroke-width: 6;\n stroke-dasharray: 2 4;\n stroke-linecap: round;\n stroke-linejoin: round;\n vector-effect: non-scaling-stroke;\n pointer-events: none;\n opacity: 0;\n }\n .relationship-hit-target:focus-visible .relationship-focus-rail {\n opacity: 1;\n }\n svg[data-preset=\"blueprint\"] .relationship-hit-target:focus-visible .relationship-focus-rail {\n stroke-linecap: square;\n filter: none;\n }\n svg[data-relationship-direct-active] [data-node-id],\n svg[data-relationship-direct-active] [data-edge-from] { opacity: 0.16; }\n svg[data-relationship-direct-active] [data-graph-role=\"automatic-crossover\"] \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.16; }\n svg[data-relationship-direct-active] [data-relationship-preview],\n svg[data-relationship-direct-active] [data-relationship-preview-node] { opacity: 1; }\n svg[data-relationship-direct-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-relationship-preview]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 1; }\n svg[data-focus-active]:not([data-relationship-pin-active]) .relationship-hit-rail,\n svg[data-route-picking] .relationship-hit-rail,\n svg[data-route-active] .relationship-hit-rail,\n svg[data-lens-active] .relationship-hit-rail { pointer-events: none; }\n html[data-embed=\"true\"] .relationship-hit-overlay { display: none; }\n @media (hover: none), (pointer: coarse) {\n .relationship-hit-rail { stroke-width: 24; }\n }\n\n /* Relationship Preview is temporary exploration state layered on top of\n neighborhood focus. It changes emphasis only; exported geometry and the\n relationship's original solid/dashed visual language stay untouched. */\n svg[data-relationship-preview-active] [data-focus-match] { opacity: 0.18; }\n svg[data-relationship-preview-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-focus-match]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.18; }\n svg[data-relationship-preview-active] [data-lifecycle-rail] { opacity: 0; }\n svg[data-relationship-preview-active] [data-relationship-preview],\n svg[data-relationship-preview-active] [data-relationship-preview-node] { opacity: 1; }\n svg[data-relationship-preview-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-relationship-preview]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 1; }\n svg[data-relationship-preview-active] [data-relationship-preview] {\n filter: drop-shadow(0 0 5px var(--arrow-emphasis));\n }\n svg[data-relationship-preview-active] [data-relationship-preview] path,\n svg[data-relationship-preview-active] path[data-relationship-preview],\n svg[data-relationship-preview-active] [data-relationship-preview] line,\n svg[data-relationship-preview-active] line[data-relationship-preview],\n svg[data-relationship-preview-active] [data-relationship-preview] polyline,\n svg[data-relationship-preview-active] polyline[data-relationship-preview] {\n stroke-width: 2.75;\n }\n svg[data-relationship-preview-active] [data-relationship-preview-source] {\n filter: drop-shadow(0 0 7px var(--frontend-stroke));\n }\n svg[data-relationship-preview-active] [data-relationship-preview-target] {\n filter: drop-shadow(0 0 7px var(--database-stroke));\n }\n .relationship-pulse-overlay { pointer-events: none; }\n .relationship-flow-pulse {\n fill: none;\n stroke: var(--arrow-emphasis);\n stroke-width: 3.35;\n stroke-linecap: round;\n stroke-dasharray: 0.085 0.915;\n stroke-dashoffset: 0;\n vector-effect: non-scaling-stroke;\n opacity: 0;\n filter: drop-shadow(0 0 4px var(--arrow-emphasis));\n animation: archify-relationship-pulse 1.2s linear 1 both;\n }\n svg[data-preset=\"signal-flow\"] .relationship-flow-pulse {\n stroke: var(--frontend-stroke);\n stroke-width: 3.85;\n filter: drop-shadow(0 0 7px var(--frontend-stroke));\n }\n svg[data-preset=\"blueprint\"] .relationship-flow-pulse {\n stroke-width: 2.5;\n stroke-linecap: square;\n filter: none;\n }\n svg[data-preset=\"editorial\"] .relationship-flow-pulse {\n stroke: var(--arrow-emphasis);\n stroke-width: 2.75;\n filter: none;\n }\n .semantic-flow-token {\n color: var(--frontend-stroke);\n opacity: 0;\n pointer-events: none;\n }\n .relationship-flow-token {\n animation: archify-relationship-token-life 1.2s linear 1 both;\n }\n\n .semantic-flow-token-halo {\n fill: var(--mask);\n stroke: currentColor;\n stroke-width: 1.1;\n vector-effect: non-scaling-stroke;\n opacity: 0.96;\n }\n .relationship-flow-token-shape {\n fill: var(--mask);\n stroke: currentColor;\n stroke-width: 1.35;\n stroke-linecap: round;\n stroke-linejoin: round;\n vector-effect: non-scaling-stroke;\n }\n .relationship-flow-token-ink {\n fill: none;\n stroke: currentColor;\n stroke-width: 1.05;\n stroke-linecap: round;\n vector-effect: non-scaling-stroke;\n }\n .relationship-flow-token-dot { fill: currentColor; stroke: none; }\n .semantic-flow-token[data-token-kind=\"data\"] { color: var(--database-stroke); }\n .semantic-flow-token[data-token-kind=\"event\"] { color: var(--messagebus-stroke); }\n .semantic-flow-token[data-token-kind=\"security\"] { color: var(--security-stroke); }\n .semantic-flow-token[data-token-kind=\"state\"] { color: var(--cloud-stroke); }\n svg[data-preset=\"signal-flow\"] .semantic-flow-token {\n filter: drop-shadow(0 0 5px currentColor);\n }\n svg[data-preset=\"blueprint\"] .semantic-flow-token { filter: none; }\n svg[data-preset=\"editorial\"] .semantic-flow-token { filter: none; }\n html[data-embed=\"true\"] .relationship-pulse-overlay { display: none; }\n\n /* Intent Trace is a temporary, pre-click exploration layer. Related\n topology stays readable while a short viewer-only signal runs over\n cloned edge geometry; the authored edge remains untouched underneath. */\n /* Keep the node's opaque backing mask intact while its visible ink dims.\n Fading the whole group also fades that mask and briefly exposes arrows\n routed underneath the node when the pointer leaves. */\n svg[data-intent-trace-active] [data-node-id] { fill-opacity: 0.2; stroke-opacity: 0.2; }\n svg [data-node-id] \u003e .c-mask { fill-opacity: 1; }\n svg[data-intent-trace-active] [data-node-id][data-intent-trace-match] { fill-opacity: 1; stroke-opacity: 1; }\n svg[data-intent-trace-active] [data-edge-from] { opacity: 0.2; }\n svg[data-intent-trace-active] [data-graph-role=\"automatic-crossover\"] \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.2; }\n svg[data-intent-trace-active] [data-lifecycle-rail] { opacity: 0; }\n svg[data-intent-trace-active] [data-intent-trace-match] { opacity: 1; }\n svg[data-intent-trace-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-intent-trace-match]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 1; }\n svg[data-intent-trace-active] [data-intent-trace-selected] {\n filter: drop-shadow(0 0 10px var(--frontend-stroke));\n }\n .intent-trace-overlay { pointer-events: none; }\n .intent-trace-flow {\n fill: none;\n stroke-width: 3.1;\n stroke-linecap: round;\n stroke-dasharray: 0.1 0.9;\n stroke-dashoffset: 0;\n vector-effect: non-scaling-stroke;\n opacity: 0.94;\n animation: archify-intent-trace-flow 1.15s linear 1 both;\n }\n /* Direction names describe each edge relative to the focused node only.\n The cloned geometry already runs from the authored source to target, so\n incoming and outgoing signals must share the same playback direction. */\n .intent-trace-flow[data-direction=\"out\"] {\n stroke: var(--frontend-stroke);\n filter: drop-shadow(0 0 4px var(--frontend-stroke));\n }\n .intent-trace-flow[data-direction=\"in\"] {\n stroke: var(--database-stroke);\n filter: drop-shadow(0 0 4px var(--database-stroke));\n animation-direction: normal;\n }\n .intent-trace-flow[data-direction=\"loop\"] {\n stroke: var(--security-stroke);\n filter: drop-shadow(0 0 4px var(--security-stroke));\n }\n svg[data-preset=\"blueprint\"] [data-intent-trace-selected],\n svg[data-preset=\"blueprint\"] .intent-trace-flow {\n filter: none;\n stroke-linecap: square;\n }\n svg[data-preset=\"editorial\"] [data-intent-trace-selected],\n svg[data-preset=\"editorial\"] .intent-trace-flow { filter: none; }\n .intent-trace-status {\n position: absolute;\n width: 1px;\n height: 1px;\n padding: 0;\n margin: -1px;\n overflow: hidden;\n clip: rect(0, 0, 0, 0);\n clip-path: inset(50%);\n white-space: nowrap;\n border: 0;\n }\n\n /* Route Probe separates a durable two-point query from selection and\n one-hop hover. Only the chosen shortest directed path stays prominent;\n the traveling signal is cloned viewer geometry and never authored SVG. */\n svg[data-route-picking=\"target\"] [data-node-id] { opacity: 0.24; }\n svg[data-route-picking=\"target\"] [data-route-candidate],\n svg[data-route-picking=\"target\"] [data-route-start] { opacity: 1; }\n svg[data-route-picking] [data-node-id] { cursor: crosshair; }\n svg[data-route-picking] [data-route-start] {\n filter: drop-shadow(0 0 10px var(--frontend-stroke));\n }\n svg[data-route-active] [data-node-id],\n svg[data-route-active] [data-edge-from] { opacity: 0.11; }\n svg[data-route-active] [data-graph-role=\"automatic-crossover\"] \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.11; }\n svg[data-route-active] [data-route-match] { opacity: 1; }\n svg[data-route-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-route-match]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 1; }\n svg[data-route-active] [data-route-start] {\n filter: drop-shadow(0 0 11px var(--frontend-stroke));\n }\n svg[data-route-active] [data-route-end] {\n filter: drop-shadow(0 0 11px var(--security-stroke));\n }\n svg[data-route-active] [data-route-step]:not([data-route-start]):not([data-route-end]) {\n filter: drop-shadow(0 0 7px var(--backend-stroke));\n }\n svg[data-route-journey] [data-route-match][data-route-journey-state=\"past\"] { opacity: 0.62; }\n svg[data-route-journey] [data-route-match][data-route-journey-state=\"future\"] { opacity: 0.34; }\n svg[data-route-journey] [data-route-match][data-route-journey-state=\"current\"] { opacity: 1; }\n svg[data-route-journey] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-route-match][data-route-journey-state=\"past\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.62; }\n svg[data-route-journey] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-route-match][data-route-journey-state=\"future\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.34; }\n svg[data-route-journey] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-route-match][data-route-journey-state=\"current\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 1; }\n svg[data-route-journey] [data-node-id][data-route-journey-current] {\n filter: drop-shadow(0 0 10px var(--backend-stroke));\n }\n svg[data-route-journey] [data-edge-from][data-route-journey-current] {\n opacity: 1;\n filter: drop-shadow(0 0 6px var(--backend-stroke));\n }\n .route-probe-overlay { pointer-events: none; }\n .route-journey-overlay { pointer-events: none; }\n .route-probe-flow {\n fill: none;\n stroke: var(--backend-stroke);\n stroke-width: 3.25;\n stroke-linecap: round;\n stroke-dasharray: 0.085 0.915;\n stroke-dashoffset: 0;\n vector-effect: non-scaling-stroke;\n opacity: 0.96;\n filter: drop-shadow(0 0 5px var(--backend-stroke));\n animation: archify-route-probe-flow 1.1s cubic-bezier(0.22, 1, 0.36, 1) 1 both;\n animation-delay: calc(var(--route-step, 0) * 0.16s);\n }\n .route-journey-flow {\n fill: none;\n stroke: var(--backend-stroke);\n stroke-width: 3.5;\n stroke-linecap: round;\n stroke-dasharray: 0.1 0.9;\n stroke-dashoffset: 0;\n vector-effect: non-scaling-stroke;\n opacity: 0;\n filter: drop-shadow(0 0 6px var(--backend-stroke));\n animation: archify-route-journey-flow 780ms cubic-bezier(0.22, 1, 0.36, 1) 1 both;\n }\n svg[data-preset=\"blueprint\"] [data-route-start],\n svg[data-preset=\"blueprint\"] [data-route-end],\n svg[data-preset=\"blueprint\"] [data-route-step],\n svg[data-preset=\"blueprint\"] .route-probe-flow {\n filter: none;\n stroke-linecap: square;\n }\n svg[data-preset=\"blueprint\"] .route-journey-flow {\n filter: none;\n stroke-linecap: square;\n }\n svg[data-preset=\"editorial\"] [data-route-start],\n svg[data-preset=\"editorial\"] [data-route-end],\n svg[data-preset=\"editorial\"] [data-route-step],\n svg[data-preset=\"editorial\"] .route-probe-flow,\n svg[data-preset=\"editorial\"] .route-journey-flow { filter: none; }\n\n svg[data-preset=\"editorial\"] .c-grid {\n stroke-dasharray: 1 4;\n opacity: 0.48;\n }\n svg[data-preset=\"editorial\"] .c-region {\n fill: color-mix(in srgb, var(--cloud-fill) 48%, transparent);\n stroke-dasharray: 9 4;\n }\n svg[data-preset=\"editorial\"] [data-node-id]:hover,\n svg[data-preset=\"editorial\"] [data-node-id]:focus-visible,\n svg[data-preset=\"editorial\"][data-focus-active] [data-focus-selected] {\n filter: drop-shadow(0 2px 2px color-mix(in srgb, var(--text) 18%, transparent));\n }\n\n svg[data-preset=\"blueprint\"] .c-grid {\n stroke-dasharray: 1 3;\n opacity: 0.78;\n }\n svg[data-preset=\"blueprint\"] .c-region {\n fill: color-mix(in srgb, var(--cloud-fill) 58%, transparent);\n stroke-dasharray: 12 4 2 4;\n }\n svg[data-preset=\"blueprint\"] .c-security-group,\n svg[data-preset=\"blueprint\"] .c-lane { stroke-dasharray: 7 3; }\n svg[data-preset=\"blueprint\"] [data-node-id]:hover,\n svg[data-preset=\"blueprint\"] [data-node-id]:focus-visible {\n filter: drop-shadow(0 0 3px var(--frontend-stroke));\n }\n svg[data-preset=\"blueprint\"][data-focus-active] [data-focus-selected] {\n filter: drop-shadow(0 0 3px var(--frontend-stroke));\n }\n svg[data-preset=\"blueprint\"][data-focus-active][data-reach-active] [data-focus-selected][data-reach-origin] {\n filter: none;\n }\n svg[data-preset=\"blueprint\"][data-relationship-preview-active] [data-relationship-preview],\n svg[data-preset=\"blueprint\"][data-relationship-preview-active] [data-relationship-preview-source],\n svg[data-preset=\"blueprint\"][data-relationship-preview-active] [data-relationship-preview-target] {\n filter: drop-shadow(0 0 3px var(--frontend-stroke));\n }\n\n /* Dashed boundary variants */\n .c-security-group { fill: transparent; stroke: var(--security-stroke); stroke-dasharray: 4,4; }\n .c-region { fill: rgba(251, 191, 36, 0.05); stroke: var(--cloud-stroke); stroke-dasharray: 8,4; }\n .c-lane { fill: var(--lane-fill); stroke: var(--lane-stroke); stroke-dasharray: 6,6; }\n\n /* Optional trace animation, enabled only by meta.animation = \"trace\".\n The ordinary viewer performs one ambient pass and then restores the\n authored solid/security/async line language. WebM samples the same\n authored geometry into an explicit canvas timeline. */\n html[data-ambient-motion=\"running\"] svg[data-animation=\"trace\"] [data-animate=\"edge\"] {\n animation: archify-edge-flow 2.4s linear 1;\n animation-delay: calc(var(--step, 0) * 160ms);\n }\n html[data-ambient-motion=\"running\"] svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] {\n animation: archify-edge-flow 2.4s linear 1;\n animation-delay: calc(var(--step, 0) * 160ms);\n }\n html[data-ambient-motion=\"running\"] svg[data-animation=\"trace\"] [data-animate=\"node\"] {\n transform-box: fill-box;\n transform-origin: center;\n animation: archify-node-pulse 3.6s ease-in-out 1;\n animation-delay: calc(var(--step, 0) * 160ms);\n }\n svg[data-preset=\"signal-flow\"][data-animation=\"trace\"] [data-animate=\"edge\"] {\n stroke-linecap: round;\n filter: drop-shadow(0 0 3px var(--arrow-emphasis));\n animation-duration: 1.75s;\n }\n svg[data-preset=\"signal-flow\"][data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { animation-duration: 1.75s; }\n svg[data-preset=\"signal-flow\"][data-animation=\"trace\"] [data-animate=\"node\"] {\n animation-duration: 3.1s;\n }\n svg[data-preset=\"blueprint\"][data-animation=\"trace\"] [data-animate=\"edge\"] {\n stroke-linecap: square;\n filter: none;\n animation-duration: 2.15s;\n }\n svg[data-preset=\"blueprint\"][data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { animation-duration: 2.15s; }\n svg[data-preset=\"blueprint\"][data-animation=\"trace\"] [data-animate=\"node\"] {\n animation-name: archify-blueprint-node-pulse;\n animation-duration: 3.8s;\n }\n svg[data-preset=\"editorial\"][data-animation=\"trace\"] [data-animate=\"edge\"] {\n filter: none;\n animation-duration: 2.2s;\n }\n svg[data-preset=\"editorial\"][data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { animation-duration: 2.2s; }\n svg[data-preset=\"editorial\"][data-animation=\"trace\"] [data-animate=\"node\"] {\n animation-name: archify-editorial-node-pulse;\n animation-duration: 3.5s;\n }\n /* Embedded proofs stay static so proof grids are calm instead of leaving\n ambient trace loops on. */\n html[data-embed=\"true\"] svg[data-animation=\"trace\"] [data-animate],\n html[data-share-playback=\"true\"] svg[data-animation=\"trace\"] [data-animate] {\n animation: none !important;\n stroke-dashoffset: 0;\n }\n html[data-embed=\"true\"] svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"],\n html[data-share-playback=\"true\"] svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] {\n animation: none !important;\n stroke-dashoffset: 0;\n }\n @keyframes archify-edge-flow {\n 0% { stroke-dasharray: 10 8; stroke-dashoffset: 54; opacity: 0.42; }\n 88% { stroke-dasharray: 10 8; stroke-dashoffset: 0; opacity: 1; }\n 99.9% { stroke-dasharray: 10 8; stroke-dashoffset: 0; opacity: 1; }\n 100% { stroke-dashoffset: 0; opacity: 1; }\n }\n @keyframes archify-node-pulse {\n 0%, 72%, 100% { filter: none; stroke-width: 1.5; }\n 18%, 36% {\n filter: drop-shadow(0 0 8px var(--arrow-emphasis));\n stroke-width: 2.4;\n }\n }\n @keyframes archify-blueprint-node-pulse {\n 0%, 72%, 100% { opacity: 1; filter: none; }\n 18%, 36% { opacity: 0.72; filter: drop-shadow(0 0 2px var(--frontend-stroke)); }\n }\n @keyframes archify-editorial-node-pulse {\n 0%, 72%, 100% { opacity: 1; filter: none; }\n 18%, 36% { opacity: 0.78; filter: drop-shadow(0 2px 2px color-mix(in srgb, var(--text) 18%, transparent)); }\n }\n @keyframes archify-signal-scan {\n 0%, 18% { opacity: 1; transform: translateX(-70%); }\n 70% { opacity: 1; transform: translateX(70%); }\n 100% { opacity: 0; transform: translateX(70%); }\n }\n @keyframes archify-radar-live {\n 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--backend-stroke) 52%, transparent); }\n 55%, 100% { box-shadow: 0 0 0 0.32rem transparent; }\n }\n\n @keyframes archify-intent-trace-flow {\n 0% { opacity: 0.28; stroke-dashoffset: 0; }\n 12%, 78% { opacity: 0.94; }\n 100% { opacity: 0; stroke-dashoffset: -1; }\n }\n @keyframes archify-route-probe-flow {\n 0% { stroke-dashoffset: 0; opacity: 0.96; }\n 78% { stroke-dashoffset: -1; opacity: 0.96; }\n 100% { stroke-dasharray: none; stroke-dashoffset: 0; opacity: 0.58; }\n }\n @keyframes archify-route-journey-flow {\n 0% { opacity: 0.16; stroke-dashoffset: 0; }\n 14%, 76% { opacity: 1; }\n 100% { opacity: 0; stroke-dashoffset: -1; }\n }\n @keyframes archify-semantic-lens-flow {\n 0% { opacity: 0.2; stroke-dashoffset: 0; }\n 12%, 78% { opacity: 0.9; }\n 100% { opacity: 0; stroke-dashoffset: -1; }\n }\n @keyframes archify-relationship-pulse {\n 0% { opacity: 0.18; stroke-dashoffset: 0; }\n 10%, 76% { opacity: 0.98; }\n 100% { opacity: 0; stroke-dashoffset: -1; }\n }\n @keyframes archify-relationship-token-life {\n 0%, 7% { opacity: 0; }\n 13%, 82% { opacity: 1; }\n 100% { opacity: 0; }\n }\n\n @keyframes archify-share-cue-enter {\n from { opacity: 0; transform: translate(-50%, -0.45rem); }\n to { opacity: 1; transform: translate(-50%, 0); }\n }\n @keyframes archify-share-cue-pulse {\n 0%, 100% { opacity: 1; transform: scale(1); }\n 50% { opacity: 0.48; transform: scale(0.78); }\n }\n @media (prefers-reduced-motion: reduce) {\n html[data-preset=\"signal-flow\"] .diagram-container::before {\n animation: none !important;\n }\n .pulse-dot { animation: none !important; }\n svg[data-animation=\"trace\"] [data-animate] {\n animation: none !important;\n stroke-dashoffset: 0;\n }\n svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] {\n animation: none !important;\n stroke-dashoffset: 0;\n }\n .intent-trace-flow,\n .route-probe-flow,\n .semantic-lens,\n .diagram-guide,\n .overview-map-live { animation: none !important; }\n \n .intent-trace-flow {\n animation: none !important;\n stroke-dasharray: none;\n stroke-dashoffset: 0;\n opacity: 0.72;\n }\n .route-probe-flow {\n animation: none !important;\n stroke-dasharray: none;\n stroke-dashoffset: 0;\n opacity: 0.78;\n }\n .route-journey-overlay { display: none !important; }\n .semantic-lens-flow {\n animation: none !important;\n stroke-dasharray: none;\n stroke-width: 2.2;\n opacity: 0.34;\n filter: none;\n }\n .relationship-pulse-overlay { display: none !important; }\n svg [data-node-id], svg [data-edge-from], svg [data-detail], svg [data-detail-anchor], svg [data-legend-hit], svg { transition: none !important; }\n }\n ";
+ const exportCss = "\n /* ==========================================================\n THEME VARIABLES — switch by toggling [data-theme] on \u003chtml\u003e\n ========================================================== */\n :root,\n [data-theme=\"dark\"] {\n --bg: #020617;\n --grid: #1e293b;\n --canvas-dot: rgba(148, 163, 184, 0.16);\n --text: #ffffff;\n --text-muted: #94a3b8;\n --text-dim: #475569;\n /* UI chrome and menu hints need more contrast than SVG .t-dim accents */\n --text-faint: #7d8da1;\n\n --panel: rgba(15, 23, 42, 0.5);\n --panel-border: #1e293b;\n --lane-fill: rgba(15, 23, 42, 0.22);\n --lane-stroke: #334155;\n\n --arrow: #64748b;\n --arrow-emphasis: #34d399;\n\n /* Opaque mask color used behind semi-transparent component fills\n so the arrows drawn underneath are properly hidden. */\n --mask: #0f172a;\n\n --frontend-fill: rgba(8, 51, 68, 0.4);\n --frontend-stroke: #22d3ee;\n --backend-fill: rgba(6, 78, 59, 0.4);\n --backend-stroke: #34d399;\n --database-fill: rgba(76, 29, 149, 0.4);\n --database-stroke: #a78bfa;\n --cloud-fill: rgba(120, 53, 15, 0.3);\n --cloud-stroke: #fbbf24;\n --security-fill: rgba(136, 19, 55, 0.4);\n --security-stroke: #fb7185;\n --messagebus-fill: rgba(251, 146, 60, 0.3);\n --messagebus-stroke:#fb923c;\n --external-fill: rgba(30, 41, 59, 0.5);\n --external-stroke: #94a3b8;\n\n --toolbar-bg: rgba(15, 23, 42, 0.8);\n --toolbar-border: #334155;\n --toolbar-text: #e2e8f0;\n --toolbar-hover: rgba(15, 23, 42, 0.95);\n --toolbar-menu-bg: #0f172a;\n }\n\n [data-theme=\"light\"] {\n --bg: #f4f5f7;\n --grid: #e9edf2;\n --canvas-dot: #d9dee5;\n --text: #111827;\n --text-muted: #5b6474;\n --text-dim: #9aa3b2;\n --text-faint: #6b7280;\n\n --panel: #ffffff;\n --panel-border: #e5e7eb;\n --lane-fill: rgba(248, 250, 252, 0.65);\n --lane-stroke: #cbd5e1;\n\n --arrow: #94a3b8;\n --arrow-emphasis: #059669;\n\n --mask: #ffffff;\n\n --frontend-fill: rgba(34, 211, 238, 0.15);\n --frontend-stroke: #0891b2;\n --backend-fill: rgba(52, 211, 153, 0.18);\n --backend-stroke: #059669;\n --database-fill: rgba(167, 139, 250, 0.2);\n --database-stroke: #7c3aed;\n --cloud-fill: rgba(251, 191, 36, 0.18);\n --cloud-stroke: #d97706;\n --security-fill: rgba(251, 113, 133, 0.15);\n --security-stroke: #e11d48;\n --messagebus-fill: rgba(251, 146, 60, 0.15);\n --messagebus-stroke: #ea580c;\n --external-fill: rgba(148, 163, 184, 0.18);\n --external-stroke: #64748b;\n\n --toolbar-bg: rgba(255, 255, 255, 0.92);\n --toolbar-border: #cbd5e1;\n --toolbar-text: #334155;\n --toolbar-hover: #ffffff;\n --toolbar-menu-bg: #ffffff;\n }\n\n /* ==========================================================\n SIGNAL FLOW — an opt-in, motion-forward visual preset.\n The variables also target a standalone exported SVG, whose\n root carries data-preset and data-theme directly.\n ========================================================== */\n [data-preset=\"signal-flow\"][data-theme=\"dark\"] {\n --bg: #030711;\n --grid: #15233a;\n --panel: rgba(6, 14, 28, 0.78);\n --panel-border: #1d3350;\n --lane-fill: rgba(9, 22, 40, 0.5);\n --lane-stroke: #2c4564;\n --text: #f5fbff;\n --text-muted: #9eb0c7;\n --text-dim: #52667f;\n --text-faint: #7890ad;\n --mask: #07101e;\n --frontend-fill: rgba(6, 182, 212, 0.14);\n --frontend-stroke: #67e8f9;\n --backend-fill: rgba(16, 185, 129, 0.14);\n --backend-stroke: #5eead4;\n --database-fill: rgba(139, 92, 246, 0.16);\n --database-stroke: #c4b5fd;\n --cloud-fill: rgba(245, 158, 11, 0.13);\n --cloud-stroke: #fcd34d;\n --security-fill: rgba(244, 63, 94, 0.13);\n --security-stroke: #fda4af;\n --messagebus-fill: rgba(249, 115, 22, 0.13);\n --messagebus-stroke: #fdba74;\n --external-fill: rgba(71, 85, 105, 0.24);\n --external-stroke: #a5b4c7;\n --arrow: #7890ad;\n --arrow-emphasis: #2dd4bf;\n --toolbar-bg: rgba(7, 16, 30, 0.86);\n --toolbar-border: #29415f;\n --toolbar-menu-bg: #07101e;\n }\n\n [data-preset=\"signal-flow\"][data-theme=\"light\"] {\n --bg: #f4f9fc;\n --grid: #d4e5ee;\n --panel: rgba(255, 255, 255, 0.82);\n --panel-border: #bfd5e2;\n --lane-fill: rgba(232, 243, 248, 0.62);\n --lane-stroke: #a9c5d5;\n --text: #102638;\n --text-muted: #587287;\n --text-dim: #8aa2b4;\n --text-faint: #668397;\n --mask: #ffffff;\n --frontend-fill: rgba(6, 182, 212, 0.09);\n --frontend-stroke: #0789a1;\n --backend-fill: rgba(5, 150, 105, 0.09);\n --backend-stroke: #087f69;\n --database-fill: rgba(124, 58, 237, 0.09);\n --database-stroke: #7254c7;\n --cloud-fill: rgba(217, 119, 6, 0.08);\n --cloud-stroke: #b9670b;\n --security-fill: rgba(225, 29, 72, 0.08);\n --security-stroke: #c53a59;\n --messagebus-fill: rgba(234, 88, 12, 0.08);\n --messagebus-stroke: #c65f27;\n --external-fill: rgba(100, 116, 139, 0.1);\n --external-stroke: #607a8c;\n --arrow: #7b97aa;\n --arrow-emphasis: #0d9488;\n }\n\n /* ==========================================================\n BLUEPRINT — a review-first drafting preset for deployment,\n infrastructure, and technical design documentation. It keeps\n the same semantic palette and geometry while trading glow for\n precise grid contrast, squared materials, and drafting marks.\n ========================================================== */\n [data-preset=\"blueprint\"][data-theme=\"dark\"] {\n --bg: #06131f;\n --grid: #17425a;\n --panel: rgba(7, 27, 43, 0.9);\n --panel-border: #27627f;\n --lane-fill: rgba(10, 43, 66, 0.36);\n --lane-stroke: #34799a;\n --text: #e3f6ff;\n --text-muted: #91b8ca;\n --text-dim: #557e92;\n --text-faint: #739caf;\n --mask: #0a2031;\n --frontend-fill: rgba(26, 157, 193, 0.14);\n --frontend-stroke: #66d9ef;\n --backend-fill: rgba(31, 155, 124, 0.13);\n --backend-stroke: #69dfbd;\n --database-fill: rgba(120, 105, 196, 0.14);\n --database-stroke: #b4a8ff;\n --cloud-fill: rgba(197, 145, 43, 0.13);\n --cloud-stroke: #ffd166;\n --security-fill: rgba(199, 76, 104, 0.13);\n --security-stroke: #ff8da1;\n --messagebus-fill: rgba(207, 112, 49, 0.13);\n --messagebus-stroke: #ffad66;\n --external-fill: rgba(84, 119, 139, 0.18);\n --external-stroke: #a7cad9;\n --arrow: #78a3b7;\n --arrow-emphasis: #64dfc1;\n --toolbar-bg: rgba(7, 28, 45, 0.92);\n --toolbar-border: #34799a;\n --toolbar-text: #d8f3ff;\n --toolbar-hover: rgba(18, 58, 83, 0.95);\n --toolbar-menu-bg: #0a2031;\n }\n\n [data-preset=\"blueprint\"][data-theme=\"light\"] {\n --bg: #edf7fa;\n --grid: #b5d5e1;\n --panel: rgba(249, 253, 255, 0.94);\n --panel-border: #78aabd;\n --lane-fill: rgba(210, 232, 240, 0.42);\n --lane-stroke: #83b2c4;\n --text: #123344;\n --text-muted: #4e7486;\n --text-dim: #86a6b4;\n --text-faint: #668c9d;\n --mask: #f9fdff;\n --frontend-fill: rgba(8, 145, 178, 0.08);\n --frontend-stroke: #087f9c;\n --backend-fill: rgba(5, 128, 101, 0.08);\n --backend-stroke: #08755f;\n --database-fill: rgba(100, 75, 180, 0.08);\n --database-stroke: #6757a8;\n --cloud-fill: rgba(181, 120, 15, 0.08);\n --cloud-stroke: #a86609;\n --security-fill: rgba(190, 48, 80, 0.07);\n --security-stroke: #b32f50;\n --messagebus-fill: rgba(196, 81, 22, 0.07);\n --messagebus-stroke: #b65120;\n --external-fill: rgba(79, 112, 128, 0.08);\n --external-stroke: #506f7e;\n --arrow: #6d93a5;\n --arrow-emphasis: #087f69;\n --toolbar-bg: rgba(247, 252, 254, 0.94);\n --toolbar-border: #8ab5c5;\n --toolbar-text: #294f61;\n --toolbar-hover: #ffffff;\n --toolbar-menu-bg: #f9fdff;\n }\n\n /* ==========================================================\n EDITORIAL — a warm, publication-minded preset for design\n reviews, launch notes, and documentation. The diagram keeps\n the same semantic palette and exact geometry, but trades\n software chrome for paper, ink, ruled structure, and one\n restrained vermilion accent.\n ========================================================== */\n [data-preset=\"editorial\"][data-theme=\"dark\"] {\n --bg: #181611;\n --grid: #39342a;\n --panel: rgba(35, 31, 24, 0.96);\n --panel-border: #625a4a;\n --lane-fill: rgba(52, 46, 35, 0.46);\n --lane-stroke: #726957;\n --text: #f4eddf;\n --text-muted: #b9ae9b;\n --text-dim: #776e60;\n --text-faint: #9d917e;\n --mask: #231f18;\n --frontend-fill: rgba(43, 133, 142, 0.16);\n --frontend-stroke: #7fc6c7;\n --backend-fill: rgba(63, 132, 92, 0.16);\n --backend-stroke: #8fc29e;\n --database-fill: rgba(117, 91, 141, 0.17);\n --database-stroke: #c0a4d0;\n --cloud-fill: rgba(170, 119, 49, 0.16);\n --cloud-stroke: #d8ad68;\n --security-fill: rgba(157, 69, 65, 0.17);\n --security-stroke: #df9085;\n --messagebus-fill: rgba(174, 79, 42, 0.16);\n --messagebus-stroke: #df946f;\n --external-fill: rgba(126, 115, 96, 0.18);\n --external-stroke: #b8ad99;\n --arrow: #948978;\n --arrow-emphasis: #dd6b3d;\n --toolbar-bg: rgba(35, 31, 24, 0.92);\n --toolbar-border: #625a4a;\n --toolbar-text: #eee5d5;\n --toolbar-hover: #302a20;\n --toolbar-menu-bg: #231f18;\n }\n\n [data-preset=\"editorial\"][data-theme=\"light\"] {\n --bg: #f2eee5;\n --grid: #d8d0c2;\n --panel: rgba(251, 248, 241, 0.97);\n --panel-border: #c4b9a6;\n --lane-fill: rgba(229, 221, 207, 0.42);\n --lane-stroke: #b8aa94;\n --text: #242018;\n --text-muted: #6f6658;\n --text-dim: #a09788;\n --text-faint: #817767;\n --mask: #fbf8f1;\n --frontend-fill: rgba(31, 117, 126, 0.09);\n --frontend-stroke: #287e84;\n --backend-fill: rgba(42, 119, 75, 0.09);\n --backend-stroke: #397b53;\n --database-fill: rgba(105, 75, 130, 0.09);\n --database-stroke: #765d86;\n --cloud-fill: rgba(157, 103, 31, 0.1);\n --cloud-stroke: #9a671f;\n --security-fill: rgba(153, 58, 52, 0.09);\n --security-stroke: #9e463f;\n --messagebus-fill: rgba(182, 70, 27, 0.09);\n --messagebus-stroke: #ad4b25;\n --external-fill: rgba(101, 91, 75, 0.09);\n --external-stroke: #746b5e;\n --arrow: #8a806f;\n --arrow-emphasis: #bb4c23;\n --toolbar-bg: rgba(251, 248, 241, 0.94);\n --toolbar-border: #c4b9a6;\n --toolbar-text: #40392f;\n --toolbar-hover: #fffdf8;\n --toolbar-menu-bg: #fbf8f1;\n }\n\n * { margin: 0; padding: 0; box-sizing: border-box; }\n\n body {\n --archify-page-top: 2rem;\n font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', 'Noto Sans CJK SC', 'Noto Sans', Roboto, 'Helvetica Neue', Arial, sans-serif;\n -webkit-font-smoothing: antialiased;\n background: var(--bg);\n min-height: 100vh;\n padding: var(--archify-page-top) 2rem 2rem;\n color: var(--text);\n /* Theme surfaces change together; animating the page background leaves it\n visibly out of sync with the SVG and panel for the first 200ms. */\n }\n\n html[data-preset=\"signal-flow\"] body {\n background-image:\n radial-gradient(circle at 18% -8%, rgba(34, 211, 238, 0.14), transparent 34rem),\n radial-gradient(circle at 92% 18%, rgba(139, 92, 246, 0.12), transparent 30rem);\n background-attachment: fixed;\n }\n html[data-preset=\"signal-flow\"][data-theme=\"light\"] body {\n background-image:\n radial-gradient(circle at 18% -8%, rgba(6, 182, 212, 0.12), transparent 34rem),\n radial-gradient(circle at 92% 18%, rgba(139, 92, 246, 0.08), transparent 30rem);\n }\n html[data-preset=\"blueprint\"] body {\n background-image:\n linear-gradient(var(--grid) 1px, transparent 1px),\n linear-gradient(90deg, var(--grid) 1px, transparent 1px);\n background-size: 32px 32px;\n background-position: -1px -1px;\n background-attachment: fixed;\n }\n html[data-preset=\"editorial\"] body {\n background-image:\n linear-gradient(90deg, transparent 0, transparent 5.4rem, color-mix(in srgb, var(--security-stroke) 18%, transparent) 5.4rem, color-mix(in srgb, var(--security-stroke) 18%, transparent) calc(5.4rem + 1px), transparent calc(5.4rem + 1px)),\n repeating-linear-gradient(0deg, transparent 0, transparent 31px, color-mix(in srgb, var(--grid) 36%, transparent) 31px, color-mix(in srgb, var(--grid) 36%, transparent) 32px);\n background-attachment: fixed;\n }\n\n /* Gallery/embed mode keeps the generated artifact as the source of truth\n while presenting only its diagram surface inside a proof card. */\n html[data-embed=\"true\"] body {\n min-height: 0;\n padding: 0;\n overflow: hidden;\n background: var(--bg);\n background-image: none;\n }\n html[data-embed=\"true\"] .toolbar,\n html[data-embed=\"true\"] .header,\n html[data-embed=\"true\"] .cards,\n html[data-embed=\"true\"] .diagram-nav,\n html[data-embed=\"true\"] .overview-map,\n html[data-embed=\"true\"] .focus-chip,\n html[data-embed=\"true\"] .route-probe,\n html[data-embed=\"true\"] .semantic-lens,\n html[data-embed=\"true\"] .diagram-guide,\n html[data-embed=\"true\"] .node-finder,\n html[data-embed=\"true\"] .node-outline { display: none !important; }\n html[data-embed=\"true\"] .container { max-width: none; }\n html[data-embed=\"true\"] .diagram-container {\n padding: 0.5rem;\n border: 0;\n border-radius: 0;\n box-shadow: none;\n }\n html[data-embed=\"true\"] .diagram-container svg { min-width: 0; }\n\n /* Presentation Stage is a viewer-only layer: it gives the live diagram\n the viewport while keeping guided views, theme, focus, and exports real.\n Embed mode wins when both query parameters are present. */\n html[data-present=\"true\"]:not([data-embed=\"true\"]) body {\n --archify-page-top: 1rem;\n height: 100dvh;\n min-height: 0;\n padding: 1rem;\n overflow: hidden;\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .container {\n display: flex;\n flex-direction: column;\n gap: 0.75rem;\n width: 100%;\n max-width: none;\n height: calc(100dvh - 2rem);\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .header {\n flex: none;\n min-width: 0;\n margin: 0;\n padding-right: 23rem;\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .header-row { margin-bottom: 0.25rem; }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .subtitle {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .diagram-container {\n display: flex;\n flex: 1 1 auto;\n align-items: center;\n justify-content: center;\n min-height: 0;\n padding: 0.75rem;\n padding-bottom: calc(0.75rem + var(--archify-nav-reserve));\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .diagram-container \u003e svg {\n flex: 1 1 auto;\n height: 100%;\n min-height: 0;\n width: 100%;\n min-width: 0;\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .cards { display: none; }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) #btn-present {\n border-color: var(--frontend-stroke);\n color: var(--frontend-stroke);\n }\n\n /* The reader owns only the outer scale. Compact automatic sequences fit at\n their authored text size or larger. Long sequences and waterfall rows\n favor reading width and page scroll; other diagrams keep height fitting.\n Small automatic canvases retain a modest scale inside a usable shell.\n Every strategy preserves the authored SVG/viewBox and semantic geometry. */\n .container {\n width: 100%;\n max-width: var(--archify-reader-width, 1440px);\n margin: 0 auto;\n }\n html[data-reader-area=\"true\"] .diagram-container {\n min-height: var(--archify-diagram-min-height);\n display: flex;\n align-items: center;\n }\n html[data-reader-area=\"true\"] .diagram-container \u003e svg { flex-shrink: 0; }\n /* The original SVG legend can use the spare outer reader canvas while the\n capped diagram stays centered. The container still clips all outer paint. */\n .diagram-container:has([data-reader-legend-corner]) \u003e svg { overflow: visible; }\n .diagram-container [data-reader-legend-corner] {\n transform-origin: 0 0;\n transform-box: view-box;\n transform: var(--archify-reader-legend-transform);\n }\n html[data-reader-narrow=\"true\"]:not([data-present=\"true\"]) .diagram-container \u003e svg {\n min-width: 0;\n max-width: var(--archify-diagram-max-width);\n margin-inline: auto;\n }\n @media (min-width: 768px) and (max-height: 920px) {\n .header { margin-bottom: 1rem; }\n .diagram-container { padding: 1rem; }\n .cards { margin-top: 1rem; }\n .card { padding: 1rem; }\n }\n\n .header { margin-bottom: 1.5rem; padding-right: 29.5rem; }\n\n html[data-preset=\"signal-flow\"] .header,\n html[data-preset=\"blueprint\"] .header,\n html[data-preset=\"editorial\"] .header { padding-right: 29.5rem; }\n\n .header-row {\n display: flex;\n align-items: center;\n gap: 0.75rem;\n min-height: 2.75rem;\n margin-bottom: 0.25rem;\n }\n\n .pulse-dot {\n flex: none;\n width: 10px;\n height: 10px;\n background: var(--frontend-stroke);\n border-radius: 50%;\n box-shadow: 0 0 0 4px color-mix(in srgb, var(--frontend-stroke) 16%, transparent);\n animation: none;\n }\n\n html[data-motion-capable=\"true\"] .pulse-dot { animation: pulse 2s infinite; }\n\n @keyframes pulse {\n 0%, 100% { opacity: 1; }\n 50% { opacity: 0.5; }\n }\n\n h1 {\n font-size: 1.5rem;\n font-weight: 650;\n line-height: 1.25;\n letter-spacing: -0.015em;\n }\n\n .subtitle {\n color: var(--text-muted);\n font-size: 0.875rem;\n line-height: 1.55;\n margin-left: 1.375rem;\n }\n\n html[data-preset=\"signal-flow\"] .header-row::after {\n content: attr(data-preset-badge-signal-flow);\n flex: none;\n margin-left: 0.25rem;\n color: var(--frontend-stroke);\n border: 1px solid var(--frontend-stroke);\n border-radius: 999px;\n padding: 0.28rem 0.6rem;\n font-size: 0.625rem;\n letter-spacing: 0.12em;\n opacity: 0.82;\n box-shadow: 0 0 20px rgba(34, 211, 238, 0.12);\n white-space: nowrap;\n }\n\n html[data-preset=\"blueprint\"] .pulse-dot {\n width: 10px;\n height: 10px;\n border: 1px solid var(--frontend-stroke);\n border-radius: 1px;\n background: transparent;\n box-shadow: inset 0 0 0 2px var(--bg);\n transform: rotate(45deg);\n animation: none;\n }\n html[data-preset=\"blueprint\"] .header-row::after {\n content: attr(data-preset-badge-blueprint);\n flex: none;\n margin-left: 0.25rem;\n padding: 0.28rem 0.55rem;\n border-top: 1px solid var(--frontend-stroke);\n border-bottom: 1px solid var(--frontend-stroke);\n color: var(--frontend-stroke);\n font-size: 0.5625rem;\n font-weight: 700;\n letter-spacing: 0.14em;\n white-space: nowrap;\n }\n\n html[data-preset=\"editorial\"] h1,\n html[data-preset=\"editorial\"] .card h3 {\n font-family: Georgia, 'Times New Roman', 'Songti SC', STSong, serif;\n letter-spacing: -0.02em;\n }\n html[data-preset=\"editorial\"] h1 { font-size: 1.72rem; font-weight: 600; }\n html[data-preset=\"editorial\"] .pulse-dot {\n width: 9px;\n height: 9px;\n border: 1px solid var(--arrow-emphasis);\n border-radius: 0;\n background: var(--arrow-emphasis);\n box-shadow: 0 0 0 3px color-mix(in srgb, var(--arrow-emphasis) 14%, transparent);\n transform: rotate(45deg);\n animation: none;\n }\n html[data-preset=\"editorial\"] .header-row::after {\n content: attr(data-preset-badge-editorial);\n flex: none;\n margin-left: 0.25rem;\n padding: 0.32rem 0 0.24rem;\n border-bottom: 2px solid var(--arrow-emphasis);\n color: var(--arrow-emphasis);\n font-family: Georgia, 'Times New Roman', serif;\n font-size: 0.625rem;\n font-style: italic;\n font-weight: 600;\n letter-spacing: 0.08em;\n white-space: nowrap;\n }\n\n .diagram-container {\n --archify-nav-reserve: 0px;\n background: var(--panel);\n border-radius: 1rem;\n border: 1px solid var(--panel-border);\n box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 16px 40px -20px rgba(15, 23, 42, 0.18);\n padding: 1.5rem;\n padding-bottom: calc(1.5rem + var(--archify-nav-reserve));\n overflow: hidden;\n position: relative;\n }\n\n html[data-preset=\"signal-flow\"] .diagram-container {\n position: relative;\n overflow: hidden;\n background: linear-gradient(180deg, rgba(8, 20, 38, 0.82), rgba(3, 8, 18, 0.94));\n box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), 0 28px 80px rgba(0, 0, 0, 0.34);\n }\n html[data-preset=\"signal-flow\"][data-theme=\"light\"] .diagram-container {\n background: linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(237, 246, 250, 0.94));\n box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72), 0 24px 60px rgba(45, 78, 99, 0.12);\n }\n html[data-preset=\"blueprint\"] .diagram-container {\n border-color: var(--panel-border);\n border-radius: 0.35rem;\n background: var(--panel);\n box-shadow:\n inset 0 0 0 1px color-mix(in srgb, var(--panel-border) 34%, transparent),\n 0 18px 48px rgba(0, 0, 0, 0.16);\n }\n html[data-preset=\"blueprint\"] .diagram-container::after {\n content: \"\";\n position: absolute;\n z-index: 10;\n inset: 0.7rem;\n pointer-events: none;\n background:\n linear-gradient(var(--frontend-stroke), var(--frontend-stroke)) left top / 1.35rem 1px no-repeat,\n linear-gradient(var(--frontend-stroke), var(--frontend-stroke)) left top / 1px 1.35rem no-repeat,\n linear-gradient(var(--frontend-stroke), var(--frontend-stroke)) right top / 1.35rem 1px no-repeat,\n linear-gradient(var(--frontend-stroke), var(--frontend-stroke)) right top / 1px 1.35rem no-repeat,\n linear-gradient(var(--frontend-stroke), var(--frontend-stroke)) left bottom / 1.35rem 1px no-repeat,\n linear-gradient(var(--frontend-stroke), var(--frontend-stroke)) left bottom / 1px 1.35rem no-repeat,\n linear-gradient(var(--frontend-stroke), var(--frontend-stroke)) right bottom / 1.35rem 1px no-repeat,\n linear-gradient(var(--frontend-stroke), var(--frontend-stroke)) right bottom / 1px 1.35rem no-repeat;\n opacity: 0.58;\n }\n html[data-preset=\"editorial\"] .diagram-container {\n overflow: hidden;\n border-color: var(--panel-border);\n border-radius: 0.38rem;\n background:\n linear-gradient(90deg, color-mix(in srgb, var(--security-fill) 58%, transparent), transparent 12%),\n var(--panel);\n box-shadow:\n 0 1px 0 color-mix(in srgb, var(--text) 6%, transparent),\n 0 18px 48px color-mix(in srgb, #000 19%, transparent);\n }\n html[data-preset=\"editorial\"] .diagram-container::after {\n position: absolute;\n z-index: 10;\n top: 0.72rem;\n right: 1.25rem;\n padding: 0.2rem 0.52rem;\n border: 1px solid var(--panel-border);\n background: var(--panel);\n color: var(--arrow-emphasis);\n content: attr(data-preset-badge-editorial-plate);\n font-family: Georgia, 'Times New Roman', serif;\n font-size: 0.52rem;\n font-style: italic;\n font-weight: 600;\n letter-spacing: 0.09em;\n pointer-events: none;\n }\n html[data-embed=\"true\"][data-preset=\"editorial\"] .diagram-container::after { display: none; }\n html[data-motion-capable=\"true\"][data-preset=\"signal-flow\"][data-ambient-motion=\"running\"] .diagram-container::before {\n content: \"\";\n position: absolute;\n inset: 0;\n pointer-events: none;\n background: linear-gradient(115deg, transparent 28%, rgba(103, 232, 249, 0.035) 48%, transparent 68%);\n transform: translateX(-70%);\n animation: archify-signal-scan 4.8s ease-in-out 1 both;\n }\n\n /* Motion Governor gives the reader a real static state and gives the\n strongest semantic action the only motion budget. Atmosphere resets to\n its authored base instead of freezing mid-cycle. Static artifacts never\n start a decorative pulse or scan. */\n html:not([data-motion-capable=\"true\"]) svg[data-animation=\"trace\"] [data-animate] {\n animation: none !important;\n }\n html:not([data-motion-capable=\"true\"]) svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] {\n animation: none !important;\n }\n html[data-motion=\"still\"] .pulse-dot,\n html[data-motion=\"still\"] .diagram-container::before,\n html[data-motion=\"still\"] svg[data-animation=\"trace\"] [data-animate],\n html[data-motion-owner] .pulse-dot,\n html[data-motion-owner] .diagram-container::before,\n html[data-motion-owner] svg[data-animation=\"trace\"] [data-animate],\n html[data-embed=\"true\"] .pulse-dot,\n html[data-embed=\"true\"] .diagram-container::before,\n html[data-share-playback=\"true\"] .pulse-dot,\n html[data-share-playback=\"true\"] .diagram-container::before,\n html[data-document-hidden=\"true\"] .pulse-dot,\n html[data-document-hidden=\"true\"] .diagram-container::before,\n html[data-document-hidden=\"true\"] svg[data-animation=\"trace\"] [data-animate],\n html[data-motion=\"still\"] svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"],\n html[data-motion-owner] svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"],\n html[data-embed=\"true\"] svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"],\n html[data-share-playback=\"true\"] svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"],\n html[data-document-hidden=\"true\"] svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] {\n animation: none !important;\n }\n html[data-motion=\"still\"] .diagram-container::before,\n html[data-motion-owner] .diagram-container::before,\n html[data-embed=\"true\"] .diagram-container::before,\n html[data-share-playback=\"true\"] .diagram-container::before {\n opacity: 0;\n }\n html[data-motion=\"still\"] .intent-trace-flow,\n html[data-motion=\"still\"] .route-probe-flow,\n html[data-motion=\"still\"] .route-journey-flow,\n html[data-motion=\"still\"] .semantic-lens-flow,\n html[data-motion=\"still\"] .diagram-guide,\n html[data-motion=\"still\"] .overview-map-live,\n html[data-document-hidden=\"true\"] .intent-trace-flow,\n html[data-document-hidden=\"true\"] .route-probe-flow,\n html[data-document-hidden=\"true\"] .route-journey-flow,\n html[data-document-hidden=\"true\"] .semantic-lens-flow,\n html[data-document-hidden=\"true\"] .diagram-guide,\n html[data-document-hidden=\"true\"] .overview-map-live {\n animation: none !important;\n }\n\n html[data-motion=\"still\"] .intent-trace-flow,\n html[data-motion=\"still\"] .route-probe-flow {\n stroke-dasharray: none;\n stroke-dashoffset: 0;\n opacity: 0.72;\n }\n html[data-motion=\"still\"] .route-journey-overlay,\n html[data-document-hidden=\"true\"] .route-journey-overlay { display: none !important; }\n html[data-motion=\"still\"] .relationship-pulse-overlay { display: none !important; }\n\n html[data-motion=\"still\"] svg [data-node-id],\n html[data-motion=\"still\"] svg [data-edge-from],\n html[data-motion=\"still\"] svg [data-detail],\n html[data-motion=\"still\"] svg [data-detail-anchor],\n html[data-motion=\"still\"] svg [data-legend-hit],\n html[data-motion=\"still\"] svg {\n transition: none !important;\n }\n\n svg {\n font-family: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, 'DejaVu Sans Mono', 'Liberation Mono', 'Noto Sans Mono CJK SC', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', monospace;\n width: 100%;\n min-width: min(900px, 100%);\n display: block;\n transform-origin: 0 0;\n transition: transform 0.18s ease;\n }\n\n .diagram-container.is-camera-moving svg {\n transition: transform 0.42s cubic-bezier(0.22, 1, 0.36, 1);\n }\n .diagram-container.is-camera-transaction svg { transition: none; }\n .diagram-container.is-pannable { cursor: grab; }\n .diagram-container.is-panning { cursor: grabbing; user-select: none; }\n .diagram-container.is-panning svg { transition: none; }\n\n .diagram-nav {\n position: absolute;\n right: 1rem;\n bottom: 1rem;\n z-index: 12;\n translate: 0 calc(-1 * var(--archify-dock-lift, 0px));\n display: inline-flex;\n align-items: center;\n max-width: calc(100% - 2rem);\n padding: 0.25rem;\n gap: 0.0625rem;\n overflow-x: auto;\n border: 1px solid color-mix(in srgb, var(--panel-border) 80%, transparent);\n border-radius: 0.75rem;\n background: color-mix(in srgb, var(--panel) 84%, transparent);\n box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05), 0 10px 28px -14px rgba(15, 23, 42, 0.28);\n backdrop-filter: blur(14px) saturate(1.2);\n scrollbar-width: none;\n }\n .diagram-nav::-webkit-scrollbar { display: none; }\n .diagram-nav button,\n .focus-chip button {\n border: 0;\n background: transparent;\n color: var(--toolbar-text);\n font: inherit;\n cursor: pointer;\n }\n .diagram-nav button {\n min-width: 2rem;\n height: 2rem;\n padding: 0 0.4rem;\n border-radius: 0.5rem;\n color: var(--text-muted);\n font-size: 0.75rem;\n font-weight: 500;\n letter-spacing: 0;\n transition: background 0.15s, color 0.15s;\n }\n .diagram-nav button:hover,\n .diagram-nav button:focus-visible {\n color: var(--text);\n background: color-mix(in srgb, var(--text) 6%, transparent);\n }\n .diagram-nav button:hover,\n .diagram-nav button:focus-visible,\n .focus-chip button:hover,\n .focus-chip button:focus-visible { background: var(--toolbar-hover); }\n .diagram-nav button:focus-visible,\n .focus-chip button:focus-visible {\n outline: 2px solid var(--frontend-stroke);\n outline-offset: 1px;\n }\n .diagram-nav button:disabled { opacity: 0.38; cursor: default; }\n /* The Guide stays on the ? shortcut; Map only earns dock space once the\n reader has zoomed past the full diagram (or opened it from the keyboard). */\n .diagram-nav button[hidden] { display: none; }\n .diagram-container:not(.is-pannable) #btn-overview-map:not([data-radar-requested]):not(:focus) { display: none; }\n .diagram-nav button:disabled:hover { background: transparent; }\n .diagram-nav #btn-route-probe,\n .diagram-nav #btn-overview-map,\n .diagram-nav #btn-semantic-lens {\n min-width: auto;\n padding-inline: 0.6rem;\n color: var(--text-muted);\n font-weight: 500;\n }\n .diagram-nav #btn-node-finder,\n .diagram-nav [data-view=\"out\"] {\n position: relative;\n margin-left: 0.375rem;\n }\n .diagram-nav #btn-node-finder::before,\n .diagram-nav [data-view=\"out\"]::before {\n position: absolute;\n top: 0.55rem;\n bottom: 0.55rem;\n left: -0.19rem;\n width: 1px;\n background: color-mix(in srgb, var(--panel-border) 90%, transparent);\n content: \"\";\n pointer-events: none;\n }\n .diagram-nav-icon {\n display: block;\n width: 0.875rem;\n height: 0.875rem;\n margin: auto;\n background: currentColor;\n -webkit-mask-position: center;\n -webkit-mask-repeat: no-repeat;\n -webkit-mask-size: contain;\n mask-position: center;\n mask-repeat: no-repeat;\n mask-size: contain;\n }\n .diagram-nav-icon.find {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Ccircle cx='8.5' cy='8.5' r='4.5' fill='none' stroke='black' stroke-width='1.8'/%3E%3Cpath d='m12 12 4 4' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Ccircle cx='8.5' cy='8.5' r='4.5' fill='none' stroke='black' stroke-width='1.8'/%3E%3Cpath d='m12 12 4 4' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E\");\n }\n .diagram-nav-icon.guide {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Ccircle cx='10' cy='10' r='7' fill='none' stroke='black' stroke-width='1.7'/%3E%3Cpath d='M7.8 7.3a2.4 2.4 0 014.6.9c0 1.8-2.4 2-2.4 3.7M10 14.9h.01' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Ccircle cx='10' cy='10' r='7' fill='none' stroke='black' stroke-width='1.7'/%3E%3Cpath d='M7.8 7.3a2.4 2.4 0 014.6.9c0 1.8-2.4 2-2.4 3.7M10 14.9h.01' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round'/%3E%3C/svg%3E\");\n }\n .diagram-nav-icon.minus {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 10h10' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 10h10' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E\");\n }\n .diagram-nav-icon.plus {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M10 5v10M5 10h10' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M10 5v10M5 10h10' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E\");\n }\n .diagram-nav [data-view=\"reset\"] {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n gap: 0.2rem;\n min-width: 3.1rem;\n padding-inline: 0.35rem;\n }\n .diagram-nav [data-view=\"reset\"][data-detail-visible] {\n min-width: 3.8rem;\n }\n .diagram-nav-detail {\n color: color-mix(in srgb, var(--toolbar-text) 52%, transparent);\n font-size: 0.44rem;\n font-weight: 700;\n line-height: 1;\n letter-spacing: 0.07em;\n }\n .diagram-nav-percent {\n color: var(--text-muted);\n font-size: 0.75rem;\n font-weight: 500;\n font-variant-numeric: tabular-nums;\n line-height: 1;\n }\n /* Mode buttons carry a small glyph so the dock reads as one icon language. */\n .diagram-nav #btn-route-probe,\n .diagram-nav #btn-overview-map,\n .diagram-nav #btn-semantic-lens {\n display: inline-flex;\n align-items: center;\n gap: 0.375rem;\n padding-inline: 0.55rem 0.65rem;\n }\n .diagram-nav #btn-route-probe::before,\n .diagram-nav #btn-overview-map::before,\n .diagram-nav #btn-semantic-lens::before {\n flex: none;\n width: 0.875rem;\n height: 0.875rem;\n background: currentColor;\n content: \"\";\n opacity: 0.85;\n -webkit-mask: var(--nav-glyph) center / contain no-repeat;\n mask: var(--nav-glyph) center / contain no-repeat;\n }\n .diagram-nav #btn-route-probe { --nav-glyph: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cg fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round'%3E%3Ccircle cx='4.8' cy='14.8' r='2.2'/%3E%3Ccircle cx='15.2' cy='5.2' r='2.2'/%3E%3Cpath d='M6.9 13.9c3.8-1.4 2.6-6.3 6.2-7.8'/%3E%3C/g%3E%3C/svg%3E\"); }\n .diagram-nav #btn-overview-map { --nav-glyph: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cg fill='none' stroke='black' stroke-width='1.7' stroke-linejoin='round'%3E%3Cpath d='M2.8 5.4 7.4 3.5l5.2 2 4.6-1.9v11l-4.6 1.9-5.2-2-4.6 1.9z'/%3E%3Cpath d='M7.4 3.5v11M12.6 5.5v11'/%3E%3C/g%3E%3C/svg%3E\"); }\n .diagram-nav #btn-semantic-lens { --nav-glyph: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cg fill='none' stroke='black' stroke-width='1.7'%3E%3Ccircle cx='10' cy='10' r='6.8'/%3E%3Ccircle cx='10' cy='10' r='2.6'/%3E%3C/g%3E%3C/svg%3E\"); }\n /* Zoom out / level / zoom in join into one stepper well. */\n .diagram-nav [data-view=\"out\"],\n .diagram-nav [data-view=\"reset\"],\n .diagram-nav [data-view=\"in\"] {\n border-radius: 0;\n background: color-mix(in srgb, var(--text) 4.5%, transparent);\n }\n .diagram-nav [data-view=\"out\"] { margin-left: 0.375rem; border-radius: 0.5rem 0 0 0.5rem; }\n .diagram-nav [data-view=\"out\"]::before { display: none; }\n .diagram-nav [data-view=\"reset\"],\n .diagram-nav [data-view=\"in\"] { margin-left: -0.0625rem; }\n .diagram-nav [data-view=\"in\"] { border-radius: 0 0.5rem 0.5rem 0; }\n .diagram-nav [data-view=\"out\"]:hover,\n .diagram-nav [data-view=\"reset\"]:hover,\n .diagram-nav [data-view=\"in\"]:hover { background: color-mix(in srgb, var(--text) 9%, transparent); }\n .diagram-nav [data-view=\"out\"]:disabled,\n .diagram-nav [data-view=\"in\"]:disabled { opacity: 1; color: color-mix(in srgb, var(--text-muted) 40%, transparent); }\n .diagram-nav [data-view=\"out\"]:disabled:hover,\n .diagram-nav [data-view=\"in\"]:disabled:hover { background: color-mix(in srgb, var(--text) 4.5%, transparent); }\n .diagram-nav [data-view=\"reset\"] { min-width: 3.25rem; }\n .diagram-container[data-camera-indicator=\"true\"] .diagram-nav-detail,\n .diagram-container[data-camera-indicator=\"true\"] .diagram-nav-percent { color: var(--frontend-stroke); }\n .diagram-nav #btn-diagram-guide[aria-expanded=\"true\"] {\n color: var(--cloud-stroke);\n background: var(--toolbar-hover);\n }\n\n /* Semantic Radar is a deliberately simplified, viewer-only overview. It\n uses authored node bounds and the live camera viewport rather than\n cloning the canonical SVG, so IDs, filters, animation, and export state\n stay singular and deterministic. */\n .overview-map {\n position: absolute;\n right: 1rem;\n bottom: calc(4.15rem + var(--archify-nav-reserve));\n z-index: 12;\n width: 11.25rem;\n overflow: hidden;\n border: 1px solid color-mix(in srgb, var(--frontend-stroke) 52%, var(--toolbar-border));\n border-radius: 0.78rem;\n background: var(--toolbar-menu-bg);\n color: var(--toolbar-text);\n box-shadow: 0 16px 42px rgba(0, 0, 0, 0.3);\n backdrop-filter: blur(16px);\n font-size: 0.625rem;\n }\n .overview-map[hidden] { display: none; }\n .overview-map[data-docked=\"true\"] {\n position: fixed;\n right: var(--archify-radar-right, 1rem);\n top: var(--archify-radar-top, 1rem);\n bottom: auto;\n }\n .overview-map[data-docked=\"true\"][data-dock-side=\"left\"] {\n right: auto;\n left: var(--archify-radar-left, 1rem);\n }\n html[data-preset=\"blueprint\"] .overview-map { border-radius: 0.28rem; }\n .overview-map-head {\n display: grid;\n grid-template-columns: auto minmax(0, 1fr) auto;\n align-items: center;\n gap: 0.45rem;\n min-height: 2.25rem;\n padding: 0.42rem 0.48rem 0.38rem 0.55rem;\n border-bottom: 1px solid var(--toolbar-border);\n background: linear-gradient(110deg, color-mix(in srgb, var(--frontend-fill) 45%, transparent), transparent 68%);\n cursor: grab;\n touch-action: none;\n user-select: none;\n }\n .overview-map[data-panel-dragging=\"true\"] .overview-map-head { cursor: grabbing; }\n .overview-map[data-placement-invalid=\"true\"] {\n border-color: var(--security-stroke);\n box-shadow: 0 0 0 2px color-mix(in srgb, var(--security-stroke) 34%, transparent), 0 16px 42px rgba(0, 0, 0, 0.3);\n }\n .overview-map[data-compact=\"true\"] {\n width: 7.4rem;\n }\n .overview-map[data-compact=\"true\"] .overview-map-head {\n grid-template-columns: minmax(0, 1fr) auto;\n gap: 0.24rem;\n min-height: 1.5rem;\n padding: 0.05rem 0.16rem 0.05rem 0.32rem;\n border-bottom: 0;\n }\n .overview-map[data-compact=\"true\"] .overview-map-live,\n .overview-map[data-compact=\"true\"] .overview-map-copy,\n .overview-map[data-compact=\"true\"] .overview-map-surface,\n .overview-map[data-compact=\"true\"] .overview-map-hint {\n display: none;\n }\n .overview-map[data-compact=\"true\"] .overview-map-expand { display: inline-flex; }\n .overview-map[data-compact=\"true\"] .overview-map-close {\n width: 1.15rem;\n height: 1.15rem;\n font-size: 0.72rem;\n }\n .overview-map-live {\n width: 0.42rem;\n height: 0.42rem;\n border-radius: 50%;\n background: var(--backend-stroke);\n box-shadow: 0 0 0 0 color-mix(in srgb, var(--backend-stroke) 52%, transparent);\n animation: archify-radar-live 2.4s ease-out infinite;\n }\n .overview-map-copy { min-width: 0; line-height: 1.1; }\n .overview-map-copy strong {\n display: block;\n overflow: hidden;\n color: var(--frontend-stroke);\n font-size: 0.59rem;\n letter-spacing: 0.12em;\n text-transform: uppercase;\n white-space: nowrap;\n text-overflow: ellipsis;\n }\n .overview-map-copy small {\n display: block;\n margin-top: 0.18rem;\n overflow: hidden;\n color: var(--text-faint);\n font-size: 0.52rem;\n letter-spacing: 0.04em;\n white-space: nowrap;\n text-overflow: ellipsis;\n }\n .overview-map-expand {\n display: none;\n align-items: center;\n justify-content: center;\n min-width: 0;\n height: 1.2rem;\n padding: 0 0.34rem;\n overflow: hidden;\n border: 0;\n border-radius: 0.3rem;\n background: transparent;\n color: var(--frontend-stroke);\n font: inherit;\n font-size: 0.49rem;\n font-weight: 700;\n letter-spacing: 0.06em;\n text-transform: uppercase;\n white-space: nowrap;\n cursor: pointer;\n }\n .overview-map-close {\n width: 1.55rem;\n height: 1.55rem;\n padding: 0;\n border: 0;\n border-radius: 0.34rem;\n background: transparent;\n color: var(--toolbar-text);\n font: inherit;\n font-size: 0.9rem;\n cursor: pointer;\n }\n .overview-map-expand:hover,\n .overview-map-expand:focus-visible,\n .overview-map-close:hover,\n .overview-map-close:focus-visible { background: var(--toolbar-hover); }\n .overview-map-expand:focus-visible,\n .overview-map-close:focus-visible,\n .overview-map-surface:focus-visible,\n .overview-map-node:focus-visible {\n outline: 2px solid var(--frontend-stroke);\n outline-offset: 1px;\n }\n .overview-map-surface {\n position: relative;\n height: 7rem;\n margin: 0.42rem;\n overflow: hidden;\n border: 1px solid color-mix(in srgb, var(--panel-border) 72%, transparent);\n border-radius: 0.42rem;\n background:\n linear-gradient(color-mix(in srgb, var(--panel-border) 26%, transparent) 1px, transparent 1px),\n linear-gradient(90deg, color-mix(in srgb, var(--panel-border) 26%, transparent) 1px, transparent 1px),\n color-mix(in srgb, var(--bg) 86%, transparent);\n background-size: 12px 12px;\n cursor: crosshair;\n touch-action: none;\n }\n html[data-preset=\"blueprint\"] .overview-map-surface { border-radius: 0.1rem; }\n .overview-map-surface \u003e svg {\n width: 100%;\n height: 100%;\n min-width: 0;\n transform: none !important;\n transition: none !important;\n display: block;\n overflow: visible;\n }\n .overview-map-node {\n fill: var(--backend-stroke);\n fill-opacity: 0.52;\n stroke: var(--backend-stroke);\n stroke-opacity: 0.86;\n vector-effect: non-scaling-stroke;\n cursor: pointer;\n transition: fill-opacity 140ms ease, stroke-width 140ms ease, filter 140ms ease;\n }\n .overview-map-node[data-kind=\"frontend\"],\n .overview-map-node[data-kind=\"start\"] { fill: var(--frontend-stroke); stroke: var(--frontend-stroke); }\n .overview-map-node[data-kind=\"database\"],\n .overview-map-node[data-kind=\"success\"] { fill: var(--database-stroke); stroke: var(--database-stroke); }\n .overview-map-node[data-kind=\"cloud\"],\n .overview-map-node[data-kind=\"waiting\"] { fill: var(--cloud-stroke); stroke: var(--cloud-stroke); }\n .overview-map-node[data-kind=\"messagebus\"] { fill: var(--messagebus-stroke); stroke: var(--messagebus-stroke); }\n .overview-map-node[data-kind=\"security\"],\n .overview-map-node[data-kind=\"decision\"],\n .overview-map-node[data-kind=\"failure\"] { fill: var(--security-stroke); stroke: var(--security-stroke); }\n .overview-map-node[data-kind=\"external\"],\n .overview-map-node[data-kind=\"neutral\"] { fill: var(--external-stroke); stroke: var(--external-stroke); }\n .overview-map-node[data-radar-active=\"true\"],\n .overview-map-node:hover,\n .overview-map-node:focus-visible {\n fill-opacity: 0.92;\n stroke-width: 2.2;\n filter: drop-shadow(0 0 3px currentColor);\n }\n .overview-map-viewport {\n fill: color-mix(in srgb, var(--frontend-fill) 56%, transparent);\n stroke: var(--frontend-stroke);\n stroke-width: 2;\n vector-effect: non-scaling-stroke;\n pointer-events: none;\n filter: drop-shadow(0 0 3px color-mix(in srgb, var(--frontend-stroke) 54%, transparent));\n }\n .overview-map-hint {\n display: flex;\n justify-content: space-between;\n gap: 0.5rem;\n padding: 0 0.52rem 0.46rem;\n color: var(--text-faint);\n font-size: 0.49rem;\n letter-spacing: 0.06em;\n text-transform: uppercase;\n }\n .diagram-nav #btn-overview-map[aria-expanded=\"true\"] {\n color: var(--frontend-stroke);\n background: color-mix(in srgb, var(--frontend-stroke) 11%, transparent);\n }\n .overview-map-feedback {\n position: absolute;\n right: 1rem;\n bottom: 4.15rem;\n z-index: 13;\n max-width: min(16rem, calc(100% - 2rem));\n padding: 0.38rem 0.55rem;\n border: 1px solid color-mix(in srgb, var(--frontend-stroke) 52%, var(--toolbar-border));\n border-radius: 0.5rem;\n background: var(--toolbar-menu-bg);\n color: var(--toolbar-text);\n box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);\n font-size: 0.52rem;\n line-height: 1.35;\n pointer-events: none;\n }\n .overview-map-feedback[hidden] { display: none; }\n .focus-chip[data-radar-yielded=\"true\"] { display: none !important; }\n .diagram-nav #btn-route-probe[aria-pressed=\"true\"] {\n color: var(--backend-stroke);\n background: color-mix(in srgb, var(--backend-stroke) 11%, transparent);\n }\n .diagram-nav #btn-semantic-lens[aria-expanded=\"true\"],\n .diagram-nav #btn-semantic-lens[aria-pressed=\"true\"] {\n color: var(--database-stroke);\n background: color-mix(in srgb, var(--database-stroke) 11%, transparent);\n }\n\n /* Semantic Lens turns the compiled node-kind palette into an analytical\n legend. One kind reveals its real traffic; two kinds compare only their\n direct authored relationships. Geometry and the canonical SVG stay put. */\n .semantic-lens {\n position: absolute;\n right: 1rem;\n bottom: calc(4.15rem + var(--archify-nav-reserve));\n z-index: 24;\n width: min(20rem, calc(100% - 2rem));\n overflow: hidden;\n border: 1px solid color-mix(in srgb, var(--database-stroke) 58%, var(--toolbar-border));\n border-radius: 0.82rem;\n background:\n linear-gradient(135deg, color-mix(in srgb, var(--database-fill) 34%, transparent), transparent 48%),\n var(--toolbar-menu-bg);\n color: var(--toolbar-text);\n box-shadow: 0 18px 52px rgba(0, 0, 0, 0.36);\n backdrop-filter: blur(18px);\n animation: archify-lens-in 180ms cubic-bezier(0.22, 1, 0.36, 1);\n }\n .semantic-lens[hidden] { display: none; }\n .semantic-lens[data-dock-side=\"left\"] { left: 1rem; right: auto; }\n .semantic-lens[data-dock-side=\"right\"] { left: auto; right: 1rem; }\n html[data-preset=\"blueprint\"] .semantic-lens { border-radius: 0.28rem; }\n .semantic-lens-head {\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n align-items: start;\n gap: 0.75rem;\n padding: 0.72rem 0.78rem 0.62rem;\n border-bottom: 1px solid var(--toolbar-border);\n }\n .semantic-lens-eyebrow {\n display: block;\n color: var(--database-stroke);\n font-size: 0.5rem;\n font-weight: 800;\n letter-spacing: 0.16em;\n text-transform: uppercase;\n }\n .semantic-lens-title {\n display: block;\n margin-top: 0.16rem;\n color: var(--text);\n font-size: 0.82rem;\n letter-spacing: -0.02em;\n }\n .semantic-lens-close {\n width: 1.75rem;\n height: 1.75rem;\n padding: 0;\n border: 0;\n border-radius: 0.35rem;\n background: transparent;\n color: var(--toolbar-text);\n font: inherit;\n font-size: 1rem;\n cursor: pointer;\n }\n .semantic-lens-close:hover,\n .semantic-lens-close:focus-visible { background: var(--toolbar-hover); }\n .semantic-lens-instruction {\n margin: 0;\n padding: 0.52rem 0.78rem 0.48rem;\n color: var(--text-faint);\n font-size: 0.55rem;\n line-height: 1.45;\n }\n .semantic-lens-kinds {\n display: grid;\n grid-template-columns: 1fr 1fr;\n gap: 0.3rem;\n max-height: min(15rem, 40vh);\n padding: 0 0.5rem 0.5rem;\n overflow-y: auto;\n scrollbar-width: thin;\n }\n .semantic-lens-kind {\n --lens-color: var(--external-stroke);\n display: grid;\n grid-template-columns: auto minmax(0, 1fr) auto;\n align-items: center;\n gap: 0.42rem;\n min-width: 0;\n min-height: 2.15rem;\n padding: 0.35rem 0.42rem;\n border: 1px solid color-mix(in srgb, var(--lens-color) 24%, var(--toolbar-border));\n border-radius: 0.45rem;\n background: color-mix(in srgb, var(--panel) 76%, transparent);\n color: var(--toolbar-text);\n font: inherit;\n text-align: left;\n cursor: pointer;\n transition: border-color 140ms ease, background 140ms ease, opacity 140ms ease;\n }\n html[data-preset=\"blueprint\"] .semantic-lens-kind { border-radius: 0.12rem; }\n .semantic-lens-kind[data-kind=\"frontend\"],\n .semantic-lens-kind[data-kind=\"start\"] { --lens-color: var(--frontend-stroke); }\n .semantic-lens-kind[data-kind=\"backend\"],\n .semantic-lens-kind[data-kind=\"active\"] { --lens-color: var(--backend-stroke); }\n .semantic-lens-kind[data-kind=\"database\"],\n .semantic-lens-kind[data-kind=\"success\"] { --lens-color: var(--database-stroke); }\n .semantic-lens-kind[data-kind=\"cloud\"],\n .semantic-lens-kind[data-kind=\"waiting\"] { --lens-color: var(--cloud-stroke); }\n .semantic-lens-kind[data-kind=\"messagebus\"] { --lens-color: var(--messagebus-stroke); }\n .semantic-lens-kind[data-kind=\"security\"],\n .semantic-lens-kind[data-kind=\"decision\"],\n .semantic-lens-kind[data-kind=\"failure\"] { --lens-color: var(--security-stroke); }\n .semantic-lens-kind:hover,\n .semantic-lens-kind:focus-visible,\n .semantic-lens-kind[aria-pressed=\"true\"] {\n border-color: color-mix(in srgb, var(--lens-color) 78%, var(--toolbar-border));\n background: color-mix(in srgb, var(--lens-color) 11%, var(--panel));\n }\n .semantic-lens-kind:focus-visible,\n .semantic-lens-close:focus-visible,\n .semantic-lens-actions button:focus-visible {\n outline: 2px solid var(--database-stroke);\n outline-offset: 1px;\n }\n .semantic-lens-kind:disabled { opacity: 0.34; cursor: default; }\n .semantic-lens-swatch {\n width: 0.48rem;\n height: 0.48rem;\n border-radius: 50%;\n background: var(--lens-color);\n box-shadow: 0 0 8px color-mix(in srgb, var(--lens-color) 58%, transparent);\n }\n .semantic-lens-kind strong {\n overflow: hidden;\n color: var(--text);\n font-size: 0.61rem;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .semantic-lens-kind em {\n color: var(--lens-color);\n font-size: 0.54rem;\n font-style: normal;\n font-weight: 800;\n }\n .semantic-lens-status {\n min-height: 2.5rem;\n margin: 0;\n padding: 0.55rem 0.78rem;\n border-top: 1px solid var(--toolbar-border);\n color: var(--text-faint);\n font-size: 0.55rem;\n line-height: 1.45;\n }\n .semantic-lens-status strong { color: var(--database-stroke); font-weight: 800; }\n .semantic-lens-actions {\n display: flex;\n justify-content: flex-end;\n gap: 0.28rem;\n padding: 0 0.62rem 0.62rem;\n }\n .semantic-lens-actions button {\n min-height: 1.8rem;\n padding: 0.28rem 0.48rem;\n border: 0;\n border-radius: 0.35rem;\n background: transparent;\n color: var(--toolbar-text);\n font: inherit;\n font-size: 0.56rem;\n cursor: pointer;\n }\n .semantic-lens-actions button:hover { background: var(--toolbar-hover); }\n .semantic-lens-actions #semantic-lens-copy { color: var(--database-stroke); }\n @keyframes archify-lens-in {\n from { opacity: 0; transform: translateY(5px) scale(0.985); }\n to { opacity: 1; transform: translateY(0) scale(1); }\n }\n\n /* Route Probe answers a reader question over the compiled semantic graph:\n choose two stable nodes and reveal the shortest authored directed route.\n The receipt and signal live entirely in the viewer layer. */\n .route-probe {\n position: absolute;\n left: 1rem;\n bottom: calc(1rem + var(--archify-nav-reserve));\n z-index: 12;\n width: min(46rem, calc(100% - 25rem));\n min-width: 18rem;\n overflow: hidden;\n border: 1px solid color-mix(in srgb, var(--backend-stroke) 62%, var(--toolbar-border));\n border-radius: 0.82rem;\n background:\n linear-gradient(115deg, color-mix(in srgb, var(--backend-fill) 50%, transparent), transparent 62%),\n var(--toolbar-menu-bg);\n color: var(--toolbar-text);\n box-shadow: 0 18px 48px rgba(0, 0, 0, 0.3);\n backdrop-filter: blur(16px);\n font-size: 0.75rem;\n }\n .route-probe[hidden] { display: none; }\n /* Picking needs one line of guidance, not a wide empty card; the panel\n widens only when there is a traced route to show. */\n .route-probe:not([data-state=\"result\"]) { width: min(22rem, calc(100% - 2rem)); min-width: 0; }\n .route-probe-path:has(\u003e .route-probe-placeholder:only-child) { display: none; }\n .route-probe[data-route-dock=\"top\"] {\n top: 1rem;\n bottom: auto;\n }\n html[data-preset=\"blueprint\"] .route-probe { border-radius: 0.25rem; }\n .route-probe-head {\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n align-items: start;\n gap: 0.65rem;\n padding: 0.625rem 0.75rem 0.5rem;\n border-bottom: 1px solid color-mix(in srgb, var(--toolbar-border) 80%, transparent);\n }\n .route-probe-copy { min-width: 0; }\n .route-probe-eyebrow {\n display: block;\n color: var(--backend-stroke);\n font-size: 0.6875rem;\n font-weight: 600;\n letter-spacing: 0.02em;\n }\n .route-probe-title {\n display: block;\n margin-top: 0.14rem;\n overflow: hidden;\n color: var(--toolbar-text);\n font-size: 0.875rem;\n font-weight: 600;\n line-height: 1.3;\n white-space: nowrap;\n text-overflow: ellipsis;\n }\n .route-probe-actions { display: flex; gap: 0.2rem; }\n .route-probe button {\n min-height: 1.55rem;\n padding: 0.25rem 0.42rem;\n border: 0;\n border-radius: 0.36rem;\n background: transparent;\n color: var(--toolbar-text);\n font: inherit;\n cursor: pointer;\n }\n .route-probe button:hover,\n .route-probe button:focus-visible { background: var(--toolbar-hover); }\n .route-probe button:focus-visible {\n outline: 2px solid var(--backend-stroke);\n outline-offset: 1px;\n }\n .route-probe-copy-link { color: var(--frontend-stroke) !important; }\n .route-probe-find { color: var(--backend-stroke) !important; }\n .route-probe-copy-link[hidden] { display: none; }\n .route-probe-find[hidden] { display: none; }\n .route-probe-path {\n display: flex;\n align-items: center;\n min-height: 2.2rem;\n padding: 0.42rem 0.58rem 0.24rem;\n overflow-x: auto;\n scrollbar-width: thin;\n white-space: nowrap;\n }\n .route-probe-node,\n .route-probe button.route-probe-node {\n flex: none;\n max-width: 9.5rem;\n overflow: hidden;\n min-height: 1.75rem !important;\n padding: 0.22rem 0.38rem;\n border: 1px solid color-mix(in srgb, var(--backend-stroke) 46%, var(--toolbar-border));\n border-radius: 999px;\n background: color-mix(in srgb, var(--backend-fill) 52%, transparent);\n color: var(--text);\n font-size: 0.56rem;\n font-weight: 700;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .route-probe-node[data-endpoint=\"start\"] {\n border-color: var(--frontend-stroke);\n color: var(--frontend-stroke);\n }\n .route-probe-node[data-endpoint=\"end\"] {\n border-color: var(--security-stroke);\n color: var(--security-stroke);\n }\n .route-probe-node[data-route-journey-state=\"past\"] { opacity: 0.66; }\n .route-probe-node[data-route-journey-state=\"future\"] { opacity: 0.48; }\n .route-probe-node[aria-current=\"step\"] {\n border-color: var(--backend-stroke);\n background: color-mix(in srgb, var(--backend-fill) 82%, var(--toolbar-menu-bg));\n color: var(--text);\n box-shadow: 0 0 0 1px color-mix(in srgb, var(--backend-stroke) 42%, transparent), 0 0 14px color-mix(in srgb, var(--backend-stroke) 34%, transparent);\n opacity: 1;\n }\n html[data-preset=\"blueprint\"] .route-probe-node[aria-current=\"step\"] {\n border-style: double;\n border-width: 3px;\n border-radius: 0.2rem;\n box-shadow: none;\n }\n .route-probe-arrow {\n flex: none;\n padding: 0 0.28rem;\n color: var(--text-faint);\n font-size: 0.65rem;\n }\n .route-probe-placeholder {\n color: var(--text-faint);\n font-size: 0.75rem;\n }\n .route-probe-status {\n display: block;\n min-height: 1.45rem;\n padding: 0.5rem 0.75rem 0.625rem;\n color: var(--text-muted, var(--text-faint));\n font-size: 0.75rem;\n line-height: 1.45;\n }\n .route-journey-controls {\n display: grid;\n grid-template-columns: 2rem minmax(5.8rem, auto) 2rem minmax(4.8rem, auto);\n justify-content: start;\n gap: 0.22rem;\n padding: 0.08rem 0.58rem 0.28rem;\n }\n .route-journey-controls[hidden] { display: none; }\n .route-journey-controls button {\n min-height: 1.8rem;\n border: 1px solid color-mix(in srgb, var(--toolbar-border) 86%, transparent);\n background: color-mix(in srgb, var(--toolbar-bg) 72%, transparent);\n font-size: 0.54rem;\n font-weight: 700;\n }\n .route-journey-controls button:disabled {\n cursor: default;\n opacity: 0.34;\n }\n .route-journey-play { color: var(--backend-stroke) !important; }\n .route-journey-overview { color: var(--frontend-stroke) !important; }\n .route-journey-controls[data-playing=\"true\"] .route-journey-play {\n border-color: color-mix(in srgb, var(--backend-stroke) 64%, var(--toolbar-border));\n background: color-mix(in srgb, var(--backend-fill) 62%, transparent);\n }\n .route-probe[data-state=\"error\"] {\n border-color: color-mix(in srgb, var(--security-stroke) 72%, var(--toolbar-border));\n }\n .route-probe[data-state=\"error\"] .route-probe-status { color: var(--security-stroke); }\n\n .focus-chip {\n position: absolute;\n left: 1rem;\n top: 1rem;\n z-index: 12;\n display: block;\n width: min(22rem, calc(100% - 13rem));\n max-width: calc(100% - 13rem);\n overflow: hidden;\n border: 1px solid var(--frontend-stroke);\n border-radius: 0.85rem;\n background: var(--toolbar-menu-bg);\n color: var(--toolbar-text);\n box-shadow: 0 18px 48px rgba(0, 0, 0, 0.3);\n backdrop-filter: blur(16px);\n font-size: 0.6875rem;\n }\n .focus-chip[hidden] { display: none; }\n html[data-preset=\"blueprint\"] .focus-chip { border-radius: 0.3rem; }\n .focus-chip button {\n flex: none;\n padding: 0.3rem 0.45rem;\n border-radius: 0.35rem;\n font-size: 0.625rem;\n }\n .relationship-lens-head {\n position: relative;\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n align-items: start;\n gap: 0.75rem;\n padding: 0.9rem 0.75rem 0.65rem;\n border-bottom: 1px solid var(--toolbar-border);\n background: linear-gradient(120deg, color-mix(in srgb, var(--frontend-fill) 34%, transparent), transparent 72%);\n }\n .relationship-lens-drag-handle {\n position: absolute;\n top: 0.12rem;\n left: 50%;\n width: 2.5rem;\n height: 0.78rem;\n padding: 0 !important;\n transform: translateX(-50%);\n color: var(--text-faint) !important;\n cursor: grab;\n touch-action: none;\n user-select: none;\n }\n .relationship-lens-drag-handle::before {\n content: \"\";\n display: block;\n width: 1.25rem;\n margin: auto;\n border-top: 2px dotted currentColor;\n opacity: 0.72;\n }\n .focus-chip[data-panel-dragging=\"true\"] .relationship-lens-drag-handle { cursor: grabbing; }\n @media (hover: none), (pointer: coarse) {\n .relationship-lens-drag-handle { display: none; }\n }\n .relationship-lens-copy { min-width: 0; }\n .relationship-lens-actions {\n display: flex;\n flex-direction: column;\n align-items: flex-end;\n gap: 0.18rem;\n }\n .relationship-lens-actions button { white-space: nowrap; }\n .relationship-lens-actions #btn-focus-clear {\n display: grid;\n width: 1.75rem;\n height: 1.75rem;\n padding: 0;\n place-items: center;\n color: var(--text-muted);\n font-size: 1rem;\n line-height: 1;\n }\n .relationship-lens-actions #btn-focus-clear:hover,\n .relationship-lens-actions #btn-focus-clear:focus-visible {\n background: var(--toolbar-hover);\n color: var(--text);\n }\n .relationship-lens-actions #btn-focus-copy { color: var(--frontend-stroke); }\n .relationship-lens-actions #btn-focus-relations { display: none; }\n .relationship-lens-eyebrow {\n display: block;\n margin-bottom: 0.18rem;\n color: var(--frontend-stroke);\n font-size: 0.5rem;\n font-weight: 800;\n letter-spacing: 0.14em;\n text-transform: uppercase;\n }\n .relationship-lens-title {\n display: block;\n overflow: hidden;\n color: var(--text);\n font-size: 0.8rem;\n line-height: 1.35;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .semantic-passport-detail {\n display: block;\n margin-top: 0.12rem;\n overflow: hidden;\n color: var(--text-muted);\n font-size: 0.625rem;\n line-height: 1.4;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .semantic-passport-detail[hidden] { display: none; }\n .semantic-passport-meta {\n display: flex;\n flex-wrap: wrap;\n gap: 0.24rem;\n margin-top: 0.42rem;\n }\n .semantic-passport-meta span,\n .semantic-passport-meta code {\n max-width: 100%;\n overflow: hidden;\n padding: 0.14rem 0.34rem;\n border: 1px solid color-mix(in srgb, var(--toolbar-border) 82%, transparent);\n border-radius: 999px;\n background: color-mix(in srgb, var(--panel) 68%, transparent);\n color: var(--text-faint);\n font: inherit;\n font-size: 0.5rem;\n letter-spacing: 0.04em;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .semantic-passport-meta [data-passport=\"kind\"] {\n border-color: color-mix(in srgb, var(--frontend-stroke) 50%, var(--toolbar-border));\n color: var(--frontend-stroke);\n font-weight: 800;\n text-transform: uppercase;\n }\n .semantic-passport-meta [data-passport=\"tag\"] { color: var(--cloud-stroke); }\n .semantic-passport-meta [data-passport=\"brand\"] {\n border-color: color-mix(in srgb, var(--messagebus-stroke) 52%, var(--toolbar-border));\n color: var(--messagebus-stroke);\n font-weight: 700;\n }\n .semantic-passport-meta [hidden] { display: none; }\n html[data-preset=\"blueprint\"] .semantic-passport-meta span,\n html[data-preset=\"blueprint\"] .semantic-passport-meta code { border-radius: 0.1rem; }\n .semantic-passport-evidence {\n margin-top: 0.52rem;\n padding: 0.5rem;\n border: 1px solid color-mix(in srgb, var(--backend-stroke) 32%, var(--toolbar-border));\n border-radius: 0.55rem;\n background: color-mix(in srgb, var(--backend-fill) 18%, var(--panel));\n }\n .semantic-passport-evidence[hidden] { display: none; }\n html[data-preset=\"blueprint\"] .semantic-passport-evidence { border-radius: 0.18rem; }\n .semantic-passport-evidence-head {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: 0.55rem;\n margin-bottom: 0.35rem;\n }\n .semantic-passport-evidence-status {\n display: inline-flex;\n align-items: center;\n gap: 0.28rem;\n color: var(--backend-stroke);\n font-size: 0.5rem;\n font-weight: 800;\n letter-spacing: 0.08em;\n text-transform: uppercase;\n }\n .semantic-passport-evidence-status::before {\n content: '';\n width: 0.38rem;\n height: 0.38rem;\n border-radius: 50%;\n background: var(--backend-stroke);\n box-shadow: 0 0 0 3px color-mix(in srgb, var(--backend-stroke) 14%, transparent);\n }\n .semantic-passport-repository {\n min-width: 0;\n overflow: hidden;\n color: var(--text-faint);\n font-size: 0.5rem;\n text-decoration: none;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .semantic-passport-repository:hover,\n .semantic-passport-repository:focus-visible { color: var(--backend-stroke); }\n .semantic-passport-evidence-links { display: grid; gap: 0.22rem; }\n .semantic-passport-source {\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n gap: 0.15rem 0.45rem;\n align-items: center;\n padding: 0.34rem 0.4rem;\n border: 1px solid transparent;\n border-radius: 0.38rem;\n color: var(--text-muted);\n text-decoration: none;\n }\n a.semantic-passport-source:hover,\n a.semantic-passport-source:focus-visible {\n border-color: color-mix(in srgb, var(--backend-stroke) 42%, transparent);\n background: color-mix(in srgb, var(--backend-fill) 32%, transparent);\n color: var(--text);\n }\n .semantic-passport-source strong {\n overflow: hidden;\n font-size: 0.5625rem;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .semantic-passport-source code {\n color: var(--backend-stroke);\n font: inherit;\n font-size: 0.5rem;\n }\n .semantic-passport-source small {\n grid-column: 1 / -1;\n overflow: hidden;\n color: var(--text-faint);\n font-size: 0.5rem;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .relationship-lens-summary {\n display: block;\n margin-top: 0.12rem;\n color: var(--text-faint);\n font-size: 0.5625rem;\n }\n .semantic-passport-reach {\n display: grid;\n gap: 0.28rem;\n margin-top: 0.52rem;\n padding-top: 0.48rem;\n border-top: 1px solid color-mix(in srgb, var(--toolbar-border) 76%, transparent);\n }\n .semantic-passport-reach[hidden] { display: none; }\n .semantic-passport-reach-label {\n color: var(--text-faint);\n font-size: 0.5rem;\n font-weight: 800;\n letter-spacing: 0.1em;\n text-transform: uppercase;\n }\n .semantic-passport-reach-actions {\n display: grid;\n grid-template-columns: repeat(2, minmax(0, 1fr));\n gap: 0.25rem;\n }\n .semantic-passport-reach-actions button {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: 0.5rem;\n min-width: 0;\n min-height: 2rem;\n padding: 0.32rem 0.42rem;\n border: 1px solid color-mix(in srgb, var(--toolbar-border) 86%, transparent);\n background: color-mix(in srgb, var(--panel) 70%, transparent);\n color: var(--text-muted);\n text-align: left;\n }\n .semantic-passport-reach-actions button:hover:not(:disabled),\n .semantic-passport-reach-actions button:focus-visible {\n border-color: color-mix(in srgb, var(--frontend-stroke) 62%, var(--toolbar-border));\n color: var(--text);\n }\n .semantic-passport-reach-actions button:focus-visible {\n outline: 2px solid var(--frontend-stroke);\n outline-offset: 1px;\n }\n .semantic-passport-reach-actions button:disabled {\n cursor: default;\n opacity: 0.5;\n }\n .semantic-passport-reach-actions button[aria-pressed=\"true\"] {\n border-color: color-mix(in srgb, var(--reach-color, var(--frontend-stroke)) 72%, var(--toolbar-border));\n background: color-mix(in srgb, var(--reach-fill, var(--frontend-fill)) 48%, transparent);\n color: var(--text);\n }\n #btn-reach-upstream {\n --reach-color: var(--database-stroke);\n --reach-fill: var(--database-fill);\n }\n #btn-reach-downstream {\n --reach-color: var(--backend-stroke);\n --reach-fill: var(--backend-fill);\n }\n .semantic-passport-reach-actions strong {\n color: var(--reach-color, var(--frontend-stroke));\n font-size: 0.625rem;\n }\n .semantic-passport-reach-status {\n color: var(--text-faint);\n font-size: 0.525rem;\n line-height: 1.4;\n }\n .semantic-passport-reach-status[hidden] { display: none; }\n .relationship-lens-list {\n max-height: min(18rem, 46vh);\n overflow: auto;\n padding: 0.4rem;\n scrollbar-width: thin;\n scrollbar-color: var(--frontend-stroke) transparent;\n }\n .relationship-lens-list::-webkit-scrollbar { width: 4px; }\n .relationship-lens-list::-webkit-scrollbar-thumb {\n border-radius: 999px;\n background: color-mix(in srgb, var(--frontend-stroke) 68%, transparent);\n }\n .relationship-lens-group + .relationship-lens-group { margin-top: 0.35rem; }\n .relationship-lens-group-title {\n display: block;\n padding: 0.24rem 0.38rem 0.16rem;\n color: var(--text-faint);\n font-size: 0.5rem;\n font-weight: 800;\n letter-spacing: 0.12em;\n text-transform: uppercase;\n }\n .relationship-lens-row {\n display: grid;\n grid-template-columns: 2.1rem minmax(0, 1fr);\n gap: 0.06rem 0.45rem;\n width: 100%;\n padding: 0.45rem 0.5rem !important;\n text-align: left;\n }\n .relationship-lens-row:hover,\n .relationship-lens-row:focus-visible,\n .relationship-lens-row[data-preview-active=\"true\"] {\n background: var(--toolbar-hover);\n box-shadow: inset 2px 0 0 var(--frontend-stroke);\n }\n .relationship-lens-row:focus-visible {\n outline: 2px solid var(--frontend-stroke);\n outline-offset: -2px;\n }\n .relationship-lens-direction {\n grid-row: 1 / 3;\n align-self: center;\n color: var(--frontend-stroke);\n font-size: 0.5rem;\n font-weight: 800;\n letter-spacing: 0.08em;\n }\n .relationship-lens-row[data-direction=\"in\"] .relationship-lens-direction { color: var(--database-stroke); }\n .relationship-lens-row[data-direction=\"loop\"] .relationship-lens-direction { color: var(--security-stroke); }\n .relationship-lens-row strong {\n overflow: hidden;\n color: var(--text);\n font-size: 0.6875rem;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .relationship-lens-row small {\n overflow: hidden;\n color: var(--text-faint);\n font-size: 0.5625rem;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .relationship-lens-empty {\n margin: 0;\n padding: 0.75rem;\n color: var(--text-faint);\n font-size: 0.625rem;\n text-align: center;\n }\n\n /* Diagram Guide keeps the artifact's growing reader vocabulary\n discoverable without widening the permanent control bar. It derives\n honest counts at runtime and delegates every action to an existing\n production interaction instead of creating a second command system. */\n .diagram-guide {\n position: absolute;\n top: 1rem;\n right: 1rem;\n z-index: 26;\n width: min(32rem, calc(100% - 2rem));\n max-height: min(42rem, calc(100% - 2rem));\n overflow: auto;\n border: 1px solid color-mix(in srgb, var(--cloud-stroke) 58%, var(--toolbar-border));\n border-radius: 0.82rem;\n background:\n linear-gradient(135deg, color-mix(in srgb, var(--cloud-fill) 32%, transparent), transparent 42%),\n var(--toolbar-menu-bg);\n color: var(--toolbar-text);\n box-shadow: 0 22px 64px rgba(0, 0, 0, 0.4);\n backdrop-filter: blur(18px);\n animation: archify-guide-in 180ms cubic-bezier(0.22, 1, 0.36, 1);\n }\n .diagram-guide[hidden] { display: none; }\n html[data-preset=\"blueprint\"] .diagram-guide { border-radius: 0.28rem; }\n .diagram-guide-head {\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n align-items: start;\n gap: 1rem;\n padding: 0.82rem 0.9rem 0.68rem;\n border-bottom: 1px solid var(--toolbar-border);\n }\n .diagram-guide-eyebrow {\n display: block;\n color: var(--cloud-stroke);\n font-size: 0.5rem;\n font-weight: 800;\n letter-spacing: 0.16em;\n text-transform: uppercase;\n }\n .diagram-guide-title {\n display: block;\n margin-top: 0.16rem;\n color: var(--text);\n font-size: 0.86rem;\n letter-spacing: -0.02em;\n }\n .diagram-guide-close {\n width: 1.8rem;\n height: 1.8rem;\n border: 0;\n border-radius: 0.35rem;\n background: transparent;\n color: var(--toolbar-text);\n font: inherit;\n font-size: 1rem;\n cursor: pointer;\n }\n .diagram-guide-close:hover,\n .diagram-guide-close:focus-visible { background: var(--toolbar-hover); }\n .diagram-guide-stats {\n display: flex;\n align-items: center;\n gap: 0.5rem;\n margin: 0;\n padding: 0.54rem 0.9rem;\n border-bottom: 1px solid color-mix(in srgb, var(--toolbar-border) 74%, transparent);\n color: var(--text-faint);\n font-size: 0.56rem;\n letter-spacing: 0.025em;\n }\n .diagram-guide-stats::before {\n content: '';\n width: 0.42rem;\n height: 0.42rem;\n flex: none;\n border-radius: 50%;\n background: var(--backend-stroke);\n box-shadow: 0 0 10px color-mix(in srgb, var(--backend-stroke) 72%, transparent);\n }\n .diagram-guide-actions {\n display: grid;\n grid-template-columns: 1fr 1fr;\n gap: 0.38rem;\n padding: 0.62rem;\n }\n .diagram-guide-action {\n --guide-accent: var(--frontend-stroke);\n display: grid;\n grid-template-columns: auto minmax(0, 1fr) auto;\n align-items: center;\n gap: 0.55rem;\n min-height: 4.15rem;\n padding: 0.55rem 0.58rem;\n border: 1px solid color-mix(in srgb, var(--guide-accent) 22%, var(--toolbar-border));\n border-radius: 0.55rem;\n background: color-mix(in srgb, var(--panel) 78%, transparent);\n color: var(--toolbar-text);\n font: inherit;\n text-align: left;\n cursor: pointer;\n transition: border-color 140ms ease, background 140ms ease, transform 140ms ease;\n }\n .diagram-guide-action[data-guide-action=\"route\"] { --guide-accent: var(--backend-stroke); }\n .diagram-guide-action[data-guide-action=\"map\"] { --guide-accent: var(--database-stroke); }\n .diagram-guide-action[data-guide-action=\"lens\"] { --guide-accent: var(--messagebus-stroke); }\n\n .diagram-guide-action[data-guide-action=\"present\"] {\n --guide-accent: var(--cloud-stroke);\n }\n .diagram-guide-action:hover,\n .diagram-guide-action:focus-visible {\n border-color: color-mix(in srgb, var(--guide-accent) 76%, var(--toolbar-border));\n background: color-mix(in srgb, var(--guide-accent) 9%, var(--panel));\n transform: translateY(-1px);\n }\n .diagram-guide-action:focus-visible,\n .diagram-guide-close:focus-visible {\n outline: 2px solid var(--cloud-stroke);\n outline-offset: 1px;\n }\n .diagram-guide-action:disabled {\n opacity: 0.42;\n cursor: default;\n transform: none;\n }\n .diagram-guide-index {\n display: grid;\n place-items: center;\n width: 1.65rem;\n height: 1.65rem;\n border: 1px solid color-mix(in srgb, var(--guide-accent) 64%, var(--toolbar-border));\n border-radius: 0.35rem;\n color: var(--guide-accent);\n font-size: 0.5rem;\n font-weight: 800;\n letter-spacing: 0.06em;\n }\n .diagram-guide-action-copy { min-width: 0; }\n .diagram-guide-action strong {\n display: block;\n overflow: hidden;\n color: var(--text);\n font-size: 0.66rem;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .diagram-guide-action small {\n display: -webkit-box;\n margin-top: 0.18rem;\n overflow: hidden;\n color: var(--text-faint);\n font-size: 0.5rem;\n line-height: 1.35;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: 2;\n }\n .diagram-guide kbd {\n align-self: start;\n min-width: 1.45rem;\n padding: 0.12rem 0.3rem;\n border: 1px solid var(--toolbar-border);\n border-radius: 0.25rem;\n color: var(--text-faint);\n font: inherit;\n font-size: 0.5rem;\n text-align: center;\n }\n .diagram-guide-shortcuts {\n display: flex;\n flex-wrap: wrap;\n gap: 0.34rem 0.62rem;\n padding: 0.58rem 0.9rem 0.68rem;\n border-top: 1px solid var(--toolbar-border);\n color: var(--text-faint);\n font-size: 0.5rem;\n }\n .diagram-guide-shortcuts span {\n display: inline-flex;\n align-items: center;\n gap: 0.28rem;\n white-space: nowrap;\n }\n .diagram-guide-feedback {\n min-height: 1rem;\n margin: -0.18rem 0.9rem 0.62rem;\n color: var(--security-stroke);\n font-size: 0.5rem;\n }\n .diagram-guide-feedback:empty { display: none; }\n @keyframes archify-guide-in {\n from { opacity: 0; transform: translateY(-5px) scale(0.985); }\n to { opacity: 1; transform: translateY(0) scale(1); }\n }\n\n .node-finder {\n position: absolute;\n top: 1rem;\n left: 1rem;\n z-index: 24;\n display: flex;\n flex-direction: column;\n width: min(22rem, calc(100% - 2rem));\n max-height: calc(100% - 2rem);\n overflow: hidden;\n border: 1px solid var(--toolbar-border);\n border-radius: 0.85rem;\n background: var(--toolbar-menu-bg);\n color: var(--toolbar-text);\n box-shadow: 0 6px 8px rgba(0, 0, 0, 0.22);\n backdrop-filter: blur(16px);\n }\n .node-finder[hidden] { display: none; }\n .node-finder[data-context=\"route-source\"] {\n border-color: color-mix(in srgb, var(--frontend-stroke) 68%, var(--toolbar-border));\n }\n .node-finder[data-context=\"route-target\"] {\n border-color: color-mix(in srgb, var(--security-stroke) 68%, var(--toolbar-border));\n }\n html[data-preset=\"blueprint\"] .node-finder { border-radius: 0.3rem; }\n .node-finder-head {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: 1rem;\n padding: 0.7rem 0.8rem 0.45rem;\n }\n .node-finder-head strong {\n color: var(--text);\n font-size: 0.6875rem;\n letter-spacing: 0.08em;\n text-transform: uppercase;\n }\n .node-finder[data-context=\"route-source\"] .node-finder-head strong { color: var(--frontend-stroke); }\n .node-finder[data-context=\"route-target\"] .node-finder-head strong { color: var(--security-stroke); }\n .node-finder-close {\n width: 1.75rem;\n height: 1.75rem;\n border: 0;\n border-radius: 0.35rem;\n background: transparent;\n color: var(--toolbar-text);\n font: inherit;\n font-size: 1rem;\n cursor: pointer;\n }\n .node-finder-close:hover,\n .node-finder-close:focus-visible { background: var(--toolbar-hover); }\n .node-finder-close:focus-visible,\n .node-finder-result:focus-visible {\n outline: 2px solid var(--frontend-stroke);\n outline-offset: -2px;\n }\n .node-finder-search {\n display: grid;\n grid-template-columns: auto minmax(0, 1fr) auto;\n align-items: center;\n gap: 0.55rem;\n margin: 0 0.55rem 0.55rem;\n padding: 0 0.7rem;\n min-height: 2.6rem;\n border: 1px solid var(--toolbar-border);\n border-radius: 0.55rem;\n background: color-mix(in srgb, var(--panel) 78%, transparent);\n transition: border-color 160ms ease-out, box-shadow 160ms ease-out;\n }\n html[data-preset=\"blueprint\"] .node-finder-search { border-radius: 0.18rem; }\n .node-finder-search \u003e span { color: var(--frontend-stroke); font-size: 0.875rem; }\n .node-finder-search:focus-within {\n border-color: var(--frontend-stroke);\n box-shadow: 0 0 0 2px color-mix(in srgb, var(--frontend-stroke) 20%, transparent);\n }\n .node-finder-input {\n appearance: none;\n width: 100%;\n min-width: 0;\n border: 0;\n outline: 0;\n background: transparent;\n color: var(--text);\n font: inherit;\n font-size: 0.75rem;\n }\n .node-finder-input:focus-visible { outline: none; }\n .node-finder-input::placeholder { color: var(--text-faint); }\n .node-finder kbd {\n padding: 0.1rem 0.32rem;\n border: 1px solid var(--toolbar-border);\n border-radius: 0.25rem;\n color: var(--text-faint);\n font: inherit;\n font-size: 0.5625rem;\n }\n .node-finder-results {\n display: grid;\n flex: 1 1 auto;\n gap: 0;\n min-height: 0;\n max-height: min(18rem, 48vh);\n margin: 0 0.55rem 0.45rem;\n padding: 0;\n overflow-y: auto;\n overscroll-behavior: contain;\n border: 1px solid color-mix(in srgb, var(--toolbar-border) 78%, transparent);\n border-radius: 0.55rem;\n background: color-mix(in srgb, var(--panel) 54%, transparent);\n scroll-padding-block: 0.25rem;\n scrollbar-width: thin;\n }\n html[data-preset=\"blueprint\"] .node-finder-results { border-radius: 0.18rem; }\n .node-finder-result {\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n gap: 0.2rem 0.75rem;\n width: 100%;\n min-height: 3.25rem;\n padding: 0.58rem 0.65rem;\n border: 0;\n border-radius: 0;\n background: transparent;\n color: var(--text);\n font: inherit;\n text-align: left;\n cursor: pointer;\n transition: background-color 160ms ease-out;\n }\n .node-finder-result:not(:last-child) {\n border-bottom: 1px solid color-mix(in srgb, var(--toolbar-border) 62%, transparent);\n }\n .node-finder-result:hover,\n .node-finder-result:focus-visible {\n position: relative;\n z-index: 1;\n background: color-mix(in srgb, var(--frontend-fill) 48%, var(--toolbar-hover));\n }\n .node-finder-result strong {\n overflow: hidden;\n font-size: 0.75rem;\n line-height: 1.25;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .node-finder-result small {\n grid-column: 1 / -1;\n overflow: hidden;\n color: var(--text-faint);\n font-size: 0.5625rem;\n letter-spacing: 0.015em;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .node-finder-result em {\n align-self: center;\n color: var(--frontend-stroke);\n font-size: 0.625rem;\n font-style: normal;\n }\n .node-finder[data-context^=\"route-\"] .node-finder-result em {\n padding: 0.1rem 0.3rem;\n border: 1px solid color-mix(in srgb, currentColor 52%, transparent);\n border-radius: 999px;\n font-size: 0.5rem;\n font-weight: 800;\n letter-spacing: 0.05em;\n text-transform: uppercase;\n }\n .node-finder[data-context=\"route-target\"] .node-finder-result em { color: var(--security-stroke); }\n .node-finder-empty {\n padding: 1.1rem 0.75rem 1.25rem;\n color: var(--text-faint);\n font-size: 0.6875rem;\n text-align: center;\n }\n .node-finder-status {\n margin: 0;\n padding: 0.1rem 0.8rem 0.65rem;\n color: var(--text-faint);\n font-size: 0.5625rem;\n }\n\n .cards {\n display: grid;\n grid-template-columns: repeat(auto-fit, minmax(min(15rem, 100%), 1fr));\n gap: 1rem;\n margin-top: 2rem;\n }\n\n .card {\n background: var(--panel);\n border-radius: 0.75rem;\n border: 1px solid var(--panel-border);\n padding: 1.125rem 1.25rem;\n /* Card notes are authored prose and may carry an unbreakable run such as a\n slash-joined pipeline or a long identifier. Without this, that run sets the\n card's min-content width, spills past its track in every rail placement,\n and pushes the whole page into horizontal overflow at desktop widths.\n `anywhere` rather than `break-word` because only `anywhere` shrinks the\n intrinsic minimum the layout is sized from. */\n overflow-wrap: anywhere;\n }\n\n html[data-preset=\"signal-flow\"] .card {\n background: linear-gradient(145deg, rgba(10, 24, 43, 0.86), rgba(5, 12, 24, 0.92));\n box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035);\n }\n html[data-preset=\"signal-flow\"][data-theme=\"light\"] .card {\n background: linear-gradient(145deg, rgba(255, 255, 255, 0.92), rgba(237, 246, 250, 0.9));\n box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.82), 0 12px 32px rgba(45, 78, 99, 0.08);\n }\n\n /* Preserve the one-screen guarantee on ordinary laptop displays. The\n high-screen expansion above must not trade a fuller canvas for page\n scrolling at 900–1080px heights. */\n @media (min-width: 768px) and (max-height: 1100px) {\n .header { margin-bottom: 1rem; }\n .diagram-container {\n padding: 0.875rem;\n padding-bottom: calc(0.875rem + var(--archify-nav-reserve));\n }\n .cards { margin-top: 1rem; }\n .card { padding: 1rem; }\n }\n @media (min-width: 768px) and (max-height: 920px) {\n body { padding-block: 1.25rem; }\n body { --archify-page-top: 1.25rem; }\n .header { margin-bottom: 0.875rem; }\n .cards { margin-top: 0.75rem; }\n html[data-nav-stage-rail=\"true\"] body { padding-block: 0.375rem; }\n /* Align the fixed toolbar with the compact title row. Reserve its hit area\n above the guide without taking extra height from a fitted diagram. */\n html[data-nav-stage-rail=\"true\"] .toolbar { top: 0.25rem; }\n html[data-nav-stage-rail=\"true\"] .header { min-height: 2.625rem; margin-bottom: 0.5rem; }\n html[data-nav-stage-rail=\"true\"] .diagram-container[data-nav-stage-rail=\"true\"] { padding-top: 0.5rem; }\n html[data-nav-stage-rail=\"true\"] .cards { margin-top: 0.375rem; }\n }\n\n html[data-preset=\"blueprint\"] .card {\n position: relative;\n border-color: var(--panel-border);\n border-radius: 0.3rem;\n background: var(--panel);\n box-shadow: none;\n }\n html[data-preset=\"blueprint\"] .card::before {\n content: \"\";\n position: absolute;\n top: -1px;\n left: 1rem;\n width: 2.5rem;\n border-top: 2px solid var(--frontend-stroke);\n }\n\n html[data-preset=\"editorial\"] .card {\n position: relative;\n border-radius: 0.28rem;\n background: var(--panel);\n box-shadow: 0 10px 28px color-mix(in srgb, #000 10%, transparent);\n }\n html[data-preset=\"editorial\"] .card::before {\n position: absolute;\n top: -1px;\n left: 1.25rem;\n width: 3.25rem;\n border-top: 3px solid var(--arrow-emphasis);\n content: \"\";\n }\n html[data-preset=\"editorial\"] .card-dot { border-radius: 0; transform: rotate(45deg) scale(0.78); }\n\n /* Summary rail: the reader measures the viewport and enables it only when the\n diagram keeps its readable width beside the notes. */\n .reader-rail { display: contents; }\n html[data-reader-rail=\"true\"] .container {\n display: grid;\n grid-template-columns: minmax(0, 1fr) var(--archify-rail-width);\n grid-auto-flow: row dense;\n column-gap: var(--archify-rail-gap);\n align-items: start;\n }\n html[data-reader-rail=\"true\"] .container \u003e .header { grid-column: 1 / -1; }\n html[data-reader-rail=\"true\"] .container \u003e .diagram-container { grid-column: 1; }\n /* The rail is at least the diagram's height and may run on to the viewport\n floor (--archify-rail-max, set by the reader); past that, notes scroll and\n the index keeps a usable share instead of collapsing to its header. */\n html[data-reader-rail=\"true\"] .reader-rail {\n display: flex;\n flex-direction: column;\n grid-column: 2;\n align-self: stretch;\n min-height: 0;\n max-height: var(--archify-rail-max, none);\n }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards:empty { display: none; }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards {\n display: flex;\n flex: 0 1 auto;\n flex-direction: column;\n gap: 0;\n min-height: 0;\n margin-top: 0;\n padding: 0.125rem 0 0;\n overflow-y: auto;\n scrollbar-width: none;\n -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - 1.25rem), transparent);\n mask-image: linear-gradient(to bottom, #000 calc(100% - 1.25rem), transparent);\n }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards::-webkit-scrollbar { display: none; }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards .card { flex: none; }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards .card {\n padding: 0 0.25rem 1.125rem;\n border: 0;\n border-radius: 0;\n background: transparent;\n box-shadow: none;\n }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards .card + .card {\n padding-top: 1.125rem;\n border-top: 1px solid var(--panel-border);\n }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards .card::before { display: none; }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .card-header { gap: 0.55rem; margin-bottom: 0.45rem; }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards .card h3 { font-size: 0.875rem; letter-spacing: -0.005em; }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards .card ul { font-size: 0.8125rem; line-height: 1.6; }\n\n .node-outline { display: none; }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .node-outline:not([hidden]) {\n display: flex;\n flex: 1 0 min(13rem, 55%);\n flex-direction: column;\n min-height: 0;\n margin-top: 0.25rem;\n overflow: hidden;\n border-top: 1px solid var(--panel-border);\n }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"]) .cards:empty + .node-outline:not([hidden]) { margin-top: 0; border-top: 0; }\n /* Collapsed: only the reveal control remains, so the diagram takes the width. */\n html[data-reader-rail=\"collapsed\"] .reader-rail { display: none; }\n /* Overlay: a drawer for diagrams whose readable floor leaves no room to dock. */\n html[data-reader-rail=\"overlay\"] .reader-rail {\n position: fixed;\n z-index: 150;\n top: 1rem;\n right: 1rem;\n bottom: 1rem;\n display: flex;\n flex-direction: column;\n width: var(--archify-rail-width);\n padding: 0.75rem 1rem 0.5rem;\n border: 1px solid color-mix(in srgb, var(--panel-border) 90%, transparent);\n border-radius: 1rem;\n background: var(--toolbar-menu-bg);\n box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06), 0 28px 64px -18px rgba(15, 23, 42, 0.38);\n animation: rail-drawer-in 0.2s cubic-bezier(0.22, 1, 0.36, 1);\n }\n @keyframes rail-drawer-in {\n from { opacity: 0; transform: translateX(0.75rem); }\n to { opacity: 1; transform: translateX(0); }\n }\n /* Bottom (default): the notes keep their full-width card row and the index\n follows as one panel whose groups flow into columns, so nothing scrolls\n inside it. The placement toggle sits in the index header. */\n html[data-reader-rail=\"bottom\"] .reader-rail {\n display: grid;\n grid-template-areas: \"cards\" \"index\";\n grid-template-columns: minmax(0, 1fr);\n row-gap: 1rem;\n margin-top: 1rem;\n }\n html[data-reader-rail=\"bottom\"] .cards { grid-area: cards; margin-top: 0; }\n html[data-reader-rail=\"bottom\"] .cards:empty { display: none; }\n html[data-reader-rail=\"bottom\"] .node-outline:not([hidden]) {\n display: block;\n grid-area: index;\n padding: 0 1.25rem 0.75rem;\n border: 1px solid var(--panel-border);\n border-radius: 0.75rem;\n background: var(--panel);\n }\n html[data-reader-rail=\"bottom\"] .reader-rail \u003e .rail-controls {\n z-index: 1;\n grid-area: index;\n align-self: start;\n justify-self: end;\n margin: 0.625rem 0.625rem 0 0;\n }\n html[data-reader-rail=\"bottom\"] .node-outline-head { padding: 1rem 2.5rem 0.375rem 0.25rem; }\n html[data-reader-rail=\"bottom\"] .node-outline-list {\n columns: 15rem;\n column-gap: 1.75rem;\n padding: 0;\n overflow: visible;\n -webkit-mask-image: none;\n mask-image: none;\n }\n /* Named groups stay whole; a single unnamed group may split across columns,\n where a continuous spine would read as a broken line. */\n html[data-reader-rail=\"bottom\"] .node-outline-group + .node-outline-group { margin-top: 0; }\n html[data-reader-rail=\"bottom\"] .node-outline-group:has(\u003e .node-outline-heading) { break-inside: avoid; padding-bottom: 0.25rem; }\n html[data-reader-rail=\"bottom\"] .node-outline-group:not(:has(\u003e .node-outline-heading)) \u003e ul::before { display: none; }\n html[data-reader-rail=\"bottom\"] .node-outline-group li { break-inside: avoid; }\n .rail-controls { display: none; }\n html:is([data-reader-rail=\"true\"], [data-reader-rail=\"overlay\"], [data-reader-rail=\"bottom\"]) .rail-controls {\n display: flex;\n flex: none;\n justify-content: flex-end;\n gap: 0.125rem;\n margin: -0.25rem -0.25rem 0.25rem 0;\n }\n .rail-control {\n display: inline-grid;\n place-items: center;\n width: 1.875rem;\n height: 1.875rem;\n border: 0;\n border-radius: 0.5rem;\n background: transparent;\n color: var(--text-faint);\n cursor: pointer;\n transition: background 0.14s ease, color 0.14s ease;\n }\n .rail-control[hidden] { display: none; }\n .rail-control:hover,\n .rail-control:focus-visible { color: var(--text); background: color-mix(in srgb, var(--text) 6%, transparent); }\n .rail-control:focus-visible { outline: 1.5px solid color-mix(in srgb, var(--frontend-stroke) 60%, transparent); outline-offset: -1.5px; }\n .rail-control-icon,\n .rail-reveal-icon {\n width: 1rem;\n height: 1rem;\n background: currentColor;\n -webkit-mask: var(--rail-glyph) center / contain no-repeat;\n mask: var(--rail-glyph) center / contain no-repeat;\n }\n /* Panel glyphs: a frame with the panel drawn on the side it moves to. */\n .rail-control-icon.placement,\n #rail-placement[data-placement=\"right\"] .rail-control-icon { --rail-glyph: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cg fill='none' stroke='black' stroke-width='1.6'%3E%3Crect x='2.8' y='3.8' width='14.4' height='12.4' rx='2'/%3E%3Cpath d='M2.8 12h14.4'/%3E%3C/g%3E%3C/svg%3E\"); }\n #rail-placement[data-placement=\"bottom\"] .rail-control-icon { --rail-glyph: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cg fill='none' stroke='black' stroke-width='1.6'%3E%3Crect x='2.8' y='3.8' width='14.4' height='12.4' rx='2'/%3E%3Cpath d='M12.6 3.8v12.4'/%3E%3C/g%3E%3C/svg%3E\"); }\n .rail-control-icon.collapse { --rail-glyph: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='m8 5.5 4.5 4.5L8 14.5' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E\"); }\n .rail-reveal-icon { --rail-glyph: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cg fill='none' stroke='black' stroke-width='1.6'%3E%3Crect x='2.8' y='3.8' width='14.4' height='12.4' rx='2'/%3E%3Cpath d='M12.6 3.8v12.4M14.4 7.2h1M14.4 9.6h1M14.4 12h1'/%3E%3C/g%3E%3C/svg%3E\"); }\n .rail-reveal[hidden] { display: none; }\n /* The collapsed rail leaves one quiet pill in the canvas corner. */\n .rail-reveal {\n position: absolute;\n z-index: 13;\n top: 0.75rem;\n right: 0.75rem;\n display: inline-flex;\n align-items: center;\n gap: 0.45rem;\n min-height: 2rem;\n padding: 0 0.75rem 0 0.625rem;\n border: 1px solid color-mix(in srgb, var(--panel-border) 85%, transparent);\n border-radius: 999px;\n background: color-mix(in srgb, var(--panel) 86%, transparent);\n color: var(--text-muted);\n box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05), 0 8px 20px -12px rgba(15, 23, 42, 0.28);\n backdrop-filter: blur(12px);\n font: inherit;\n font-size: 0.75rem;\n font-weight: 500;\n cursor: pointer;\n transition: color 0.14s ease, background 0.14s ease;\n }\n .rail-reveal:hover,\n .rail-reveal:focus-visible { color: var(--text); background: var(--panel); }\n .rail-reveal:focus-visible { outline: 1.5px solid color-mix(in srgb, var(--frontend-stroke) 60%, transparent); outline-offset: 2px; }\n html[data-motion=\"still\"] .reader-rail { animation: none !important; }\n .node-outline-head {\n display: flex;\n align-items: center;\n gap: 0.5rem;\n padding: 1.125rem 0.25rem 0.375rem;\n }\n .node-outline-head strong {\n color: var(--text);\n font-size: 0.875rem;\n font-weight: 600;\n letter-spacing: -0.005em;\n }\n .node-outline-count {\n min-width: 1.35rem;\n padding: 0.1rem 0.4rem;\n border-radius: 999px;\n background: color-mix(in srgb, var(--text) 6%, transparent);\n color: var(--text-muted);\n font-size: 0.6875rem;\n font-weight: 600;\n line-height: 1.3;\n text-align: center;\n font-variant-numeric: tabular-nums;\n }\n .node-outline-list {\n flex: 1 1 auto;\n min-height: 0;\n margin: 0 -0.375rem;\n padding: 0 0 1.25rem;\n overflow-y: auto;\n list-style: none;\n scrollbar-width: none;\n -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - 2rem), transparent);\n mask-image: linear-gradient(to bottom, #000 calc(100% - 2rem), transparent);\n }\n .node-outline-list::-webkit-scrollbar { display: none; }\n .node-outline-group + .node-outline-group { margin-top: 0.25rem; }\n .node-outline-group \u003e ul {\n position: relative;\n list-style: none;\n }\n /* A quiet spine ties each group's swatches together like a lane. */\n .node-outline-group \u003e ul::before {\n position: absolute;\n top: 0.95rem;\n bottom: 0.95rem;\n left: calc(0.625rem + 0.3125rem - 0.5px);\n width: 1px;\n background: var(--panel-border);\n content: \"\";\n }\n .node-outline-heading {\n display: flex;\n align-items: baseline;\n justify-content: space-between;\n padding: 0.7rem 0.625rem 0.25rem;\n color: var(--text-faint);\n font-size: 0.6875rem;\n font-weight: 600;\n letter-spacing: 0.02em;\n }\n .node-outline-heading small {\n color: var(--text-dim);\n font-size: 0.6875rem;\n font-weight: 500;\n font-variant-numeric: tabular-nums;\n }\n /* The rail frees the vertical budget, so compact viewports keep the normal\n title spacing instead of the stacked layout's tight stage rail. */\n html[data-reader-rail]:not([data-reader-rail=\"bottom\"]) body { --archify-page-top: 1.5rem; padding-block: 1.5rem; }\n html[data-reader-rail]:not([data-reader-rail=\"bottom\"]) .toolbar { top: calc(var(--archify-page-top) - 0.1875rem); }\n html[data-reader-rail]:not([data-reader-rail=\"bottom\"]) .header { min-height: 0; margin-bottom: 1.125rem; }\n .node-outline-item {\n position: relative;\n display: grid;\n grid-template-columns: 0.625rem minmax(0, auto) minmax(0, 1fr) 0.75rem;\n align-items: center;\n column-gap: 0.625rem;\n width: 100%;\n min-height: 1.95rem;\n padding: 0.28rem 0.5rem 0.28rem 0.625rem;\n border: 0;\n border-radius: 0.5rem;\n background: transparent;\n color: var(--text);\n font: inherit;\n text-align: left;\n cursor: pointer;\n transition: background 0.16s ease;\n }\n /* Trailing chevron hints that a click focuses the node. */\n .node-outline-item::after {\n grid-column: 4;\n width: 0.75rem;\n height: 0.75rem;\n background: currentColor;\n color: var(--text-muted);\n content: \"\";\n opacity: 0;\n transform: translateX(-3px);\n transition: opacity 0.16s ease, transform 0.16s ease;\n -webkit-mask: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='m4.5 3 3 3-3 3' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E\") center / contain no-repeat;\n mask: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='m4.5 3 3 3-3 3' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E\") center / contain no-repeat;\n }\n .node-outline-item:hover,\n .node-outline-item:focus-visible,\n .node-outline-item[data-previewing] { background: color-mix(in srgb, var(--text) 4.5%, transparent); }\n .node-outline-item:hover::after,\n .node-outline-item:focus-visible::after { opacity: 0.7; transform: translateX(0); }\n .node-outline-item:focus-visible { outline: 1.5px solid color-mix(in srgb, var(--outline-tone) 60%, transparent); outline-offset: -1.5px; }\n .node-outline-item[aria-current=\"true\"] { background: color-mix(in srgb, var(--outline-tone) 10%, transparent); }\n .node-outline-item[aria-current=\"true\"]::after { opacity: 0; }\n /* Swatches echo the diagram's node cards: tinted fill, hairline stroke. */\n .node-outline-dot {\n width: 0.625rem;\n height: 0.5rem;\n border: 1.25px solid var(--outline-tone);\n border-radius: 0.15rem;\n background: color-mix(in srgb, var(--outline-tone) 16%, var(--bg));\n transition: background 0.16s ease, transform 0.16s ease, box-shadow 0.16s ease;\n }\n .node-outline-item:hover .node-outline-dot,\n .node-outline-item:focus-visible .node-outline-dot,\n .node-outline-item[data-previewing] .node-outline-dot,\n .node-outline-item[aria-current=\"true\"] .node-outline-dot {\n background: var(--outline-tone);\n box-shadow: 0 0 0 3px color-mix(in srgb, var(--outline-tone) 18%, transparent);\n transform: scale(1.08);\n }\n .node-outline-item strong {\n overflow: hidden;\n font-size: 0.8125rem;\n font-weight: 500;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .node-outline-item[aria-current=\"true\"] strong { font-weight: 600; }\n .node-outline-item small {\n overflow: hidden;\n color: var(--text-faint);\n font-size: 0.6875rem;\n text-align: right;\n text-overflow: ellipsis;\n white-space: nowrap;\n transition: color 0.16s ease;\n }\n .node-outline-item:hover small,\n .node-outline-item[data-previewing] small,\n .node-outline-item[aria-current=\"true\"] small { color: var(--text-muted); }\n\n .card-header {\n display: flex;\n align-items: center;\n gap: 0.5rem;\n margin-bottom: 0.625rem;\n }\n\n .card-dot {\n flex: none;\n width: 8px;\n height: 8px;\n border-radius: 50%;\n }\n\n .card-dot.cyan { background: var(--frontend-stroke); }\n .card-dot.emerald { background: var(--backend-stroke); }\n .card-dot.violet { background: var(--database-stroke); }\n .card-dot.amber { background: var(--cloud-stroke); }\n .card-dot.rose { background: var(--security-stroke); }\n .card-dot.orange { background: var(--messagebus-stroke); }\n .card-dot.slate { background: var(--external-stroke); }\n\n .card h3 { font-size: 0.9375rem; font-weight: 600; line-height: 1.4; color: var(--text); }\n\n .card ul {\n list-style: none;\n color: var(--text-muted);\n font-size: 0.8125rem;\n line-height: 1.6;\n }\n\n .card li {\n position: relative;\n margin-bottom: 0.3rem;\n padding-left: 0.9rem;\n }\n .card li:last-child { margin-bottom: 0; }\n /* Hanging markers take the card's tone so wrapped lines align under text. */\n .card li::before {\n position: absolute;\n top: calc(0.8em - 2px);\n left: 0.2rem;\n width: 4px;\n height: 4px;\n border-radius: 50%;\n background: color-mix(in srgb, var(--card-tone, var(--text-muted)) 70%, transparent);\n content: \"\";\n }\n .card:has(.card-dot.cyan) { --card-tone: var(--frontend-stroke); }\n .card:has(.card-dot.emerald) { --card-tone: var(--backend-stroke); }\n .card:has(.card-dot.violet) { --card-tone: var(--database-stroke); }\n .card:has(.card-dot.amber) { --card-tone: var(--cloud-stroke); }\n .card:has(.card-dot.rose) { --card-tone: var(--security-stroke); }\n .card:has(.card-dot.orange) { --card-tone: var(--messagebus-stroke); }\n .card:has(.card-dot.slate) { --card-tone: var(--external-stroke); }\n .card-dot { box-shadow: 0 0 0 3px color-mix(in srgb, var(--card-tone, transparent) 16%, transparent); }\n\n /* ==========================================================\n Print stylesheet — hide interactive controls, force light,\n drop the grid so the diagram doesn't waste ink, use landscape\n so wide diagrams fit, pack summary cards into 2 columns to\n avoid an orphan card on a trailing page.\n ========================================================== */\n @page { size: landscape; margin: 1.5cm; }\n\n @media print {\n /* Force the FULL light palette — including component fills/strokes and\n lane/arrow colors — so printing from dark theme doesn't put neon\n strokes and translucent dark fills on white paper. */\n :root, [data-theme=\"dark\"], [data-theme=\"light\"] {\n --bg: #ffffff;\n --grid: transparent;\n --panel: #ffffff;\n --panel-border: #e2e8f0;\n --text: #0f172a;\n --text-muted: #475569;\n --text-dim: #94a3b8;\n --text-faint: #64748b;\n --mask: #ffffff;\n --lane-fill: rgba(248, 250, 252, 0.65);\n --lane-stroke: #cbd5e1;\n --arrow: #94a3b8;\n --arrow-emphasis: #059669;\n --frontend-fill: rgba(34, 211, 238, 0.15);\n --frontend-stroke: #0891b2;\n --backend-fill: rgba(52, 211, 153, 0.18);\n --backend-stroke: #059669;\n --database-fill: rgba(167, 139, 250, 0.2);\n --database-stroke: #7c3aed;\n --cloud-fill: rgba(251, 191, 36, 0.18);\n --cloud-stroke: #d97706;\n --security-fill: rgba(251, 113, 133, 0.15);\n --security-stroke: #e11d48;\n --messagebus-fill: rgba(251, 146, 60, 0.15);\n --messagebus-stroke:#ea580c;\n --external-fill: rgba(148, 163, 184, 0.18);\n --external-stroke: #64748b;\n }\n body { background: #ffffff !important; padding: 0; }\n .container { max-width: none; }\n .toolbar, .diagram-nav, .focus-chip, .archify-toast, .no-print { display: none !important; }\n \n .diagram-container, .card { box-shadow: none; border-color: #e2e8f0; }\n .diagram-container { --archify-nav-reserve: 0px !important; }\n html[data-preset=\"signal-flow\"] .diagram-container,\n html[data-preset=\"signal-flow\"] .card { background: #ffffff; }\n .cards { grid-template-columns: 1fr 1fr; }\n /* Ensure elements break sensibly across pages */\n .card { break-inside: avoid; page-break-inside: avoid; }\n .diagram-container { break-inside: avoid; page-break-inside: avoid; }\n .diagram-container svg [data-detail] {\n opacity: 1 !important;\n pointer-events: auto !important;\n }\n .diagram-container svg [data-detail-anchor] { transform: none !important; }\n .diagram-container svg[data-lens-active] [data-node-id],\n .diagram-container svg[data-lens-active] [data-edge-from],\n .diagram-container svg[data-legend-preview-active] [data-node-id],\n .diagram-container svg[data-legend-preview-active] [data-edge-from] {\n opacity: 1 !important;\n filter: none !important;\n }\n [data-legend-bridge-runtime] { display: none !important; }\n .semantic-lens-overlay { display: none !important; }\n .relationship-hit-overlay { display: none !important; }\n .relationship-pulse-overlay { display: none !important; }\n .route-probe-overlay, .route-journey-overlay { display: none !important; }\n .diagram-container svg[data-focus-active] [data-node-id],\n .diagram-container svg[data-focus-active] [data-edge-from],\n .diagram-container svg[data-focus-active] [data-graph-role=\"automatic-crossover-underlay\"],\n .diagram-container svg[data-reach-active] [data-node-id],\n .diagram-container svg[data-reach-active] [data-edge-from],\n .diagram-container svg[data-reach-active] [data-graph-role=\"automatic-crossover-underlay\"],\n .diagram-container svg[data-route-active] [data-node-id],\n .diagram-container svg[data-route-active] [data-edge-from],\n .diagram-container svg[data-route-active] [data-graph-role=\"automatic-crossover-underlay\"] {\n opacity: 1 !important;\n filter: none !important;\n animation: none !important;\n }\n h1, .subtitle { color: #0f172a; }\n }\n\n /* ==========================================================\n TOOLBAR (theme toggle + export menu)\n ========================================================== */\n /* The toolbar tracks the centered reader column and the title row, so\n an adaptive narrow reader does not leave its controls stranded at the\n viewport edge. */\n .toolbar {\n position: absolute;\n top: var(--archify-page-top);\n right: max(1rem, calc((100vw - min(100vw - 4rem, var(--archify-reader-width, 1440px))) / 2));\n display: flex;\n align-items: center;\n gap: 0.125rem;\n padding: 0;\n border: 0;\n background: transparent;\n box-shadow: none;\n z-index: 100;\n }\n /* Ghost controls keep a 44px hit area while the visible pill stays compact;\n Export is the one primary action. */\n .toolbar button {\n position: relative;\n isolation: isolate;\n background: transparent;\n color: var(--text-muted);\n border: 0;\n padding: 0.5rem 0.75rem;\n border-radius: 0.5625rem;\n font-family: inherit;\n font-size: 0.8125rem;\n font-weight: 500;\n cursor: pointer;\n white-space: nowrap;\n box-shadow: none;\n transition: color 0.15s;\n display: inline-flex;\n align-items: center;\n gap: 0.4rem;\n min-height: 2.75rem;\n }\n .toolbar button::before {\n position: absolute;\n z-index: -1;\n inset: 0.375rem 0;\n border-radius: 0.5rem;\n background: transparent;\n content: \"\";\n transition: background 0.15s, box-shadow 0.15s;\n }\n .toolbar button:hover { color: var(--text); }\n .toolbar button:hover::before { background: color-mix(in srgb, var(--text) 6%, transparent); }\n .toolbar button[aria-expanded=\"true\"],\n .toolbar button[aria-pressed=\"true\"]:not(#btn-theme) { color: var(--text); }\n .toolbar button[aria-expanded=\"true\"]::before,\n .toolbar button[aria-pressed=\"true\"]:not(#btn-theme)::before {\n background: color-mix(in srgb, var(--text) 8%, transparent);\n }\n .toolbar #btn-export {\n margin-left: 0.375rem;\n padding-right: 0.95rem;\n padding-left: 1rem;\n color: var(--bg);\n font-weight: 550;\n }\n .toolbar #btn-export::before {\n background: var(--text);\n box-shadow: 0 1px 2px rgba(15, 23, 42, 0.12), 0 6px 16px -8px rgba(15, 23, 42, 0.4);\n }\n .toolbar #btn-export:hover,\n .toolbar #btn-export[aria-expanded=\"true\"] { color: var(--bg); }\n .toolbar #btn-export:hover::before,\n .toolbar #btn-export[aria-expanded=\"true\"]::before { background: color-mix(in srgb, var(--text) 86%, var(--bg)); }\n .toolbar button:focus-visible {\n outline: 2px solid var(--frontend-stroke);\n outline-offset: -4px;\n }\n .toolbar { gap: 0.5rem; }\n .toolbar #btn-export { margin-left: 0; }\n .toolbar #btn-export::before { inset: 0.25rem 0; border-radius: 0.6875rem; }\n /* Tools share one quiet capsule; the capsule is drawn inside the 44px row\n so the controls keep their hit area without a tall visible box. */\n .toolbar-group {\n position: relative;\n isolation: isolate;\n display: flex;\n align-items: center;\n gap: 0.0625rem;\n padding: 0 0.25rem;\n }\n .toolbar-group::before {\n position: absolute;\n z-index: -1;\n inset: 0.25rem 0;\n border: 1px solid color-mix(in srgb, var(--panel-border) 85%, transparent);\n border-radius: 0.6875rem;\n background: color-mix(in srgb, var(--panel) 78%, transparent);\n box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 8px 20px -14px rgba(15, 23, 42, 0.22);\n backdrop-filter: blur(12px);\n content: \"\";\n }\n .toolbar-group button { padding-inline: 0.625rem; }\n .toolbar-group button::before { inset: 0.5rem 0; border-radius: 0.5rem; }\n /* Theme becomes a sliding switch; its label stays for assistive tech. */\n .toolbar #theme-label,\n .toolbar #present-label {\n position: absolute;\n width: 1px;\n height: 1px;\n overflow: hidden;\n clip: rect(0 0 0 0);\n white-space: nowrap;\n }\n .toolbar #btn-theme {\n width: 3.5rem;\n padding: 0;\n justify-content: center;\n }\n .toolbar #btn-theme::before {\n inset: 0.75rem 0.4375rem;\n border-radius: 999px;\n background: color-mix(in srgb, var(--text) 9%, transparent);\n box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.08);\n }\n .toolbar #btn-theme:hover::before { background: color-mix(in srgb, var(--text) 13%, transparent); }\n .toolbar #btn-theme::after {\n position: absolute;\n z-index: 0;\n top: 50%;\n left: 0.5625rem;\n width: 1.125rem;\n height: 1.125rem;\n border-radius: 50%;\n background: var(--panel);\n box-shadow: 0 1px 2px rgba(15, 23, 42, 0.18), 0 2px 6px rgba(15, 23, 42, 0.12);\n content: \"\";\n transform: translateY(-50%);\n transition: left 0.22s cubic-bezier(0.22, 1, 0.36, 1);\n }\n .toolbar #theme-icon {\n position: absolute;\n z-index: 1;\n top: 50%;\n left: calc(0.5625rem + 0.1875rem);\n width: 0.75rem;\n height: 0.75rem;\n color: var(--cloud-stroke);\n transform: translateY(-50%);\n transition: left 0.22s cubic-bezier(0.22, 1, 0.36, 1);\n }\n [data-theme=\"dark\"] .toolbar #btn-theme::before { background: rgba(148, 163, 184, 0.16); }\n [data-theme=\"dark\"] .toolbar #btn-theme::after { left: calc(100% - 0.5625rem - 1.125rem); background: #3b4a63; box-shadow: 0 1px 3px rgba(0, 0, 0, 0.4); }\n [data-theme=\"dark\"] .toolbar #theme-icon { left: calc(100% - 0.5625rem - 1.125rem + 0.1875rem); color: #c7d2fe; }\n .toolbar #btn-present { width: 2.5rem; padding: 0; justify-content: center; }\n .toolbar #btn-present .toolbar-icon { width: 1rem; height: 1rem; }\n html[data-motion=\"still\"] .toolbar #btn-theme::after,\n html[data-motion=\"still\"] .toolbar #theme-icon { transition: none; }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .toolbar { right: 1rem; }\n html[data-preset=\"editorial\"] .toolbar { border-radius: 0.45rem; }\n .toolbar #btn-motion[hidden] { display: none !important; }\n .toolbar #btn-motion { min-width: 4.4rem; }\n .toolbar #btn-motion:disabled { cursor: default; opacity: 0.58; }\n .toolbar .preset-wrap,\n .toolbar .export-wrap {\n position: relative;\n }\n .toolbar-icon {\n display: inline-block;\n width: 0.95rem;\n height: 0.95rem;\n flex: 0 0 auto;\n background: currentColor;\n -webkit-mask-position: center;\n -webkit-mask-repeat: no-repeat;\n -webkit-mask-size: contain;\n mask-position: center;\n mask-repeat: no-repeat;\n mask-size: contain;\n }\n .toolbar-chevron {\n width: 0.65rem;\n height: 0.65rem;\n transition: transform 0.15s ease;\n }\n [aria-expanded=\"true\"] \u003e .toolbar-chevron { transform: rotate(180deg); }\n [data-theme=\"light\"] #theme-icon {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cg fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round'%3E%3Ccircle cx='10' cy='10' r='3.1'/%3E%3Cpath d='M10 2.2v1.4M10 16.4v1.4M2.2 10h1.4M16.4 10h1.4M4.5 4.5l1 1M14.5 14.5l1 1M15.5 4.5l-1 1M5.5 14.5l-1 1'/%3E%3C/g%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cg fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round'%3E%3Ccircle cx='10' cy='10' r='3.1'/%3E%3Cpath d='M10 2.2v1.4M10 16.4v1.4M2.2 10h1.4M16.4 10h1.4M4.5 4.5l1 1M14.5 14.5l1 1M15.5 4.5l-1 1M5.5 14.5l-1 1'/%3E%3C/g%3E%3C/svg%3E\");\n }\n [data-theme=\"dark\"] #theme-icon {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M15.2 12.7A6.3 6.3 0 017.3 4.8a6.3 6.3 0 107.9 7.9Z' fill='none' stroke='black' stroke-width='1.7' stroke-linejoin='round'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M15.2 12.7A6.3 6.3 0 017.3 4.8a6.3 6.3 0 107.9 7.9Z' fill='none' stroke='black' stroke-width='1.7' stroke-linejoin='round'/%3E%3C/svg%3E\");\n }\n #btn-present[aria-pressed=\"false\"] #present-icon {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M7.2 3.2h-4v4M12.8 3.2h4v4M7.2 16.8h-4v-4M12.8 16.8h4v-4' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M7.2 3.2h-4v4M12.8 3.2h4v4M7.2 16.8h-4v-4M12.8 16.8h4v-4' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round'/%3E%3C/svg%3E\");\n }\n #btn-present[aria-pressed=\"true\"] #present-icon {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M7.2 7.2h-4v-4M12.8 7.2h4v-4M7.2 12.8h-4v4M12.8 12.8h4v4' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M7.2 7.2h-4v-4M12.8 7.2h4v-4M7.2 12.8h-4v4M12.8 12.8h4v4' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round'/%3E%3C/svg%3E\");\n }\n .toolbar-chevron {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='m3 4.5 3 3 3-3' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='m3 4.5 3 3 3-3' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E\");\n }\n .toolbar #btn-preset { min-width: 5.4rem; }\n .preset-control-mark {\n width: 0.58rem;\n height: 0.58rem;\n flex: 0 0 auto;\n border: 1px solid var(--frontend-stroke);\n border-radius: 0.2rem;\n background: color-mix(in srgb, var(--frontend-stroke) 28%, transparent);\n transition: border-radius 0.15s, box-shadow 0.15s, transform 0.15s;\n }\n #btn-preset[data-preset-option=\"signal-flow\"] .preset-control-mark {\n border-radius: 50%;\n box-shadow: 0 0 10px color-mix(in srgb, var(--frontend-stroke) 78%, transparent);\n }\n #btn-preset[data-preset-option=\"blueprint\"] .preset-control-mark {\n border-radius: 0.06rem;\n background: transparent;\n box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--frontend-stroke) 32%, transparent);\n transform: rotate(45deg) scale(0.84);\n }\n #btn-preset[data-preset-option=\"editorial\"] .preset-control-mark {\n border-color: var(--arrow-emphasis);\n border-radius: 0;\n background: var(--arrow-emphasis);\n box-shadow: 0 0 0 2px color-mix(in srgb, var(--arrow-emphasis) 14%, transparent);\n transform: rotate(45deg) scale(0.72);\n }\n /* Menus anchor to the tools capsule so they open flush under it. */\n .toolbar-group .preset-wrap { position: static; }\n .toolbar .preset-menu {\n position: absolute;\n top: calc(100% + 0.125rem);\n right: 0;\n display: none;\n width: 17.5rem;\n max-width: calc(100vw - 2rem);\n padding: 0.375rem;\n border: 1px solid color-mix(in srgb, var(--panel-border) 90%, transparent);\n border-radius: 0.875rem;\n background: var(--toolbar-menu-bg);\n box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06), 0 18px 44px -14px rgba(15, 23, 42, 0.3);\n }\n [data-theme=\"dark\"] .toolbar .preset-menu,\n [data-theme=\"dark\"] .toolbar .export-menu {\n border-color: rgba(148, 163, 184, 0.16);\n box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 18px 44px -12px rgba(0, 0, 0, 0.6);\n }\n /* Menu rows are not toolbar pills: drop the ghost-button pseudo surface. */\n .toolbar .preset-menu button,\n .toolbar .export-menu button { isolation: auto; min-height: 0; }\n .toolbar .preset-menu button::before { display: none; }\n .toolbar .preset-menu.open { display: block; }\n .toolbar .preset-menu.open,\n .toolbar .export-menu.open {\n animation: toolbar-menu-in 0.16s cubic-bezier(0.2, 0.8, 0.2, 1);\n transform-origin: top right;\n }\n @keyframes toolbar-menu-in {\n from { opacity: 0; transform: translateY(-0.25rem) scale(0.985); }\n to { opacity: 1; transform: translateY(0) scale(1); }\n }\n .preset-menu-heading {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: 1rem;\n padding: 0.45rem 0.55rem 0.4rem;\n color: var(--text-faint);\n font-size: 0.6875rem;\n font-weight: 600;\n letter-spacing: 0.01em;\n }\n .preset-menu-shortcut {\n display: inline-flex;\n align-items: center;\n gap: 0.35rem;\n font-weight: 500;\n }\n .preset-menu-shortcut kbd {\n min-width: 1.125rem;\n padding: 0.05rem 0.3rem;\n border: 1px solid var(--panel-border);\n border-bottom-width: 2px;\n border-radius: 0.3rem;\n background: color-mix(in srgb, var(--text) 3%, var(--toolbar-menu-bg));\n color: var(--text-muted);\n font-family: inherit;\n font-size: 0.625rem;\n font-weight: 600;\n line-height: 1.3;\n text-align: center;\n }\n .toolbar .preset-option {\n display: grid;\n grid-template-columns: 2.375rem minmax(0, 1fr) 1rem;\n align-items: center;\n gap: 0.75rem;\n width: 100%;\n min-height: 3.125rem;\n margin-top: 0.125rem;\n padding: 0.45rem 0.6rem 0.45rem 0.5rem;\n border: 0;\n border-radius: 0.625rem;\n background: transparent;\n color: var(--text);\n box-shadow: none;\n backdrop-filter: none;\n text-align: left;\n transition: background 0.14s ease;\n }\n .toolbar .preset-option:hover,\n .toolbar .preset-option:focus-visible { background: color-mix(in srgb, var(--text) 5%, transparent); }\n .toolbar .preset-option[aria-checked=\"true\"] { background: color-mix(in srgb, var(--frontend-stroke) 8%, transparent); }\n .toolbar .preset-option:focus-visible {\n outline: 1.5px solid color-mix(in srgb, var(--frontend-stroke) 55%, transparent);\n outline-offset: -1.5px;\n }\n .preset-option-swatch {\n position: relative;\n width: 2.375rem;\n height: 1.75rem;\n overflow: hidden;\n border: 0;\n border-radius: 0.4375rem;\n background: #0f172a;\n box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.28), 0 1px 2px rgba(15, 23, 42, 0.12);\n transition: box-shadow 0.14s ease, transform 0.14s ease;\n }\n .toolbar .preset-option:hover .preset-option-swatch { transform: translateY(-1px); }\n .toolbar .preset-option[aria-checked=\"true\"] .preset-option-swatch {\n box-shadow: 0 0 0 2px var(--toolbar-menu-bg), 0 0 0 3.5px var(--frontend-stroke);\n }\n .preset-option-swatch::before,\n .preset-option-swatch::after { position: absolute; content: \"\"; }\n .preset-option-swatch.classic::before {\n top: 0.42rem;\n right: 0.35rem;\n bottom: 0.42rem;\n left: 0.35rem;\n border: 1px solid #22d3ee;\n border-radius: 0.16rem;\n background: rgba(34, 211, 238, 0.14);\n }\n /* Classic previews the canvas it will actually produce in this theme. */\n [data-theme=\"light\"] .preset-option-swatch.classic {\n background:\n radial-gradient(circle at 1px 1px, #d9dee5 0.6px, transparent 0.9px) 0 0 / 5px 5px,\n #ffffff;\n }\n [data-theme=\"light\"] .preset-option-swatch.classic::before {\n border-color: #1b87a3;\n background: rgba(14, 116, 144, 0.08);\n box-shadow: 0 2px 4px rgba(17, 24, 39, 0.12);\n }\n .preset-option-swatch.signal-flow {\n border-color: #29415f;\n background: linear-gradient(135deg, #07101e 10%, #10243c 100%);\n }\n .preset-option-swatch.signal-flow::before {\n top: 50%;\n right: 0.2rem;\n left: 0.2rem;\n height: 1px;\n background: linear-gradient(90deg, #67e8f9, #c4b5fd);\n box-shadow: 0 0 8px #67e8f9;\n }\n .preset-option-swatch.signal-flow::after {\n top: calc(50% - 0.13rem);\n right: 0.28rem;\n width: 0.26rem;\n height: 0.26rem;\n border-radius: 50%;\n background: #67e8f9;\n box-shadow: 0 0 7px #67e8f9;\n }\n .preset-option-swatch.blueprint {\n border-color: #34799a;\n border-radius: 0.08rem;\n background-color: #0a2031;\n background-image:\n linear-gradient(rgba(102, 217, 239, 0.18) 1px, transparent 1px),\n linear-gradient(90deg, rgba(102, 217, 239, 0.18) 1px, transparent 1px);\n background-size: 0.42rem 0.42rem;\n }\n .preset-option-swatch.blueprint::before {\n top: 0.34rem;\n right: 0.38rem;\n bottom: 0.34rem;\n left: 0.38rem;\n border: 1px solid #66d9ef;\n }\n .preset-option-swatch.editorial {\n border-color: #b8aa94;\n border-radius: 0.08rem;\n background: repeating-linear-gradient(0deg, #f2eee5 0 0.34rem, #d8d0c2 0.36rem, #f2eee5 0.38rem);\n }\n .preset-option-swatch.editorial::before {\n top: 0;\n bottom: 0;\n left: 0.42rem;\n width: 1px;\n background: #c9502d;\n opacity: 0.72;\n }\n .preset-option-swatch.editorial::after {\n top: 0.52rem;\n right: 0.45rem;\n width: 0.38rem;\n height: 0.38rem;\n background: #c9502d;\n transform: rotate(45deg);\n }\n .preset-option-copy { min-width: 0; }\n .preset-option-copy strong,\n .preset-option-copy small { display: block; }\n .preset-option-copy strong {\n color: var(--text);\n font-size: 0.8125rem;\n font-weight: 550;\n letter-spacing: -0.005em;\n }\n .toolbar .preset-option[aria-checked=\"true\"] .preset-option-copy strong { font-weight: 650; }\n .preset-option-copy small {\n margin-top: 0.125rem;\n overflow: hidden;\n color: var(--text-faint);\n font-size: 0.6875rem;\n font-weight: 400;\n white-space: nowrap;\n text-overflow: ellipsis;\n }\n .preset-option-check {\n display: inline-block;\n width: 0.9rem;\n height: 0.9rem;\n color: var(--frontend-stroke);\n background: currentColor;\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='m3 8.5 3 3 7-7' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E\");\n -webkit-mask-position: center;\n -webkit-mask-repeat: no-repeat;\n -webkit-mask-size: contain;\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='m3 8.5 3 3 7-7' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E\");\n mask-position: center;\n mask-repeat: no-repeat;\n mask-size: contain;\n opacity: 0;\n }\n .preset-option[aria-checked=\"true\"] .preset-option-check { opacity: 1; }\n html[data-preset=\"editorial\"] .toolbar button,\n html[data-preset=\"editorial\"] .preset-menu,\n html[data-preset=\"editorial\"] .export-menu,\n html[data-preset=\"editorial\"] .overview-map,\n html[data-preset=\"editorial\"] .semantic-lens,\n html[data-preset=\"editorial\"] .route-probe,\n html[data-preset=\"editorial\"] .focus-chip,\n html[data-preset=\"editorial\"] .diagram-guide,\n html[data-preset=\"editorial\"] .node-finder {\n border-radius: 0.3rem;\n }\n .motion-control-dot {\n width: 0.46rem;\n height: 0.46rem;\n flex: 0 0 auto;\n border: 1px solid var(--frontend-stroke);\n border-radius: 50%;\n background: var(--frontend-stroke);\n box-shadow: 0 0 9px color-mix(in srgb, var(--frontend-stroke) 72%, transparent);\n }\n #btn-motion[aria-pressed=\"false\"] .motion-control-dot {\n background: transparent;\n box-shadow: none;\n }\n .toolbar .export-menu {\n position: absolute;\n top: calc(100% + 0.125rem);\n right: 0;\n background: var(--toolbar-menu-bg);\n border: 1px solid color-mix(in srgb, var(--panel-border) 90%, transparent);\n width: 19rem;\n max-width: calc(100vw - 2rem);\n max-height: calc(100vh - 5.5rem);\n overflow-y: auto;\n border-radius: 0.875rem;\n padding: 0.375rem;\n display: none;\n flex-direction: column;\n box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06), 0 18px 44px -14px rgba(15, 23, 42, 0.3);\n scrollbar-width: thin;\n }\n .toolbar .export-menu.open { display: flex; }\n .export-menu-header {\n display: flex;\n align-items: flex-start;\n justify-content: space-between;\n gap: 1rem;\n padding: 0.55rem 0.6rem 0.6rem;\n }\n .export-menu-header strong,\n .export-menu-header span { display: block; }\n .export-menu-header strong {\n color: var(--text);\n font-size: 0.875rem;\n font-weight: 600;\n letter-spacing: -0.005em;\n }\n .export-menu-header span {\n margin-top: 0.15rem;\n color: var(--text-faint);\n font-size: 0.75rem;\n }\n .export-menu-header kbd {\n min-width: 1.125rem;\n padding: 0.05rem 0.3rem;\n border: 1px solid var(--panel-border);\n border-bottom-width: 2px;\n border-radius: 0.3rem;\n background: color-mix(in srgb, var(--text) 3%, var(--toolbar-menu-bg));\n color: var(--text-muted);\n font-family: inherit;\n font-size: 0.625rem;\n font-weight: 600;\n line-height: 1.3;\n text-align: center;\n }\n .export-menu-section {\n display: grid;\n grid-template-columns: minmax(0, 1fr);\n gap: 0.0625rem;\n }\n .export-menu-section + .export-menu-section {\n margin-top: 0.3rem;\n padding-top: 0.3rem;\n border-top: 1px solid color-mix(in srgb, var(--panel-border) 80%, transparent);\n }\n .export-menu-heading {\n grid-column: 1 / -1;\n display: block;\n padding: 0.4rem 0.6rem 0.25rem;\n color: var(--text-faint);\n font-size: 0.6875rem;\n font-weight: 600;\n letter-spacing: 0.01em;\n }\n .toolbar .export-menu button {\n display: grid;\n grid-template-columns: 1rem minmax(0, 1fr);\n align-items: center;\n column-gap: 0.7rem;\n background: transparent;\n border: 0;\n box-shadow: none;\n backdrop-filter: none;\n width: 100%;\n min-height: 2.5rem;\n text-align: left;\n padding: 0.4rem 0.6rem;\n border-radius: 0.5625rem;\n color: var(--text);\n white-space: nowrap;\n transition: background 0.14s ease;\n }\n .toolbar .export-menu button:hover,\n .toolbar .export-menu button:focus-visible { background: color-mix(in srgb, var(--text) 5%, transparent); color: var(--text); }\n .toolbar .export-menu button:focus-visible {\n outline: 1.5px solid color-mix(in srgb, var(--frontend-stroke) 55%, transparent);\n outline-offset: -1.5px;\n }\n /* Name and format hint share one line, so each row stays compact. */\n .export-item-copy {\n display: flex;\n align-items: baseline;\n justify-content: space-between;\n gap: 0.75rem;\n min-width: 0;\n }\n .export-item-copy strong {\n overflow: hidden;\n color: inherit;\n font-size: 0.8125rem;\n font-weight: 500;\n text-overflow: ellipsis;\n }\n .export-item-copy small {\n flex: none;\n color: var(--text-faint);\n font-size: 0.6875rem;\n font-weight: 450;\n }\n .toolbar .export-menu button::before {\n position: static;\n z-index: auto;\n inset: auto;\n border-radius: 0;\n display: block;\n width: 1rem;\n height: 1rem;\n background: currentColor;\n color: var(--text-muted);\n content: \"\";\n opacity: 0.8;\n -webkit-mask-position: center;\n -webkit-mask-repeat: no-repeat;\n -webkit-mask-size: contain;\n mask-position: center;\n mask-repeat: no-repeat;\n mask-size: contain;\n }\n .toolbar .export-menu button[data-action=\"route-share-card\"]::before,\n .toolbar .export-menu button[data-action=\"reach-share-card\"]::before {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath fill='none' stroke='black' stroke-width='1.7' d='M3 4.5h14v11H3zM6 12l2.5-2.5 2 2 1.5-1.5 2 2'/%3E%3Ccircle cx='13.8' cy='7.3' r='1.2' fill='black'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath fill='none' stroke='black' stroke-width='1.7' d='M3 4.5h14v11H3zM6 12l2.5-2.5 2 2 1.5-1.5 2 2'/%3E%3Ccircle cx='13.8' cy='7.3' r='1.2' fill='black'/%3E%3C/svg%3E\");\n }\n .toolbar .export-menu button[data-action^=\"copy\"]::before {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Crect x='6' y='6' width='10' height='10' rx='1.5' fill='none' stroke='black' stroke-width='1.7'/%3E%3Cpath d='M4 13H3.5A1.5 1.5 0 012 11.5v-8A1.5 1.5 0 013.5 2h8A1.5 1.5 0 0113 3.5V4' fill='none' stroke='black' stroke-width='1.7'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Crect x='6' y='6' width='10' height='10' rx='1.5' fill='none' stroke='black' stroke-width='1.7'/%3E%3Cpath d='M4 13H3.5A1.5 1.5 0 012 11.5v-8A1.5 1.5 0 013.5 2h8A1.5 1.5 0 0113 3.5V4' fill='none' stroke='black' stroke-width='1.7'/%3E%3C/svg%3E\");\n }\n .toolbar .export-menu button[data-format=\"png\"]::before,\n .toolbar .export-menu button[data-format=\"jpeg\"]::before,\n .toolbar .export-menu button[data-format=\"webp\"]::before {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 2.5h7l3 3v12H5zM12 2.5v3h3' fill='none' stroke='black' stroke-width='1.7'/%3E%3Cpath d='M7.5 14l2-2 1.5 1.5 1.5-1.5' fill='none' stroke='black' stroke-width='1.7'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 2.5h7l3 3v12H5zM12 2.5v3h3' fill='none' stroke='black' stroke-width='1.7'/%3E%3Cpath d='M7.5 14l2-2 1.5 1.5 1.5-1.5' fill='none' stroke='black' stroke-width='1.7'/%3E%3C/svg%3E\");\n }\n .toolbar .export-menu button[data-format^=\"svg\"]::before,\n .toolbar .export-menu button[data-format=\"webm\"]::before {\n -webkit-mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M10 2.5l7 4v7l-7 4-7-4v-7zM3 6.5l7 4 7-4M10 10.5v7' fill='none' stroke='black' stroke-width='1.7'/%3E%3C/svg%3E\");\n mask-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M10 2.5l7 4v7l-7 4-7-4v-7zM3 6.5l7 4 7-4M10 10.5v7' fill='none' stroke='black' stroke-width='1.7'/%3E%3C/svg%3E\");\n }\n .toolbar .export-menu button[data-action=\"route-share-card\"],\n .toolbar .export-menu button[data-action=\"reach-share-card\"] {\n color: var(--text);\n background: color-mix(in srgb, var(--frontend-stroke) 7%, transparent);\n }\n .toolbar .export-menu button[data-action=\"route-share-card\"]::before,\n .toolbar .export-menu button[data-action=\"reach-share-card\"]::before { color: var(--frontend-stroke); opacity: 1; }\n .toolbar .export-menu button[hidden] { display: none; }\n .toolbar .export-menu button[data-action=\"route-share-card\"]:hover,\n .toolbar .export-menu button[data-action=\"reach-share-card\"]:hover {\n background: color-mix(in srgb, var(--frontend-stroke) 12%, transparent);\n }\n .toolbar .export-menu button:disabled {\n color: var(--text-faint);\n background: transparent;\n opacity: 0.55;\n cursor: not-allowed;\n }\n .toolbar .export-menu .hint {\n color: var(--text-faint);\n font-size: 0.6875rem;\n }\n\n /* Toast — brief feedback for actions like \"copied\" */\n .archify-toast {\n position: fixed;\n top: 1rem;\n left: 50%;\n transform: translateX(-50%) translateY(-8px);\n background: var(--toolbar-menu-bg);\n color: var(--text);\n border: 1px solid var(--toolbar-border);\n padding: 0.5rem 1rem;\n border-radius: 0.5rem;\n font-family: inherit;\n font-size: 0.75rem;\n opacity: 0;\n transition: opacity 0.2s, transform 0.2s;\n z-index: 200;\n pointer-events: none;\n box-shadow: 0 4px 20px rgba(0,0,0,0.25);\n }\n .archify-toast.show {\n opacity: 1;\n transform: translateX(-50%) translateY(0);\n }\n\n @media (max-width: 720px) {\n body { padding: 1rem; }\n .toolbar .preset-menu,\n .toolbar .export-menu {\n position: fixed;\n top: 4.5rem;\n right: 1rem;\n left: 1rem;\n width: auto;\n max-width: none;\n }\n .toolbar {\n position: relative;\n top: auto;\n right: auto;\n justify-content: flex-end;\n width: max-content;\n max-width: 100%;\n margin-left: auto;\n margin-bottom: 1rem;\n }\n .header { margin-bottom: 1.25rem; padding-right: 0; }\n html[data-preset=\"signal-flow\"] .header,\n html[data-preset=\"blueprint\"] .header,\n html[data-preset=\"editorial\"] .header { padding-right: 0; }\n .header-row {\n gap: 0.75rem;\n align-items: flex-start;\n }\n html[data-preset=\"signal-flow\"] .header-row,\n html[data-preset=\"blueprint\"] .header-row,\n html[data-preset=\"editorial\"] .header-row { flex-wrap: wrap; }\n html[data-preset=\"signal-flow\"] .header-row::after {\n margin-left: 0;\n order: 3;\n }\n html[data-preset=\"blueprint\"] .header-row::after {\n margin-left: 0;\n order: 3;\n }\n html[data-preset=\"editorial\"] .header-row::after {\n margin-left: 0;\n order: 3;\n }\n h1 {\n font-size: 1.25rem;\n line-height: 1.25;\n }\n .subtitle {\n margin-left: 0;\n font-size: 0.8125rem;\n line-height: 1.55;\n }\n .diagram-container {\n padding: 0.75rem;\n border-radius: 0.75rem;\n }\n html:not([data-embed=\"true\"]) .diagram-container {\n padding: 0.75rem 0.75rem 4.25rem;\n }\n html:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] {\n overflow-x: auto;\n overflow-y: hidden;\n overscroll-behavior-x: contain;\n scrollbar-width: thin;\n scroll-behavior: smooth;\n }\n html:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] \u003e svg {\n min-width: 720px;\n }\n html:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] .diagram-nav,\n html:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] .overview-map,\n html:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] .focus-chip,\n html:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] .route-probe,\n html:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] .semantic-lens,\n html:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] .diagram-guide,\n html:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] .node-finder {\n transform: translateX(var(--archify-scroll-x, 0px));\n }\n .diagram-nav { right: 0.5rem; bottom: 0.5rem; }\n .diagram-nav button {\n min-width: 2.75rem;\n height: 2.75rem;\n }\n .diagram-nav [data-view=\"reset\"] { min-width: 3.75rem; }\n .diagram-nav [data-view=\"reset\"][data-detail-visible] { min-width: 4.35rem; }\n .overview-map {\n right: 0.5rem;\n bottom: 3.7rem;\n width: min(10.25rem, calc(100% - 1rem));\n }\n .overview-map[data-docked=\"true\"] {\n right: var(--archify-radar-right, 0.5rem);\n top: var(--archify-radar-top, 0.5rem);\n bottom: auto;\n transform: none !important;\n }\n .overview-map[data-docked=\"true\"][data-dock-side=\"left\"] {\n right: auto;\n left: var(--archify-radar-left, 0.5rem);\n }\n .overview-map-surface { height: 4rem; }\n .overview-map-feedback { right: 0.5rem; bottom: 3.7rem; }\n .semantic-lens {\n right: 0.5rem;\n bottom: 3.7rem;\n width: calc(100% - 1rem);\n max-height: calc(100% - 4.2rem);\n }\n .semantic-lens[data-dock-side] { left: auto; right: 0.5rem; }\n .semantic-lens-kinds { max-height: min(12rem, 34vh); }\n .focus-chip {\n left: 0.5rem;\n top: 0.5rem;\n width: calc(100% - 1rem);\n max-width: none;\n }\n .relationship-lens-head { padding-top: 0.7rem; }\n .relationship-lens-drag-handle { display: none; }\n .relationship-lens-list { max-height: min(12rem, 38vh); }\n .relationship-lens-actions #btn-focus-relations { display: block; color: var(--database-stroke); }\n .focus-chip:not([data-relations-expanded=\"true\"]) .relationship-lens-head { border-bottom-color: transparent; }\n .focus-chip:not([data-relations-expanded=\"true\"]) .relationship-lens-list { display: none; }\n /* While a mobile reader previews one relationship, turn the full Lens\n into a compact peek card. This keeps the exact source and target on\n canvas instead of covering them with a long, scrollable list. */\n .focus-chip[data-relationship-previewing=\"true\"] .relationship-lens-list {\n max-height: none;\n padding: 0.35rem;\n overflow: hidden;\n }\n .focus-chip[data-relationship-previewing=\"true\"] .relationship-lens-group { margin: 0; }\n .focus-chip[data-relationship-previewing=\"true\"] .relationship-lens-group-title,\n .focus-chip[data-relationship-previewing=\"true\"] .relationship-lens-row:not([data-preview-active=\"true\"]) {\n display: none;\n }\n .node-finder {\n top: 0.5rem;\n left: 0.5rem;\n width: min(22rem, calc(100% - 1rem));\n max-height: calc(100% - 1rem);\n }\n .diagram-guide {\n top: 0.5rem;\n right: 0.5rem;\n left: 0.5rem;\n width: auto;\n max-height: calc(100% - 1rem);\n }\n .diagram-guide-head { padding: 0.62rem 0.7rem 0.52rem; }\n .diagram-guide-stats { padding: 0.42rem 0.7rem; }\n .diagram-guide-actions {\n grid-template-columns: 1fr;\n gap: 0.28rem;\n padding: 0.42rem;\n }\n .diagram-guide-action {\n min-height: 3.1rem;\n padding: 0.42rem 0.48rem;\n }\n .diagram-guide-action small {\n display: block;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n .diagram-guide-index {\n width: 1.5rem;\n height: 1.5rem;\n }\n .diagram-guide-shortcuts { padding: 0.46rem 0.7rem 0.52rem; }\n .diagram-guide-action[data-guide-action=\"present\"] { grid-column: auto; }\n .route-probe[data-guide-open=\"true\"] {\n visibility: hidden;\n pointer-events: none;\n }\n .node-finder-results { max-height: min(16rem, 38vh); }\n .route-probe {\n left: 0.5rem;\n bottom: 3.7rem;\n width: calc(100% - 1rem);\n min-width: 0;\n }\n .route-probe[data-route-dock=\"top\"] {\n top: 0.5rem;\n bottom: auto;\n }\n .route-probe[data-finder-open=\"true\"] {\n visibility: hidden;\n pointer-events: none;\n }\n .route-probe-head { padding: 0.45rem 0.48rem 0.38rem; }\n .route-probe-path { padding: 0.35rem 0.48rem 0.2rem; }\n .route-probe-node { min-height: 2.75rem !important; }\n .route-journey-controls {\n grid-template-columns: 2.75rem minmax(0, 1fr) 2.75rem minmax(0, 1fr);\n padding: 0.08rem 0.48rem 0.32rem;\n }\n .route-journey-controls button { min-height: 2.75rem; }\n .route-probe-status { padding: 0.05rem 0.48rem 0.38rem; }\n .route-probe-node { max-width: 7.5rem; }\n \n \n \n \n \n \n \n \n \n \n \n html[data-embed=\"true\"][data-share-playback=\"true\"] .diagram-container {\n padding-top: 4.25rem;\n }\n html[data-embed=\"true\"][data-share-moment=\"true\"] .diagram-container {\n padding-top: 4.25rem;\n }\n \n .cards {\n grid-template-columns: 1fr;\n margin-top: 1rem;\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) body { padding: 0.5rem; }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .container {\n gap: 0.5rem;\n height: calc(100dvh - 1rem);\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .toolbar {\n position: fixed;\n top: 0.5rem;\n right: 0.5rem;\n margin: 0;\n gap: 0.25rem;\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .toolbar button {\n min-height: 2.75rem;\n padding: 0.42rem 0.58rem;\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .header {\n min-height: 2.25rem;\n padding: 3.5rem 0 0;\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .header-row {\n min-height: 2.25rem;\n margin: 0;\n align-items: center;\n flex-wrap: nowrap;\n }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .header-row::after,\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .pulse-dot,\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .subtitle { display: none; }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) h1 {\n flex: 1 1 auto;\n min-width: 0;\n max-width: 100%;\n overflow: hidden;\n font-size: 0.875rem;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n \n html[data-present=\"true\"]:not([data-embed=\"true\"]) .diagram-container { padding: 0.5rem 0.5rem 3.75rem; }\n html[data-present=\"true\"]:not([data-embed=\"true\"]) .diagram-container[data-wide-diagram=\"true\"] \u003e svg {\n width: 720px;\n height: auto;\n min-width: 720px;\n }\n }\n\n @media (max-width: 420px) {\n .export-menu-section { grid-template-columns: 1fr; }\n .export-menu-heading,\n .toolbar .export-menu button[data-action=\"route-share-card\"],\n .toolbar .export-menu button[data-action=\"reach-share-card\"] { grid-column: 1; }\n }\n\n @media (prefers-reduced-motion: reduce) {\n .toolbar .preset-menu.open,\n .toolbar .export-menu.open { animation: none; }\n .toolbar-chevron { transition: none; }\n }\n\n @media (max-width: 360px) {\n .toolbar { gap: 0.25rem; }\n .toolbar button { padding-right: 0.58rem; padding-left: 0.58rem; }\n .toolbar #btn-motion { min-width: 4.4rem; padding-right: 0.58rem; padding-left: 0.58rem; }\n #theme-label, #preset-label, #present-label { display: none; }\n }\n\n /* ==========================================================\n SVG SEMANTIC CLASSES — use these instead of inline fill/stroke\n ========================================================== */\n .c-grid { stroke: var(--grid); fill: none; }\n .c-mask { fill: var(--mask); stroke: none; }\n .c-lane-rule { stroke: var(--lane-stroke); fill: none; opacity: 0.7; }\n .c-lane-wash { fill: var(--lane-fill); stroke: none; }\n\n .c-frontend { fill: var(--frontend-fill); stroke: var(--frontend-stroke); }\n .c-backend { fill: var(--backend-fill); stroke: var(--backend-stroke); }\n .c-database { fill: var(--database-fill); stroke: var(--database-stroke); }\n .c-cloud { fill: var(--cloud-fill); stroke: var(--cloud-stroke); }\n .c-security { fill: var(--security-fill); stroke: var(--security-stroke); }\n .c-messagebus { fill: var(--messagebus-fill); stroke: var(--messagebus-stroke); }\n .c-external { fill: var(--external-fill); stroke: var(--external-stroke); }\n\n /* Text helpers */\n .t-primary { fill: var(--text); }\n .t-muted { fill: var(--text-muted); }\n .t-dim { fill: var(--text-dim); }\n .t-frontend { fill: var(--frontend-stroke); }\n .t-backend { fill: var(--backend-stroke); }\n .t-database { fill: var(--database-stroke); }\n .t-cloud { fill: var(--cloud-stroke); }\n .t-security { fill: var(--security-stroke); }\n .t-messagebus { fill: var(--messagebus-stroke); }\n .t-external { fill: var(--external-stroke); }\n\n /* Relationship labels share the exact color token used by their path. */\n .t-edge-default { fill: var(--arrow); }\n .t-edge-emphasis { fill: var(--arrow-emphasis); }\n .t-edge-security { fill: var(--security-stroke); }\n .t-edge-dashed { fill: var(--database-stroke); }\n\n /* Classic canvas: a quiet dot field replaces drafting grid lines, and nodes\n read as lifted cards with hairline strokes. Paint only; authored geometry,\n hit areas and exports keep their canonical shapes. */\n html[data-preset=\"classic\"] .diagram-container {\n background:\n radial-gradient(circle at 1px 1px, var(--canvas-dot) 1px, transparent 1.4px) 0 0 / 20px 20px,\n var(--panel);\n }\n html[data-preset=\"classic\"] .diagram-container \u003e svg .c-grid { stroke: transparent; }\n html[data-preset=\"classic\"][data-theme=\"light\"] .diagram-container \u003e svg [data-node-id] \u003e rect:not(.c-mask) {\n filter: drop-shadow(0 1px 1px rgba(17, 24, 39, 0.05)) drop-shadow(0 6px 12px rgba(17, 24, 39, 0.06));\n }\n html[data-preset=\"classic\"][data-theme=\"dark\"] .diagram-container \u003e svg [data-node-id] \u003e rect:not(.c-mask) {\n filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.35));\n }\n html[data-preset=\"classic\"] .diagram-container \u003e svg [data-edge-from] {\n stroke-linecap: round;\n stroke-linejoin: round;\n }\n html[data-preset=\"classic\"] .diagram-container \u003e svg .c-lane-wash { fill: color-mix(in srgb, var(--text) 2.6%, transparent); }\n html[data-preset=\"classic\"] .diagram-container \u003e svg .c-lane-rule { stroke: var(--panel-border); opacity: 1; }\n html[data-preset=\"classic\"][data-theme=\"dark\"] .diagram-container \u003e svg .c-lane-rule { stroke: rgba(148, 163, 184, 0.16); }\n html[data-preset=\"classic\"] .diagram-container \u003e svg [data-node-id] {\n transition: transform 0.18s cubic-bezier(0.22, 1, 0.36, 1);\n }\n html[data-preset=\"classic\"]:not([data-motion=\"still\"]) .diagram-container \u003e svg [data-node-id]:hover {\n transform: translateY(-1.5px);\n }\n\n /* Semantic Sigils are small authored role stamps, not icons from a brand\n pack and not viewer controls. Prefix selectors with svg so the canonical\n export's SVG-only stylesheet collector keeps them automatically. */\n svg .semantic-sigil {\n fill: none;\n stroke: currentColor;\n stroke-width: 1.35;\n stroke-linecap: round;\n stroke-linejoin: round;\n opacity: 0.76;\n pointer-events: none;\n }\n svg .semantic-sigil \u003e * { vector-effect: non-scaling-stroke; }\n svg .semantic-sigil .sigil-fill { fill: currentColor; stroke: none; }\n svg .s-frontend { color: var(--frontend-stroke); }\n svg .s-backend { color: var(--backend-stroke); }\n svg .s-database { color: var(--database-stroke); }\n svg .s-cloud { color: var(--cloud-stroke); }\n svg .s-security { color: var(--security-stroke); }\n svg .s-messagebus { color: var(--messagebus-stroke); }\n svg .s-external { color: var(--external-stroke); }\n\n /* Brand Marks are authored identity badges. Their color is contained\n inside one neutral plate so vendor color never replaces Archify's\n semantic node and relationship vocabulary. */\n svg .brand-mark { pointer-events: none; }\n svg .brand-mark-badge { fill: #fff; stroke: none; }\n svg .brand-mark-frame {\n fill: none;\n stroke: #cbd5e1;\n stroke-width: 0.8;\n vector-effect: non-scaling-stroke;\n }\n svg .brand-mark-fallback {\n fill: none;\n stroke: #475569;\n stroke-width: 1.15;\n stroke-linecap: round;\n stroke-linejoin: round;\n }\n svg[data-preset=\"blueprint\"] .brand-mark-badge,\n svg[data-preset=\"blueprint\"] .brand-mark-frame { rx: 1px; }\n\n /* Reading Depth is a viewer-only level-of-detail layer. MAP preserves the\n authored structure and primary labels, READ restores relationship labels\n and node context, and FULL restores tags and fine annotations. Semantic\n intent can reveal the relevant detail without moving any geometry. */\n svg [data-detail] { transition: opacity 160ms ease; }\n svg [data-detail-anchor] {\n transform-box: fill-box;\n transform-origin: center;\n transition: transform 160ms ease;\n }\n .diagram-container[data-detail-level=\"map\"] svg [data-detail=\"context\"],\n .diagram-container[data-detail-level=\"map\"] svg [data-detail=\"fine\"],\n .diagram-container[data-detail-level=\"read\"] svg [data-detail=\"fine\"] {\n opacity: 0;\n pointer-events: none;\n }\n .diagram-container[data-detail-level=\"map\"] svg [data-detail-anchor] {\n transform: translateY(8px);\n }\n\n /* Focus, lens, preview, route, and story states are stronger reader intent than\n the global zoom level. Reveal only their exact semantic matches. */\n svg[data-focus-active] [data-focus-match][data-detail],\n svg[data-focus-active] [data-focus-match] [data-detail],\n svg[data-reach-active] [data-reach-match][data-detail],\n svg[data-reach-active] [data-reach-match] [data-detail],\n svg[data-lens-active] [data-lens-match][data-detail],\n svg[data-lens-active] [data-lens-match] [data-detail],\n svg[data-legend-preview-active] [data-legend-preview-match][data-detail],\n svg[data-legend-preview-active] [data-legend-preview-match] [data-detail],\n svg[data-intent-trace-active] [data-intent-trace-match][data-detail],\n svg[data-intent-trace-active] [data-intent-trace-match] [data-detail],\n svg[data-route-active] [data-route-match][data-detail],\n svg[data-route-active] [data-route-match] [data-detail],\n svg[data-relationship-preview-active] [data-relationship-preview][data-detail],\n svg[data-relationship-preview-active] [data-relationship-preview] [data-detail],\n svg [data-node-id]:hover [data-detail],\n svg [data-node-id]:focus-visible [data-detail] {\n opacity: 1;\n pointer-events: auto;\n }\n svg[data-focus-active] [data-focus-match] [data-detail-anchor],\n svg[data-reach-active] [data-reach-match] [data-detail-anchor],\n svg[data-lens-active] [data-lens-match] [data-detail-anchor],\n svg[data-legend-preview-active] [data-legend-preview-match] [data-detail-anchor],\n svg[data-intent-trace-active] [data-intent-trace-match] [data-detail-anchor],\n svg[data-route-active] [data-route-match] [data-detail-anchor],\n svg [data-node-id]:hover [data-detail-anchor],\n svg [data-node-id]:focus-visible [data-detail-anchor] { transform: none; }\n\n /* Arrows */\n .a-default { stroke: var(--arrow); fill: none; }\n .a-emphasis { stroke: var(--arrow-emphasis); fill: none; }\n .a-security { stroke: var(--security-stroke); fill: none; stroke-dasharray: 5,5; }\n .a-dashed { stroke: var(--database-stroke); fill: none; stroke-dasharray: 4,4; }\n\n /* Arrowhead markers reference these */\n .m-default { fill: var(--arrow); }\n .m-emphasis { fill: var(--arrow-emphasis); }\n .m-security { fill: var(--security-stroke); }\n .m-dashed { fill: var(--database-stroke); }\n\n /* Stable semantic exploration hooks emitted by every renderer. */\n svg [data-node-id] {\n cursor: pointer;\n transition: opacity 0.18s ease, fill-opacity 0.18s ease, stroke-opacity 0.18s ease, filter 0.18s ease;\n }\n svg [data-edge-from],\n svg [data-graph-role=\"automatic-crossover-underlay\"] { transition: opacity 0.18s ease, filter 0.18s ease; }\n svg [data-node-id]:hover,\n svg [data-node-id]:focus-visible {\n filter: drop-shadow(0 0 7px var(--frontend-stroke));\n outline: none;\n }\n svg [data-legend-kind][role=\"button\"] { cursor: pointer; }\n svg [data-legend-kind]:focus { outline: none; }\n svg [data-legend-hit] {\n fill: transparent;\n stroke: transparent;\n stroke-width: 1.4;\n pointer-events: all;\n vector-effect: non-scaling-stroke;\n transition: stroke 150ms ease, stroke-width 150ms ease, filter 150ms ease;\n }\n svg [data-legend-count-badge] { pointer-events: none; }\n svg [data-legend-count-badge] rect {\n fill: var(--mask);\n stroke: var(--panel-border);\n stroke-width: 1;\n vector-effect: non-scaling-stroke;\n }\n svg [data-legend-count-badge] text {\n fill: var(--text-muted);\n font-size: 8px;\n font-weight: 700;\n text-anchor: middle;\n }\n svg [data-legend-kind][role=\"button\"]:hover [data-legend-hit] {\n stroke: color-mix(in srgb, var(--database-stroke) 58%, transparent);\n }\n svg [data-legend-kind][role=\"button\"]:focus-visible [data-legend-hit] {\n stroke: var(--frontend-stroke);\n stroke-width: 1.8;\n filter: drop-shadow(0 0 3px var(--frontend-stroke));\n }\n svg [data-legend-kind][data-legend-selected] [data-legend-hit] {\n stroke: var(--database-stroke);\n stroke-width: 2.2;\n stroke-dasharray: 3 2;\n }\n svg [data-legend-kind][data-legend-selected] [data-legend-count-badge] rect {\n stroke: var(--database-stroke);\n stroke-width: 1.8;\n }\n svg [data-legend-kind][data-legend-zero] { opacity: 0.44; }\n svg[data-preset=\"signal-flow\"] [data-legend-kind][data-legend-selected] [data-legend-hit] {\n filter: drop-shadow(0 0 4px var(--database-stroke));\n }\n svg[data-preset=\"blueprint\"] [data-legend-hit],\n svg[data-preset=\"blueprint\"] [data-legend-count-badge] rect { rx: 0; filter: none; }\n svg[data-legend-preview-active] [data-node-id],\n svg[data-legend-preview-active] [data-edge-from] { opacity: 0.11; }\n svg[data-legend-preview-active] [data-legend-preview-match] { opacity: 1; }\n svg[data-legend-preview-active] [data-legend-preview-peer] { opacity: 0.62; }\n svg[data-legend-preview-active] [data-legend-preview-selected] {\n filter: drop-shadow(0 0 8px var(--database-stroke));\n }\n svg[data-lens-active] [data-node-id],\n svg[data-lens-active] [data-edge-from] { opacity: 0.11; }\n svg[data-lens-active] [data-lens-match] { opacity: 1; }\n svg[data-lens-active] [data-lens-peer] { opacity: 0.62; }\n svg[data-lens-active] [data-lens-selected] {\n filter: drop-shadow(0 0 10px var(--database-stroke));\n }\n .semantic-lens-overlay { pointer-events: none; }\n .semantic-lens-flow {\n fill: none;\n stroke-width: 3.05;\n stroke-linecap: round;\n stroke-dasharray: 0.075 0.925;\n stroke-dashoffset: 0;\n vector-effect: non-scaling-stroke;\n opacity: 0.9;\n animation: archify-semantic-lens-flow 1.35s linear 1 both;\n animation-delay: var(--lens-flow-delay, 0s);\n }\n .semantic-lens-flow[data-direction=\"out\"],\n .semantic-lens-flow[data-direction=\"forward\"] {\n stroke: var(--frontend-stroke);\n filter: drop-shadow(0 0 3px var(--frontend-stroke));\n }\n .semantic-lens-flow[data-direction=\"in\"],\n .semantic-lens-flow[data-direction=\"reverse\"] {\n stroke: var(--database-stroke);\n filter: drop-shadow(0 0 3px var(--database-stroke));\n }\n .semantic-lens-flow[data-direction=\"within\"] {\n stroke: var(--messagebus-stroke);\n filter: drop-shadow(0 0 3px var(--messagebus-stroke));\n }\n svg[data-preset=\"signal-flow\"] .semantic-lens-flow {\n stroke-width: 3.7;\n opacity: 1;\n }\n svg[data-preset=\"signal-flow\"] .semantic-lens-flow[data-direction=\"out\"],\n svg[data-preset=\"signal-flow\"] .semantic-lens-flow[data-direction=\"forward\"] {\n filter: drop-shadow(0 0 6px var(--frontend-stroke));\n }\n svg[data-preset=\"signal-flow\"] .semantic-lens-flow[data-direction=\"in\"],\n svg[data-preset=\"signal-flow\"] .semantic-lens-flow[data-direction=\"reverse\"] {\n filter: drop-shadow(0 0 6px var(--database-stroke));\n }\n svg[data-preset=\"signal-flow\"] .semantic-lens-flow[data-direction=\"within\"] {\n filter: drop-shadow(0 0 6px var(--messagebus-stroke));\n }\n svg[data-preset=\"blueprint\"] .semantic-lens-flow {\n stroke-width: 2.45;\n stroke-linecap: square;\n filter: none;\n opacity: 0.78;\n }\n html[data-embed=\"true\"] .semantic-lens-overlay { display: none; }\n /* Automatic crossover masks are visual companions of their one semantic\n edge. Keep the mask free of data-edge-* identity so graph traversal and\n export still observe exactly one edge, then mirror reader emphasis from\n the paired foreground path in this presentation-only wrapper. */\n svg[data-legend-preview-active] [data-graph-role=\"automatic-crossover\"] \u003e [data-graph-role=\"automatic-crossover-underlay\"],\n svg[data-lens-active] [data-graph-role=\"automatic-crossover\"] \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.11; }\n svg[data-legend-preview-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-legend-preview-match]) \u003e [data-graph-role=\"automatic-crossover-underlay\"],\n svg[data-lens-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-lens-match]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 1; }\n svg[data-legend-preview-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-legend-preview-peer]) \u003e [data-graph-role=\"automatic-crossover-underlay\"],\n svg[data-lens-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-lens-peer]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.62; }\n svg[data-focus-active] [data-node-id],\n svg[data-focus-active] [data-edge-from] { opacity: 0.13; }\n svg[data-focus-active] [data-graph-role=\"automatic-crossover\"] \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.13; }\n svg[data-focus-active] [data-lifecycle-rail] { opacity: 0; }\n svg[data-focus-active] [data-focus-match] { opacity: 1; }\n svg[data-focus-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-focus-match]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 1; }\n svg[data-focus-active] [data-focus-selected] {\n filter: drop-shadow(0 0 10px var(--frontend-stroke));\n }\n\n /* Authored Reachability is a bounded graph query over the relationships\n already present in the artifact. Upstream walks incoming edges;\n downstream walks outgoing edges. It never claims runtime causality and\n changes only viewer emphasis, not canonical geometry or export bytes. */\n svg[data-reach-active] [data-node-id],\n svg[data-reach-active] [data-edge-from] { opacity: 0.09; }\n svg[data-reach-active] [data-graph-role=\"automatic-crossover\"] \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.09; }\n svg[data-reach-active] [data-reach-match] { opacity: 1; }\n svg[data-reach-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-reach-match]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 1; }\n svg[data-reach-active=\"upstream\"] [data-reach-origin] {\n filter: drop-shadow(0 0 11px var(--database-stroke));\n }\n svg[data-reach-active=\"downstream\"] [data-reach-origin] {\n filter: drop-shadow(0 0 11px var(--backend-stroke));\n }\n svg[data-reach-active=\"upstream\"] [data-edge-from][data-reach-match] {\n filter: drop-shadow(0 0 4px color-mix(in srgb, var(--database-stroke) 72%, transparent));\n }\n svg[data-reach-active=\"downstream\"] [data-edge-from][data-reach-match] {\n filter: drop-shadow(0 0 4px color-mix(in srgb, var(--backend-stroke) 72%, transparent));\n }\n svg[data-preset=\"blueprint\"][data-reach-active] [data-reach-origin],\n svg[data-preset=\"blueprint\"][data-reach-active] [data-edge-from][data-reach-match] {\n filter: none;\n }\n\n /* Direct Relationship Explorer makes authored paths a real input surface\n without changing their visible stroke or canonical SVG. A transparent\n runtime rail supplies forgiving pointer geometry; the exact authored\n path and endpoints continue to carry every visible state. */\n .relationship-hit-overlay { pointer-events: none; }\n .relationship-hit-target { outline: none; }\n .relationship-hit-rail {\n fill: none;\n stroke: transparent;\n stroke-width: 24;\n stroke-linecap: round;\n stroke-linejoin: round;\n vector-effect: non-scaling-stroke;\n pointer-events: stroke;\n cursor: pointer;\n }\n .relationship-focus-rail {\n fill: none;\n stroke: color-mix(in srgb, var(--frontend-stroke) 34%, transparent);\n stroke-width: 6;\n stroke-dasharray: 2 4;\n stroke-linecap: round;\n stroke-linejoin: round;\n vector-effect: non-scaling-stroke;\n pointer-events: none;\n opacity: 0;\n }\n .relationship-hit-target:focus-visible .relationship-focus-rail {\n opacity: 1;\n }\n svg[data-preset=\"blueprint\"] .relationship-hit-target:focus-visible .relationship-focus-rail {\n stroke-linecap: square;\n filter: none;\n }\n svg[data-relationship-direct-active] [data-node-id],\n svg[data-relationship-direct-active] [data-edge-from] { opacity: 0.16; }\n svg[data-relationship-direct-active] [data-graph-role=\"automatic-crossover\"] \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.16; }\n svg[data-relationship-direct-active] [data-relationship-preview],\n svg[data-relationship-direct-active] [data-relationship-preview-node] { opacity: 1; }\n svg[data-relationship-direct-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-relationship-preview]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 1; }\n svg[data-focus-active]:not([data-relationship-pin-active]) .relationship-hit-rail,\n svg[data-route-picking] .relationship-hit-rail,\n svg[data-route-active] .relationship-hit-rail,\n svg[data-lens-active] .relationship-hit-rail { pointer-events: none; }\n html[data-embed=\"true\"] .relationship-hit-overlay { display: none; }\n @media (hover: none), (pointer: coarse) {\n .relationship-hit-rail { stroke-width: 24; }\n }\n\n /* Relationship Preview is temporary exploration state layered on top of\n neighborhood focus. It changes emphasis only; exported geometry and the\n relationship's original solid/dashed visual language stay untouched. */\n svg[data-relationship-preview-active] [data-focus-match] { opacity: 0.18; }\n svg[data-relationship-preview-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-focus-match]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.18; }\n svg[data-relationship-preview-active] [data-lifecycle-rail] { opacity: 0; }\n svg[data-relationship-preview-active] [data-relationship-preview],\n svg[data-relationship-preview-active] [data-relationship-preview-node] { opacity: 1; }\n svg[data-relationship-preview-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-relationship-preview]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 1; }\n svg[data-relationship-preview-active] [data-relationship-preview] {\n filter: drop-shadow(0 0 5px var(--arrow-emphasis));\n }\n svg[data-relationship-preview-active] [data-relationship-preview] path,\n svg[data-relationship-preview-active] path[data-relationship-preview],\n svg[data-relationship-preview-active] [data-relationship-preview] line,\n svg[data-relationship-preview-active] line[data-relationship-preview],\n svg[data-relationship-preview-active] [data-relationship-preview] polyline,\n svg[data-relationship-preview-active] polyline[data-relationship-preview] {\n stroke-width: 2.75;\n }\n svg[data-relationship-preview-active] [data-relationship-preview-source] {\n filter: drop-shadow(0 0 7px var(--frontend-stroke));\n }\n svg[data-relationship-preview-active] [data-relationship-preview-target] {\n filter: drop-shadow(0 0 7px var(--database-stroke));\n }\n .relationship-pulse-overlay { pointer-events: none; }\n .relationship-flow-pulse {\n fill: none;\n stroke: var(--arrow-emphasis);\n stroke-width: 3.35;\n stroke-linecap: round;\n stroke-dasharray: 0.085 0.915;\n stroke-dashoffset: 0;\n vector-effect: non-scaling-stroke;\n opacity: 0;\n filter: drop-shadow(0 0 4px var(--arrow-emphasis));\n animation: archify-relationship-pulse 1.2s linear 1 both;\n }\n svg[data-preset=\"signal-flow\"] .relationship-flow-pulse {\n stroke: var(--frontend-stroke);\n stroke-width: 3.85;\n filter: drop-shadow(0 0 7px var(--frontend-stroke));\n }\n svg[data-preset=\"blueprint\"] .relationship-flow-pulse {\n stroke-width: 2.5;\n stroke-linecap: square;\n filter: none;\n }\n svg[data-preset=\"editorial\"] .relationship-flow-pulse {\n stroke: var(--arrow-emphasis);\n stroke-width: 2.75;\n filter: none;\n }\n .semantic-flow-token {\n color: var(--frontend-stroke);\n opacity: 0;\n pointer-events: none;\n }\n .relationship-flow-token {\n animation: archify-relationship-token-life 1.2s linear 1 both;\n }\n\n .semantic-flow-token-halo {\n fill: var(--mask);\n stroke: currentColor;\n stroke-width: 1.1;\n vector-effect: non-scaling-stroke;\n opacity: 0.96;\n }\n .relationship-flow-token-shape {\n fill: var(--mask);\n stroke: currentColor;\n stroke-width: 1.35;\n stroke-linecap: round;\n stroke-linejoin: round;\n vector-effect: non-scaling-stroke;\n }\n .relationship-flow-token-ink {\n fill: none;\n stroke: currentColor;\n stroke-width: 1.05;\n stroke-linecap: round;\n vector-effect: non-scaling-stroke;\n }\n .relationship-flow-token-dot { fill: currentColor; stroke: none; }\n .semantic-flow-token[data-token-kind=\"data\"] { color: var(--database-stroke); }\n .semantic-flow-token[data-token-kind=\"event\"] { color: var(--messagebus-stroke); }\n .semantic-flow-token[data-token-kind=\"security\"] { color: var(--security-stroke); }\n .semantic-flow-token[data-token-kind=\"state\"] { color: var(--cloud-stroke); }\n svg[data-preset=\"signal-flow\"] .semantic-flow-token {\n filter: drop-shadow(0 0 5px currentColor);\n }\n svg[data-preset=\"blueprint\"] .semantic-flow-token { filter: none; }\n svg[data-preset=\"editorial\"] .semantic-flow-token { filter: none; }\n html[data-embed=\"true\"] .relationship-pulse-overlay { display: none; }\n\n /* Intent Trace is a temporary, pre-click exploration layer. Related\n topology stays readable while a short viewer-only signal runs over\n cloned edge geometry; the authored edge remains untouched underneath. */\n /* Keep the node's opaque backing mask intact while its visible ink dims.\n Fading the whole group also fades that mask and briefly exposes arrows\n routed underneath the node when the pointer leaves. */\n svg[data-intent-trace-active] [data-node-id] { fill-opacity: 0.2; stroke-opacity: 0.2; }\n svg [data-node-id] \u003e .c-mask { fill-opacity: 1; }\n svg[data-intent-trace-active] [data-node-id][data-intent-trace-match] { fill-opacity: 1; stroke-opacity: 1; }\n svg[data-intent-trace-active] [data-edge-from] { opacity: 0.2; }\n svg[data-intent-trace-active] [data-graph-role=\"automatic-crossover\"] \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.2; }\n svg[data-intent-trace-active] [data-lifecycle-rail] { opacity: 0; }\n svg[data-intent-trace-active] [data-intent-trace-match] { opacity: 1; }\n svg[data-intent-trace-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-intent-trace-match]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 1; }\n svg[data-intent-trace-active] [data-intent-trace-selected] {\n filter: drop-shadow(0 0 10px var(--frontend-stroke));\n }\n .intent-trace-overlay { pointer-events: none; }\n .intent-trace-flow {\n fill: none;\n stroke-width: 3.1;\n stroke-linecap: round;\n stroke-dasharray: 0.1 0.9;\n stroke-dashoffset: 0;\n vector-effect: non-scaling-stroke;\n opacity: 0.94;\n animation: archify-intent-trace-flow 1.15s linear 1 both;\n }\n /* Direction names describe each edge relative to the focused node only.\n The cloned geometry already runs from the authored source to target, so\n incoming and outgoing signals must share the same playback direction. */\n .intent-trace-flow[data-direction=\"out\"] {\n stroke: var(--frontend-stroke);\n filter: drop-shadow(0 0 4px var(--frontend-stroke));\n }\n .intent-trace-flow[data-direction=\"in\"] {\n stroke: var(--database-stroke);\n filter: drop-shadow(0 0 4px var(--database-stroke));\n animation-direction: normal;\n }\n .intent-trace-flow[data-direction=\"loop\"] {\n stroke: var(--security-stroke);\n filter: drop-shadow(0 0 4px var(--security-stroke));\n }\n svg[data-preset=\"blueprint\"] [data-intent-trace-selected],\n svg[data-preset=\"blueprint\"] .intent-trace-flow {\n filter: none;\n stroke-linecap: square;\n }\n svg[data-preset=\"editorial\"] [data-intent-trace-selected],\n svg[data-preset=\"editorial\"] .intent-trace-flow { filter: none; }\n .intent-trace-status {\n position: absolute;\n width: 1px;\n height: 1px;\n padding: 0;\n margin: -1px;\n overflow: hidden;\n clip: rect(0, 0, 0, 0);\n clip-path: inset(50%);\n white-space: nowrap;\n border: 0;\n }\n\n /* Route Probe separates a durable two-point query from selection and\n one-hop hover. Only the chosen shortest directed path stays prominent;\n the traveling signal is cloned viewer geometry and never authored SVG. */\n svg[data-route-picking=\"target\"] [data-node-id] { opacity: 0.24; }\n svg[data-route-picking=\"target\"] [data-route-candidate],\n svg[data-route-picking=\"target\"] [data-route-start] { opacity: 1; }\n svg[data-route-picking] [data-node-id] { cursor: crosshair; }\n svg[data-route-picking] [data-route-start] {\n filter: drop-shadow(0 0 10px var(--frontend-stroke));\n }\n svg[data-route-active] [data-node-id],\n svg[data-route-active] [data-edge-from] { opacity: 0.11; }\n svg[data-route-active] [data-graph-role=\"automatic-crossover\"] \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.11; }\n svg[data-route-active] [data-route-match] { opacity: 1; }\n svg[data-route-active] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-route-match]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 1; }\n svg[data-route-active] [data-route-start] {\n filter: drop-shadow(0 0 11px var(--frontend-stroke));\n }\n svg[data-route-active] [data-route-end] {\n filter: drop-shadow(0 0 11px var(--security-stroke));\n }\n svg[data-route-active] [data-route-step]:not([data-route-start]):not([data-route-end]) {\n filter: drop-shadow(0 0 7px var(--backend-stroke));\n }\n svg[data-route-journey] [data-route-match][data-route-journey-state=\"past\"] { opacity: 0.62; }\n svg[data-route-journey] [data-route-match][data-route-journey-state=\"future\"] { opacity: 0.34; }\n svg[data-route-journey] [data-route-match][data-route-journey-state=\"current\"] { opacity: 1; }\n svg[data-route-journey] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-route-match][data-route-journey-state=\"past\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.62; }\n svg[data-route-journey] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-route-match][data-route-journey-state=\"future\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 0.34; }\n svg[data-route-journey] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-route-match][data-route-journey-state=\"current\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { opacity: 1; }\n svg[data-route-journey] [data-node-id][data-route-journey-current] {\n filter: drop-shadow(0 0 10px var(--backend-stroke));\n }\n svg[data-route-journey] [data-edge-from][data-route-journey-current] {\n opacity: 1;\n filter: drop-shadow(0 0 6px var(--backend-stroke));\n }\n .route-probe-overlay { pointer-events: none; }\n .route-journey-overlay { pointer-events: none; }\n .route-probe-flow {\n fill: none;\n stroke: var(--backend-stroke);\n stroke-width: 3.25;\n stroke-linecap: round;\n stroke-dasharray: 0.085 0.915;\n stroke-dashoffset: 0;\n vector-effect: non-scaling-stroke;\n opacity: 0.96;\n filter: drop-shadow(0 0 5px var(--backend-stroke));\n animation: archify-route-probe-flow 1.1s cubic-bezier(0.22, 1, 0.36, 1) 1 both;\n animation-delay: calc(var(--route-step, 0) * 0.16s);\n }\n .route-journey-flow {\n fill: none;\n stroke: var(--backend-stroke);\n stroke-width: 3.5;\n stroke-linecap: round;\n stroke-dasharray: 0.1 0.9;\n stroke-dashoffset: 0;\n vector-effect: non-scaling-stroke;\n opacity: 0;\n filter: drop-shadow(0 0 6px var(--backend-stroke));\n animation: archify-route-journey-flow 780ms cubic-bezier(0.22, 1, 0.36, 1) 1 both;\n }\n svg[data-preset=\"blueprint\"] [data-route-start],\n svg[data-preset=\"blueprint\"] [data-route-end],\n svg[data-preset=\"blueprint\"] [data-route-step],\n svg[data-preset=\"blueprint\"] .route-probe-flow {\n filter: none;\n stroke-linecap: square;\n }\n svg[data-preset=\"blueprint\"] .route-journey-flow {\n filter: none;\n stroke-linecap: square;\n }\n svg[data-preset=\"editorial\"] [data-route-start],\n svg[data-preset=\"editorial\"] [data-route-end],\n svg[data-preset=\"editorial\"] [data-route-step],\n svg[data-preset=\"editorial\"] .route-probe-flow,\n svg[data-preset=\"editorial\"] .route-journey-flow { filter: none; }\n\n svg[data-preset=\"editorial\"] .c-grid {\n stroke-dasharray: 1 4;\n opacity: 0.48;\n }\n svg[data-preset=\"editorial\"] .c-region {\n fill: color-mix(in srgb, var(--cloud-fill) 48%, transparent);\n stroke-dasharray: 9 4;\n }\n svg[data-preset=\"editorial\"] [data-node-id]:hover,\n svg[data-preset=\"editorial\"] [data-node-id]:focus-visible,\n svg[data-preset=\"editorial\"][data-focus-active] [data-focus-selected] {\n filter: drop-shadow(0 2px 2px color-mix(in srgb, var(--text) 18%, transparent));\n }\n\n svg[data-preset=\"blueprint\"] .c-grid {\n stroke-dasharray: 1 3;\n opacity: 0.78;\n }\n svg[data-preset=\"blueprint\"] .c-region {\n fill: color-mix(in srgb, var(--cloud-fill) 58%, transparent);\n stroke-dasharray: 12 4 2 4;\n }\n svg[data-preset=\"blueprint\"] .c-security-group,\n svg[data-preset=\"blueprint\"] .c-lane { stroke-dasharray: 7 3; }\n svg[data-preset=\"blueprint\"] [data-node-id]:hover,\n svg[data-preset=\"blueprint\"] [data-node-id]:focus-visible {\n filter: drop-shadow(0 0 3px var(--frontend-stroke));\n }\n svg[data-preset=\"blueprint\"][data-focus-active] [data-focus-selected] {\n filter: drop-shadow(0 0 3px var(--frontend-stroke));\n }\n svg[data-preset=\"blueprint\"][data-focus-active][data-reach-active] [data-focus-selected][data-reach-origin] {\n filter: none;\n }\n svg[data-preset=\"blueprint\"][data-relationship-preview-active] [data-relationship-preview],\n svg[data-preset=\"blueprint\"][data-relationship-preview-active] [data-relationship-preview-source],\n svg[data-preset=\"blueprint\"][data-relationship-preview-active] [data-relationship-preview-target] {\n filter: drop-shadow(0 0 3px var(--frontend-stroke));\n }\n\n /* Dashed boundary variants */\n .c-security-group { fill: transparent; stroke: var(--security-stroke); stroke-dasharray: 4,4; }\n .c-region { fill: rgba(251, 191, 36, 0.05); stroke: var(--cloud-stroke); stroke-dasharray: 8,4; }\n .c-lane { fill: var(--lane-fill); stroke: var(--lane-stroke); stroke-dasharray: 6,6; }\n\n /* Optional trace animation, enabled only by meta.animation = \"trace\".\n The ordinary viewer performs one ambient pass and then restores the\n authored solid/security/async line language. WebM samples the same\n authored geometry into an explicit canvas timeline. */\n html[data-ambient-motion=\"running\"] svg[data-animation=\"trace\"] [data-animate=\"edge\"] {\n animation: archify-edge-flow 2.4s linear 1;\n animation-delay: calc(var(--step, 0) * 160ms);\n }\n html[data-ambient-motion=\"running\"] svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] {\n animation: archify-edge-flow 2.4s linear 1;\n animation-delay: calc(var(--step, 0) * 160ms);\n }\n html[data-ambient-motion=\"running\"] svg[data-animation=\"trace\"] [data-animate=\"node\"] {\n transform-box: fill-box;\n transform-origin: center;\n animation: archify-node-pulse 3.6s ease-in-out 1;\n animation-delay: calc(var(--step, 0) * 160ms);\n }\n svg[data-preset=\"signal-flow\"][data-animation=\"trace\"] [data-animate=\"edge\"] {\n stroke-linecap: round;\n filter: drop-shadow(0 0 3px var(--arrow-emphasis));\n animation-duration: 1.75s;\n }\n svg[data-preset=\"signal-flow\"][data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { animation-duration: 1.75s; }\n svg[data-preset=\"signal-flow\"][data-animation=\"trace\"] [data-animate=\"node\"] {\n animation-duration: 3.1s;\n }\n svg[data-preset=\"blueprint\"][data-animation=\"trace\"] [data-animate=\"edge\"] {\n stroke-linecap: square;\n filter: none;\n animation-duration: 2.15s;\n }\n svg[data-preset=\"blueprint\"][data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { animation-duration: 2.15s; }\n svg[data-preset=\"blueprint\"][data-animation=\"trace\"] [data-animate=\"node\"] {\n animation-name: archify-blueprint-node-pulse;\n animation-duration: 3.8s;\n }\n svg[data-preset=\"editorial\"][data-animation=\"trace\"] [data-animate=\"edge\"] {\n filter: none;\n animation-duration: 2.2s;\n }\n svg[data-preset=\"editorial\"][data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] { animation-duration: 2.2s; }\n svg[data-preset=\"editorial\"][data-animation=\"trace\"] [data-animate=\"node\"] {\n animation-name: archify-editorial-node-pulse;\n animation-duration: 3.5s;\n }\n /* Embedded proofs stay static so proof grids are calm instead of leaving\n ambient trace loops on. */\n html[data-embed=\"true\"] svg[data-animation=\"trace\"] [data-animate],\n html[data-share-playback=\"true\"] svg[data-animation=\"trace\"] [data-animate] {\n animation: none !important;\n stroke-dashoffset: 0;\n }\n html[data-embed=\"true\"] svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"],\n html[data-share-playback=\"true\"] svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] {\n animation: none !important;\n stroke-dashoffset: 0;\n }\n @keyframes archify-edge-flow {\n 0% { stroke-dasharray: 10 8; stroke-dashoffset: 54; opacity: 0.42; }\n 88% { stroke-dasharray: 10 8; stroke-dashoffset: 0; opacity: 1; }\n 99.9% { stroke-dasharray: 10 8; stroke-dashoffset: 0; opacity: 1; }\n 100% { stroke-dashoffset: 0; opacity: 1; }\n }\n @keyframes archify-node-pulse {\n 0%, 72%, 100% { filter: none; stroke-width: 1.5; }\n 18%, 36% {\n filter: drop-shadow(0 0 8px var(--arrow-emphasis));\n stroke-width: 2.4;\n }\n }\n @keyframes archify-blueprint-node-pulse {\n 0%, 72%, 100% { opacity: 1; filter: none; }\n 18%, 36% { opacity: 0.72; filter: drop-shadow(0 0 2px var(--frontend-stroke)); }\n }\n @keyframes archify-editorial-node-pulse {\n 0%, 72%, 100% { opacity: 1; filter: none; }\n 18%, 36% { opacity: 0.78; filter: drop-shadow(0 2px 2px color-mix(in srgb, var(--text) 18%, transparent)); }\n }\n @keyframes archify-signal-scan {\n 0%, 18% { opacity: 1; transform: translateX(-70%); }\n 70% { opacity: 1; transform: translateX(70%); }\n 100% { opacity: 0; transform: translateX(70%); }\n }\n @keyframes archify-radar-live {\n 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--backend-stroke) 52%, transparent); }\n 55%, 100% { box-shadow: 0 0 0 0.32rem transparent; }\n }\n\n @keyframes archify-intent-trace-flow {\n 0% { opacity: 0.28; stroke-dashoffset: 0; }\n 12%, 78% { opacity: 0.94; }\n 100% { opacity: 0; stroke-dashoffset: -1; }\n }\n @keyframes archify-route-probe-flow {\n 0% { stroke-dashoffset: 0; opacity: 0.96; }\n 78% { stroke-dashoffset: -1; opacity: 0.96; }\n 100% { stroke-dasharray: none; stroke-dashoffset: 0; opacity: 0.58; }\n }\n @keyframes archify-route-journey-flow {\n 0% { opacity: 0.16; stroke-dashoffset: 0; }\n 14%, 76% { opacity: 1; }\n 100% { opacity: 0; stroke-dashoffset: -1; }\n }\n @keyframes archify-semantic-lens-flow {\n 0% { opacity: 0.2; stroke-dashoffset: 0; }\n 12%, 78% { opacity: 0.9; }\n 100% { opacity: 0; stroke-dashoffset: -1; }\n }\n @keyframes archify-relationship-pulse {\n 0% { opacity: 0.18; stroke-dashoffset: 0; }\n 10%, 76% { opacity: 0.98; }\n 100% { opacity: 0; stroke-dashoffset: -1; }\n }\n @keyframes archify-relationship-token-life {\n 0%, 7% { opacity: 0; }\n 13%, 82% { opacity: 1; }\n 100% { opacity: 0; }\n }\n\n @keyframes archify-share-cue-enter {\n from { opacity: 0; transform: translate(-50%, -0.45rem); }\n to { opacity: 1; transform: translate(-50%, 0); }\n }\n @keyframes archify-share-cue-pulse {\n 0%, 100% { opacity: 1; transform: scale(1); }\n 50% { opacity: 0.48; transform: scale(0.78); }\n }\n @media (prefers-reduced-motion: reduce) {\n html[data-preset=\"signal-flow\"] .diagram-container::before {\n animation: none !important;\n }\n .pulse-dot { animation: none !important; }\n svg[data-animation=\"trace\"] [data-animate] {\n animation: none !important;\n stroke-dashoffset: 0;\n }\n svg[data-animation=\"trace\"] [data-graph-role=\"automatic-crossover\"]:has(\u003e [data-animate=\"edge\"]) \u003e [data-graph-role=\"automatic-crossover-underlay\"] {\n animation: none !important;\n stroke-dashoffset: 0;\n }\n .intent-trace-flow,\n .route-probe-flow,\n .semantic-lens,\n .diagram-guide,\n .overview-map-live { animation: none !important; }\n \n .intent-trace-flow {\n animation: none !important;\n stroke-dasharray: none;\n stroke-dashoffset: 0;\n opacity: 0.72;\n }\n .route-probe-flow {\n animation: none !important;\n stroke-dasharray: none;\n stroke-dashoffset: 0;\n opacity: 0.78;\n }\n .route-journey-overlay { display: none !important; }\n .semantic-lens-flow {\n animation: none !important;\n stroke-dasharray: none;\n stroke-width: 2.2;\n opacity: 0.34;\n filter: none;\n }\n .relationship-pulse-overlay { display: none !important; }\n svg [data-node-id], svg [data-edge-from], svg [data-detail], svg [data-detail-anchor], svg [data-legend-hit], svg { transition: none !important; }\n }\n ";
let activeIndex = -1;
let playbackToken = 0;
let playbackTimer = 0;
diff --git a/examples/checkout-platform-delta.receipt.json b/examples/checkout-platform-delta.receipt.json
index c2e13bbb..f50d0251 100644
--- a/examples/checkout-platform-delta.receipt.json
+++ b/examples/checkout-platform-delta.receipt.json
@@ -219,8 +219,8 @@
"Boundary identity is conservatively derived from kind + label."
],
"artifact": {
- "sha256": "f11fe32ffad8a31c076b7d9ca1446b23b0bc667571d33cac5520d9f7615e99cc",
- "bytes": 2157141
+ "sha256": "e41cdddfc05b3b96caaf999a0ed2519f789763fd53d8f35eda318ae99cc93e5d",
+ "bytes": 2158762
},
"validation": {
"checksPassed": 28,
diff --git a/examples/class-payment-processors-rendered.html b/examples/class-payment-processors-rendered.html
index 0e11654d..adb2dd4a 100644
--- a/examples/class-payment-processors-rendered.html
+++ b/examples/class-payment-processors-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9657,6 +9658,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9945,7 +9948,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9964,17 +9967,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -10010,10 +10017,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/examples/class-payments-rendered.html b/examples/class-payments-rendered.html
index 7c6db689..b14b4e2e 100644
--- a/examples/class-payments-rendered.html
+++ b/examples/class-payments-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9463,6 +9464,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9751,7 +9754,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9770,17 +9773,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9816,10 +9823,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/examples/dataflow-product-analytics.html b/examples/dataflow-product-analytics.html
index 8c4324d8..61c0124a 100644
--- a/examples/dataflow-product-analytics.html
+++ b/examples/dataflow-product-analytics.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9577,6 +9578,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9865,7 +9868,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9884,17 +9887,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9930,10 +9937,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/examples/erd-orders-rendered.html b/examples/erd-orders-rendered.html
index 91af14e9..39f1bf9a 100644
--- a/examples/erd-orders-rendered.html
+++ b/examples/erd-orders-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9745,6 +9746,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -10033,7 +10036,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -10052,17 +10055,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -10098,10 +10105,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/examples/lifecycle-agent-run.html b/examples/lifecycle-agent-run.html
index a767d1d7..c87f6035 100644
--- a/examples/lifecycle-agent-run.html
+++ b/examples/lifecycle-agent-run.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9589,6 +9590,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9877,7 +9880,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9896,17 +9899,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9942,10 +9949,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/examples/sequence-cache-miss-request.html b/examples/sequence-cache-miss-request.html
index 0a061a5e..c57e6d3e 100644
--- a/examples/sequence-cache-miss-request.html
+++ b/examples/sequence-cache-miss-request.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9592,6 +9593,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9880,7 +9883,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9899,17 +9902,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9945,10 +9952,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/examples/subscription-billing-rendered.html b/examples/subscription-billing-rendered.html
index aa2620b8..efb24310 100644
--- a/examples/subscription-billing-rendered.html
+++ b/examples/subscription-billing-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9969,6 +9970,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -10257,7 +10260,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -10276,17 +10279,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -10322,10 +10329,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/examples/timeline-archify-dev-activity-rendered.html b/examples/timeline-archify-dev-activity-rendered.html
index d4b42263..038afc22 100644
--- a/examples/timeline-archify-dev-activity-rendered.html
+++ b/examples/timeline-archify-dev-activity-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9669,6 +9670,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9957,7 +9960,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9976,17 +9979,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -10022,10 +10029,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/examples/timeline-payment-incident-rendered.html b/examples/timeline-payment-incident-rendered.html
index 7c88097e..8b0de775 100644
--- a/examples/timeline-payment-incident-rendered.html
+++ b/examples/timeline-payment-incident-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9454,6 +9455,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9742,7 +9745,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9761,17 +9764,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9807,10 +9814,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/examples/tree-archify-repository-rendered.html b/examples/tree-archify-repository-rendered.html
index b3c3564d..b5029f81 100644
--- a/examples/tree-archify-repository-rendered.html
+++ b/examples/tree-archify-repository-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9688,6 +9689,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9976,7 +9979,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9995,17 +9998,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -10041,10 +10048,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/examples/tree-payment-platform-rendered.html b/examples/tree-payment-platform-rendered.html
index ff38a6e6..9355cb70 100644
--- a/examples/tree-payment-platform-rendered.html
+++ b/examples/tree-payment-platform-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9469,6 +9470,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9757,7 +9760,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9776,17 +9779,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9822,10 +9829,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/examples/waterfall-checkout-request-rendered.html b/examples/waterfall-checkout-request-rendered.html
index 21d8f377..e112b297 100644
--- a/examples/waterfall-checkout-request-rendered.html
+++ b/examples/waterfall-checkout-request-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9451,6 +9452,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9739,7 +9742,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9758,17 +9761,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9804,10 +9811,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/examples/waterfall-example-rebuild-rendered.html b/examples/waterfall-example-rebuild-rendered.html
index c5d2aee8..880e7723 100644
--- a/examples/waterfall-example-rebuild-rendered.html
+++ b/examples/waterfall-example-rebuild-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9637,6 +9638,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9925,7 +9928,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9944,17 +9947,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9990,10 +9997,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/examples/web-app-rendered.html b/examples/web-app-rendered.html
index 11ff2214..f8e9cb64 100644
--- a/examples/web-app-rendered.html
+++ b/examples/web-app-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9565,6 +9566,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9853,7 +9856,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9872,17 +9875,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9918,10 +9925,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/examples/web-app.html b/examples/web-app.html
index 7b6abc27..c7a5c14b 100644
--- a/examples/web-app.html
+++ b/examples/web-app.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9565,6 +9566,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9853,7 +9856,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9872,17 +9875,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9918,10 +9925,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/examples/workflow-agent-tool-call-rendered.html b/examples/workflow-agent-tool-call-rendered.html
index 314cca9f..8c58a40a 100644
--- a/examples/workflow-agent-tool-call-rendered.html
+++ b/examples/workflow-agent-tool-call-rendered.html
@@ -599,7 +599,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
color: var(--frontend-stroke);
}
- /* The reader owns only the outer scale. Long sequences and waterfall rows
+ /* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */
@@ -9583,6 +9584,8 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -9871,7 +9874,7 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -9890,17 +9893,21 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -9936,10 +9943,13 @@ OTHER DEALINGS IN THE FONT SOFTWARE.
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/test/fixtures/reader-readability/compact-roundtrip.sequence.json b/test/fixtures/reader-readability/compact-roundtrip.sequence.json
new file mode 100644
index 00000000..d9328932
--- /dev/null
+++ b/test/fixtures/reader-readability/compact-roundtrip.sequence.json
@@ -0,0 +1,124 @@
+{
+ "schema_version": 1,
+ "diagram_type": "sequence",
+ "meta": {
+ "title": "Compact request roundtrip",
+ "locale": "en",
+ "output": "diagram.html",
+ "quality_profile": "showcase"
+ },
+ "participants": [
+ {
+ "id": "client",
+ "type": "backend",
+ "label": "Client",
+ "sublabel": "Request sender"
+ },
+ {
+ "id": "service",
+ "type": "backend",
+ "label": "Service",
+ "sublabel": "Queue and storage"
+ },
+ {
+ "id": "worker",
+ "type": "backend",
+ "label": "Worker",
+ "sublabel": "Task runner"
+ }
+ ],
+ "segments": [
+ {
+ "from": 150,
+ "to": 325,
+ "label": "Request and delivery"
+ },
+ {
+ "from": 355,
+ "to": 560,
+ "label": "Result and receipt"
+ }
+ ],
+ "messages": [
+ {
+ "id": "send",
+ "from": "client",
+ "to": "service",
+ "y": 170,
+ "label": "Submit task",
+ "variant": "emphasis",
+ "note": "Validate the request and store the task before starting asynchronous delivery."
+ },
+ {
+ "id": "accepted",
+ "from": "service",
+ "to": "client",
+ "y": 230,
+ "label": "Accepted",
+ "variant": "return",
+ "note": "Confirm acceptance without waiting for completion; delivery can occur independently."
+ },
+ {
+ "id": "deliver",
+ "from": "service",
+ "to": "worker",
+ "y": 290,
+ "label": "Deliver task",
+ "variant": "dashed",
+ "note": "Wait for an available worker before delivering queued work to the task runner."
+ },
+ {
+ "id": "report",
+ "from": "worker",
+ "to": "service",
+ "y": 380,
+ "label": "Submit result",
+ "variant": "emphasis",
+ "note": "After execution, validate the open task and store the result and pending notification."
+ },
+ {
+ "id": "receipt",
+ "from": "service",
+ "to": "worker",
+ "y": 450,
+ "label": "Result accepted",
+ "variant": "return",
+ "note": "Acknowledge the stored result; this does not imply that the sender has read it."
+ },
+ {
+ "id": "notify",
+ "from": "service",
+ "to": "client",
+ "y": 520,
+ "label": "Deliver result",
+ "variant": "dashed",
+ "note": "Notify the sender when available; otherwise keep the result queued for later delivery."
+ }
+ ],
+ "cards": [
+ {
+ "dot": "cyan",
+ "title": "Request",
+ "items": [
+ "The service accepts a request before a worker completes it.",
+ "Vertical order describes logical steps rather than elapsed time."
+ ]
+ },
+ {
+ "dot": "amber",
+ "title": "Delivery",
+ "items": [
+ "Accepted work can remain queued until the worker becomes available.",
+ "Delivery failure does not imply that the request was never stored."
+ ]
+ },
+ {
+ "dot": "emerald",
+ "title": "Result",
+ "items": [
+ "Results are stored before the sender receives a notification.",
+ "A successful response does not imply that the sender has read it."
+ ]
+ }
+ ]
+}
diff --git a/test/reader-layout-browser.test.mjs b/test/reader-layout-browser.test.mjs
index 6a0928e9..a3ec9432 100644
--- a/test/reader-layout-browser.test.mjs
+++ b/test/reader-layout-browser.test.mjs
@@ -631,6 +631,96 @@ test('Reader Layout preserves final-artifact behavior across its ownership bound
assert.ok(await evaluate("document.querySelector('.diagram-container > svg').clientWidth > 456 * 1.5"),
'an authored canvas retains its previous enlargement behavior');
});
+ await t.test('compact automatic Sequence fits the initial desktop stage without shrinking source text', async () => {
+ const compact = JSON.parse(fs.readFileSync(path.resolve(skillRoot,
+ '../test/fixtures/reader-readability/compact-roundtrip.sequence.json'), 'utf8'));
+ function renderSequence(name, doc) {
+ const input = path.join(scratch, `${name}.json`);
+ const output = path.join(scratch, `${name}.html`);
+ fs.writeFileSync(input, JSON.stringify(doc));
+ execFileSync(process.execPath, [path.join(skillRoot, 'bin/archify.mjs'), 'render', 'sequence', input, output]);
+ return output;
+ }
+ async function stage(label) {
+ const value = await evaluate(`(function () {
+ var svg = document.querySelector('.diagram-container > svg');
+ function bounds(element) {
+ var rect = element.getBoundingClientRect();
+ return { top: rect.top, bottom: rect.bottom, left: rect.left, right: rect.right };
+ }
+ var textScales = Array.from(svg.querySelectorAll('text')).map(function (text) {
+ var matrix = text.getScreenCTM();
+ return Math.hypot(matrix.a, matrix.b);
+ });
+ return { svg: bounds(svg), stage: bounds(svg.parentElement),
+ controls: bounds(document.querySelector('.diagram-nav')),
+ width: svg.clientWidth, sourceWidth: svg.viewBox.baseVal.width,
+ minimumTextScale: Math.min.apply(Math, textScales),
+ viewportWidth: innerWidth, viewportHeight: innerHeight,
+ geometry: ['viewBox', 'width', 'height'].map(function (name) { return svg.getAttribute(name); }) };
+ })()`);
+ records.push({ label, ...value });
+ return value;
+ }
+ function fits(value) {
+ for (const region of [value.svg, value.stage, value.controls]) {
+ assert.ok(region.top >= -1 && region.bottom <= value.viewportHeight + 1 &&
+ region.left >= -1 && region.right <= value.viewportWidth + 1, JSON.stringify(value));
+ }
+ assert.ok(value.minimumTextScale >= 1 - 0.01, 'initial fitting must retain source text size: ' + JSON.stringify(value));
+ assert.ok(value.width <= value.sourceWidth * 1.5 + 1, 'automatic enlargement remains capped: ' + JSON.stringify(value));
+ }
+ const file = renderSequence('compact-roundtrip', compact);
+ await load(file, { width: 1396, height: 830 });
+ const initial = await stage('compact-sequence-initial');
+ fits(initial);
+ assert.ok((await snapshot('compact-sequence-shell')).shellWidth >= 960, 'height fitting preserves the desktop shell');
+ await viewport(1396, 540);
+ await stable();
+ const short = await stage('compact-sequence-short-window');
+ assert.ok(short.stage.bottom > short.viewportHeight, 'insufficient height retains page scrolling');
+ assert.ok(short.minimumTextScale >= 1 - 0.01, 'short windows do not shrink source text');
+ assert.ok(short.width >= initial.width, 'short windows recover reading width');
+ await viewport(1396, 830);
+ await stable();
+ fits(await stage('compact-sequence-resized-back'));
+ await evaluate('Archify.presentation.enter()');
+ await stable();
+ const presented = await stage('compact-sequence-presentation');
+ assert.ok(presented.svg.top >= -1 && presented.svg.bottom <= presented.viewportHeight + 1, JSON.stringify(presented));
+ await evaluate('Archify.presentation.exit()');
+ await stable();
+ const returned = await stage('compact-sequence-return');
+ fits(returned);
+ assert.deepEqual(returned.geometry, initial.geometry, 'fitting never rewrites authored SVG geometry');
+
+ const wide = { ...compact, segments: [], cards: [],
+ messages: [{ from: 'client', to: 'worker', y: 160, label: 'Check status' }] };
+ await load(renderSequence('short-wide-sequence', wide), { width: 1396, height: 480 });
+ const shortWide = await stage('short-wide-sequence');
+ assert.ok(shortWide.sourceWidth < 960 && shortWide.sourceWidth /
+ Number(shortWide.geometry[0].split(/\s+/)[3]) >= 1.55, 'exercise a small wide canvas');
+ fits(shortWide);
+
+ const long = { ...compact, segments: [], cards: [], messages: Array.from({ length: 20 }, (_, index) => ({
+ from: index % 2 ? 'service' : 'client', to: index % 2 ? 'client' : 'service',
+ y: 160 + index * 100, label: `Message ${index + 1}`,
+ })) };
+ await load(renderSequence('long-automatic-sequence', long), { width: 1396, height: 830 });
+ const reading = await stage('long-automatic-sequence');
+ assert.ok(reading.stage.bottom > reading.viewportHeight, 'long automatic Sequence retains page scrolling');
+ assert.ok(reading.minimumTextScale >= 1 - 0.01, 'long Sequence preserves readable text');
+ assert.ok(reading.width >= reading.sourceWidth * 1.4, 'long Sequence retains reading-width enlargement');
+
+ const explicit = structuredClone(compact);
+ explicit.meta.viewBox = initial.geometry[0].split(/\s+/).slice(2).map(Number);
+ await load(renderSequence('explicit-roundtrip', explicit), { width: 1396, height: 830 });
+ const authored = await stage('explicit-roundtrip');
+ assert.deepEqual(authored.geometry, initial.geometry);
+ assert.equal((await snapshot('explicit-sequence')).readerFit, null, 'explicit canvases retain their previous eligibility');
+ assert.ok(authored.stage.bottom > authored.viewportHeight, 'explicit geometry retains its original desktop layout');
+ });
+
await t.test('public renderers declare automatic reading width while undeclared canvases retain their fit', async () => {
const sequence = { schema_version: 1, diagram_type: 'sequence', meta: { title: 'Reader sequence', output: 'reader-sequence.html' },
participants: [{ id: 'a', type: 'external', label: 'Client' }, { id: 'b', type: 'backend', label: 'Server' }],
diff --git a/viewer/reader-layout.js b/viewer/reader-layout.js
index 567d2969..dfafa0c9 100644
--- a/viewer/reader-layout.js
+++ b/viewer/reader-layout.js
@@ -11,6 +11,8 @@
var ratio = viewBox && viewBox.height > 0 ? viewBox.width / viewBox.height : 0;
var readerFit = svg && svg.getAttribute('data-reader-fit');
var widthFirstReading = readerFit === 'width-first';
+ var automaticSequence = widthFirstReading && svg.hasAttribute('data-sequence-column-fit');
+ var readingScroll = widthFirstReading;
var measuredHeightFit = readerFit === 'intrinsic-height' || widthFirstReading;
var frame = 0;
var settleFrame = 0;
@@ -299,7 +301,7 @@
) - window.innerHeight - belowFold();
// visual-check fails any page whose rounded-up height exceeds the
// viewport, so even a 1px remainder must be reduced or declared.
- if (overflow > 0 && !widthFirstReading && lastWidth > Math.ceil(minWidth)) {
+ if (overflow > 0 && !readingScroll && lastWidth > Math.ceil(minWidth)) {
applyWidth(Math.max(minWidth, lastWidth - overflow * ratio - 4), minWidth);
settledCap = lastWidth;
html.setAttribute('data-reader-overflow', 'reduced');
@@ -318,17 +320,21 @@
}
var chrome = chromeMetrics();
var viewportCap = Math.max(0, window.innerWidth - chrome.bodyX);
+ // Sequence first-screen fitting preserves source text sizes instead
+ // of shrinking to the shared hard readability floor.
var readableWidth = viewBox && viewBox.width > 0
- ? viewBox.width * minimumReadableScale() + chrome.diagramX
+ ? viewBox.width * (automaticSequence ? 1 : minimumReadableScale()) + chrome.diagramX
: MIN_READER_WIDTH;
var maxWidth = Math.min(MAX_READER_WIDTH, viewportCap);
- var readableMinimumWidth = measuredHeightFit && ratio < WIDE_RATIO
+ var readableMinimumWidth = automaticSequence || measuredHeightFit && ratio < WIDE_RATIO
? readableWidth
: measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)
? Math.max(MIN_READER_WIDTH, readableWidth)
: MIN_READER_WIDTH;
var minWidth;
- if (measuredHeightFit && ratio < WIDE_RATIO) {
+ if (automaticSequence) {
+ minWidth = Math.min(readableMinimumWidth, maxWidth);
+ } else if (measuredHeightFit && ratio < WIDE_RATIO) {
minWidth = Math.min(readableMinimumWidth, viewportCap);
} else if (measuredHeightFit && ratio >= WIDE_RATIO && Number.isFinite(declaredMinimumText)) {
minWidth = Math.min(readableMinimumWidth, maxWidth);
@@ -364,10 +370,13 @@
outerHeight(header) + stackedBelow;
var availableSvgHeight = Math.max(1, window.innerHeight - fixedHeight);
var desiredWidth = availableSvgHeight * ratio + chrome.diagramX + (docked ? railExtra : 0);
- // Long sequences and waterfall rows use the available horizontal room;
- // ordinary page scrolling keeps their text and row spacing readable.
- // Other diagram families retain the existing height-fit strategy.
- if (widthFirstReading) desiredWidth = maxWidth;
+ // Compact automatic sequences fit the first screen without shrinking
+ // their authored text. Longer sequences retain reading width and page
+ // scroll; other width-first families keep their existing strategy.
+ var sequenceFits = automaticSequence && Math.min(desiredWidth, maxWidth) >=
+ readableWidth + (docked ? railExtra : 0);
+ readingScroll = widthFirstReading && !sequenceFits;
+ if (readingScroll) desiredWidth = maxWidth;
// Only a binding enlargement cap needs a separate normal reader area.
// Uncapped diagrams keep their existing natural height and Chrome fit.
automaticAreaHeight = availableSvgHeight + chrome.diagramY;
diff --git a/viewer/viewer.css b/viewer/viewer.css
index 6bc99e80..18f5c185 100644
--- a/viewer/viewer.css
+++ b/viewer/viewer.css
@@ -430,7 +430,8 @@ html[data-present="true"]:not([data-embed="true"]) #btn-present {
color: var(--frontend-stroke);
}
-/* The reader owns only the outer scale. Long sequences and waterfall rows
+/* The reader owns only the outer scale. Compact automatic sequences fit at
+ their authored text size or larger. Long sequences and waterfall rows
favor reading width and page scroll; other diagrams keep height fitting.
Small automatic canvases retain a modest scale inside a usable shell.
Every strategy preserves the authored SVG/viewBox and semantic geometry. */