/* हिन्दी (hi) overrides.
 *
 * Loaded by header.php only when the page is in this language, so no other visitor
 * downloads it. Everything is scoped to html[lang="hi"] and cannot leak.
 *
 * Hindi, in Devanagari. Inter has no Devanagari, so it falls through to the system face.
 * Measured against the English: the median string is 101% of the English length.
 */

/* What js/main.js reads about this language's script:
   --pot-letter-split: off   hero headlines are not animated letter by letter: splitting
                             the text into single letters breaks this script
   --pot-heading-wrap-lh     line height of a heading that wraps (1.3 if not set) */
html[lang="hi"] { --pot-letter-split: off; --pot-heading-wrap-lh: 1.55; }

/* Latin stays in the site's own Inter; this script falls through to the system face named
   here. Setting the theme's two font variables reaches everything styled with them. */
html[lang="hi"] {
    --primary-font: "Inter", "Noto Sans Devanagari", "Nirmala UI", "Kohinoor Devanagari", "Mangal", sans-serif;
    --alt-font: "Inter", "Noto Sans Devanagari", "Nirmala UI", "Kohinoor Devanagari", "Mangal", sans-serif;
}
html[lang="hi"] :is(body, input, textarea, select, button, .btn) {
    font-family: var(--primary-font);
}

/* Marks above and below the line need more room than the Latin line height gives. */
html[lang="hi"] :is(body, p, li) { line-height: 1.85; }
/* Small headings set with a size utility (an h3 at fs-20) keep the theme's 50px line: it is what
   spaces them. main.js tightens them only when they wrap, to --pot-heading-wrap-lh. */
html[lang="hi"] :is(h1, h2, h3, h4, h5, h6):not(.fs-12, .fs-13, .fs-14, .fs-15, .fs-16, .fs-17, .fs-18, .fs-19, .fs-20, .fs-22, .fs-24, .fs-26, .fs-2, .fs-3, .fs-4, .fs-5, .fs-6) { line-height: 1.45; }

/* Tracking and synthetic italics were chosen for Latin. On this script tracking pulls
   apart clusters that belong together, and there is no true italic -- the browser only
   slants the glyphs. Icon fonts rely on <i> and are exempt. */
html[lang="hi"] :is(.btn, .pot-lang-toggle, .pot-lang-soon) { letter-spacing: 0; }
/* headings and the ls-* utilities: those utilities carry !important */
html[lang="hi"] :is(h1, h2, h3, h4, h5, h6, [class*="ls-"], .text-uppercase) { letter-spacing: 0 !important; }
html[lang="hi"] :is(em, i:not([class*="icon"]):not([class*="fa-"]):not([class*="bi-"]):not([class*="feather"])) {
    font-style: normal;
    font-weight: 600;
}

/* Buttons whose English label is one word and whose translation is two or three. */
html[lang="hi"] :is(.btn.btn-switch-text.btn-small, .btn.btn-switch-text.btn-very-small, .btn.btn-medium) > span {
    white-space: normal;
    line-height: 1.3;
}

/* Plan cards keep each feature on one line; translated feature names need a second
   line rather than an ellipsis. */
html[lang="hi"] :is(#vps-features-list li, .pot-plan-feature) {
    white-space: normal;
    line-height: 1.5;
}
