/*!
 * latn.css — lightweight tweaks for Latin-script languages
 * Load AFTER your main theme.css when <html class="script-Latn">.
 * Keep this minimal; most layout is identical to your default LTR styles.
 * If you already like your typography, this file can be EMPTY.
 */

/* -------------------- Global Latin typography polish -------------------- */
.script-Latn body{
  /* Comfortable reading rhythm for Latin text */
  line-height: 1.55;
  letter-spacing: 0;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;

  /* Turn on common OpenType features when available */
  font-kerning: normal;
  font-variant-ligatures: common-ligatures contextual;
  font-feature-settings: "kern" 1, "liga" 1, "clig" 1, "calt" 1;
}

/* Headings: crisp but not cramped */
.script-Latn h1, .script-Latn h2, .script-Latn h3{
  line-height: 1.25;
  letter-spacing: .005em; /* tiny tracking to help bold headings */
}

/* Paragraphs & long text blocks */
.script-Latn p{
  hyphens: auto;            /* enable soft hyphenation for justified/long lines */
  -webkit-hyphens: auto;
  overflow-wrap: break-word; /* prevent overflow on long URLs/strings */
  word-break: normal;
}

/* Small text: keep legible */
.script-Latn small{ letter-spacing: 0; }

/* Numeric/UI alignment in tables, dashboards, etc. */
.script-Latn table,
.script-Latn .table{
  font-variant-numeric: tabular-nums; /* align digits in columns */
}

/* Code/monospace stacks tuned for Latin UI */
.script-Latn code,
.script-Latn pre,
.script-Latn kbd,
.script-Latn samp{
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", "DejaVu Sans Mono", monospace;
  font-feature-settings: "liga" 0; /* avoid programming ligatures unless you want them */
}

/* Links: sensible underline position */
.script-Latn a{
  text-underline-position: from-font;
  text-underline-offset: 0.12em;
}

/* Buttons/chips in ALL CAPS: modest tracking so they don’t look cramped */
.script-Latn .btn.text-uppercase,
.script-Latn .badge.text-uppercase{
  letter-spacing: .06em;
}

/* Lists: use logical padding for consistency with RTL/LTR */
.script-Latn ul,
.script-Latn ol{
  padding-inline-start: 1.25rem;
}

/* Optional: fine-tune placeholder readability */
.script-Latn ::placeholder{
  letter-spacing: 0;
  opacity: .7;
}

/* Reduce motion if user prefers (mirrors your base behavior) */
@media (prefers-reduced-motion: reduce){
  .script-Latn *{
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
}
