/* Hari Villa — help pages (Features, FAQ, Knowledge Base, Dictionary).
 *
 * Trilingual, three columns side by side on desktop; one column plus a
 * language switch on a phone. The three language versions are all in the
 * markup; which show is decided by CSS, so there is one page, not three
 * routes. Loaded after style.css so it can use the tokens.
 *
 * Layout rule (mobile-first, matching the shell):
 *   phone (<900px): one column, the pills choose the language.
 *   desktop (>=900px): three columns, pills hidden — all languages visible.
 */

/* ---------- language switch (phone only) ---------- */
.help-lang {
  display: flex;
  gap: 0.4rem;
  margin-bottom: 1.1rem;
  flex-wrap: wrap;
}
.help-lang button {
  flex: 1 1 auto;
  min-height: 44px;   /* touch-target floor (was 40px) */
  padding: 0 0.7rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}
.help-lang button[aria-pressed="true"] {
  background: var(--navy);
  border-color: var(--navy);
  color: #fff;
}
.help-lang button:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

/* ---------- columns ---------- */
.help-cols { display: block; }              /* phone: one column */
.help-col { display: none; }                /* phone: only the chosen one */
:root[data-help-lang="en"] .help-col.lang-en,
:root[data-help-lang="hi"] .help-col.lang-hi,
:root[data-help-lang="pa"] .help-col.lang-pa,
:root:not([data-help-lang]) .help-col.lang-en { display: block; }   /* default: English */

/* Indic scripts want the right glyphs and a touch more line-height. Latin
   inside them falls back to Manrope, declared second. */
.lang-hi { font-family: 'Noto Sans Devanagari', 'Manrope', system-ui, sans-serif; }
.lang-pa { font-family: 'Noto Sans Gurmukhi', 'Manrope', system-ui, sans-serif; }
.lang-hi, .lang-pa { line-height: 1.7; }

/* ---------- content ---------- */
.help-lead {
  color: var(--muted);
  font-size: 1.02rem;
  line-height: 1.6;
  margin: 0 0 1.2rem;
}
.help-h {
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 1.6rem 0 0.7rem;
  padding-bottom: 0.3rem;
  border-bottom: 1px solid var(--line);
}
.lang-hi .help-h, .lang-pa .help-h { letter-spacing: 0.02em; text-transform: none; }
.help-item {
  margin: 0 0 0.85rem;
  line-height: 1.6;
  color: var(--ink);
}
.help-item b { color: var(--navy); font-weight: 700; }
.help-item code, .help-def code, .help-card code {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 0 0.25rem;
  font-size: 0.9em;
}

/* Knowledge Base cards */
.help-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.9rem 1rem;
  margin: 0 0 0.9rem;
}
.help-card h2 { font-size: 1rem; margin: 0 0 0.6rem; color: var(--navy); }
.help-card p { margin: 0 0 0.6rem; line-height: 1.6; }
.help-card ol { margin: 0.2rem 0 0; padding-left: 1.2rem; }
.help-card ol li { margin: 0 0 0.5rem; line-height: 1.55; }

/* Dictionary rows */
.help-term { margin: 0 0 0.9rem; line-height: 1.55; }
.help-term b { color: var(--navy); display: block; }

/* The Punjabi-is-new note, Punjabi column only */
.help-note {
  background: #FCFAF2;
  border: 1px solid var(--gold);
  border-radius: 8px;
  padding: 0.55rem 0.75rem;
  font-size: 0.9rem;
  color: var(--amber);
  margin: 0 0 1.1rem;
  line-height: 1.6;
}

/* The help links are a second footer row beneath the module links — same
   styling (they inherit .site-footer a), forced onto their own line. */
.site-footer-help { flex-basis: 100%; display: flex; flex-wrap: wrap; gap: 0.9rem; margin: 0; }

@media (min-width: 900px) {
  .help-lang { display: none; }             /* desktop: no switch needed */
  .help-cols {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.6rem;
    align-items: start;
  }
  .help-col { display: block; }             /* all three columns */
  .help-col + .help-col { border-left: 1px solid var(--line); padding-left: 1.6rem; }
}
