/*
  One font per feeling. All use Playwrite France Moderne for now: change them one at a time.

  Each feeling uses its font for its words in the word clouds, its button in
  the feeling list, its word chips, the tooltip and the word card's title.

  To change a feeling's font:
    1. Add an @import line for the font, below the Playwrite France Moderne one. For Google
       Fonts, pick the font on fonts.google.com and copy the URL from "Get embed
       code". A local or system font needs no @import.
    2. Change its --font-<id> value below. Keep var(--font-fallback) after it, and
       a generic family at the end (serif, sans-serif, monospace, cursive).
    3. Reload the page. No rebuild is needed.

  The <id> is the feeling's "id" in feelings.json. If a feeling has no
  --font-<id>, it uses the site's body font, DM Sans.

  Scripts the words need (see README, "Fonts"):
    Latin, including latin-ext and the dotted letters of Arabic romanization
      (ḩ ḍ ḑ ẖ ḧ, as in "Sayḩ as Salm"); Cyrillic; Han (Simplified and
      Traditional); Hangul.
  Pick feeling fonts with the latin-ext subset on Google Fonts. Anything a
  feeling's font doesn't have, letter by letter, comes from --font-fallback.
*/

/* All feelings use Playwrite France Moderne for now. To give a feeling
   its own font, add its @import here and change its --font-<id> below. */
@import url('https://fonts.googleapis.com/css2?family=Playwrite+FR+Moderne:wght@100..400&display=swap');

/* Fallbacks for letters and scripts the feeling fonts don't have. Google serves
   these in pieces by character range, so a browser only downloads the pieces
   for characters on the page. */
/* fallback */ @import url('https://fonts.googleapis.com/css2?family=Noto+Sans:wght@400;700&family=Noto+Sans+SC:wght@400;700&family=Noto+Sans+TC:wght@400;700&family=Noto+Sans+KR:wght@400;700&display=swap');

:root {
  /* Noto Sans: Latin (all of latin-ext, including ḩ ḍ ḑ ẖ ḧ) and Cyrillic, in a
     sans serif. It comes first so that Cyrillic is always sans serif.
     Noto Sans SC, then TC: Han, Simplified then Traditional. Noto Sans KR: Hangul. */
  --font-fallback: "Noto Sans", "Noto Sans SC", "Noto Sans TC", "Noto Sans KR";

  /* Line height for text in the feeling fonts, in font sizes. Playwrite's
     letters reach about 1.12 above the baseline and 0.62 below it, so lines
     need about 1.75 to keep descenders off the line below. Change it with the
     fonts: about 1.2 suits an ordinary font. */
  --feeling-line: 1.75;

  /* The site's title, in the same font as the feeling words. */
  --font-title: "Playwrite FR Moderne", var(--font-fallback), cursive;

  --font-love:   "Playwrite FR Moderne", var(--font-fallback), cursive;
  --font-joy:    "Playwrite FR Moderne", var(--font-fallback), cursive;
  --font-hope:   "Playwrite FR Moderne", var(--font-fallback), cursive;
  --font-wonder: "Playwrite FR Moderne", var(--font-fallback), cursive;
  --font-calm:   "Playwrite FR Moderne", var(--font-fallback), cursive;
  --font-lonely: "Playwrite FR Moderne", var(--font-fallback), cursive;
  --font-sorrow: "Playwrite FR Moderne", var(--font-fallback), cursive;
  --font-anger:  "Playwrite FR Moderne", var(--font-fallback), cursive;
  --font-fear:   "Playwrite FR Moderne", var(--font-fallback), cursive;
}
