@@ -121,16 +121,20 @@ html {
121121body {
122122 display : flex;
123123 flex-direction : column;
124- align-items : center;
125- padding : 12px ;
124+ max-width : 900px ; /* the whole page is one centered column; */
125+ margin-inline : auto; /* html paints the full-viewport background */
126+ padding : 12px 1rem ;
126127 gap : 12px ;
127128 background : var (--bg );
128129 color : var (--fg );
129130 font : var (--text-md )/ 1.6 var (--font-sans );
130131}
131132
132133h1 { font-size : clamp (24px , 6vmin , 40px ); }
133- p { font-size : 14px ; }
134+ /* Paragraphs inherit the body type (--text-md / 1.6). Secondary text
135+ that wants to be small opts in via a class (.hint, .credit, .by,
136+ ...) rather than every paragraph opting out of the base size. */
137+ .hint { font-size : var (--text-sm ); }
134138
135139button {
136140 background : var (--accent );
@@ -309,9 +313,6 @@ body.flash-red { animation: flash-red 300ms ease; }
309313}
310314
311315.page {
312- width : 100% ;
313- max-width : 900px ;
314- padding : 0 1rem ;
315316 display : flex;
316317 flex-direction : column;
317318 gap : 1rem ;
@@ -534,9 +535,6 @@ body.flash-red { animation: flash-red 300ms ease; }
534535 display : flex;
535536 flex-direction : column;
536537 gap : 1.5rem ;
537- max-width : 900px ;
538- width : 100% ;
539- padding : 0 1rem ;
540538 margin : 1rem 0 2.5rem ;
541539}
542540.hero > h2 { font-family : var (--font-mono ); color : var (--fg-header ); font-size : 3rem ; line-height : 1.1 ; }
@@ -569,76 +567,57 @@ body.flash-red { animation: flash-red 300ms ease; }
569567.callouts a { font-size : var (--text-lg ); }
570568.callout-desc { font-size : var (--text-md ); opacity : 0.85 ; }
571569
572- /* Article typography. Scoped to .prose so chrome (breadcrumbs, headers,
573- sidebars) keeps its own type rules. Used by /notes pages and the
574- /design markdown story. */
575- .prose {
576- max-width : 65ch ;
577- font-size : 1.2em ; /* ~21.6px relative to body's 18px -- article body */
578- line-height : 1.6 ;
579- }
580- .prose > * + * { margin-top : 1em ; }
581- .prose h2 {
582- font-family : var (--font-mono );
583- font-size : var (--text-xl );
584- color : var (--fg-header );
585- line-height : 1.2 ;
586- margin-top : 2.5em ;
587- }
588- .prose h3 {
589- font-family : var (--font-mono );
590- font-size : var (--text-lg );
591- color : var (--fg-header );
592- line-height : 1.2 ;
593- margin-top : 2em ;
594- }
595- .prose ul , .prose ol { padding-left : 1.5em ; }
596- .prose li + li { margin-top : 0.4em ; }
597- .prose li > p { margin : 0 ; } /* tight bullets, no double spacing */
598- .prose blockquote {
599- margin : 0 ;
570+ /* Raw-tag typography: the look lives on the tag so it reads the same
571+ wherever the tag appears (essays, the /design markdown demo, ...).
572+ Vertical rhythm (margins) is added per context below, not here, since
573+ the reset zeroes margins for the flex-based chrome.
574+ Headings share one look (the body's sans + off-white, like h1); each
575+ step just sizes down. The cream (--fg-header) is a specialization
576+ applied where wanted -- e.g. the splash hero's .hero > h2. */
577+ h2 { font-size : var (--text-xl ); }
578+ h3 { font-size : var (--text-lg ); }
579+ blockquote {
600580 padding : 0.25em 0 0.25em 1.25em ;
601581 border-left : 3px solid var (--brand );
602582 color : var (--fg-header );
603583 font-style : italic;
604584 opacity : 0.9 ;
605585}
606- .prose code {
607- /* element-rule already mono; just add a small pill background */
586+ code { /* mono is already set on the element; add the inline pill */
608587 font-size : 0.92em ;
609588 padding : 0.1em 0.35em ;
610589 background : rgba (0 , 0 , 0 , 0.3 );
611590 border-radius : 3px ;
612591}
613- .prose pre {
614- margin : 0 ;
592+ pre {
615593 padding : 0.9em 1.1em ;
616594 background : rgba (0 , 0 , 0 , 0.35 );
617595 border-radius : 6px ;
618596 overflow-x : auto;
619597 font-size : var (--text-sm );
620598 line-height : 1.5 ;
621599}
622- .prose pre code {
623- /* inline-code styling shouldn't apply inside a <pre> */
624- padding : 0 ;
625- background : none;
626- border-radius : 0 ;
627- font-size : inherit;
628- }
600+ pre code { padding : 0 ; background : none; border-radius : 0 ; font-size : inherit; }
601+
602+ /* Vertical rhythm for content blocks inside <main>. App pages put a
603+ single .page/.hero in main, so this is a no-op for them; essay pages
604+ (/notes) put their prose blocks straight in main, where it does the
605+ spacing. Direct-child (>) keeps the splash hero's nested h2 out of it. */
606+ main > * + * { margin-top : 1em ; }
607+ /* Section breaks before headings, in rem so they don't compound with the
608+ heading's own (large) font-size the way em would. */
609+ main > h2 { margin-top : 2rem ; }
610+ main > h3 { margin-top : 1.5rem ; }
629611
630612/* Site header: shared by / and /play. Mirrors the http-nu/www header
631613 pattern -- `flex items-baseline justify-between mt-10 mb-2`. Title
632614 left, status + credit right. No divider lines; whitespace separates. */
633615.site-header {
634- width : 100% ;
635- max-width : 900px ;
636616 display : flex;
637617 align-items : baseline;
638618 justify-content : space-between;
639619 gap : 1rem ;
640620 margin : 2rem 0 0.75rem ;
641- padding : 0 1rem ;
642621 font-size : var (--text-sm );
643622}
644623.site-header .site-title {
@@ -673,12 +652,8 @@ body.flash-red { animation: flash-red 300ms ease; }
673652/* Site footer: whitespace partitions, no border or background. Links
674653 like nav -- each page anchors the same set of meta destinations. */
675654.site-footer {
676- /* Same container shape as .page / .hero (body's align-items: center
677- does the centering). Content right-aligned within. The link's
678- muted look comes from the shared chrome-link rule. */
679- width : 100% ;
680- max-width : 900px ;
681- padding : 0 1rem ;
655+ /* Content right-aligned within the page column. The link's muted look
656+ comes from the shared chrome-link rule. */
682657 margin : 4rem 0 1.5rem ;
683658 text-align : right;
684659 font-size : var (--text-sm );
0 commit comments