From 68555020d4899e5450466ff199c0da943a34c5a3 Mon Sep 17 00:00:00 2001 From: Pieter Viljoen Date: Tue, 29 Sep 2026 08:11:40 -0700 Subject: [PATCH 1/6] Raise the Family Page's Smallest Text to a Comfortable Reading Size The root size now grows with the viewport from 16px to 20px, and the frame, masthead, and couple card widths are in rem, so a wide screen scales the whole page up rather than leaving small text in a narrow column. The secondary lines rise to a 1rem floor, and the Cormorant Garamond italic lines run about an eighth larger than the EB Garamond lines beside them, since that face reads smaller at the same size. The stacked layout now starts at 1000px, because six columns of the larger text no longer fit at 910px. The legend's entries wrap as whole units, which removes the horizontal scroll at 360px and below. --- sites/viljoen.family/README.md | 3 ++- sites/viljoen.family/site.css | 37 +++++++++++++++++----------------- 2 files changed, 21 insertions(+), 19 deletions(-) diff --git a/sites/viljoen.family/README.md b/sites/viljoen.family/README.md index 3c72a366..af02529c 100644 --- a/sites/viljoen.family/README.md +++ b/sites/viljoen.family/README.md @@ -51,6 +51,7 @@ The arms derive from the French family Villon de Varennes, whose crest was a gol - **Palette:** parchment `#f4ead3`, cards `#fbf5e4`, red `#9e1b22`, gold `#b8862b`, bark `#5b3f27`, leaf `#6f7d3a`, all CSS variables in `:root`. - **Fonts (Google Fonts):** Cormorant Garamond for headings, EB Garamond for body text. +- **Type scale:** the root size grows with the viewport from 16px up to 20px, and the frame, masthead, and couple card widths are in `rem`, so on a wide screen the whole page scales up rather than leaving the text small in a narrow column. No text sits below `1rem` except the "Viljoen line" badge and the stub on mid-width screens (`.95rem`). Cormorant Garamond has a smaller x-height than EB Garamond, so its italic secondary lines run about an eighth larger than the EB Garamond lines beside them. - **Frame:** a 2.5px red border plus an inner 1px gold rule (`.frame::before`) with rounded corners and four gold corner flourishes (`#corner` symbol). A negative margin on the masthead equals the frame's top margin (128px, or 96px on phones). That puts the top border behind the mantling, so change both values together. - **Paper texture:** an inline SVG `feTurbulence` noise data URI plus a radial vignette on `html`. - **Divider:** a simplified Huguenot cross (a Maltese cross with fleur points, balls on the tips, and a hanging dove), the `#huguenot-cross` symbol. @@ -72,7 +73,7 @@ The tree is a stamboom. The children form the crown, and the stamouers card sits - Leaves sprout at chosen positions along a limb, alternating sides (`leaves()`). The pattern is fixed rather than random, so every redraw looks the same. About one leaf in five is gold. - **Roots:** seven tapering roots run from the bottom of the couple card into the soil band, in both layouts. - **Wide layout** (six cards in a row): a trunk rises from the couple card to a fork. One S-curve branch runs from there to the bottom of each child card. A short limb continues from each name-carrying card to its stub. -- **Stacked layout** (900px wide or less): the cards form a column. The trunk rises up the left gutter from the couple card, with a twig into each card. A "Stamouers" jump link at the top leads to the couple card, which sits below the children. +- **Stacked layout** (1000px wide or less): the cards form a column. The trunk rises up the left gutter from the couple card, with a twig into each card. A "Stamouers" jump link at the top leads to the couple card, which sits below the children. - It redraws on resize, on load, when the fonts finish loading, and through a `ResizeObserver`. With JavaScript off the page still reads correctly, without branches. ## Facts on the Page and Their Sources diff --git a/sites/viljoen.family/site.css b/sites/viljoen.family/site.css index f7bc7153..f1939df2 100644 --- a/sites/viljoen.family/site.css +++ b/sites/viljoen.family/site.css @@ -15,6 +15,7 @@ } * { box-sizing: border-box; } html { + font-size: clamp(100%, calc(.75rem + .35vw), 125%); background: var(--paper-tex), radial-gradient(ellipse at 50% 30%, #f7efdc 0%, var(--paper) 55%, #e6d5ae 100%) fixed; background-color: var(--paper); } @@ -30,7 +31,7 @@ a:hover { text-decoration-color: currentColor; } /* ---------- Page frame: double rule, rounded, hung from the crest ---------- */ .frame { position: relative; - max-width: 1180px; + max-width: 73.75rem; margin: 128px auto 0; padding: 0 clamp(18px, 4vw, 60px) 40px; border: 2.5px solid var(--red); @@ -59,7 +60,7 @@ a:hover { text-decoration-color: currentColor; } .masthead { position: relative; margin: -128px auto 0; - width: min(340px, 78vw); + width: min(21.25rem, 78vw); text-align: center; z-index: 1; } @@ -81,7 +82,7 @@ a:hover { text-decoration-color: currentColor; } .couple, .child, .stub { position: relative; z-index: 1; } .couple { width: 100%; - max-width: 620px; + max-width: 38.75rem; margin: 170px auto 0; padding: 20px 28px 18px; text-align: center; @@ -92,7 +93,7 @@ a:hover { text-decoration-color: currentColor; } } .eyebrow { margin: 0 0 4px; - font: italic 500 1rem/1.3 "Cormorant Garamond", serif; + font: italic 500 1.125rem/1.3 "Cormorant Garamond", serif; letter-spacing: .06em; color: var(--ink-soft); } @@ -103,7 +104,7 @@ a:hover { text-decoration-color: currentColor; } } .couple h2 .x { font-weight: 500; color: var(--gold); padding: 0 .15em; } .couple h2 .nm { white-space: nowrap; } -.couple p.meta { margin: 8px 0 0; font-size: 1rem; color: var(--ink-soft); line-height: 1.45; } +.couple p.meta { margin: 8px 0 0; font-size: 1.0625rem; color: var(--ink-soft); line-height: 1.45; } .soil { display: flex; @@ -139,12 +140,12 @@ a:hover { text-decoration-color: currentColor; } .code { display: inline-block; margin-bottom: 2px; - font: italic 500 .85rem/1 "Cormorant Garamond", serif; + font: italic 500 1rem/1 "Cormorant Garamond", serif; color: var(--gold); letter-spacing: .05em; } .child h3 { margin: 0; font: 700 1.4rem/1.1 "Cormorant Garamond", serif; color: var(--ink); } -.child p { margin: 6px 0 0; font-size: .92rem; line-height: 1.35; color: var(--ink-soft); } +.child p { margin: 6px 0 0; font-size: 1rem; line-height: 1.35; color: var(--ink-soft); } .child p.spouse { font-style: italic; } .vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; } abbr[title] { text-decoration: none; cursor: help; font-style: normal; font-weight: 500; color: var(--red-deep); } @@ -155,7 +156,7 @@ abbr[title] { text-decoration: none; cursor: help; font-style: normal; font-weig margin: 8px auto 0; width: max-content; padding: 1px 10px 2px; - font: italic 500 .8rem/1.3 "Cormorant Garamond", serif; + font: italic 500 .95rem/1.3 "Cormorant Garamond", serif; color: var(--paper-card); background: var(--red); border-radius: 999px; @@ -164,7 +165,7 @@ abbr[title] { text-decoration: none; cursor: help; font-style: normal; font-weig align-self: center; margin: 0 0 54px; padding: 2px 12px 3px; - font: italic 500 .9rem/1.3 "Cormorant Garamond", serif; + font: italic 500 1.05rem/1.3 "Cormorant Garamond", serif; color: var(--leaf-dark); background: var(--paper-card); border: 1px dashed var(--leaf); @@ -173,14 +174,14 @@ abbr[title] { text-decoration: none; cursor: help; font-style: normal; font-weig white-space: nowrap; } .legend, .tree-note { - max-width: 680px; + max-width: 42.5rem; margin: 22px auto 0; text-align: center; color: var(--ink-soft); } -.legend { font-size: 1rem; } -.legend > span { white-space: nowrap; padding: 0 .5em; } -.tree-note { margin-top: 10px; font-style: italic; font-size: 1rem; } +.legend { font-size: 1.0625rem; } +.legend > span { display: inline-block; padding: 0 .5em; } +.tree-note { margin-top: 10px; font-style: italic; font-size: 1.0625rem; } /* ---------- Divider (Huguenot cross) ---------- */ .divider { @@ -209,7 +210,7 @@ abbr[title] { text-decoration: none; cursor: help; font-style: normal; font-weig } .story h2 small { display: block; - font: italic 500 1rem/1.4 "Cormorant Garamond", serif; + font: italic 500 1.125rem/1.4 "Cormorant Garamond", serif; color: var(--gold); letter-spacing: .04em; } @@ -224,21 +225,21 @@ abbr[title] { text-decoration: none; cursor: help; font-style: normal; font-weig .links { list-style: none; margin: 0; padding: 0; } .links li { padding: 7px 0; border-bottom: 1px dotted color-mix(in srgb, var(--gold) 60%, transparent); } .links li:last-child { border-bottom: 0; } -.links span { display: block; font-size: .92rem; color: var(--ink-soft); line-height: 1.35; } +.links span { display: block; font-size: 1rem; color: var(--ink-soft); line-height: 1.35; } footer { margin-top: 44px; text-align: center; - font: italic 500 1rem/1.5 "Cormorant Garamond", serif; + font: italic 500 1.125rem/1.5 "Cormorant Garamond", serif; color: var(--ink-soft); } @media (max-width: 1100px) { - .stub { padding: 2px 8px 3px; font-size: .8rem; } + .stub { padding: 2px 8px 3px; font-size: .95rem; } } /* ---------- Narrow screens: the tree becomes a single descending line ---------- */ -@media (max-width: 900px) { +@media (max-width: 1000px) { .jump { display: block; width: max-content; From 79c9cab19168d171e0ecaaee1fd72eef4eeb6411 Mon Sep 17 00:00:00 2001 From: Pieter Viljoen Date: Tue, 29 Sep 2026 08:19:24 -0700 Subject: [PATCH 2/6] Keep the Family Page's Stubs and Crest in Step With the Larger Text The frame's top margin and the masthead's matching negative margin move to rem, like the masthead width, so the border meets the crest at the same point as the root size grows. The "c generation to follow" stubs wrap inside their columns rather than overlapping when the reader's default font is larger than 16px, and the soil labels and the language switch on phones rise to the 1rem floor. The README's type scale bullet now states the floors the CSS actually sets. --- sites/viljoen.family/README.md | 4 ++-- sites/viljoen.family/site.css | 14 +++++++------- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/sites/viljoen.family/README.md b/sites/viljoen.family/README.md index af02529c..4d50b7f3 100644 --- a/sites/viljoen.family/README.md +++ b/sites/viljoen.family/README.md @@ -51,8 +51,8 @@ The arms derive from the French family Villon de Varennes, whose crest was a gol - **Palette:** parchment `#f4ead3`, cards `#fbf5e4`, red `#9e1b22`, gold `#b8862b`, bark `#5b3f27`, leaf `#6f7d3a`, all CSS variables in `:root`. - **Fonts (Google Fonts):** Cormorant Garamond for headings, EB Garamond for body text. -- **Type scale:** the root size grows with the viewport from 16px up to 20px, and the frame, masthead, and couple card widths are in `rem`, so on a wide screen the whole page scales up rather than leaving the text small in a narrow column. No text sits below `1rem` except the "Viljoen line" badge and the stub on mid-width screens (`.95rem`). Cormorant Garamond has a smaller x-height than EB Garamond, so its italic secondary lines run about an eighth larger than the EB Garamond lines beside them. -- **Frame:** a 2.5px red border plus an inner 1px gold rule (`.frame::before`) with rounded corners and four gold corner flourishes (`#corner` symbol). A negative margin on the masthead equals the frame's top margin (128px, or 96px on phones). That puts the top border behind the mantling, so change both values together. +- **Type scale:** the root size grows with the viewport from 16px, at 1143px wide or less, up to 20px at about 2286px, and the frame, masthead, and couple card widths are in `rem`, so on a wide screen the whole page scales up rather than leaving the text small in a narrow column. No text sits below `1rem` except the "Viljoen line" badge, and the "c generation to follow" stub at 1100px wide or less, both `.95rem`. The stub wraps inside its column rather than spilling into the next one, since the column widths follow the viewport while the stub follows the reader's font size. Cormorant Garamond has a smaller x-height than EB Garamond, so its italic lines (the eyebrow, the section subtitles, and the footer) are set at `1.125rem`, above the `1rem` floor. +- **Frame:** a 2.5px red border plus an inner 1px gold rule (`.frame::before`) with rounded corners and four gold corner flourishes (`#corner` symbol). A negative margin on the masthead equals the frame's top margin (`8rem`, or `6rem` on phones). That puts the top border behind the mantling, so change both values together. Both are in `rem`, like the masthead width, so the border meets the crest at the same point as the root size grows. - **Paper texture:** an inline SVG `feTurbulence` noise data URI plus a radial vignette on `html`. - **Divider:** a simplified Huguenot cross (a Maltese cross with fleur points, balls on the tips, and a hanging dove), the `#huguenot-cross` symbol. - **CSP:** the policy in `deploy/Caddyfile` allows only `'self'` for scripts, since the one script is `site.js`. Styles keep `'unsafe-inline'` for the `style` attributes and the `