diff --git a/docs/githire.css b/docs/githire.css
index 443c91c..6d4baf9 100644
--- a/docs/githire.css
+++ b/docs/githire.css
@@ -366,6 +366,22 @@ main, .topnav, .site-foot { position: relative; z-index: 1; }
text-align: center;
padding: 0 var(--gutter);
}
+/* Soft paper scrim between the moving canvas and the text. Sits inside the
+ hero's stacking context (so it's above the z-0 canvas) but behind the copy,
+ lifting legibility while the starfield still reads through at the edges. */
+.hero-content::before{
+ content: "";
+ position: absolute;
+ inset: -10% -8%;
+ z-index: -1;
+ pointer-events: none;
+ background: radial-gradient(
+ ellipse 76% 66% at 50% 47%,
+ rgba(246, 241, 232, 0.85) 0%,
+ rgba(246, 241, 232, 0.66) 40%,
+ rgba(246, 241, 232, 0) 76%
+ );
+}
.hero-title{
font-family: var(--font-serif);
font-weight: 500;
diff --git a/docs/i18n.js b/docs/i18n.js
index b1331e7..93769b3 100644
--- a/docs/i18n.js
+++ b/docs/i18n.js
@@ -937,6 +937,14 @@
return 'en';
}
+ // Normalize markup for comparison only: collapse insignificant whitespace
+ // and drop the self-closing slash on void elements. The browser serializes
+ // `
` as `
`, so without this the dictionary source (which writes
+ // `
`) would never match the DOM and we'd re-render needlessly.
+ function normMarkup(s) {
+ return s.replace(/\s+/g, ' ').replace(/\s*\/>/g, '>').trim();
+ }
+
function applyTo(root, lang) {
var els = root.querySelectorAll('[data-i18n]');
for (var i = 0; i < els.length; i++) {
@@ -944,6 +952,13 @@
var key = el.getAttribute('data-i18n');
var entry = T[key];
if (!entry || typeof entry[lang] !== 'string') continue;
+ // Skip the swap when the element already renders this exact markup.
+ // The page ships in its own language, so on first load every value
+ // already matches — re-setting innerHTML would needlessly reflow the
+ // page and restart the hero's CSS entrance animation, making the
+ // slogan visibly "jump" a second time. Comparison only; a mismatch
+ // (a real language switch) still updates as before.
+ if (normMarkup(el.innerHTML) === normMarkup(entry[lang])) continue;
el.innerHTML = entry[lang];
}