# Notion-As-Blog Design System ## 1. Atmosphere & Identity Notion-As-Blog should feel like a governed publishing surface: calm enough for long reading, structured enough for documentation, and flexible enough for a personal or team blog. The signature is source-order clarity: each page exposes a clear reading path first, then supporting navigation and metadata are placed nearby without stealing attention. ## 2. Color ### Palette | Role | Token | Light | Dark | Usage | |------|-------|-------|------|-------| | Surface/primary | `--background` | brand-configured warm white | brand-configured warm black | Main page background | | Surface/secondary | `--muted` | brand-configured muted surface | brand-configured muted surface | Tag bars, quiet panels, thumbnail fallback | | Surface/elevated | `--card` | brand-configured card surface | brand-configured card surface | Post cards and header/footer surfaces | | Text/primary | `--foreground` | brand-configured text | brand-configured text | Body and headings | | Text/secondary | `--muted-foreground` | brand-configured muted text | brand-configured muted text | Dates, labels, summaries | | Border/default | `--border` | brand-configured edge | brand-configured edge | Dividers, focused panel edges | | Accent/primary | `--primary` | brand-configured accent | brand-configured accent | Links, CTAs, active navigation | | Accent/foreground | `--primary-foreground` | brand-configured contrast | brand-configured contrast | Text on primary surfaces | | Focus/ring | `--ring` | brand-configured ring | brand-configured ring | Keyboard focus | | Status/error | `--destructive` | brand-configured red | brand-configured red | Destructive or error states | ### Rules - Keep color ownership in `src/config/brand.ts`; components consume semantic tokens through Tailwind/shadcn variables. - Notion block colors are allowed as imported content semantics and live in `src/app/globals.css`. - Accent color is interactive first. Decorative use must stay quiet and support reading hierarchy. ### Social Icon Interaction Colors - `--social-github`: black in light mode, white in dark mode. - `--social-linkedin`: LinkedIn blue `#0a66c2`. - Footer platform order starts GitHub, Hugging Face, LinkedIn, X. - Social links share a centered 32px focus box. Optical glyph sizes: GitHub 28px, X/Hugging Face 26px, LinkedIn 24px; preserve logo aspect ratios. - X shares the black/white monochrome interaction palette. Hugging Face uses its official local SVG, muted with grayscale/opacity by default and full color on hover/focus. Empty profile URLs hide icons. - Footer social icons use these colors on hover and keyboard focus; retain the visible focus ring and existing muted default. ## 3. Typography ### Scale | Level | Size | Weight | Line Height | Tracking | Usage | |-------|------|--------|-------------|----------|-------| | Display | `clamp(2.5rem, 7vw, 4.5rem)` | 800 | 1.05-1.15 | tight | Home hero | | H1 | `1.875rem` to `3rem` | 700 | 1.15 | tight | Article title | | H2 | `1.5rem` to `1.875rem` | 700 | 1.25 | tight | Section headers | | H3 | `1.25rem` to `1.5rem` | 600 | 1.35 | normal | Card titles | | Body/lg | `1.125rem` to `1.25rem` | 400 | 1.65 | normal | Hero and article lead copy | | Body | `1rem` | 400 | 1.6 | normal | Default text | | Body/sm | `0.875rem` | 500 | 1.5 | normal | Navigation, metadata | | Caption | `0.75rem` | 700 | 1.4 | wide | Sidebar labels | ### Font Stack - Primary: `brand.fonts.sans.stack` - Mono: `brand.fonts.mono.family`, monospace ### Rules - Keep body measure near `70ch` for prose and summaries. - Use `text-wrap: balance` or Tailwind balanced wrapping on display/title text. - Article paragraphs and list items use 1.5 line height; paragraph margins use `--space-4`. Short paragraphs use balanced wrapping to avoid a very short final line. - Metadata uses medium weight and muted color; it should not compete with headings. ## 4. Spacing & Layout ### Base Unit All reusable spacing derives from a 4px base. | Token | Value | Usage | |-------|-------|-------| | `--space-2` | 8px | Tight inline labels | | `--space-3` | 12px | Compact groups | | `--space-4` | 16px | Default local gap | | `--space-6` | 24px | Card padding and comfortable clusters | | `--space-8` | 32px | Feed item rhythm | | `--space-10` | 40px | Local section rhythm | | `--space-12` | 48px | Article/supporting separation | | `--space-16` | 64px | Page section rhythm | | `--space-20` | 80px | Hero-to-content rhythm | ### Grid - Max content width: `1120px` - Prose measure: `70ch` - Article shell: `minmax(0, 1fr) 18rem` on large screens - Repeating grid: `repeat(auto-fit, minmax(min(18rem, 100%), 1fr))` - Breakpoints follow Tailwind defaults: `sm`, `md`, `lg`, `xl`, `2xl` ### Rules - StyleGallery is the layout reference: use content limiter, stack, cluster, fluid repeat grid, and sticky aside patterns before custom layout. - Document owns scrolling. Sidebars may be sticky, but they do not own an independent scroll container unless overflow behavior is explicit. - Use normal DOM/source order for reading paths; visual layout must not reorder focus meaning. ## 5. Components ### Site Shell - **Structure**: sticky header with a mobile category row, `main#main-content`, footer. - **Variants**: normal, dark mode. - **Spacing**: content limiter at `1120px`, horizontal page gutters. - **States**: header links have active, hover, focus; skip link appears on focus. - **Accessibility**: semantic landmarks and skip-to-content support. - **Motion**: color and transform transitions only. ### Featured Slideshow - **Structure**: featured post link, visible mobile controls, and slide indicators. - **Spacing**: photo slides are at least `20rem` tall on mobile; text-only collections size to their content. - **States**: autoplay pauses on hover, keyboard focus, and touch; arrow keys and buttons change slides. - **Accessibility**: hidden slides leave the tab order; reduced motion keeps controls responsive. - **Motion**: slides transition with opacity and transform, and skip transitions when reduced motion is requested. ### Header Navigation - Text links use weight/color for active and hover states, without pill backgrounds or gradients. - Desktop links retain the original 20px gap; keyboard focus remains visible. ### Article Shell - **Structure**: `
` followed by desktop `