/*
 * Self-hosted Bengali web font (Noto Sans Bengali), added because the app's
 * default font — "Source Sans Pro" (see public/fonts/google-fonts/google-fonts.css)
 * — has ZERO Bengali glyphs, and the rest of its fallback chain in
 * public/css/init.css ('Helvetica Neue', Helvetica, Arial, sans-serif) has none
 * either. With no Bengali-capable font anywhere in the stack, every browser was
 * falling all the way through to whatever Bengali system font (if any) happened
 * to be installed on that specific device — which is why Bengali text rendered
 * fine on some devices/browsers and broke (tofu boxes / missing glyphs) on
 * others after deploying to the server.
 *
 * Fix: bundle the font file itself (woff2 + woff fallback, ~300KB total for
 * regular + bold) so every device gets the exact same glyphs regardless of
 * what's installed locally or whether Google Fonts' CDN is reachable from
 * that device/network.
 */

@font-face {
  font-family: 'Noto Sans Bengali';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/noto-sans-bengali/noto-sans-bengali-bengali-400-normal.woff2') format('woff2'),
       url('../fonts/noto-sans-bengali/noto-sans-bengali-bengali-400-normal.woff') format('woff');
  unicode-range: U+0951-0952, U+0964-0965, U+0980-09FE, U+1CD0, U+1CD2, U+1CD5-1CD6, U+1CD8, U+1CE1, U+1CEA, U+1CED, U+1CF2, U+1CF5-1CF7, U+200C-200D, U+20B9, U+25CC, U+A8F1;
}

@font-face {
  font-family: 'Noto Sans Bengali';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../fonts/noto-sans-bengali/noto-sans-bengali-bengali-700-normal.woff2') format('woff2'),
       url('../fonts/noto-sans-bengali/noto-sans-bengali-bengali-700-normal.woff') format('woff');
  unicode-range: U+0951-0952, U+0964-0965, U+0980-09FE, U+1CD0, U+1CD2, U+1CD5-1CD6, U+1CD8, U+1CE1, U+1CEA, U+1CED, U+1CF2, U+1CF5-1CF7, U+200C-200D, U+20B9, U+25CC, U+A8F1;
}

@font-face {
  font-family: 'Noto Sans Bengali';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/noto-sans-bengali/noto-sans-bengali-latin-ext-400-normal.woff2') format('woff2'),
       url('../fonts/noto-sans-bengali/noto-sans-bengali-latin-ext-400-normal.woff') format('woff');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: 'Noto Sans Bengali';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../fonts/noto-sans-bengali/noto-sans-bengali-latin-ext-700-normal.woff2') format('woff2'),
       url('../fonts/noto-sans-bengali/noto-sans-bengali-latin-ext-700-normal.woff') format('woff');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: 'Noto Sans Bengali';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/noto-sans-bengali/noto-sans-bengali-latin-400-normal.woff2') format('woff2'),
       url('../fonts/noto-sans-bengali/noto-sans-bengali-latin-400-normal.woff') format('woff');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: 'Noto Sans Bengali';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../fonts/noto-sans-bengali/noto-sans-bengali-latin-700-normal.woff2') format('woff2'),
       url('../fonts/noto-sans-bengali/noto-sans-bengali-latin-700-normal.woff') format('woff');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/*
 * Apply it site-wide, ahead of the old Latin-only stack. For English text the
 * browser still picks Source Sans Pro (this font's own Latin subset above is
 * just a safety net); for Bengali text it now always has real glyphs to use,
 * on every device, with or without internet access to Google Fonts.
 */
html, body {
  font-family: 'Noto Sans Bengali', 'Source Sans Pro', 'Helvetica Neue', Helvetica, Arial, sans-serif !important;
}
