# Fonts

One file belongs here and it is not in the repository:

    noto-sans-bengali-subset.woff2

`app/globals.css` declares it with `font-display: swap` and a `unicode-range` covering
`U+0980-09FF`, `U+200C-200D` and `U+25CC`. Until the file exists the browser falls back to
whatever Bangla face the device has, so the site works without it — it just looks like three
different devices rendering three different fonts.

## Producing it

Noto Sans Bengali is SIL OFL 1.1, so it may be redistributed with this application. Subset it
rather than shipping the full family — the unsubsetted variable font is around 250 KB, and the
invitation page has an 800 KB budget for *everything*.

```bash
pip install fonttools brotli
pyftsubset NotoSansBengali-VariableFont_wdth,wght.ttf \
  --output-file=noto-sans-bengali-subset.woff2 \
  --flavor=woff2 \
  --layout-features='*' \
  --unicodes='U+0980-09FF,U+200C-200D,U+25CC'
```

`--layout-features='*'` is not optional padding. Bangla conjuncts are produced by GSUB
substitutions; drop the layout tables and words render as their component letters side by side,
which is wrong in a way that looks like a typo rather than a font problem.

## Checking it

The invitation's Bangla greeting is the fastest test — open any invitation with `?lang=bn` and
confirm the greeting and the card's Bangla text render in the same face. The card's shadow root
blocks selectors but not inheritance, so it picks this up through `font-family: inherit` on
`:host` without the designer referencing any font themselves.
