# Harbor Page Design

> Build new web pages in Harbor School's design tone — paper + ink palette, Cal Sans + Wanted Sans typography, rounded-full CTAs, rounded-3xl cards with hairline

- Skill: `ruucm/harbor-page-design` (Agent Skill, multi-file: 33 files)
- Install (CLI): `npx get-skill add ruucm/harbor-page-design`
- Raw SKILL.md: https://api.skillmd.com/api/skills/ruucm/harbor-page-design/raw
- Safety review: pending
- Works with: any agent that reads SKILL.md (Claude Code, Claude.ai, Cursor, Codex, Windsurf, 60+ more)
- Category: Coding & Dev Tools
- Author: ruucm (https://skillmd.com/u/ruucm)
- Updated: 2026-11-29
- Page: https://skillmd.com/skills/ruucm/harbor-page-design

---

---
name: harbor-page-design
description: Build new web pages in Harbor School's design tone — paper + ink palette, Cal Sans + Wanted Sans typography, rounded-full CTAs, rounded-3xl cards with hairline borders, frosted-glass + matte 3D assets, Reveal-on-scroll motion. Use whenever the user asks to create / design / build / scaffold a new page that should look like Harbor School, or mentions phrases such as "harbor 스타일", "harbor school style", "harbor page", "하버스쿨 디자인", "harbor 컴포넌트", "harbor 디자인으로", or installs/uses the harbor-design plugin.
---

# Harbor Page Design

This skill produces new web pages matching the Harbor School design tone. It ships **everything needed**: 13 React primitives, design tokens, motion CSS, fonts (Cal Sans + Wanted Sans), 3D assets, and 4 page exemplars.

## When to invoke

Trigger on requests like:
- "Harbor 스타일로 가격 페이지 만들어줘"
- "Harbor school landing for my course"
- "이 디자인 톤으로 새 페이지"
- "하버스쿨 디자인 시스템 가져와 줘"
- Explicit: `/plugin install harbor-design@harbor-design-skills` was just executed

## What this skill provides

Files live next to this `SKILL.md`:

```
bundle/
├── components/     ← 13 React primitives (.tsx). Self-contained, only depend on `clsx` + React.
├── styles/         ← tokens.css (@theme block) + motion.css (Reveal + keyframes)
├── assets/         ← objects/*.png (frosted glass + matte 3D) + brand/*.svg
└── fonts/          ← Cal Sans + Wanted Sans WOFF2
exemplars/          ← 4 ready-to-modify page templates
DESIGN.md           ← full design system reference (load on demand)
AGENTS.md           ← 9 hard rules + workflow + anti-patterns
```

## Procedure

Follow these steps in order. Each step has explicit success criteria.

### Step 0 — Load context (always)

Read **`AGENTS.md`** in this skill folder. The 9 hard rules and anti-patterns drive every decision. If you encounter a tone or pairing question, read **`DESIGN.md`** for the deeper rationale.

### Step 1 — Detect the target project

Inspect the user's current working directory:

1. Is there a `package.json`? Read `dependencies` to detect framework.
2. **Framework detection** (priority order):
   - `next` in dependencies → Next.js (App Router likely if `app/` exists, Pages Router if `pages/` exists)
   - `vite` + `react` → Vite + React
   - `react` only + `index.html` → CRA / plain React
   - Otherwise → ask user (Astro / Remix / SvelteKit are not currently supported targets; offer plain React only)
3. **Tailwind detection**:
   - `tailwindcss` in dependencies → check version. v4 is required (uses `@theme`). If v3 → warn and offer to migrate or use plain CSS variables fallback.
   - No Tailwind → install it (`pnpm add -D tailwindcss @tailwindcss/postcss postcss` + run init).
4. **Existing install**: look for `harbor.lock.json` at project root. If present, you're in update mode (see Step 4-update). Otherwise fresh install.

### Step 2 — Sync bundle into user's project (first install)

Copy from this skill's `bundle/` to the user's project. Target paths assume Next.js App Router; adjust for other frameworks.

| Source (in this skill) | Destination (in user project) |
|---|---|
| `bundle/components/*.tsx`, `*.ts` | `<project>/components/harbor/` |
| `bundle/styles/tokens.css` | `<project>/styles/harbor-tokens.css` (or `app/harbor-tokens.css`) |
| `bundle/styles/motion.css` | `<project>/styles/harbor-motion.css` (or `app/harbor-motion.css`) |
| `bundle/assets/objects/*.png` | `<project>/public/harbor/objects/*` |
| `bundle/assets/objects/card/*.png` | `<project>/public/harbor/objects/card/*` |
| `bundle/assets/brand/*.svg` | `<project>/public/harbor/brand/*` |
| `bundle/fonts/*.woff2` | `<project>/public/harbor/fonts/*` |

After copying, install peer deps if missing:
```bash
pnpm add clsx
# (react, react-dom, tailwindcss assumed already installed)
```

### Step 3 — Wire up tokens + fonts

#### 3a. Global stylesheet
Find the user's global stylesheet:
- Next.js App Router: `app/globals.css` or `app/layout.css`
- Next.js Pages: `styles/globals.css`
- Vite: `src/index.css` or `src/main.css`

Prepend (after `@import "tailwindcss"` if present):
```css
@import "tailwindcss";
@import "./harbor-tokens.css";   /* adjust path */
@import "./harbor-motion.css";   /* adjust path */
```

For Tailwind v4 to pick up class usage in the copied components, add a `@source` directive:
```css
@source "../components/harbor";   /* relative to the CSS file */
```

#### 3b. Fonts — Next.js

In `app/layout.tsx` (or `app/layout.jsx`), register both fonts as local fonts:

```tsx
import localFont from "next/font/local";

const calSans = localFont({
  src: "../public/harbor/fonts/CalSans-Regular.woff2",
  variable: "--font-cal",
  display: "swap",
});

const wantedSans = localFont({
  src: "../public/harbor/fonts/WantedSansVariable.woff2",
  variable: "--font-wanted",
  display: "swap",
});

export default function RootLayout({ children }) {
  return (
    <html lang="ko" className={`${calSans.variable} ${wantedSans.variable}`}>
      <body>{children}</body>
    </html>
  );
}
```

#### 3b-alt. Fonts — Vite / plain CSS

Add to the global stylesheet **before** the harbor imports:

```css
@font-face {
  font-family: "CalSans";
  src: url("/harbor/fonts/CalSans-Regular.woff2") format("woff2");
  font-display: swap;
}
@font-face {
  font-family: "WantedSans";
  src: url("/harbor/fonts/WantedSansVariable.woff2") format("woff2-variations");
  font-weight: 100 900;
  font-display: swap;
}
:root {
  --font-cal: "CalSans";
  --font-wanted: "WantedSans";
}
```

### Step 4 — Write the page (fresh install path)

1. **Ask the user for the page brief** if not already given:
   - What is the page for? (about / landing / docs / status / other)
   - What's the URL / route?
   - Any required sections or copy?
2. **Pick the closest exemplar** from `exemplars/`:

   | User's intent | Exemplar |
   |---|---|
   | Portrait, single-message, intro | `exemplars/leader-page.tsx` |
   | Full marketing landing (hero + many sections + CTA) | `exemplars/full-landing.tsx` |
   | Docs / FAQ / system reference (TOC + anchors) | `exemplars/docs-page.tsx` |
   | Single short message + one CTA (404, payment fail, thank-you) | `exemplars/minimal-status.tsx` |

3. **Read the chosen exemplar** end-to-end before writing.
4. **Clone to the user's route**:
   - Next.js App Router: `app/<slug>/page.tsx`
   - Next.js Pages: `pages/<slug>.tsx`
   - Vite: `src/pages/<slug>.tsx` (or whatever the project uses)
5. **Customize** placeholders with the user's brief. Stay in the exemplar's structure — same number of sections, same rhythm. Substitute copy, swap assets, adjust grid sizes only when the exemplar clearly doesn't fit.

### Step 4-update — Update mode (existing `harbor.lock.json`)

If `harbor.lock.json` exists:

1. Read it. Note the `skillVersion` and per-file hashes.
2. Compare every entry against the current `bundle/` contents.
3. For each file:
   - **Unchanged in bundle** → skip.
   - **Changed in bundle, unchanged in user's project** (hash matches lock) → safe to overwrite. Apply and update lock.
   - **Changed in bundle, modified by user** (hash mismatch with lock) → **ask before overwriting**. Offer 4 options:
     - (a) Overwrite (lose user's edit)
     - (b) Save user's version as `*.local.tsx` and apply update
     - (c) Skip (keep user's, don't update)
     - (d) Show diff first
4. After applying changes, regenerate `harbor.lock.json` with the new `skillVersion`.

### Step 5 — Self-check

Run in the user's project:
```bash
pnpm check-types          # or: tsc --noEmit
pnpm lint                 # if the project has lint
pnpm dev                  # then open the new route in browser
```

Verify against the checklist in `AGENTS.md` § "Self-check":
- Compile + lint errors 0.
- New route returns 200.
- All CTAs `rounded-full`, all cards `rounded-3xl` + hairline.
- No hex literals in the new page code.
- Mobile (375px) + desktop (1440px) overflow 0.
- `prefers-reduced-motion: reduce` doesn't break motion.

If the dev server doesn't reflect changes after edits, the user should restart it — Turbopack's file-watcher occasionally goes stale.

### Step 6 — Write / update `harbor.lock.json`

At the user's project root, write `harbor.lock.json`:

```json
{
  "skillVersion": "1.0.0",
  "installedAt": "2026-05-22T...",
  "files": {
    "components/harbor/section.tsx": { "hash": "sha256...", "fromVersion": "1.0.0" },
    "components/harbor/cn.ts": { "hash": "sha256...", "fromVersion": "1.0.0" },
    "styles/harbor-tokens.css": { "hash": "sha256...", "fromVersion": "1.0.0" },
    "public/harbor/objects/sphere_blue.png": { "hash": "sha256...", "fromVersion": "1.0.0" }
  },
  "skipped": []
}
```

The lock file is the single source of truth for "what's already installed and from which skill version." Future update runs read this first.

## Common scenarios

### "Make a pricing page in Harbor style"
- Detect Next.js + Tailwind v4 → fresh install if no lock.
- Sync bundle.
- Pick `exemplars/full-landing.tsx` (pricing is a marketing page).
- Replace placeholders: pricing headline, 2–3 tier cards (use `rounded-3xl` + hairline), FAQ section, final CTA.
- Run check-types + dev.

### "Make a 404 page in Harbor style"
- Pick `exemplars/minimal-status.tsx`.
- Place at `app/not-found.tsx` (Next.js convention).
- Short headline + return link.

### "Update Harbor design system to latest"
- Run plugin update first: `/plugin marketplace update harbor-design-skills`.
- Then this skill is invoked → goes to Step 4-update.
- Walk through each changed file, ask before overwriting modifications.

### "Add a new card to the existing about page"
- Skip sync (already installed — lock file present).
- Open `app/about/page.tsx`.
- Add a new card using the existing `rounded-3xl + hairline` pattern.
- Optionally swap visual anchor (`bundle/assets/objects/card/*.png`).
- No lock file change needed.

## Progressive disclosure

Only `SKILL.md` (this file) is loaded into context on trigger. Other resources are read on demand:

- **`AGENTS.md`** — read at Step 0 (always).
- **`DESIGN.md`** — read when user asks tone / philosophy / pairing questions, or before custom layout decisions.
- **`exemplars/<file>.tsx`** — read only the one matching the user's brief.
- **`bundle/assets/README.md`** — read when picking visual anchors.
- **`bundle/fonts/README.md`** — read during Step 3b font setup.

## When NOT to use this skill

- The user is editing an existing Harbor-school page (in the harbor-rebranding repo) — they already have the design system in-repo; no need to install.
- The user wants a completely different design tone — Harbor is opinionated. Suggest a different starting point.
- The user wants only the tokens (no components / fonts / assets) — copy `bundle/styles/tokens.css` directly without invoking the rest.

