/* ============================================================================
 * Procella Room Designer — SELF-HOSTED UI FACES
 * Added 2026-10-30, replacing the Google Fonts link in index.html.
 *
 * WHY THIS FILE EXISTS AND NOT A BLOCK IN procella-tokens.css: that file is
 * GENERATED by build_brandkit.py and says so at the top. An @font-face block
 * added there would survive until the next brand-kit build and then vanish,
 * silently, with the symptom appearing as "the fonts stopped working" weeks
 * later. One file, one job, hand-maintained.
 *
 * WHAT CHANGED, AND WHY IT IS A WIN RATHER THAN A TRADE
 * The app previously fetched Montserrat and JetBrains Mono from Google. That
 * cost TWO third-party origins on the critical path — fonts.googleapis.com for
 * a render-blocking stylesheet, then fonts.gstatic.com for the files, each with
 * its own DNS lookup and TLS handshake — before any text could be painted.
 *
 * The obvious objection to self-hosting was payload: the woff2 files already in
 * ui/fonts/ carry Montserrat's full charset at 79 KB per weight, 316 KB for
 * four, where Google serves a latin subset at roughly a fifth of that. Measured
 * rather than assumed, and subsetting settles it:
 *
 *     Montserrat, 4 weights   full 315.6 KB  ->  latin subset  69.1 KB
 *     Bebas Neue              full  20.6 KB  ->  latin subset  11.5 KB
 *     JetBrains Mono 400/600                      latin subset  42.0 KB
 *     ---------------------------------------------------------------
 *     whole UI face set                                       122.6 KB
 *
 * That is the same order of bytes Google was sending, from our own origin,
 * under the year-long immutable cache netlify.toml already sets — so it is free
 * on every visit after the first, which Google's files were not.
 *
 * TWO FONT SETS, DELIBERATELY. ui/fonts/*.woff2 stay FULL-CHARSET and are
 * untouched: the EXPORT embeds them in the PDF, and a PDF may carry a client or
 * project name with any character in it. Subsetting those would produce missing
 * glyphs in a document nobody checks until it is in front of a client. The
 * subsets here are for the SCREEN only, where the content is the app's own
 * English interface.
 *
 * font-display:swap throughout. The export's own @font-face uses `block`,
 * correctly — a PDF must not rasterise mid-swap. On screen the opposite is
 * wanted: text readable immediately, reflowed when the face lands.
 *
 * LICENCES. All three families are SIL Open Font License 1.1. Montserrat and
 * Bebas Neue were already in the build; JetBrains Mono is new, taken from the
 * @fontsource/jetbrains-mono package at 5.0.21. See ui/fonts/NOTICE.txt.
 * ========================================================================= */

@font-face{
  font-family:'Montserrat'; font-style:normal; font-weight:400; font-display:swap;
  src:url('fonts/ui/Montserrat-Regular.woff2') format('woff2');
}
@font-face{
  font-family:'Montserrat'; font-style:normal; font-weight:500; font-display:swap;
  src:url('fonts/ui/Montserrat-Medium.woff2') format('woff2');
}
@font-face{
  font-family:'Montserrat'; font-style:normal; font-weight:600; font-display:swap;
  src:url('fonts/ui/Montserrat-SemiBold.woff2') format('woff2');
}
@font-face{
  font-family:'Montserrat'; font-style:normal; font-weight:700; font-display:swap;
  src:url('fonts/ui/Montserrat-Bold.woff2') format('woff2');
}

/* BEBAS NEUE — the face the skin asks for and nothing ever delivered.
   procella-skin.css sets font-family:'Bebas Neue' in three rules, but the font
   had no @font-face in the app and was not in the Google link either, which
   asked only for Montserrat and JetBrains Mono. Every one of those headings has
   been falling through to Montserrat, while the EXPORT rendered them correctly
   from its own declaration against the same file. The screen and the printed
   page disagreed, and nothing said so. */
@font-face{
  font-family:'Bebas Neue'; font-style:normal; font-weight:400; font-display:swap;
  src:url('fonts/ui/BebasNeue-Regular.woff2') format('woff2');
}

/* JETBRAINS MONO — numeric fields and the figure columns. Two weights, matching
   what the Google link requested (400 and 600); no other weight is referenced. */
@font-face{
  font-family:'JetBrains Mono'; font-style:normal; font-weight:400; font-display:swap;
  src:url('fonts/ui/JetBrainsMono-Regular.woff2') format('woff2');
}
@font-face{
  font-family:'JetBrains Mono'; font-style:normal; font-weight:600; font-display:swap;
  src:url('fonts/ui/JetBrainsMono-SemiBold.woff2') format('woff2');
}
