# Star Ward

A calm tool for people who work at night. Deep indigo pages hold a big rounded "sky panel" inset from the edges of the screen, filled with drawn stars, a crescent moon and soft mauve and rose clouds. Inside it, centred Source Serif headlines sit over a short Inter lead, one violet button with a lit top edge, and a near-black ghost button. On landing pages a dark app window docks into the bottom of the sky, cut off by the panel's edge, as if the product sits on the horizon. Labels and footnotes are tiny IBM Plex Mono. It feels quiet, dreamy and careful: a serious tool that is kind to tired eyes.

Use it for: shift and rota tools, healthcare and care work, night services, developer and infrastructure platforms, sleep and rest products, anything that wants to feel calm but competent. Avoid it for: bright daytime retail, kids' brands, loud sales pages, photography-led sites, anything that needs high energy.

## How to use this file

Give this file, `tokens.css` and `components.css` to your AI coding tool and say:

> Build [your page] in the Star Ward style. Follow DESIGN.md exactly. Use the tokens in tokens.css and the classes in components.css; don't invent new colors, fonts, radii or shadows.

`demo.html` (a landing page), `pricing.html`, `blog.html` and `signup.html` are complete example pages built only with the kit, for an invented night-shift handover app called Lantern.

## Fonts

All free on Google Fonts:

```html
<link href="https://fonts.googleapis.com/css2?family=Source+Serif+4:opsz,wght@8..60,500;8..60,600&family=Inter:wght@400;500;600&family=IBM+Plex+Mono:wght@400;500&display=swap" rel="stylesheet">
```

| Role | Font | Use |
|---|---|---|
| Headlines | Source Serif 4, 500 to 600 | Hero titles, section titles, prices, stats, pull quotes and the article's h2. Tight tracking (-0.02em), balanced wrapping. |
| Body and UI | Inter 400 to 600 | Leads, body, nav, buttons (500), card titles (600). |
| Labels | IBM Plex Mono 400 to 500 | Eyebrows, footnotes, badges, table heads, timestamps. 11px, wide tracking, often uppercase. |

## Color

| Token | Hex | Role |
|---|---|---|
| `--sw-night` | #13111D | The page, ghost buttons, inputs |
| `--sw-panel` | #1A1727 | Windows, cards, plans, the blockquote |
| `--sw-raised` | #231F35 | Rows inside windows, icon tiles, inline code |
| `--sw-line` | #2F2A45 | Every 1px border |
| `--sw-text` | #F1EEF8 | Headlines and body |
| `--sw-dim` | #A39DBA | Leads, nav links, card copy |
| `--sw-sky-top` | #1D1A33 | Top of the sky panel |
| `--sw-cloud` | #4E3F62 | Mauve clouds |
| `--sw-cloud-rose` | #7C5470 | Rose clouds near the horizon |
| `--sw-star` | #F3E8C8 | Stars, the moon and the logo mark |
| `--sw-violet` | #6A4BD6 | The one accent: the main button, featured plan ring, checks |
| `--sw-lilac` | #B3A1F5 | Eyebrows, links in articles, focus rings |
| `--sw-moss` / `--sw-amber` | #66C9A0 / #E9B65E | Status dots and avatars only |

Rules:
- Color comes from the sky, not from fills. Outside the sky panel, pages are flat night with 1px lines.
- One violet button per view. Everything else is a ghost button or a quiet link.
- Moss and amber are for small status marks ("Done", "Watch"), never for areas.

## Type scale

| Token | Size | Use |
|---|---|---|
| `--sw-text-hero` | clamp(38px, 5.6vw, 68px) | Centred titles in the sky, two short lines |
| `--sw-text-h2` | clamp(28px, 3.4vw, 42px) | Section titles |
| `--sw-text-h3` | 19px | Card, plan and window titles (Inter 600) |
| `--sw-text-lead` | clamp(17px, 1.6vw, 20px) | Dim lead under a title |
| `--sw-text-body` | 15px | Body and UI (articles use 17px) |
| `--sw-text-micro` | 11px | Mono labels |

Headlines are short, gentle and a little poetic ("Hand over the night, not the chaos"). Leads explain plainly in one or two sentences.

## Shape and space

- Radius: 8px buttons and inputs, 12px rows and icon tiles, 18px cards, plans and windows, 26px the sky panel, pill for badges, toggles and the announcement pill.
- Borders: 1px `--sw-line` on cards, plans, tables and the sky. Windows use a faint white ring inside their shadow.
- Shadows: the violet button has an inset white top edge and a soft violet glow (`--sw-shadow-btn`). Windows sit on a deep drop shadow (`--sw-shadow-window`). Nothing else casts shadows.
- The sky: `.sw-sky` stacks `--sw-stars` (six star tiles in different sizes, set by `--sw-stars-size`, so they never form a grid) on `--sw-sky`, then paints `--sw-clouds` in `::before` and a dark fade at the horizon in `::after`. Add `.sw-moon` once. Use the sky for the hero and the closing CTA only.
- Sections: 72px to 112px vertical padding. Container 1180px with 20px gutters. Text column 660px.
- Motion: slow and small. The hero rises 14px on load, the moon breathes, buttons sink 1px on press. All off under reduced motion.

## Components (in components.css)

| Class | What it is |
|---|---|
| `.sw` | Put on `<body>`: night page, Inter, light text, no sideways scroll |
| `.sw-container`, `.sw-narrow`, `.sw-section`, `--tight`, `.sw-center` | Layout |
| `.sw-nav`, `__links`, `__end`, `.sw-logo`, `__mark`, `.sw-hide-sm` | Flat nav above the sky; the logo mark is a crescent |
| `.sw-hero-title`, `.sw-h2`, `.sw-h3`, `.sw-lead`, `.sw-muted`, `.sw-micro`, `.sw-eyebrow` | Type |
| `.sw-btn`, `--violet`, `--ghost`, `--quiet`, `--lg`, `--block`, `.sw-btn-row` | Buttons |
| `.sw-sky`, `__inner`, `__inner--short`, `.sw-moon` | The signature sky panel |
| `.sw-window`, `--floating`, `__bar`, `__body`, `__grid`, `__side` | App window: docked into the sky, or floating with all corners round |
| `.sw-row`, `__title`, `__meta`, `.sw-avatar`, `--moss`, `--amber` | One item inside a window |
| `.sw-badge`, `--violet`, `.sw-dot`, `--amber`, `.sw-pill` | Badges, status dots, the announcement pill |
| `.sw-grid`, `.sw-card`, `__icon`, `--sky`, `.sw-split`, `.sw-stats`, `.sw-stat`, `.sw-quote`, `.sw-quote-by` | Content blocks |
| `.sw-field`, `.sw-label`, `.sw-hint`, `.sw-input`, `.sw-select`, `.sw-check`, `.sw-choice`, `.sw-divider` | Forms |
| `.sw-toggle`, `.sw-plans`, `.sw-plan`, `--featured`, `__price`, `.sw-table-wrap`, `.sw-table`, `.sw-faq` | Pricing |
| `.sw-article`, `.sw-byline`, `.sw-figure` | Articles |
| `.sw-cta`, `.sw-footer`, `__grid`, `__base` | Closing CTA and footer |
| `.sw-rise`, `.sw-twinkle` | Motion |

## Pages in this kit

- `demo.html`: nav, sky hero with pill, title, lead, two buttons and a docked window, a row of serif "logos", three feature cards, a split with a floating window, stats, a quote, a sky CTA and the footer.
- `pricing.html`: sky hero with a monthly or yearly toggle and three plans inside the sky, a comparison table, FAQ and a sky CTA.
- `blog.html`: short sky header with eyebrow, title, lead and byline, then a 660px article with a blockquote, a figure built from window rows, and related cards.
- `signup.html`: the whole screen is one sky with a centred form card.

## Page recipe

1. `<body class="sw">`, nav in `.sw-container`.
2. A `.sw-sky` hero: `.sw-moon`, then `.sw-sky__inner` with a pill or eyebrow, a two-line `.sw-hero-title`, a `.sw-lead` and a `.sw-btn-row` (violet, then ghost).
3. Dock a `.sw-window` at the bottom of the sky to show the product. Leave the bottom unrounded so the sky's edge cuts it.
4. Below the sky, flat night sections: cards, a split with a floating window, stats, one quote.
5. Close with a second, shorter `.sw-sky.sw-cta`, then `.sw-footer`.

Pricing: put the toggle and `.sw-plans` inside the sky hero, feature the middle plan with `.sw-plan--featured`, then a table and FAQ on flat night.

Article: a `.sw-sky` with `.sw-sky__inner--short` and `.sw-narrow` for the header, then `.sw-article`. Show product moments as rows inside a `.sw-card--sky`.

Sign up: make the sky the whole `<main>`, centre one `.sw-card` form, one violet submit button.

## Don'ts

- Don't use photos or gradients outside the sky panel.
- Don't use more than one violet button per view, or violet for large areas.
- Don't set headlines in Inter or body in the serif.
- Don't put cards with heavy shadows on the flat night. Lines only.
- Don't add a second sky in the middle of a page; hero and CTA only.
- Don't use em dashes in copy.
