# Ohana Chat design system

The Design System documents the current public website and authenticated web app. It shares intent, artwork, and behavior with iOS while respecting native typography and platform conventions. Product interfaces consume semantic roles instead of choosing raw colors page by page.

Current token contract: `2026.10.3` (October 3, 2026).

## Foundations

- **Brand:** Sea Glass `#3E6F6B`, sage `#78938A`, and the exact sculpted wordmark from `public/brand/ohana-sea-glass-wordmark.svg`. Preserve the paths and proportions. The dark wordmark uses mint `#7DC9BC` and supporting sage `#ADBFBA`.
- **Light app:** White Sand canvas `#FFFDFA`, white cards, deep green ink `#193D3B`, secondary text `#526C66`, pale selected surfaces `#E8F1ED`, and borders `#D5E3DD`. The public website uses a white canvas.
- **Dark app:** canvas `#142320`, raised surfaces `#20332E`, elevated surfaces `#294039`, selected surfaces `#2E4941`, text `#E5F0EB`, secondary text `#ADBFBA`, and mint actions `#7DC9BC`. Dark mode separates surfaces and preserves contrast.
- **Semantic roles:** `--color-bg`, `--color-surface`, `--color-surface-raised`, `--color-surface-elevated`, `--color-heading`, `--color-text`, `--color-text-muted`, `--color-border`, `--color-action`, `--color-accent`, `--color-focus`, and status roles. These correspond to the app's surface, text, accent, separator, and action roles in `src/app-brand.css`.
- **Actions:** teal fill and white labels in light mode; mint fill and deep green labels in dark mode. Icons inherit label contrast. Shadows use neutral deep green or black. Selected navigation uses a pale surface and an outlined glyph; selected segmented tabs use the primary fill.
- **Geometry:** a 4px spacing scale, 44px compact controls, 48px primary controls, rounded cards, and safe-area-aware overlays. Calendar's segmented selector is 54px; Search, Sort, and Filter use equal 44px controls.
- **Typography:** DM Serif Display for expressive web headings, DM Sans for web body text and controls. iOS uses system text with Dynamic Type. Font fallbacks remain readable without a network font download.
- **Motion:** short 200ms feedback, immediate navigation, and reduced-motion alternatives. Meaning comes from labels, placement, and grouping.
- **Decorative exception:** preserve the Brand Center's existing multicolor hero background in both modes. Its `--hero-base` is independent of app surface tokens. This is a page illustration treatment, not a primary action palette.

## Brand assets

- Sea Glass wordmark: exact same SVG as the public website and web app.
- Mint wordmark: same vector geometry, supplied for dark surfaces.
- Hibiscus chat mark: exact user-supplied app geometry, with its background removed and white fills changed to Sea Glass. The favicon's tighter square viewBox improves tab readability.
- App icon: the original white mark on a Sea Glass square. Keep this distinction from the transparent website favicon.
- Navigation: current Phosphor regular glyphs, matching `NavigationGlyph` in `src/App.jsx`. Available/selected SVG downloads contain real paths; previews adapt with semantic text/accent colors.
- Illustrations: 37 approved transparent SVGs from `src/assets/empty-states`, copied unchanged to the design-site downloads. Adapt original strokes/fills in dark previews. Contain the drawing and use recipe/calendar art only when no photo is present. The original paper-backed WebP set remains available for older compositions; do not label raster artwork as vector.

## Content accents

Small labels, recipe metadata, poll results, and event date tiles use these adaptive fill/ink pairs. Light mode uses near-white color washes so labels stay secondary to family content; dark mode retains muted deep fills and readable pastel text. Primary actions and card backgrounds keep their brand/neutral roles.

| Meaning | Light fill / ink | Dark fill / ink |
| --- | --- | --- |
| Updates and announcements | `#FFF2EC` / `#85441F` | `#42291D` / `#E8B8A1` |
| Questions and poll results | `#EBF7FF` / `#115F86` | `#1C3342` / `#A0CBE6` |
| Recipes | `#FFF3E4` / `#764F0F` | `#3C2D1A` / `#DBBF9C` |
| Events | `#E9FAF4` / `#316354` | `#23352F` / `#A4CFC0` |
| Birthdays and celebrations | `#FFF1F4` / `#90314E` | `#45252D` / `#F7ACBC` |
| Stories and keepsakes (Orchid) | `#F5EFFB` / `#634184` | `#342841` / `#CEB8EA` |

Hibiscus is a small celebration/like accent. It does not replace Sea Glass navigation or primary controls. Pair every status with text, an icon, or another non-color cue.

## Components

Document anatomy, variants, and meaningful states for actions, inputs, selection, feedback, navigation, cards, sheets, and overlays. Keep keyboard focus visible in both modes. Search wrappers own the border and background; inner inputs stay borderless. Sort and Filter remain equal 44px targets beside a flexible search field.

## Product patterns

- **App shell:** three-column desktop layouts where space permits; compact mobile header with logo, Family Space selector, and search. Mobile bottom destinations are Feed, Photos, Calendar, Chats, and Notifications. Recipes, Shop, Family, and Journal remain available in More. Chat badges carry an unread count.
- **Overlays:** modal, sheet, filter popover, overflow menu, toast, and confirm/delete dialog. Provide labeling, Focus trapping where needed, Escape/Back dismissal, outside-click behavior, and focus restoration. Toasts preserve the next useful action.
- **Content:** posts and polls use author/audience/body/actions; events emphasize title and date; photos preserve image proportions and open a full viewer. Recipe illustrations occupy the same media slot as real recipe photos, contained rather than cropped.
- **Chats:** list plus thread on desktop and a focused thread on phones. Sender identity, soft person colors, right-aligned own messages, replies/reactions, send/retry state, and read receipts stay consistent with iOS. The composer clears the keyboard and safe area. Kids & Chats links approved guardians to a read-only child-chat view.
- **Forms:** accessible search labels, optional event end times, audience autocomplete, Your Eyes Only, upload progress/preview/replace/remove/retry, and selected-state cues.

## State matrix

Specify default, hover, pressed, focus, selected, disabled, loading, success, error, empty, offline, and permission-denied behavior. Explain unavailable actions, prevent duplicate submissions, reserve status space, and keep a recovery action visible. Never rely on color alone.

## Accessibility and iOS-to-web continuity

Targets are at least 44px in both dimensions. Icon-only controls have accessible names. Typography can grow without clipping. Honor `prefers-reduced-motion`, light/dark appearance, increased contrast, and keyboard navigation. The same product anatomy scales from phone to desktop; it does not require identical platform containers.

## Token governance

Raw palette values feed semantic roles, which feed component tokens. The current app/public styles and exact shipped artwork are the reference. Retired September Cocoa Bark/pink primary-action guidance and historical wordmark/navigation artwork are superseded by this contract. Legacy files retained in the repository are not advertised as current downloads.

Update this guide, the live examples, cache-versioned URLs, and contract checks together whenever a role changes. Preserve Sites packaging behavior and unrelated app functionality.

## Manual QA and deployment

- Check 320, 375, 390, 430, 768, and 1440px widths in light and dark modes.
- Verify the existing hero background is unchanged in both modes.
- Verify header/footer wordmarks, adaptive logo previews, asset downloads, and every illustration load.
- Toggle appearance, reload to verify persistence, and test with unavailable storage.
- Use keyboard Tab to inspect focus on links, buttons, the search field, and the segmented specimen.
- Confirm the search surface and adjacent controls remain 44px and the page has no horizontal overflow.
- Compare primary actions, selected navigation, content labels, and date tiles with the current app.
- Run the build and quality checks before publication.

After approval, deploy the separate design-site document root using `docs/brand-center-hostgator.md`. A public-site deployment does not copy `brand-center/` automatically.

## References

- Current public page: `src/public-home.css` and `public/brand/ohana-sea-glass-wordmark.svg`.
- Current app: `src/app-brand.css`, `src/App.jsx`, and `src/chat/chat.css`.
- [Apple Design and Human Interface Guidelines](https://developer.apple.com/design/).


## Documentation release — October 4, 2026

The Figma reference describes components, tokens, patterns and documentation as the central pieces of a design system. This site now exposes the missing practical sections rather than presenting a brand-asset gallery alone.

- Searchable directory: foundations, brand assets, tokens, layout/spacing, typography, color, components, interactive specimens, product patterns, accessibility, motion, content/imagery, brand guidance and resources/contribution.
- Tokens: active-theme resolved values, multi-term search, copy declarations, existing CSS download and theme-specific JSON reference export. This does not publish an installable package or Figma library. The palette contract remains 2026.10.3.
- Layout: 4px rhythm, radius/elevation, safe areas and reference layer roles. Actual web shell switches at 820px and 1190px; public/design-site layouts use their own content-driven breakpoints.
- Components: linked validation hints/errors, native selection, keyboard tabs with a panel, focus-contained dialog and focus restoration, disclosure, avatars/statuses, local-only file preview and progress anatomy.
- Accessibility: live opaque color-pair calculations, 4.5:1 normal-text guidance, keyboard/targets/reflow/large-type checks and stronger-contrast preview. These checks do not certify complete WCAG compliance.
- Motion and product cadence: restrained feedback, reduced motion, inactive-state pauses, rotating writing/photo prompts and occasional, dismissible weekly/event highlights.
- Content: action labels, empty/error/confirmation language, privacy/audience cues, photography, decorative versus meaningful image descriptions, long labels and timezone rules.
- Governance: distinguish shipped source, documented specimens and future packages; update tokens, examples, implementation and docs together; follow WORKFLOW.md owner approval before publishing.

References: [Figma examples](https://www.figma.com/resource-library/design-system-examples/), [W3C contrast](https://www.w3.org/WAI/WCAG22/Understanding/contrast-minimum.html), [W3C reflow](https://www.w3.org/WAI/WCAG22/Understanding/reflow.html).
