/* Nice Have Coffee Menu — Stage 6UX.5 Multilingual Typography System
 *
 * English (en):
 *   Headings, body, navigation, buttons & product info -> LINE Seed Sans TH
 * Khmer (km):
 *   Headings & titles -> Moulpali (400, no faux bold)
 *   Body, descriptions, navigation & controls -> Hanuman (400, 700)
 * Simplified Chinese (zh-Hans):
 *   Headings & titles -> ZCOOL QingKe HuangYou (400, no faux bold)
 *   Body, descriptions, navigation & controls -> Noto Sans SC (400..700)
 */

:root {
  --font-en: 'LINE Seed Sans TH', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-km-heading: 'Moulpali', 'Hanuman', 'Noto Sans Khmer', serif;
  --font-km-body: 'Hanuman', 'Noto Sans Khmer', 'LINE Seed Sans TH', sans-serif;
  --font-zh-heading: 'ZCOOL QingKe HuangYou', 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  --font-zh-body: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', 'LINE Seed Sans TH', sans-serif;

  --font-heading: var(--font-en);
  --font-body: var(--font-en);
  --font-heading-weight: 700;
  --font-heading-lh: 1.22;
  --font-heading-ls: -0.015em;
  --font-body-lh: 1.5;
}

:lang(en) {
  --font-heading: var(--font-en);
  --font-body: var(--font-en);
  --font-heading-weight: 700;
  --font-heading-lh: 1.2;
  --font-heading-ls: -0.015em;
  --font-body-lh: 1.5;
}

:lang(km) {
  --font-heading: var(--font-km-heading);
  --font-body: var(--font-km-body);
  --font-heading-weight: 400;
  --font-heading-lh: 1.48;
  --font-heading-ls: 0;
  --font-body-lh: 1.72;
}

:lang(zh-Hans),
:lang(zh) {
  --font-heading: var(--font-zh-heading);
  --font-body: var(--font-zh-body);
  --font-heading-weight: 400;
  --font-heading-lh: 1.3;
  --font-heading-ls: 0.02em;
  --font-body-lh: 1.62;
}

body {
  font-family: var(--font-body);
  line-height: var(--font-body-lh);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

button,
input,
select,
textarea {
  font-family: var(--font-body);
}

h1,
h2,
h3,
.brand-text h1,
.hero-title,
.section-head h2,
.sheet-title,
.topbar-title,
.panel-head h2,
.drawer-title,
.empty-state h3 {
  font-family: var(--font-heading);
  font-weight: var(--font-heading-weight);
  line-height: var(--font-heading-lh);
  letter-spacing: var(--font-heading-ls);
}

/* Prevent browser faux-bold distortion on single-weight display fonts (Moulpali & ZCOOL QingKe HuangYou) */
:lang(km) h1,
:lang(km) h2,
:lang(km) h3,
:lang(km) .brand-text h1,
:lang(km) .hero-title,
:lang(km) .section-head h2,
:lang(km) .sheet-title,
:lang(km) .topbar-title {
  font-synthesis-weight: none;
  font-weight: 400;
}

:lang(zh-Hans) h1,
:lang(zh-Hans) h2,
:lang(zh-Hans) h3,
:lang(zh-Hans) .brand-text h1,
:lang(zh-Hans) .hero-title,
:lang(zh-Hans) .section-head h2,
:lang(zh-Hans) .sheet-title,
:lang(zh-Hans) .topbar-title {
  font-synthesis-weight: none;
  font-weight: 400;
}

/* Product card titles keep body font for crisp 2-line legibility on 360px mobile in Khmer/Chinese,
   while English uses LINE Seed Sans TH Bold */
:lang(en) .card-name,
:lang(en) .product-name {
  font-family: var(--font-en);
  font-weight: 700;
  line-height: 1.25;
}

:lang(km) .card-name,
:lang(km) .product-name {
  font-family: var(--font-km-heading);
  font-weight: 400;
  font-synthesis-weight: none;
  line-height: 1.45;
}

:lang(zh-Hans) .card-name,
:lang(zh-Hans) .product-name {
  font-family: var(--font-zh-heading);
  font-weight: 400;
  font-synthesis-weight: none;
  line-height: 1.32;
  letter-spacing: 0.02em;
}

/* Numeric prices & size badges use tabular numerals for clean alignment */
.price-badge,
.sheet-price,
.price,
.stat-value {
  font-variant-numeric: tabular-nums;
}
