# Line Heights

## Essence

Typography-only rhythm constants for calculated text tokens.

`Line Heights` are special tokens used only by Typography tokens to define vertical rhythm for text roles.

## Hook

Use when defining or reviewing Typography token behavior.

## Internal Rules

- Used only for Typography token definitions.
- Must not be treated as standalone component styling guidance.
- `--line-height-tight` is `1.2`.
- `--line-height-body` is `1.5`.
- Tight line height supports compact roles: Caption, Subheading, and Headings.
- Body line height supports normal reading text.
- Component essences should reference text components or Typography tokens, not raw line-height constants, unless documenting token internals.

## Use When

- Calculating Typography tokens.
- Explaining why body text and headings have different vertical rhythm.
- Reviewing text token consistency.

## Do Not Use When

- A component needs normal body copy; use `Paragraph`.
- A component needs a heading; use `Heading`.
- A component needs compact secondary text; use `Caption`.
- A component should choose arbitrary local line-height values.

## Edge Cases

- If a new text role needs a different line height, create a Design System decision before adding a new token.
- Do not add component-specific line-height constants.
- Keep these values numeric and token-level, not visual examples of every component.

## Accessibility Notes

- Body copy uses `1.5` to preserve comfortable readability.
- Tight line height should not be used for long reading text.
- Text contrast and size still need separate checks.

## Related Components And Patterns

- `Typography`: the only token family that directly consumes Line Heights.
- `Paragraph`: consumes Body typography, which uses body line height.
- `Heading`: consumes heading typography, which uses tight line height.
- `Caption`: consumes Caption typography, which uses tight line height.

## Code Paths

- `apps/portfolio-site/src/pages/design-system/index.astro`
- `packages/design-system/src/styles/tokens.css`
