/* Hebrew (right-to-left) typography for the /he/ pages and the client portal.
   Layouts mirror on their own: the page styles use logical properties.
   Hebrew text is set in Heebo (400/500/700). Text marked lang="en" (the brand
   line, the headline) keeps the site's Latin fonts. */
:root:lang(he) {
  --font-display: "Heebo", "Archivo", system-ui, sans-serif;
  --font-body: "Heebo", "Source Sans 3", system-ui, sans-serif;
}
:root:lang(he) body { line-height: 1.7; }
:where(:root:lang(he) [lang="en"]) {
  --font-display: "Archivo", "Heebo", system-ui, sans-serif;
  --font-body: "Source Sans 3", "Heebo", system-ui, sans-serif;
  font-family: var(--font-body);
}
:root:lang(he) :is(.logo, .login-brand, .app-brand) [lang="en"] { font-family: var(--font-display); }

/* Hebrew has no capitals: small labels drop the wide letter-spacing. */
:lang(he):is(.eyebrow, .chart-tag, .chart-stats dt, .direct dt, .pm-day,
  .kind, .day-head, .pill, .coach-msg .label, .set-cols, .tag, .summary dt, .report-body h3) {
  letter-spacing: normal;
}

/* Hebrew has no true italics; a slanted Heebo reads poorly. */
:lang(he):is(.draft-note, .rest) { font-style: normal; }

/* The note after the automatic switch to Hebrew (assets/lang.js). */
.lang { position: relative; }
.lang-note {
  position: absolute; inset-block-start: calc(100% + 10px); inset-inline-end: 0; z-index: 60;
  inline-size: max-content; max-inline-size: min(280px, calc(100vw - 32px)); margin: 0;
  padding: 10px 14px; border-radius: 10px; background: var(--surface); color: var(--navy-700);
  box-shadow: var(--shadow-lg); font-size: .9rem; line-height: 1.5; white-space: normal; cursor: pointer;
}
.lang .lang-note a { display: inline; min-inline-size: 0; min-block-size: 0; color: var(--accent); font-weight: 700; font-family: "Source Sans 3", sans-serif; text-decoration: underline; }
.lang .lang-note a:hover { background: none; }
