/* Self-hosted Noto fonts for the Indian scripts (SIL Open Font License, see /fonts/OFL-LICENSE.txt).
   Each face has a unicode-range, so a font file is downloaded only when text in that script is on the page.
   The app's Content-Security-Policy only allows fonts from this origin, so Google Fonts cannot be used. */
@font-face { font-family: "UPSC Devanagari"; src: url("/fonts/noto-sans-devanagari.woff2") format("woff2"); font-weight: 100 900; font-display: swap; unicode-range: U+0900-097F, U+1CD0-1CF9, U+200C-200D, U+20B9, U+25CC, U+A830-A839, U+A8E0-A8FF; }
@font-face { font-family: "UPSC Bengali"; src: url("/fonts/noto-sans-bengali.woff2") format("woff2"); font-weight: 100 900; font-display: swap; 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: "UPSC Gujarati"; src: url("/fonts/noto-sans-gujarati.woff2") format("woff2"); font-weight: 100 900; font-display: swap; unicode-range: U+0951-0952, U+0964-0965, U+0A81-0AFF, U+200C-200D, U+20B9, U+25CC, U+A830-A839; }
@font-face { font-family: "UPSC Gurmukhi"; src: url("/fonts/noto-sans-gurmukhi.woff2") format("woff2"); font-weight: 100 900; font-display: swap; unicode-range: U+0951-0952, U+0964-0965, U+0A01-0A76, U+200C-200D, U+20B9, U+25CC, U+262C, U+A830-A839; }
@font-face { font-family: "UPSC Kannada"; src: url("/fonts/noto-sans-kannada.woff2") format("woff2"); font-weight: 100 900; font-display: swap; unicode-range: U+0951-0952, U+0964-0965, U+0C80-0CF3, U+1CD0, U+1CD2, U+1CDA, U+1CF2, U+200C-200D, U+20B9, U+25CC; }
@font-face { font-family: "UPSC Malayalam"; src: url("/fonts/noto-sans-malayalam.woff2") format("woff2"); font-weight: 100 900; font-display: swap; unicode-range: U+0951-0952, U+0964-0965, U+0D00-0D7F, U+1CDA, U+200C-200D, U+20B9, U+25CC; }
@font-face { font-family: "UPSC Odia"; src: url("/fonts/noto-sans-oriya.woff2") format("woff2"); font-weight: 100 900; font-display: swap; unicode-range: U+0951-0952, U+0964-0965, U+0B01-0B77, U+1CDA, U+1CF2, U+200C-200D, U+20B9, U+25CC; }
@font-face { font-family: "UPSC Tamil"; src: url("/fonts/noto-sans-tamil.woff2") format("woff2"); font-weight: 100 900; font-display: swap; unicode-range: U+0951-0952, U+0964-0965, U+0B82-0BFA, U+200C-200D, U+20B9, U+25CC; }
@font-face { font-family: "UPSC Telugu"; src: url("/fonts/noto-sans-telugu.woff2") format("woff2"); font-weight: 100 900; font-display: swap; unicode-range: U+0951-0952, U+0964-0965, U+0C00-0C7F, U+1CDA, U+1CF2, U+200C-200D, U+20B9, U+25CC; }
@font-face { font-family: "UPSC Nastaliq"; src: url("/fonts/noto-nastaliq-urdu-400.woff2") format("woff2"); font-weight: 400 500; font-display: swap; unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF, U+200C-200F; }
@font-face { font-family: "UPSC Nastaliq"; src: url("/fonts/noto-nastaliq-urdu-600.woff2") format("woff2"); font-weight: 600 900; font-display: swap; unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF, U+200C-200F; }

/* The script fonts sit at the end of the stack: Latin text keeps the app font, Indian scripts use these. */
:root { --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Inter", "UPSC Devanagari", "UPSC Bengali", "UPSC Gujarati", "UPSC Gurmukhi", "UPSC Kannada", "UPSC Malayalam", "UPSC Odia", "UPSC Tamil", "UPSC Telugu", "UPSC Nastaliq", "Noto Sans Devanagari", "Nirmala UI", sans-serif; }

/* Tall scripts need more line height or the marks collide. */
html[lang="ta"] body, html[lang="te"] body, html[lang="kn"] body, html[lang="ml"] body, html[lang="or"] body,
html[lang="bn"] body, html[lang="as"] body, html[lang="gu"] body, html[lang="pa"] body { line-height: 1.7; }
html[lang="ur"] body, html[lang="ks"] body, html[lang="sd"] body { line-height: 2; }

/* Right-to-left languages (Urdu, Kashmiri, Sindhi): mirror text direction and the main layout. */
html[dir="rtl"] body { text-align: start; }
html[dir="rtl"] .dash-row, html[dir="rtl"] .plan-check, html[dir="rtl"] .plan-bar, html[dir="rtl"] .plan-log { direction: rtl; }
html[dir="rtl"] input[type="email"], html[dir="rtl"] input[type="password"], html[dir="rtl"] input[type="number"], html[dir="rtl"] .ql-editor { direction: ltr; text-align: start; }

/* Language picker */
.lang-picker { display: block; font-size: 13px; font-weight: 600; margin: 8px 0; color: var(--color-text-secondary); }
.lang-picker select { display: block; width: 100%; margin-top: 4px; min-height: 36px; }
.auth-card .lang-picker { margin-top: 14px; }
